]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
rgw: fix extra_data_len handling in PutObj filters
authorCasey Bodley <cbodley@redhat.com>
Mon, 23 Oct 2017 18:23:32 +0000 (14:23 -0400)
committerCasey Bodley <cbodley@redhat.com>
Wed, 25 Oct 2017 18:25:09 +0000 (14:25 -0400)
commitac7ffe6ef7faef4e251c970ce2efd04616c0459c
treec887c5bf5f10f80dd30f1405a62e16fa65cbbfdc
parenta95d325bfaa4bf9e2cbf6fec65299425190327b5
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>
src/rgw/rgw_rados.cc