[#42] Fix using separate container for lifecycles #442

Merged
alexvanin merged 1 commit from mbiryukova/frostfs-s3-gw:feature/lifecycle_container into feature/lifecycle 2024-09-04 19:51:14 +00:00
Member

Signed-off-by: Marina Biryukova m.biryukova@yadro.com

Signed-off-by: Marina Biryukova <m.biryukova@yadro.com>
mbiryukova self-assigned this 2024-07-24 09:39:21 +00:00
mbiryukova added 1 commit 2024-07-24 09:39:23 +00:00
[#42] Fix using separate container for lifecycles
All checks were successful
/ DCO (pull_request) Successful in 1m11s
/ Builds (1.21) (pull_request) Successful in 1m23s
/ Builds (1.22) (pull_request) Successful in 1m21s
/ Vulncheck (pull_request) Successful in 4m33s
/ Lint (pull_request) Successful in 5m56s
/ Tests (1.21) (pull_request) Successful in 1m7s
/ Tests (1.22) (pull_request) Successful in 1m22s
5863af4a26
Signed-off-by: Marina Biryukova <m.biryukova@yadro.com>
mbiryukova requested review from storage-services-committers 2024-07-24 09:46:17 +00:00
mbiryukova requested review from storage-services-developers 2024-07-24 09:46:18 +00:00
alexvanin approved these changes 2024-07-24 12:26:22 +00:00
alexvanin left a comment
Owner

This is going to be quite nasty rebase after tree split PR. But it is what it is.

This is going to be quite nasty rebase after tree split PR. But it is what it is.
@ -821,0 +830,4 @@
if !lifecycleObj.Container().Equals(p.BktInfo.CID) {
n.deleteLifecycleObject(ctx, p.BktInfo, lifecycleObj)
}
Owner

This order looks a bit weird at the first glance. Is there a reason to get lifecycleObj before deleting container?

This order looks a bit weird at the first glance. Is there a reason to get `lifecycleObj` before deleting container?
Author
Member

If we try to get lifecycleObj after deletion, we'll get an error that container not found

If we try to get `lifecycleObj` after deletion, we'll get an error that container not found
mbiryukova force-pushed feature/lifecycle_container from 5863af4a26 to 2abb9b38cc 2024-07-24 13:26:24 +00:00 Compare
dkirillov reviewed 2024-07-25 08:08:02 +00:00
@ -146,0 +143,4 @@
prmAuth.PrivateKey = &n.gateKey.PrivateKey
}
if err = n.objectDeleteWithAuth(ctx, lifecycleBkt, obj.Object(), prmAuth); err != nil {
Member

It seems we can reuse deleteLifecycleObject if make it more general (let it return error)

It seems we can reuse `deleteLifecycleObject` if make it more general (let it return error)
Author
Member

Log and return?

Log and return?
Member

I wouldn't log inside it, but then we have to log in more other places so I don't know what is better.
Let's leave everything as is.

I wouldn't log inside it, but then we have to log in more other places so I don't know what is better. Let's leave everything as is.
dkirillov approved these changes 2024-07-25 08:09:55 +00:00
alexvanin merged commit 2abb9b38cc into feature/lifecycle 2024-07-26 13:08:26 +00:00
alexvanin deleted branch feature/lifecycle_container 2024-07-26 13:08:28 +00:00
Sign in to join this conversation.
No reviewers
TrueCloudLab/storage-services-developers
No milestone
No project
No assignees
3 participants
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-s3-gw#442
No description provided.