-
Notifications
You must be signed in to change notification settings - Fork 38
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
UPSTREAM: <carry>: openshift: Implement scale from zero #137
UPSTREAM: <carry>: openshift: Implement scale from zero #137
Conversation
Counterpart PRs: Can we update the description to match the annotations in the links above and include this links as well? |
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_utils.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_utils.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_nodegroup.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_nodegroup.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_nodegroup.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_nodegroup.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_nodegroup.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_nodegroup.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_machinedeployment.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_nodegroup_test.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_utils.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_utils.go
Outdated
Show resolved
Hide resolved
65be1d7
to
e572aba
Compare
updated to incorporate the comments here, and squashed my additions into a single commit. |
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_utils_test.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_nodegroup.go
Outdated
Show resolved
Hide resolved
e572aba
to
8dbc526
Compare
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_controller.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_controller.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_controller.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/openshiftmachineapi/machineapi_machineset.go
Outdated
Show resolved
Hide resolved
This is looking great @elmiko. We need to rebase as #137 got in. |
8dbc526
to
9c4af16
Compare
rebased, still working on the outstanding comments |
can we conflate both commits into one? the split is meaningless since the second one is introducing changes over the first one but we never had support for the first one. |
cluster-autoscaler/cloudprovider/clusterapi/clusterapi_nodegroup.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/clusterapi/clusterapi_controller.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/clusterapi/clusterapi_controller.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/clusterapi/clusterapi_controller.go
Outdated
Show resolved
Hide resolved
cluster-autoscaler/cloudprovider/clusterapi/clusterapi_utils.go
Outdated
Show resolved
Hide resolved
sounds good, i will rebase again and squash the 2 commits into one.
i am still working through my understanding of the test framework, but i will give it my best =) |
9bcacb3
to
17014e1
Compare
@JoelSpeed ptal, i think i've covered all the fields we are manually copying through the converters, even the timestamps! after looking deeper, we are not actually copying more from the underlying machines, etc... so i feel good that this test should be covering everything we have added. i have squashed my extra commit, and i just need to clean up the last few comments about the varying unit types for the memory/cpu stuff. |
17014e1
to
c06ed43
Compare
one more comment for tonight, i cleaned up the tests a little more (to make the converters stuff look similar to the others). @JoelSpeed i also added a few more unit type tests, i'm curious how many of these should we add? i'm avoiding creating some matrix of every possible combo... ;) |
I've reviewed this and am happy for this to merge on the 2 provisos:
I think what you've got is good for now, though we aren't currently testing all of the code in that file, we aren't testing the structured to unstructured converters at the moment so that's why my second proviso is there, this is the kind of stuff that is easily gonna trip someone up as explained offline yesterday /lgtm |
related to @JoelSpeed comment above kubernetes#3011 |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: enxebre 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 |
ack, i will spend some time with those tests and then post results here when it's working. |
i am fairly confident that this code is passing the end-to-end tests from cluster-api-actuator-pkg#140. i have run the "from/to zero" tests and appear to be working as expected:
i am following up with the full suite but i am seeing non-related issues. |
/retest |
This allows a Machine{Set,Deployment} to scale up/down from 0, providing the following annotations are set: ```yaml apiVersion: v1 items: - apiVersion: machine.openshift.io/v1beta1 kind: MachineSet metadata: annotations: machine.openshift.io/cluster-api-autoscaler-node-group-min-size: "0" machine.openshift.io/cluster-api-autoscaler-node-group-max-size: "6" machine.openshift.io/vCPU: "2" machine.openshift.io/memoryMb: 8G machine.openshift.io/GPU: "1" machine.openshift.io/maxPods: "100" ``` Note that `machine.openshift.io/GPU` and `machine.openshift.io/maxPods` are optional.
c06ed43
to
fe61822
Compare
/retest |
as per our conversation on slack, i am going to remove the hold given that the proposed tests are passing. /hold cancel |
/retest |
/test e2e-azure-operator |
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.
/lgtm
This allows a Machine{Set,Deployment} to scale up/down from 0,
providing the following annotations are set:
please note that
machine.openshift.io/maxPods
is not required for scale to/from zero operations.this PR is a continuation of the work started in #110
Counterpart PRs:
openshift/cluster-api-provider-aws#301
openshift/cluster-api-provider-azure#112
Design details:
openshift/enhancements#186