-
Notifications
You must be signed in to change notification settings - Fork 255
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
rbd: include details for parent image in the trash #906
Conversation
Marked as an API change for review purposes. Change itself extends an existing type with new fields. |
Change generally looks good to me and I'm willing to approve as-is, but first I want to ask. Would you mind completing the object and putting all fields present in rbd_linked_image_spec_t into the Go equivalent? As of nautilus the fields are: typedef struct {
int64_t pool_id;
char *pool_name;
char *pool_namespace;
char *image_id;
char *image_name;
bool trash;
} rbd_linked_image_spec_t; After your change we still lack What do you think? |
Also, we can ignore failures in the CI against ceph main. This is due to a general infra issues on the ceph side related to nfs-ganesha builds. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks !
It looks good to me,
added a small suggestion to check for ImageID too.
127390c
to
ee754b0
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Lgtm !
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we add an additional check to ensure that parent is no longer accessible by name but via ID(using OpenImageById()
) as mentioned in the commit message?
When a parent image has been removed, it will linger in the trash until all siblings are gone. The image is not accessible through it's name anymore, only through its ID. The ImageSpec that is returned by Image.GetParent() now contains the Trash boolean and the ImageID to identify if the image is in the trash, and use OpenImageById() to access the removed parent image. Related-to: ceph/ceph-csi#4013 Signed-off-by: Niels de Vos <[email protected]>
ee754b0
to
48392a3
Compare
Pull request has been modified.
That was taken from the discussion in ceph/ceph-csi#4013. I do not think we need to validate this particular RBD behavior. Possibly it could be added to a test that verifies the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
When a parent image has been removed, it will linger in the trash until all siblings are gone. The image is not accessible through it's name anymore, only through its ID.
The ImageSpec that is returned by Image.GetParent() now contains the Trash boolean and the ImageID to identify if the image is in the trash, and use OpenImageById() to access the removed parent image.
Related-to: ceph/ceph-csi#4013
Checklist
//go:build ceph_preview
make api-update
to record new APIs