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

Revert "chore: Revert staging changes for budgets (#799)" #839

Merged
merged 1 commit into from
Dec 5, 2023

Conversation

njtran
Copy link
Contributor

@njtran njtran commented Dec 5, 2023

This reverts commit 331c506.

Fixes #N/A

Description
This reverts the API reverts from a couple weeks back to begin staging the changes for budgets again.

How was this change tested?
make presubmit

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@k8s-ci-robot k8s-ci-robot added cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. approved Indicates a PR has been approved by an approver from all required OWNERS files. labels Dec 5, 2023
@k8s-ci-robot k8s-ci-robot added the size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Dec 5, 2023
@k8s-ci-robot
Copy link
Contributor

@njtran: The following tests 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-karpenter-test-1-28 e21ad7a link false /test pull-karpenter-test-1-28
pull-karpenter-test-1-27 e21ad7a link false /test pull-karpenter-test-1-27
pull-karpenter-test-1-29 e21ad7a link false /test pull-karpenter-test-1-29
pull-karpenter-test-1-26 e21ad7a link false /test pull-karpenter-test-1-26

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

@coveralls
Copy link

Pull Request Test Coverage Report for Build 7094762859

  • 11 of 26 (42.31%) changed or added relevant lines in 1 file are covered.
  • 2 unchanged lines in 1 file lost coverage.
  • Overall coverage decreased (-0.1%) to 79.388%

Changes Missing Coverage Covered Lines Changed/Added Lines %
pkg/apis/v1beta1/zz_generated.deepcopy.go 11 26 42.31%
Files with Coverage Reduction New Missed Lines %
pkg/controllers/provisioning/scheduling/nodeclaim.go 2 88.17%
Totals Coverage Status
Change from base Build 7094537609: -0.1%
Covered Lines: 7969
Relevant Lines: 10038

💛 - Coveralls

// This only considers NodeClaims with the karpenter.sh/disruption taint.
// +kubebuilder:validation:XIntOrString
// +kubebuilder:default:="10%"
MaxUnavailable intstr.IntOrString `json:"maxUnavailable" hash:"ignore"`
Copy link
Contributor

Choose a reason for hiding this comment

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

didn't we discuss "value" for this?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The consensus was to do MaxUnavailable. It matches really nicely with the fact that the parent struct name is budgets, relying on the established parallel with PDB -> MaxUnavailable

Copy link
Contributor

@ellistarn ellistarn Dec 5, 2023

Choose a reason for hiding this comment

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

MaxUnavailable only make sense in comparison to MinAvailable. We've diverged so much from PDB, I'm not sure there's too much value in trying to stay aligned on this field.

Copy link
Contributor

Choose a reason for hiding this comment

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

Also -- MaxUnavailable is a bit confusing to me, since it implies what we know what the maximum value is.

// This is required if Duration is set.
// +kubebuilder:validation:Pattern:=`^(@(annually|yearly|monthly|weekly|daily|midnight|hourly))|((.*)\s(.*)\s(.*)\s(.*)\s(.*))$`
// +optional
Crontab *string `json:"crontab,omitempty" hash:"ignore"`
Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yep, I think schedule may be misinterpreted, since the actual schedule of this budget is determined by the combination of this crontab and the duration field. One could argue that it should be something like starts or beginnings but I think a field name of crontab indicates the syntax of the string more deliberately.

Copy link
Contributor

Choose a reason for hiding this comment

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

Crontab seems a bit awkward to me, since a crontab is a file with a schedule + command: https://man7.org/linux/man-pages/man5/crontab.5.html

Copy link
Member

@jonathan-innis jonathan-innis left a comment

Choose a reason for hiding this comment

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

/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 Dec 5, 2023
@k8s-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jonathan-innis, njtran

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:
  • OWNERS [jonathan-innis,njtran]

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 merged commit 60a2e9e into kubernetes-sigs:main Dec 5, 2023
8 of 12 checks passed
@njtran njtran deleted the revertReverts branch December 26, 2023 20:27
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. 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.

5 participants