]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
posixdriver: add bde.flags to in bucket cache serde cycle
authorMatt Benjamin <mbenjamin@redhat.com>
Sun, 15 Feb 2026 15:21:28 +0000 (10:21 -0500)
committerDaniel Gryniewicz <dang@fprintf.net>
Fri, 29 May 2026 15:03:29 +0000 (11:03 -0400)
commite72f97dd8a8bff8cf9c3dc72b9bb77b7fca79c16
tree736cb958ce2accd848b8aa56b560ad412d901b68
parentf744a78299ff65a00d2089400ad79ba0d47dd980
posixdriver: add bde.flags to in bucket cache serde cycle

The upstream logic (mostly?) correctly uses bde.flags when filling
the cache for versioned objects, but cache ser(de)ialization has
been discarding that member.

This change suppresses the visible result where RGW incorrectly produces
multiple versions in non-versioned listing because none uniquely sets
FLAG_CURRENT:

mbenjamin@fedora:~/dev/rgw/s3_py/python$ s3cmd ls s3://sheik2
2026-02-14 22:44           22  s3://sheik2/ginfizz_1
2026-02-14 22:44           22  s3://sheik2/ginfizz_1
2026-02-14 22:44           22  s3://sheik2/ginfizz_1
2026-02-14 22:44           22  s3://sheik2/ginfizz_2
2026-02-14 22:44           22  s3://sheik2/ginfizz_2
2026-02-14 22:44           22  s3://sheik2/ginfizz_2

Corrected result is:

mbenjamin@fedora:~/dev/rgw/s3_py/python$ s3cmd ls s3://sheik2
2026-02-14 22:44           22  s3://sheik2/ginfizz_1
2026-02-14 22:44           22  s3://sheik2/ginfizz_2

Cached listings for versions are still incorrect in containing an
an extra entry for the "current" version in with empty instance
(from the Symlink)--the visible effect being that list-object-versions
output is incorrect (no entry is sent with IsLatest, after the
empty instance version has been filtered out).

Signed-off-by: Matt Benjamin <mbenjamin@redhat.com>
src/rgw/driver/posix/bucket_cache.h