Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MP initiated objects remains after delete/create buckets #475

Closed
shino opened this issue Mar 8, 2013 · 3 comments
Closed

MP initiated objects remains after delete/create buckets #475

shino opened this issue Mar 8, 2013 · 3 comments

Comments

@shino
Copy link
Contributor

shino commented Mar 8, 2013

commit 304c739 (HEAD, origin/release/1.3, release/1.3)

steps to reproduce:

  1. Create a bucket
  2. Initiate MP upload
  3. Confirm list of MP uploads: 1 object
  4. Delete the bucket
  5. Confirm list of MP uploads: 1 object

Expectation: no objects listed at step 5. (as s3 does)

$ s3cmd mb s3://test-tmp
Bucket 's3://test-tmp/' created
$ s3curl.pl --id local_rcs \
>     --post \
>     -- -s -v -x localhost:8080 \
>     'http://test-tmp.s3.amazonaws.com/test1.txt?uploads'
> POST http://test-tmp.s3.amazonaws.com/test1.txt?uploads HTTP/1.1
> User-Agent: curl/7.27.0
> Host: test-tmp.s3.amazonaws.com
> Accept: */*
> Proxy-Connection: Keep-Alive
> Date: Fri, 08 Mar 2013 05:38:57 +0000
> Authorization: AWS RUY9FSJHGMBQMFU7CITP:vKN22Wd8g/jfe56TrK2uwVDmIZY=
>
< HTTP/1.1 200 OK
< Server: Riak CS
< Date: Fri, 08 Mar 2013 05:38:57 GMT
< Content-Type: application/xml
< Content-Length: 239
<

$ s3curl.pl --id local_rcs \
>     -- -s -v -x localhost:8080 \
>     'http://test-tmp.s3.amazonaws.com/?uploads'
> GET http://test-tmp.s3.amazonaws.com/?uploads HTTP/1.1
> User-Agent: curl/7.27.0
> Host: test-tmp.s3.amazonaws.com
> Accept: */*
> Proxy-Connection: Keep-Alive
> Date: Fri, 08 Mar 2013 05:39:26 +0000
> Authorization: AWS RUY9FSJHGMBQMFU7CITP:sjyDY/WUHBL7IOB0W1SnRH4Nhao=
>
< HTTP/1.1 200 OK
< Server: Riak CS
< Date: Fri, 08 Mar 2013 05:39:26 GMT
< Content-Type: application/xml
< Content-Length: 674
<
<?xml version="1.0" encoding="UTF-8"?><ListMultipartUploadsResult xmlns="http://s3.amazonaws.com/doc/2006-03-01/"><Bucket>test-tmp</Bucket><KeyMarker></KeyMarker><NextKeyMarker/><NextUploadIdMarker></NextUploadIdMarker><Delimiter></Delimiter><Prefix></Prefix><MaxUploads>1000</MaxUploads><IsTruncated>false</IsTruncated><Upload><Key>test1.txt</Key><UploadId>eMevGNjWQxaOcwli5W_mgw==</UploadId><Initiator><ID>RUY9FSJHGMBQMFU7CITP</ID><DisplayName>admin</DisplayName></Initiator><Owner><ID>RUY9FSJHGMBQMFU7CITP</ID><DisplayName>admin</DisplayName></Owner><StorageClass>REGULAR</StorageClass><Initiated>2013-03-08T05:38:57.000Z</Initiated></Upload></ListMultipartUploadsResult>

$ s3curl.pl --id local_rcs \
    -- -s -v -x localhost:8080 \
    'http://test-tmp.s3.amazonaws.com/?uploads' X
