Commit d298487
committed
Handle BucketAlreadyOwnedByYou race condition in S3 bucket initialization
The default S3 bucket name is deterministic per account+region, so
concurrent cluster creation calls (e.g. parallel integration tests)
can race: multiple callers get a 404 from head_bucket, then all
attempt create_bucket. The first succeeds; the rest fail with
BucketAlreadyOwnedByYou, which was previously unhandled and surfaced
as "Unable to initialize s3 bucket."
Treat BucketAlreadyOwnedByYou as a success condition since it confirms
the bucket exists and is owned by the caller, which is the desired
end state. Log at info level and proceed normally.1 parent 6870bc8 commit d298487
2 files changed
Lines changed: 11 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
4 | 10 | | |
5 | 11 | | |
6 | 12 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
478 | 478 | | |
479 | 479 | | |
480 | 480 | | |
481 | | - | |
482 | | - | |
| 481 | + | |
| 482 | + | |
| 483 | + | |
| 484 | + | |
| 485 | + | |
483 | 486 | | |
484 | 487 | | |
485 | 488 | | |
| |||
0 commit comments