]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
rgw: fix extra_data_len handling in PutObj filters 18867/head
authorCasey Bodley <cbodley@redhat.com>
Mon, 23 Oct 2017 18:23:32 +0000 (14:23 -0400)
committerShinobu Kinjo <shinobu@redhat.com>
Fri, 10 Nov 2017 07:07:49 +0000 (02:07 -0500)
commitdbd70f0b82a8eb512614b68d8de0c861da9e9d47
tree6a77148ba6979e97b55a3969c47b3dc5256d587d
parenta7c8c8101d4b78b4d6e437620b2c1a38cd752c3f
rgw: fix extra_data_len handling in PutObj filters

the RGWPutObj_Compress filter relies on a starting offset of 0 to ensure
that we only compress entire objects

for RGWRados::fetch_remote_obj(), we also fetch object metadata. the
replies come back with a 'Rgwx-Embedded-Metadata-Len' header, which
specifies how many bytes of object metadata are at the front of the
request body. when this is present, the offsets passed from
RGWRadosPutObj down to the RGWPutObjDataProcessor filters are offsets
into the http response body, rather than logical offsets into the object
data itself

this commit adds a transformation to RGWRadosPutObj so that only that
logical offset is visible to the RGWPutObjDataProcessor

Fixes: http://tracker.ceph.com/issues/21895
Signed-off-by: Casey Bodley <cbodley@redhat.com>
(cherry picked from commit ac7ffe6ef7faef4e251c970ce2efd04616c0459c)
src/rgw/rgw_rados.cc