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

🌱 use providerID string as-is #8577

Merged

Conversation

jackfrancis
Copy link
Contributor

What this PR does / why we need it:

This PR updates code flows that use a strongly typed, constructed ProviderID object to represent a CAPI-opinionated version of a cloud provider's node providerID: instead of wrapping the raw providerID in a CAPI object, we now simply evaluate machine-node affinity by simply comparing the providerID strings for equality.

As an exercise in best practices, the existing ProviderID type definition is kept in place and marked for deprecation. This is to allow this change to be backported to existing minor releases so that cloud providers who are blocked on the current CAPI-opinionated ProviderID validations can make forward progress towards CAPI adoption.

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #8485

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Apr 27, 2023
@jackfrancis jackfrancis force-pushed the providerid-string-literal branch 2 times, most recently from cc5cbba to 92a100a Compare April 27, 2023 00:44
@jackfrancis
Copy link
Contributor Author

/assign @sbueringer

This PR implements more or less #8505 (comment)

If we want to go in this direction, this would supercede #8505 (I'd close it).

@sbueringer
Copy link
Member

I like it!

@enxebre
Copy link
Member

enxebre commented Apr 28, 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 Apr 28, 2023
@k8s-ci-robot
Copy link
Contributor

LGTM label has been added.

Git tree hash: 0448c6c18dd7b82b906031bab7667df300d45bc5

Copy link
Member

@sbueringer sbueringer left a comment

Choose a reason for hiding this comment

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

last nit, otherwise lgtm from my side

controllers/noderefutil/providerid.go Outdated Show resolved Hide resolved
@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label Apr 28, 2023
@sbueringer
Copy link
Member

Thx!

/lgtm

/assign @vincepri @fabriziopandini

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

LGTM label has been added.

Git tree hash: a52012b55f5925fa76d073098cfc70d8c6d0d415

@k8s-ci-robot k8s-ci-robot removed the lgtm "Looks good to me", indicates that a PR is ready to be merged. label May 2, 2023
@k8s-ci-robot k8s-ci-robot requested a review from vincepri May 2, 2023 16:23
Copy link
Member

@vincepri vincepri left a comment

Choose a reason for hiding this comment

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

/approve

@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: vincepri

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

@k8s-ci-robot k8s-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label May 2, 2023
@sbueringer
Copy link
Member

/lgtm

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

LGTM label has been added.

Git tree hash: f607c8ed68597b75566a4f7789adb601bd303230

@k8s-ci-robot k8s-ci-robot merged commit 124d9be into kubernetes-sigs:main May 2, 2023
@k8s-ci-robot k8s-ci-robot added this to the v1.5 milestone May 2, 2023
@jackfrancis jackfrancis deleted the providerid-string-literal branch May 2, 2023 18:52
@jackfrancis
Copy link
Contributor Author

@vincepri @sbueringer what do we think about cherry-picking this change into v1.4?

@sbueringer
Copy link
Member

+1. Also to v1.3 if there's demand

@jackfrancis
Copy link
Contributor Author

🤞

/cherry-pick release-1.4

@k8s-infra-cherrypick-robot

@jackfrancis: new pull request created: #8594

In response to this:

🤞

/cherry-pick release-1.4

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.

@jackfrancis
Copy link
Contributor Author

yay I just got 10 minutes of extra time!

@g-gaston
Copy link
Contributor

g-gaston commented Jun 5, 2023

/area machine

@k8s-ci-robot k8s-ci-robot added the area/machine Issues or PRs related to machine lifecycle management label Jun 5, 2023
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/machine Issues or PRs related to machine lifecycle management cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. lgtm "Looks good to me", indicates that a PR is ready to be merged. size/L Denotes a PR that changes 100-499 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow provider id regex matching to support more provider formats
8 participants