Bug #15812
closedNo Last-Modified, Content-Size and X-Object-Manifest headers if no segments in DLO manifest
0%
Description
I use Ceph v0.80.9 Firefly as a part of Mirantis OpenStack installation (as Swift backend).
Customer claimed, that if there are no segments in DLO manifest, then when doing HEAD query to manifest, there would be no Last-Modified
, Content-Size
and X-Object-Manifest
headers in response:
15:26:41.478 [main] DEBUG org.apache.http.wire - http-outgoing-1 >> "HEAD /swift/v1/dummy/myobject HTTP/1.1[\r][\n]" 15:26:41.478 [main] DEBUG org.apache.http.wire - http-outgoing-1 >> "Accept: application/json; charset=utf-8[\r][\n]" 15:26:41.478 [main] DEBUG org.apache.http.wire - http-outgoing-1 >> "X-Auth-Token: 123456789changed123456789changed[\r][\n]" 15:26:41.478 [main] DEBUG org.apache.http.wire - http-outgoing-1 >> "Host: example.net:8080[\r][\n]" 15:26:41.478 [main] DEBUG org.apache.http.wire - http-outgoing-1 >> "Connection: Keep-Alive[\r][\n]" 15:26:41.478 [main] DEBUG org.apache.http.wire - http-outgoing-1 >> "User-Agent: OpenStack4j-Agent[\r][\n]" 15:26:41.478 [main] DEBUG org.apache.http.wire - http-outgoing-1 >> "Accept-Encoding: gzip,deflate[\r][\n]" 15:26:41.478 [main] DEBUG org.apache.http.wire - http-outgoing-1 >> "[\r][\n]" 15:26:41.517 [main] DEBUG org.apache.http.wire - http-outgoing-1 << "HTTP/1.1 200 OK[\r][\n]" 15:26:41.517 [main] DEBUG org.apache.http.wire - http-outgoing-1 << "Date: Fri, 06 May 2016 12:26:41 GMT[\r][\n]" 15:26:41.517 [main] DEBUG org.apache.http.wire - http-outgoing-1 << "Server: Apache[\r][\n]" 15:26:41.517 [main] DEBUG org.apache.http.wire - http-outgoing-1 << "[\r][\n]"
Steps to reproduce:
- create container (e.g.
dummy
) - create pseudo-folder (e.g.
data
) - retrive auth token
- create DLO manifest (e.g.
myobject
):$ curl -X PUT -H 'X-Auth-Token: 123456789changed123456789changed' -H 'X-Object-Manifest: dummy/data/' https://example.net:8080/swift/v1/dummy/myobject --data-binary ''
Known workaround: if add even one (or more) segment to the manifest, this problem won't reproduce (headers would be where they are supposed to be).
Updated by Radoslaw Zarzynski almost 8 years ago
- Status changed from New to In Progress
- Assignee set to Radoslaw Zarzynski
Replicated on master:
$ curl -i -X PUT -H "X-Auth-Token: $token" "$publicURL/cont/broken_dlo" -H "X-Object-Manifest: non/existent" -d ''
HTTP/1.1 201 Created
etag: d41d8cd98f00b204e9800998ecf8427e
Last-Modified: Tue, 10 May 2016 14:38:47 GMT
X-Trans-Id: tx00000000000000000000f-005731f277-1008-default
Content-Type: text/plain; charset=utf-8
Content-Length: 0
Date: Tue, 10 May 2016 14:38:47 GMT
$ curl -i -X HEAD -H "X-Auth-Token: $token" "$publicURL/cont/broken_dlo"
Content-Length: 0
Date: Tue, 10 May 2016 14:38:59 GMT
There are some slight differences due to using the civetweb front-end to RadosGW.
I will work on that. Thanks for the bug report.
Updated by Radoslaw Zarzynski almost 8 years ago
- Status changed from In Progress to Fix Under Review
- Source changed from other to Community (user)
- Backport set to Jewel,Hammer
Pull request: https://github.com/ceph/ceph/pull/9042.
Updated by Nathan Cutler almost 8 years ago
- Backport changed from Jewel,Hammer to jewel,hammer
Updated by Radoslaw Zarzynski almost 8 years ago
- Status changed from Fix Under Review to Pending Backport
Updated by Nathan Cutler almost 8 years ago
- Copied to Backport #15965: jewel: No Last-Modified, Content-Size and X-Object-Manifest headers if no segments in DLO manifest added
Updated by Nathan Cutler almost 8 years ago
- Copied to Backport #15966: hammer: No Last-Modified, Content-Size and X-Object-Manifest headers if no segments in DLO manifest added
Updated by Nathan Cutler over 7 years ago
- Status changed from Pending Backport to Resolved