Skip to content
This repository has been archived by the owner on Jan 3, 2024. It is now read-only.

rgw/sfs: ignore deleted buckets on list multipart #255

Merged
merged 1 commit into from
Nov 23, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions src/rgw/driver/sfs/sqlite/sqlite_multipart.cc
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,10 @@ std::optional<std::vector<DBMultipart>> SQLiteMultipart::list_multiparts(
) const {
auto storage = conn->get_storage();

auto bucket_entries = storage->get_all<DBBucket>(
where(is_equal(&DBBucket::bucket_name, bucket_name))
);
auto bucket_entries = storage->get_all<DBBucket>(where(
is_equal(&DBBucket::bucket_name, bucket_name) and
is_equal(&DBBucket::deleted, false)
));
if (bucket_entries.size() == 0) {
return std::nullopt;
}
Expand Down
Loading