> GET http://test-tmp.s3.amazonaws.com/?uploads HTTP/1.1
> User-Agent: curl/7.27.0
> Host: test-tmp.s3.amazonaws.com
> Accept: */*
> Proxy-Connection: Keep-Alive
> Date: Fri, 08 Mar 2013 05:39:31 +0000
> Authorization: AWS RUY9FSJHGMBQMFU7CITP:EVXhWpq3NgBx+upuw6P3QEMVFXw=
>
< HTTP/1.1 200 OK
< Server: Riak CS
< Date: Fri, 08 Mar 2013 05:39:31 GMT
< Content-Type: application/xml
< Content-Length: 674
<
<?xml version="1.0" encoding="UTF-8"?>
<ListMultipartUploadsResult xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
  <Bucket>test-tmp</Bucket>
  <KeyMarker/>
  <NextKeyMarker/>
  <NextUploadIdMarker/>
  <Delimiter/>
  <Prefix/>
  <MaxUploads>1000</MaxUploads>
  <IsTruncated>false</IsTruncated>
  <Upload>
    <Key>test1.txt</Key>
    <UploadId>eMevGNjWQxaOcwli5W_mgw==</UploadId>
    <Initiator>
      <ID>RUY9FSJHGMBQMFU7CITP</ID>
      <DisplayName>admin</DisplayName>
    </Initiator>
    <Owner>
      <ID>RUY9FSJHGMBQMFU7CITP</ID>
      <DisplayName>admin</DisplayName>
    </Owner>
    <StorageClass>REGULAR</StorageClass>
    <Initiated>2013-03-08T05:38:57.000Z</Initiated>
  </Upload>
</ListMultipartUploadsResult>

$ s3cmd rb s3://test-tmp
Bucket 's3://test-tmp/' removed
$ s3curl.pl --id local_rcs \
    -- -s -v -x localhost:8080 \
    'http://test-tmp.s3.amazonaws.com/?uploads' X
> GET http://test-tmp.s3.amazonaws.com/?uploads HTTP/1.1
> User-Agent: curl/7.27.0
> Host: test-tmp.s3.amazonaws.com
> Accept: */*
> Proxy-Connection: Keep-Alive
> Date: Fri, 08 Mar 2013 05:39:53 +0000
> Authorization: AWS RUY9FSJHGMBQMFU7CITP:8nnDvutXRxtw6TZpjGKI1g+nxBg=
>
< HTTP/1.1 404 Object Not Found
< Server: Riak CS
< Date: Fri, 08 Mar 2013 05:39:53 GMT
< Content-Type: application/xml
< Content-Length: 186
<
<?xml version="1.0" encoding="UTF-8"?>
<Error>
  <Code>NoSuchBucket</Code>
  <Message>The specified bucket does not exist.</Message>
  <Resource>/test-tmp</Resource>
  <RequestId/>
</Error>

$ s3cmd mb s3://test-tmp
Bucket 's3://test-tmp/' created
$ s3curl.pl --id local_rcs \
    -- -s -v -x localhost:8080 \
    'http://test-tmp.s3.amazonaws.com/?uploads' X
> GET http://test-tmp.s3.amazonaws.com/?uploads HTTP/1.1
> User-Agent: curl/7.27.0
> Host: test-tmp.s3.amazonaws.com
> Accept: */*
> Proxy-Connection: Keep-Alive
> Date: Fri, 08 Mar 2013 05:40:07 +0000
> Authorization: AWS RUY9FSJHGMBQMFU7CITP:qfDytrz+tZleFZhN3M5hZvgrrHk=
>
< HTTP/1.1 200 OK
< Server: Riak CS
< Date: Fri, 08 Mar 2013 05:40:07 GMT
< Content-Type: application/xml
< Content-Length: 674
<
<?xml version="1.0" encoding="UTF-8"?>
<ListMultipartUploadsResult xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
  <Bucket>test-tmp</Bucket>
  <KeyMarker/>
  <NextKeyMarker/>
  <NextUploadIdMarker/>
  <Delimiter/>
  <Prefix/>
  <MaxUploads>1000</MaxUploads>
  <IsTruncated>false</IsTruncated>
  <Upload>
    <Key>test1.txt</Key>
    <UploadId>eMevGNjWQxaOcwli5W_mgw==</UploadId>
    <Initiator>
      <ID>RUY9FSJHGMBQMFU7CITP</ID>
      <DisplayName>admin</DisplayName>
    </Initiator>
    <Owner>
      <ID>RUY9FSJHGMBQMFU7CITP</ID>
      <DisplayName>admin</DisplayName>
    </Owner>
    <StorageClass>REGULAR</StorageClass>
    <Initiated>2013-03-08T05:38:57.000Z</Initiated>
  </Upload>
</ListMultipartUploadsResult>
@kuenishi kuenishi added this to the 1.5.0 milestone Apr 17, 2014
@kuenishi
Copy link
Contributor

Note: AWS S3 successfully deletes multipart (nor aborted nor completed) when the bucket is deleted. To do this in Riak CS we should introduce a code aborting all multipart before deletes the bucket.

@shino
Copy link
Contributor Author

shino commented May 14, 2014

Addressed by #856 and basho/stanchion#78

@shino shino closed this as completed May 14, 2014
@kuenishi
Copy link
Contributor

#857 is the real PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants