-
Notifications
You must be signed in to change notification settings - Fork 40k
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
Fixed check in kubectl autoscale. #26162
Fixed check in kubectl autoscale. #26162
Conversation
Fixed check in kubectl autoscale: cpu consumption can be higher than 100%. Fixes kubernetes#25815.
cc @janetkuo |
if max < 1 || max < min { | ||
errs = append(errs, fmt.Errorf("--max=MAXPODS is required, and must be at least 1 and --min=MINPODS")) | ||
} | ||
if cpu > 100 { | ||
errs = append(errs, fmt.Errorf("CPU utilization (%%) cannot exceed 100")) |
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.
Should we keep a warning in here, or just rely on the server-side warning proposed in #18294
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.
AFAIK, there are no warning logged to output by kubectl. So, I didn't want to introduce them.
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.
ACK
LGTM 👍 |
@k8s-bot test this [submit-queue is verifying that this PR is safe to merge] |
GCE e2e build/test passed for commit 47a5c17. |
Automatic merge from submit-queue |
Fixed check in kubectl autoscale: cpu consumption can be higher than 100%. Fixes #25815.