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

Dynamic listing of SKUs #7239

Merged

Conversation

rakechill
Copy link
Contributor

What type of PR is this?

/kind cleanup
/kind deprecation

What this PR does / why we need it:

  • enables dynamic listing of SKUs by default
  • ensures SKU cache only gets regenerated at initialization and for the cluster's location
  • removes the option to define enableDynamicInstanceList as an env variable

Which issue(s) this PR fixes:

#462

Special notes for your reviewer:

Check out the relevant issue for more details ^^

I'll also add some helpful pointers in the PR itself

Does this PR introduce a user-facing change?

Deprecate option to enableDynamicInstanceList 

Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:


@k8s-ci-robot k8s-ci-robot added kind/cleanup Categorizes issue or PR as related to cleaning up code, process, or technical debt. kind/deprecation Categorizes issue or PR as related to a feature/enhancement marked for deprecation. cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Sep 4, 2024
@k8s-ci-robot
Copy link
Contributor

Hi @rakechill. Thanks for your PR.

I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

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-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added area/provider/azure Issues or PRs related to azure provider size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Sep 4, 2024
@tallaxes
Copy link
Contributor

tallaxes commented Sep 4, 2024

/ok-to-test

@k8s-ci-robot k8s-ci-robot added ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. labels Sep 4, 2024
@@ -1184,8 +1176,6 @@ func TestTemplateNodeInfo(t *testing.T) {
// Note: static-only workflow tests can be removed once support for dynamic is always on
Copy link
Contributor

Choose a reason for hiding this comment

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

☝️

msg := "no vm sku info loaded, using only static sku list"
klog.Warning(msg)
return vmssType, errors.New(msg)
}
Copy link
Contributor

@tallaxes tallaxes Sep 4, 2024

Choose a reason for hiding this comment

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

It is weird to have this check within GetVMSSTypeDynamically... Being in the very beginning, wouldn't it block the very first dynamic load?

Which got me wondering how the relevant unit test passed - and the current approach has it override GetVMSSTypeDynamically altogether, so it does not actually get tested. Maybe we don't have a choice but to switch to mocking skewer/resource APIs for proper test coverage ...

Copy link
Contributor Author

@rakechill rakechill Sep 5, 2024

Choose a reason for hiding this comment

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

The first fetch skus happens when the cache is created (newAzureCache in azure_cache.go). As such, unless dynamic fails when initializing the cache, it should have skus and thus this should pass.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

anyway, I'm removing these changes from this PR for now 🤣
but good to think about for next iteration

@comtalyst
Copy link
Contributor

comtalyst commented Sep 4, 2024

This seems to include new changes to the fork (e.g., I see some differences in azure_cache.go, deprecation of that env var), which is outside of our scope for defork. Are you confident in those, and is it worth it? Changes will need to be made in the fork as well.

@tallaxes
Copy link
Contributor

tallaxes commented Sep 4, 2024

Looking at the test-and-verify run (for other reasons), I noticed errors at the verify-golint step - which somehow don't fail the check; would be good to understand and fix.

@k8s-ci-robot k8s-ci-robot added size/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Sep 5, 2024
@rakechill
Copy link
Contributor Author

@comtalyst / @tallaxes -- I'll need one of you to:

  • choose squash as merge strategy
  • automated cherry-pick for 1.27-1.30

@comtalyst
Copy link
Contributor

/label tide/merge-method-squash
/cherry-pick cluster-autoscaler-release-1.31
/cherry-pick cluster-autoscaler-release-1.30
/cherry-pick cluster-autoscaler-release-1.29
/cherry-pick cluster-autoscaler-release-1.28
/cherry-pick cluster-autoscaler-release-1.27

@k8s-infra-cherrypick-robot

@comtalyst: once the present PR merges, I will cherry-pick it on top of cluster-autoscaler-release-1.31 in a new PR and assign it to you.

In response to this:

