karmada icon indicating copy to clipboard operation
karmada copied to clipboard

fix: retain `PersistentVolumeClaim` annotation `volume.kubernetes.io/selected-node`

Open a7i opened this issue 1 year ago • 7 comments

What type of PR is this?

/kind bug

What this PR does / why we need it:

As my colleague @jklaw90 discovered that selected-node is for the node that volume is mounted on. If this node doesn't exist, then it is never removed. See upstream issue: https://github.com/kubernetes/kubernetes/issues/100485

we should also remove this field since it's irrelevant, given that node names are likely not going to be the same.

Which issue(s) this PR fixes: Fixes #

Special notes for your reviewer:

Does this PR introduce a user-facing change?:

karmada-controller-manager: retain `PersistentVolume` annotation `volume.kubernetes.io/selected-node`

a7i avatar Apr 17 '24 23:04 a7i

Codecov Report

Attention: Patch coverage is 60.00000% with 6 lines in your changes are missing coverage. Please review.

Project coverage is 53.24%. Comparing base (e6c92d5) to head (3469d1d).

Files Patch % Lines
pkg/resourceinterpreter/default/native/retain.go 33.33% 4 Missing and 2 partials :warning:

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4847      +/-   ##
==========================================
+ Coverage   53.19%   53.24%   +0.04%     
==========================================
  Files         252      252              
  Lines       20508    20522      +14     
==========================================
+ Hits        10909    10926      +17     
+ Misses       8879     8871       -8     
- Partials      720      725       +5     
Flag Coverage Δ
unittests 53.24% <60.00%> (+0.04%) :arrow_up:

Flags with carried forward coverage won't be shown. Click here to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov-commenter avatar Apr 17 '24 23:04 codecov-commenter

LGTM @a7i, can you help squash the commit into one?

XiShanYongYe-Chang avatar Apr 19 '24 01:04 XiShanYongYe-Chang

Hi @a7i, can you help add the component name to the release note?

XiShanYongYe-Chang avatar Apr 20 '24 03:04 XiShanYongYe-Chang

/remove-hold

a7i avatar Apr 22 '24 12:04 a7i

/retest-required

a7i avatar Apr 23 '24 00:04 a7i

/assign @rainbowmango

a7i avatar Apr 23 '24 00:04 a7i

/cc @RainbowMango

XiShanYongYe-Chang avatar May 14 '24 03:05 XiShanYongYe-Chang

New changes are detected. LGTM label has been removed.

karmada-bot avatar May 14 '24 14:05 karmada-bot

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: chaunceyjiang

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment Approvers can cancel approval by writing /approve cancel in a comment

karmada-bot avatar May 14 '24 14:05 karmada-bot

/close

a7i avatar May 15 '24 02:05 a7i

@a7i: Closed this PR.

In response to this:

/close

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

karmada-bot avatar May 15 '24 02:05 karmada-bot

Hi, the pure part is still needed, can we reopen it and continue it?

XiShanYongYe-Chang avatar May 15 '24 03:05 XiShanYongYe-Chang

/reopen

Hi @XiShanYongYe-Chang , yes you're right!

a7i avatar May 15 '24 21:05 a7i

@a7i: Failed to re-open PR: state cannot be changed. The retain-pv-selected-node branch was force-pushed or recreated.

In response to this:

/reopen

Hi @XiShanYongYe-Chang , yes you're right!

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

karmada-bot avatar May 15 '24 21:05 karmada-bot

reopened as: https://github.com/karmada-io/karmada/pull/4943

a7i avatar May 15 '24 21:05 a7i