Re: The RGW create new bucket instance then delete it at every create bucket OP

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

 



Hello,

the following code snippet from rgw_rados.cc shows the problem.

RGWRados::create_bucket(...)
{
    ...
    ...
    ret = put_linked_bucket_info(info, exclusive, ceph::real_time(), pep_objv, &attrs, true);
    if (ret == -EEXIST) {
    ...
    // if the bucket has exist, the new bucket instance will be deleted here.
    ...
    }
}

RGWCreateBucket::execute()
{
   ...
   op_ret = store->get_bucket_info(obj_ctx, s->bucket_tenant, s->bucket_name, s->bucket_info, NULL, &s->bucket_attrs);
   //we can know if the bucket exists.  I think that the RGW should not continue to call the function "create_bucket" and return directly if the bucket exists.
   ...

   ...

   op_ret = store->create_bucket(...
   ...
}

Thanks!

2016-05-18 16:32 GMT+08:00 Saverio Proto <zioproto@xxxxxxxxx>:
Hello,

I am not sure I understood the problem.
Can you post the example steps to reproduce the problem ?

Also what version of Ceph RGW are you running ?

Saverio


2016-05-18 10:24 GMT+02:00 fangchen sun <sunspot0105@xxxxxxxxx>:
> Dear ALL,
>
> I found a problem that the RGW create a new bucket instance and delete
> the bucket instance at every create bucket OP with same name
>
> http://docs.aws.amazon.com/AmazonS3/latest/API/ErrorResponses.html
>
> According to the error code "BucketAlreadyOwnedByYou" from the above
> link, shouldn't the RGW return directly or do nothing when recreate
> the bucket?
> Why do the RGW create a new bucket instance and then delete it?
>
> Thanks for the reply!
> sunfch
> _______________________________________________
> ceph-users mailing list
> ceph-users@xxxxxxxxxxxxxx
> http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

_______________________________________________
ceph-users mailing list
ceph-users@xxxxxxxxxxxxxx
http://lists.ceph.com/listinfo.cgi/ceph-users-ceph.com

[Index of Archives]     [Information on CEPH]     [Linux Filesystem Development]     [Ceph Development]     [Ceph Large]     [Ceph Dev]     [Linux USB Development]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [xfs]


  Powered by Linux