]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
<rgw> Ensure the ETag format is consistent with AWS S3 API
authorliubingrun <liubr1@chinatelecom.cn>
Thu, 24 Oct 2024 14:23:09 +0000 (10:23 -0400)
committerCasey Bodley <cbodley@redhat.com>
Mon, 31 Mar 2025 20:26:05 +0000 (16:26 -0400)
commitb8795299aacfa2aee5ec4a6fe117424e2ce97b88
tree5204f7b71a03ec467c827c918def9f01c7502a32
parentc3b9e1c125bec33fbf4183e929ed11f0d93bd8ee
<rgw> Ensure the ETag format is consistent with AWS S3 API

AWS S3 API quotes ETAG everywhere. We still missed a few places.

checked with following cmd.
```
$ rg -i "dump.*\"ETag\"" ceph
./src/rgw/rgw_rest_s3.cc
1863:        s->formatter->dump_format("ETag", "\"%s\"", iter->meta.etag.c_str());
1955:      s->formatter->dump_format("ETag", "\"%s\"", iter->meta.etag.c_str());
2030:        s->formatter->dump_format("ETag", "\"%s\"", iter->meta.etag.c_str());
2099:      s->formatter->dump_format("ETag", "\"%s\"", iter->meta.etag.c_str());
2785:      s->formatter->dump_format("ETag", "\"%s\"", etag.c_str());
3422:    s->formatter->dump_string("ETag", etag);
3725:      s->formatter->dump_format("ETag", "\"%s\"",etag.c_str());
4228:    s->formatter->dump_string("ETag", etag);
4298:      s->formatter->dump_format("ETag", "\"%s\"", part->get_etag().c_str());

./src/rgw/rgw_rest.cc
421:    return dump_header(s, "etag", etag);
423:    return dump_header_quoted(s, "ETag", etag);

./src/rgw/driver/rados/rgw_sync_module_es_rest.cc
347:      s->formatter->dump_format("ETag", "\"%s\"", e.meta.etag.c_str());

./src/rgw/rgw_admin.cc
8612:        handled = dump_string("etag", bl, formatter.get());
```

Signed-off-by: liubingrun <liubr1@chinatelecom.cn>
src/rgw/rgw_rest_s3.cc