Fix drop non-static buckets during metabase reync #1048

Closed
opened 2024-03-18 09:48:03 +00:00 by dstepanov-yadro · 2 comments

During metabase resync frostfs-node drops non-static (containerID depended) buckets.
See here:

err = tx.ForEach(func(name []byte, _ *bbolt.Bucket) error {

Expected Behavior

Buckets must be deleted outside of Foreach func.

Current Behavior

Buckets deleted inside of Foreach func. This leads to undefined behavior.

During metabase resync frostfs-node drops non-static (containerID depended) buckets. See here: https://git.frostfs.info/TrueCloudLab/frostfs-node/src/commit/bd216b79cb30e560165095172c44b7e48e2ce362/pkg/local_object_storage/metabase/control.go#L170 ## Expected Behavior Buckets must be deleted outside of `Foreach` func. ## Current Behavior Buckets deleted inside of `Foreach` func. This leads to undefined behavior.
dstepanov-yadro added the
bug
frostfs-node
good first issue
triage
labels 2024-03-18 09:48:03 +00:00
dstepanov-yadro self-assigned this 2024-03-19 07:10:32 +00:00
Author
Member

Done

Done
fyrchik reopened this issue 2024-03-25 11:44:44 +00:00
Author
Member

Checked again, fixed

Checked again, fixed
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: TrueCloudLab/frostfs-node#1048
No description provided.