We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 7512650 commit 302dba5Copy full SHA for 302dba5
src/storage/examples/src/quickstart.rs
@@ -13,6 +13,7 @@
13
// limitations under the License.
14
15
// [START storage_quickstart]
16
+use google_cloud_gax::options::RequestOptionsBuilder;
17
use google_cloud_storage::{client::StorageControl, model::Bucket};
18
19
pub async fn sample(
@@ -30,6 +31,8 @@ pub async fn sample(
30
31
.set_storage_class("STANDARD")
32
.set_location("US"),
33
)
34
+ // This is an idempotent request: it can only succeed once.
35
+ .with_idempotency(true)
36
.send()
37
.await?;
38
println!("successfully created bucket {bucket:?}");
0 commit comments