Skip to content
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

Fixed the issue that bound PVC was not filtered #1556

Merged
merged 2 commits into from
Aug 28, 2024

Conversation

peng9808
Copy link
Collaborator

@peng9808 peng9808 commented Aug 6, 2024

What this PR does / why we need it:

#1554

Special notes for your reviewer:

NONE

Does this PR introduce a user-facing change?

NONE

Comment on lines 242 to 249

//Filter the bound pvc
if pvc.Status.Phase == "Bound" {
continue
}

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this change may cause confusion of this func getAssociatedVolumes, the filter logic may happen where these associated volumes are used

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This function is currently only responsible for calculating the capacity when creating a volume. I think it might be more convenient to use if we change its name.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I modified the code.According to analysis, only the vol passed when creating vol for the first time is a virtual one without config parameters. If it is a migration or expansion scenario, it will not be affected.

@FloatXD FloatXD added the Full test PR that needs full testing label Aug 12, 2024
@FloatXD FloatXD added Full test PR that needs full testing and removed Full test PR that needs full testing labels Aug 13, 2024
Signed-off-by: peng9808 <peng.lai@daocloud.io>
@peng9808 peng9808 added Full test PR that needs full testing and removed Full test PR that needs full testing labels Aug 13, 2024
@peng9808 peng9808 merged commit cd5d9a3 into hwameistor:main Aug 28, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Full test PR that needs full testing
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants