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

remove deprecated Kubeadm v1beta2 API #114540

Merged
merged 2 commits into from
Jan 6, 2023

Conversation

pacoxu
Copy link
Member

@pacoxu pacoxu commented Dec 16, 2022

What type of PR is this?

/kind cleanup

What this PR does / why we need it:

Which issue(s) this PR fixes:

Fixes kubernetes/kubeadm#2459

Special notes for your reviewer:

Does this PR introduce a user-facing change?

kubeadm: remove the deprecated v1beta2 API. kubeadm 1.26's "config migrate" command can be used to migrate a v1beta2 configuration file to v1beta3.

@k8s-ci-robot k8s-ci-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. release-note Denotes a PR that will be considered when it comes time to generate release notes. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. do-not-merge/needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. needs-priority Indicates a PR lacks a `priority/foo` label and requires one. area/kubeadm sig/cluster-lifecycle Categorizes an issue or PR as relevant to SIG Cluster Lifecycle. labels Dec 16, 2022
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/needs-sig Indicates an issue or PR lacks a `sig/foo` label and requires one. label Dec 16, 2022
@pacoxu pacoxu force-pushed the kubeadm-v1beta2 branch 2 times, most recently from 8cb363e to cd64ff5 Compare December 16, 2022 15:49
@pacoxu pacoxu force-pushed the kubeadm-v1beta2 branch 2 times, most recently from f10df23 to 56466b3 Compare January 4, 2023 10:23
@pacoxu pacoxu changed the title [wip] remove deprecated Kubeadm v1beta2 API remove deprecated Kubeadm v1beta2 API Jan 4, 2023
@k8s-ci-robot k8s-ci-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jan 4, 2023
@pacoxu
Copy link
Member Author

pacoxu commented Jan 4, 2023

/priority important-soon
/triage accepted

@k8s-ci-robot k8s-ci-robot added priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. triage/accepted Indicates an issue or PR is ready to be actively worked on. and removed needs-priority Indicates a PR lacks a `priority/foo` label and requires one. needs-triage Indicates an issue or PR lacks a `triage/foo` label and requires one. labels Jan 4, 2023
@pacoxu
Copy link
Member Author

pacoxu commented Jan 5, 2023

/assign @neolit123

Copy link
Member

@neolit123 neolit123 left a comment

Choose a reason for hiding this comment

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

thanks @pacoxu
i will review later today or tomorrow

Copy link
Member

@neolit123 neolit123 left a comment

Choose a reason for hiding this comment

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

the change looks clean, all around.
you could also announce the removal of the API on the SIG CL mailing list.

/approve
/hold
/assign @SataQiu
for additional review

cmd/kubeadm/app/util/config/common_test.go Show resolved Hide resolved
@k8s-ci-robot k8s-ci-robot added do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Jan 5, 2023
@neolit123
Copy link
Member

/release-note-edit

kubeadm: remove the deprecated v1beta2 API. kubeadm 1.26's "config migrate" command can be used to migrate a v1beta2 configuration file to v1beta3.

just in case if someone asks.

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: neolit123, pacoxu, SataQiu

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

@SataQiu
Copy link
Member

SataQiu commented Jan 6, 2023

/lgtm

@k8s-ci-robot k8s-ci-robot added the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Jan 6, 2023
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 27662aa584993716a7ff9f267c57c3f2c4aa973b

@pacoxu
Copy link
Member Author

pacoxu commented Jan 6, 2023

Thanks for your review.
/unhold

@k8s-ci-robot k8s-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jan 6, 2023
@pacoxu
Copy link
Member Author

pacoxu commented Jan 6, 2023

/test pull-kubernetes-verify-govet-levee

@k8s-ci-robot k8s-ci-robot merged commit 4a98fa2 into kubernetes:master Jan 6, 2023
@k8s-ci-robot k8s-ci-robot added this to the v1.27 milestone Jan 6, 2023
@@ -43,6 +43,7 @@ limitations under the License.
//
// - kubeadm v1.15.x and newer can be used to migrate from v1beta1 to v1beta2.
// - kubeadm v1.22.x and newer no longer support v1beta1 and older APIs, but can be used to migrate v1beta2 to v1beta3.
// - kubeadm v1.27.x and newer no longer support v1beta2 and older APIs.
Copy link
Member

Choose a reason for hiding this comment

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

but we still don't have something as v1beta4 yet? shouldn't us follow the -2 policy?

Copy link
Member

Choose a reason for hiding this comment

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

shouldn't us follow the -2 policy?

on a number of occasions kubeadm had a singe API version and we haven't followed such a policy.
but there were discussions that the kubeadm-config CM storage version should be the older API version for one release minimum before switching to the newer API.

Copy link
Member Author

Choose a reason for hiding this comment

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

In my mind, the v1beta4 plan is isolated with v1beta2 deprecation.

There is no skew policy for this. https://kubernetes.io/docs/setup/production-environment/tools/kubeadm/create-cluster-kubeadm/#version-skew-policy

func Convert_kubeadm_DNS_To_v1beta3_DNS(in *kubeadm.DNS, out *DNS, s conversion.Scope) error {
return autoConvert_kubeadm_DNS_To_v1beta3_DNS(in, out, s)
}

// Convert_v1beta3_ClusterConfiguration_To_kubeadm_ClusterConfiguration is required due to the missing
Copy link
Member

Choose a reason for hiding this comment

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

this is not a complete and read-able sentence after the removing of the below line.

// Convert_v1beta3_ClusterConfiguration_To_kubeadm_ClusterConfiguration is required due to the missing
// DNS.Type in v1beta3. TODO: Remove with v1beta2 https://github.com/kubernetes/kubeadm/issues/2459
func Convert_v1beta3_ClusterConfiguration_To_kubeadm_ClusterConfiguration(in *ClusterConfiguration, out *kubeadm.ClusterConfiguration, s conversion.Scope) error {
Copy link
Member

Choose a reason for hiding this comment

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

we can remove this manual conversion here now that v1beta2 is removed.

Copy link
Member

Choose a reason for hiding this comment

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

see: #115676

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/kubeadm cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. lgtm "Looks good to me", indicates that a PR is ready to be merged. priority/important-soon Must be staffed and worked on either currently, or very soon, ideally in time for the next release. release-note Denotes a PR that will be considered when it comes time to generate release notes. sig/cluster-lifecycle Categorizes an issue or PR as relevant to SIG Cluster Lifecycle. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. triage/accepted Indicates an issue or PR is ready to be actively worked on.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

deprecate and remove the kubeadm v1beta2 API
5 participants