Re: Duplicate bucket creation Response in RGW

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I understand here the major concern is for the clients who have
developed their apps keeping in mind 200 OK as the response in
duplicate bucket creation. However 409 can be useful in a scenario
which can be derived as below:

A customer belonging to a company account creates a bucket and fill it with some
files. A colleague of his then tries to create a bucket with the same
name as above with the same keys which are shared by the employees of
that company or a team in particular. Now since he gets 200 OK, he
thinks the bucket is created anew and tries to use it to upload some
modified versions of the previously uploaded files in that bucket, for
his own use. Now the original files will be lost.

In case if he gets 409, he will actually know that there may be some
data in the already created bucket and might check on it before
overriding it.

Since Changing the response to 409 might cause a problem to the
existing customers, we can instead provide a option (boolean probably)
'use_aws_standard_region_responses' which checks whether the region is
standard or different. Default can be true. Existing users can go with
true and we can give option to configure for new users. This flag
might as well used for fixing for other region based discrepancies in
AWS S3.

Thanks,

On Fri, Jun 12, 2015 at 5:21 AM, Yehuda Sadeh-Weinraub
<yehuda@xxxxxxxxxx> wrote:
>
>
> ----- Original Message -----
>> From: "Kyle Bader" <kyle.bader@xxxxxxxxx>
>> To: "Yehuda Sadeh-Weinraub" <yehuda@xxxxxxxxxx>
>> Cc: "Harshal Gupta" <harshal.gupta001@xxxxxxxxx>, "ceph-devel" <ceph-devel@xxxxxxxxxxxxxxx>
>> Sent: Thursday, June 11, 2015 2:22:56 PM
>> Subject: Re: Duplicate bucket creation Response in RGW
>>
>> > I don't see a compelling reason why to change our current behaviour. The
>> > fact that Amazon itself is inconsistent makes me think that it just an
>> > artifact of their architecture, rather than a carefully designed api.
>>
>> Interesting.. if we look at the Amazon S3 FAQ we can understand the
>> differences in API responses:
>>
>> "Q: What data consistency model does Amazon S3 employ?
>>
>> Amazon S3 buckets in the US Standard region provide eventual
>> consistency. Amazon S3 buckets in all other regions provide
>> read-after-write consistency for PUTS of new objects and eventual
>> consistency for overwrite PUTS and DELETES."
>>
>> If we consider buckets in our implementation to be eventually
>> consistent, we should probably return 200. If we can provide
>> read-after-write consistency, then we should probably return 209.
>>
>
> Do they tie the different responses to the different consistency models in the different regions? We're strongly consistent, however, I still think that bucket creation should be idempotent. Impatient client applications tend to retry operations and end up with error responses that can be avoided.
>
> Yehuda



-- 
HARSHAL GUPTA
Software Engineer
KIWI Inc.
--
To unsubscribe from this list: send the line "unsubscribe ceph-devel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [CEPH Users]     [Ceph Large]     [Information on CEPH]     [Linux BTRFS]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux