-
Notifications
You must be signed in to change notification settings - Fork 28.4k
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
[SPARK-43356][K8S] Migrate deprecated createOrReplace to serverSideApply #41136
Conversation
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.
How many PRs do you want to make, @pan3793 ? Actually, we don't need to follow deprecation
eagerly if there is no planned deletion.
No overall estimation, I have been working on this area recently, and would like to propose change when I find something has room for improvement. |
Then, let's hold on this PR for a while because we don't need to take any risk. |
We are now using |
rebased on the latest master branch |
Looks reasonable to me pending @dongjoon-hyun's review |
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.
+1, LGTM, too.
### What changes were proposed in this pull request? The deprecation message of `createOrReplace` indicates that we should change `createOrReplace` to `serverSideApply` instead. ``` deprecated please use {link ServerSideApplicable#serverSideApply()} or attempt a create and edit/patch operation. ``` The change is not fully equivalent, but I believe it's reasonable. > With the caveat that the user may choose not to use forcing if they want to know when there are conflicting changes. > > Also unlike createOrReplace if the resourceVersion is set on the resource and a replace is attempted, it will be optimistically locked. See more details at fabric8io/kubernetes-client#5073 ### Why are the changes needed? Remove usage of deprecated API. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? Pass GA. Closes apache#41136 from pan3793/SPARK-43356. Authored-by: Cheng Pan <[email protected]> Signed-off-by: Dongjoon Hyun <[email protected]>
What changes were proposed in this pull request?
The deprecation message of
createOrReplace
indicates that we should changecreateOrReplace
toserverSideApply
instead.The change is not fully equivalent, but I believe it's reasonable.
See more details at fabric8io/kubernetes-client#5073
Why are the changes needed?
Remove usage of deprecated API.
Does this PR introduce any user-facing change?
No.
How was this patch tested?
Pass GA.