/label tide/merge-method-squash
/cherry-pick cluster-autoscaler-release-1.31
/cherry-pick cluster-autoscaler-release-1.30
/cherry-pick cluster-autoscaler-release-1.29
/cherry-pick cluster-autoscaler-release-1.28
/cherry-pick cluster-autoscaler-release-1.27

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-sigs/prow repository.

@k8s-ci-robot k8s-ci-robot added the tide/merge-method-squash Denotes a PR that should be squashed by tide when it merges. label Sep 5, 2024
@nojnhuh
Copy link
Contributor

nojnhuh commented Sep 5, 2024

Test failure seems to be transient

/test pull-cluster-autoscaler-e2e-azure-master

@k8s-ci-robot
Copy link
Contributor

@rakechill: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
pull-cluster-autoscaler-e2e-azure-master 59cddd2 link false /test pull-cluster-autoscaler-e2e-azure-master

Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR.

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-sigs/prow repository. I understand the commands that are listed here.

@rakechill
Copy link
Contributor Author

Test failure seems to be transient

/test pull-cluster-autoscaler-e2e-azure-master

image

failed to install helm. I think this is ok for now. just need a lgtm?

@comtalyst
Copy link
Contributor

/lgtm
/approve

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

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: comtalyst, rakechill

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 Sep 6, 2024
@k8s-ci-robot k8s-ci-robot merged commit cecb34c into kubernetes:master Sep 6, 2024
7 of 8 checks passed
@k8s-infra-cherrypick-robot

@comtalyst: new pull request created: #7254

In response to this:

/label tide/merge-method-squash
/cherry-pick cluster-autoscaler-release-1.31
/cherry-pick cluster-autoscaler-release-1.30
/cherry-pick cluster-autoscaler-release-1.29
/cherry-pick cluster-autoscaler-release-1.28
/cherry-pick cluster-autoscaler-release-1.27

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-sigs/prow repository.

@k8s-infra-cherrypick-robot

@comtalyst: new pull request created: #7255

In response to this:

/label tide/merge-method-squash
/cherry-pick cluster-autoscaler-release-1.31
/cherry-pick cluster-autoscaler-release-1.30
/cherry-pick cluster-autoscaler-release-1.29
/cherry-pick cluster-autoscaler-release-1.28
/cherry-pick cluster-autoscaler-release-1.27

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-sigs/prow repository.

@k8s-infra-cherrypick-robot

@comtalyst: new pull request created: #7256

In response to this:

/label tide/merge-method-squash
/cherry-pick cluster-autoscaler-release-1.31
/cherry-pick cluster-autoscaler-release-1.30
/cherry-pick cluster-autoscaler-release-1.29
/cherry-pick cluster-autoscaler-release-1.28
/cherry-pick cluster-autoscaler-release-1.27

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-sigs/prow repository.

@k8s-infra-cherrypick-robot

@comtalyst: new pull request created: #7257

In response to this:

/label tide/merge-method-squash
/cherry-pick cluster-autoscaler-release-1.31
/cherry-pick cluster-autoscaler-release-1.30
/cherry-pick cluster-autoscaler-release-1.29
/cherry-pick cluster-autoscaler-release-1.28
/cherry-pick cluster-autoscaler-release-1.27

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-sigs/prow repository.

@k8s-infra-cherrypick-robot

@comtalyst: new pull request created: #7258

In response to this:

/label tide/merge-method-squash
/cherry-pick cluster-autoscaler-release-1.31
/cherry-pick cluster-autoscaler-release-1.30
/cherry-pick cluster-autoscaler-release-1.29
/cherry-pick cluster-autoscaler-release-1.28
/cherry-pick cluster-autoscaler-release-1.27

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-sigs/prow repository.

@rakechill rakechill changed the title Dynamic listing of SKUs (master) Dynamic listing of SKUs Sep 6, 2024
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/cluster-autoscaler area/provider/azure Issues or PRs related to azure provider 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. kind/deprecation Categorizes issue or PR as related to a feature/enhancement marked for deprecation. lgtm "Looks good to me", indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. size/M Denotes a PR that changes 30-99 lines, ignoring generated files. tide/merge-method-squash Denotes a PR that should be squashed by tide when it merges.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants