Can we do write-object-if-not-exist in S3 similar to conditional put in Dynamo DB?

1

I have a use case, where I need to avoid overriding the objects. I do understand that because of the distributed nature of the S3, it might not available. Are there any tricks and hacky way to achieve not to override the object in S3 ?

Dynamo DB is also distributed, but it provides conditional put. Wondering what is the architectural difference between Dynamo DB and S3 ?

質問済み 2年前3986ビュー
2回答
0

S3 Natively does not have any conditions that would satisfy this for the PutObject but what you could consider is making a HeadObject request first and if the object does not exist (404 - requires the writer to have s3:ListBucket permission) then continue with the PutObject.

AWS
サポートエンジニア
Suran_N
回答済み 2年前
0
回答済み 8ヶ月前

ログインしていません。 ログイン 回答を投稿する。

優れた回答とは、質問に明確に答え、建設的なフィードバックを提供し、質問者の専門分野におけるスキルの向上を促すものです。

質問に答えるためのガイドライン

関連するコンテンツ