]> git.apps.os.sepia.ceph.com Git - ceph.git/commit
osd_types: Restore new_object marking for delete missing entries 63154/head
authorNitzan Mordechai <nmordech@redhat.com>
Wed, 26 Mar 2025 08:20:15 +0000 (08:20 +0000)
committerNitzan Mordechai <nmordech@redhat.com>
Wed, 7 May 2025 06:09:20 +0000 (06:09 +0000)
commit57c0c20cfb00cd6a8a081ba3968fd7f24a90bbea
tree88e2d364c8d02f595f09a7317899d8c6ef8165e7
parent645d613c950405038bd84b41bd95c326611f1dc8
osd_types: Restore new_object marking for delete missing entries

Recent changes (PR #29893) removed the “new_object” parameter from missing.add() and the
pg_missing_item constructor. As a result, when processing delete log entries,
if an object is found on disk, its on‑disk version is stored as “have” instead
of the default eversion_t() (0'0). The invariant in read_log_and_missing() then
fails because delete entries are expected to have “have” set to eversion_t().

This patch reintroduces the following check:
if (have == eversion_t())
    clean_regions.mark_object_new();

By doing so, we ensure that when the on‑disk “have” is default, the missing record
is marked as new—restoring the previous behavior and satisfying the invariant for
delete operations.

Fixes: https://tracker.ceph.com/issues/45702
Signed-off-by: Nitzan Mordechai <nmordech@redhat.com>
(cherry picked from commit 4289371b20bb437ad38ded92bc53f5b192a8a16e)
src/osd/osd_types.h