Skip to content

Commit 1b7bdf5

Browse files
Add 5s to the billing project wait + network deletion retry wait in google_project (#12779) (#9103)
[upstream:d5d5cd3ce9eb18be29821d8b40bdce975da2243b] Signed-off-by: Modular Magician <[email protected]>
1 parent 1b2822f commit 1b7bdf5

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

.changelog/12779.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
```release-note:bug
2+
resourcemanager: added a slightly longer wait (two 10s checks bumped to 15s) for issues with billing associations in `google_project`. Default network deletion should succeed more often.
3+
```

google-beta/services/resourcemanager/resource_google_project.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -218,9 +218,9 @@ func resourceGoogleProjectCreate(d *schema.ResourceData, meta interface{}) error
218218
}
219219
}
220220

221-
// Sleep for 10s, letting the billing account settle before other resources
221+
// Sleep to let the billing account settle before other resources
222222
// try to use this project.
223-
time.Sleep(10 * time.Second)
223+
time.Sleep(15 * time.Second)
224224

225225
err = resourceGoogleProjectRead(d, meta)
226226
if err != nil {
@@ -247,7 +247,7 @@ func resourceGoogleProjectCreate(d *schema.ResourceData, meta interface{}) error
247247
err = forceDeleteComputeNetwork(d, config, project.ProjectId, "default")
248248
// Retry if API is not yet enabled.
249249
if err != nil && transport_tpg.IsGoogleApiErrorWithCode(err, 403) {
250-
time.Sleep(10 * time.Second)
250+
time.Sleep(15 * time.Second)
251251
err = forceDeleteComputeNetwork(d, config, project.ProjectId, "default")
252252
}
253253
if err != nil {

0 commit comments

Comments
 (0)