fix(pools): do not list or move free versions as delete markers

Signed-off-by: Denis Babchuk <babchukdenis@icloud.com>
This commit is contained in:
Denis Babchuk
2026-10-29 22:09:03 +03:00
parent fb1a619ee1
commit 7ce7fc8d1e
8 changed files with 288 additions and 7 deletions
+5
View File
@@ -193,6 +193,11 @@ func (o *listPathOptions) shouldSkip(ctx context.Context, entry metaCacheEntry)
if !o.InclDeleted && entry.isObject() && entry.isLatestDeletemarker() && !entry.isObjectDir() {
return true
}
// Free versions are not versions of the object. Without other versions
// there is nothing to list, and the entry must not count toward the limit.
if o.InclDeleted && entry.isObject() && entry.isAllFreeVersions() {
return true
}
if o.Lifecycle != nil || o.Replication.Config != nil {
return triggerExpiryAndRepl(ctx, *o, entry)
}