Why am I getting the error "A conflicting conditional operation is currently in progress against this resource" from Amazon S3 when I try to re-create a bucket?
I deleted my Amazon Simple Storage Service (Amazon S3) bucket and I'm trying to create a new bucket with the same name. However, I'm getting this error:
A conflicting conditional operation is currently in progress against this resource. Try again
Why is this happening?
After you send a request to delete a bucket, Amazon S3 queues the bucket name for deletion. A bucket name must be globally unique because the namespace is shared by all AWS accounts. Because Amazon S3 is a large distributed system, changes like deleting a bucket can take time to become eventually consistent across all AWS Regions. You can get the error "A conflicting conditional operation is currently in progress" if you try to create a new bucket with the same name during the process of deleting the original bucket.
Until the bucket is completely deleted by Amazon S3, you can't use the same bucket name. However, when the bucket is deleted and the name is available, other accounts can use the bucket name. If another account uses the bucket name before you do, you won't be able to use the bucket name.
Note: If you must keep a bucket name, you can empty the bucket instead of deleting it.
If your application automatically creates buckets, be sure to choose a bucket-naming logic that's unlikely to cause naming conflicts. Additionally, verify that your application's logic chooses a different bucket name when a bucket name is already taken.