-
Notifications
You must be signed in to change notification settings - Fork 547
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: add ParentInTrash parameter in rbdImage struct #4522
Conversation
/test ci/centos/mini-e2e/k8s-1.28/rbd |
/test ci/centos/mini-e2e/k8s-1.28/rbd |
/test ci/centos/mini-e2e/k8s-1.28-rbd |
/test ci/centos/mini-e2e/k8s-1.28/test-type-rbd |
/test ci/centos/mini-e2e/k8s-1.28 |
/test ci/centos/mini-e2e/k8s-1.29/test_type-rbd |
hey @karthik-us , |
Hey @Rakshith-R, the command you used is correct. Let me check why it is not triggering the e2e. I am triggring the helm e2e as well to see whether this is the case there as well (should be same I think). |
/test ci/centos/mini-e2e-helm/k8s-1.29/test_type-rbd |
57f704b
to
8aed1e9
Compare
/test ci/centos/mini-e2e/k8s-1.28 |
|
8aed1e9
to
efe7ece
Compare
/test ci/centos/mini-e2e/k8s-1.28 |
d48e200
to
d460276
Compare
The ci passes with the fix of checking if the parent is in trash. |
e2e/rbd.go
Outdated
@@ -3609,6 +3609,27 @@ var _ = Describe("RBD", func() { | |||
validateOmapCount(f, 1, rbdType, defaultRBDPool, volumesType) | |||
validateOmapCount(f, 0, rbdType, defaultRBDPool, snapsType) | |||
|
|||
// create pvc-pvc clone |
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.
Add a comment on what we are trying to test here.
framework.Failf("failed to create smart clone PVC %q: %v", | ||
smartClonePVC.Name, err) | ||
} | ||
|
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.
validate the omap
framework.Failf("failed to delete smart clone PVC %q: %v", | ||
smartClonePVC.Name, err) | ||
} | ||
|
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.
validate the omap after deletion as well
@@ -1631,7 +1634,7 @@ func (ri *rbdImage) getParent() (*rbdImage, error) { | |||
if err != nil { | |||
return nil, err | |||
} | |||
if ri.ParentName == "" { | |||
if ri.ParentName == "" || ri.ParentInTrash { |
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.
Looks like we are going to get ParentName even it its in trash, pleas add a comment here as well.
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.
Yeah, that looks weird. An image in trash does not have a name, I think?
So, does this check actually make a difference? If a parent image does not have a name, it will be set to ""
anyway, and the new ParentInTrash
is not needed.
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.
It does have name.
We just can't refer to it by its name when it is in trash.
The failed ci that I linked in the comment above proves it.
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.
thats strange, can you please add a comment about it.
d460276
to
78707a0
Compare
🛑 Command
|
15 similar comments
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
/test ci/centos/mini-e2e-helm/k8s-1.26 |
/test ci/centos/k8s-e2e-external-storage/1.26 |
/test ci/centos/mini-e2e/k8s-1.26 |
🛑 Command
|
7 similar comments
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
🛑 Command
|
rbd: add ParentInTrash parameter in rbdImage struct
This commit adds ParentInTrash parameter in rbdImage struct
and makes use of it in getParent() function in order to avoid
error in case the parent is present but in trash.
This commit modifies a test case to check creation of PVC-PVC clone of a restored PVC when parent snapshot is deleted.
Signed-off-by: Rakshith R [email protected]
Describe what this PR does
Provide some context for the reviewer
Is there anything that requires special attention
Do you have any questions?
Is the change backward compatible?
Are there concerns around backward compatibility?
Provide any external context for the change, if any.
For example:
Related issues
Mention any github issues relevant to this PR. Adding below line
will help to auto close the issue once the PR is merged.
Fixes: #issue_number
Future concerns
List items that are not part of the PR and do not impact it's
functionality, but are work items that can be taken up subsequently.
Checklist:
guidelines in the developer
guide.
Request
notes
updated with breaking and/or notable changes for the next major release.
Show available bot commands
These commands are normally not required, but in case of issues, leave any of
the following bot commands in an otherwise empty comment in this PR:
/retest ci/centos/<job-name>
: retest the<job-name>
after unrelatedfailure (please report the failure too!)