-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
🌱 MHC marks machines for remediation with conditions #3108
🌱 MHC marks machines for remediation with conditions #3108
Conversation
4f64419
to
c45798b
Compare
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.
Thanks @benmoss for this PR! Great to see conditions in action!
a696462
to
0660438
Compare
/retitle 🌱 MHC marks machines for remediation with conditions |
@benmoss What's the status of this PR? |
It's waiting for approval and lgtm |
Let's sync up with @fabriziopandini on where to move and how to name conditions constants, there is also the other comment I made about moving the tests in the other package without the need to create a new envtest. |
Yeah, I still disagree with that comment. The controllers tests are a mess in part because of the mix of envtest and unit tests going on there. I think we should keep full integration tests like these separate. |
I'd like to better understand the benefit of having multiple separate suites. There is some downsides I can see with this approach if it grows past a certain point, for example getting a new Envtest doesn't come for free either, on my machine which isn't affected by other running jobs (like in prow) spinning up etcd and api-server takes 3-400% CPU on start and it settles betwen 2-300% during tests; we can potentially cause flakes or other resource-starvation problems in prow by creating more than necessary. |
So for one by marking these as a separate suite we can address the resource consumption issues. I've been running this test using the But even still the broader point is that these are slow tests and are fully integrated against the apiserver and etcd. They are a different kind of test, so they should be represented that way. I'm fine to move this into a separate issue. I tried moving this test into the MachineSet test suite but I think I have to convert it into a Ginkgo test for it to work. |
In |
ab5449e
to
53aed25
Compare
This looks like a failure due to the MHC controller and the MachineSet controller clobbering each other's condition patches and the MHC controller ultimately winning. Not sure why we weren't seeing it before. /hold |
Just out of curiosity if it passes, it seems to not fail that often on my machine but maybe it's related to the number of cores or something. /test pull-cluster-api-test |
@benmoss Let's try to get this merged today if possible |
c501fb6
to
8b965d5
Compare
8b965d5
to
ad68bdb
Compare
b3e709e
to
d9a3ac1
Compare
d9a3ac1
to
0262fe9
Compare
LGTM pending squash |
75b632f
to
f1b2a39
Compare
@vincepri it has been squished |
@benmoss mind rebasing on master if you haven't already? Seems some of the tests are failing. |
- Implements MachineSet as the only controller that observes this condition
Seeing this failure even after rebase
opened #3178 |
f1b2a39
to
2c77beb
Compare
@benmoss: The following test failed, say
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. |
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
@@ -29,7 +29,7 @@ const ( | |||
// Conditions and condition Reasons for the Machine object | |||
|
|||
// MachineSummaryConditionsCount defines the total number of conditions on the Machine object. | |||
const MachineSummaryConditionsCount = 2 | |||
const MachineSummaryConditionsCount = 4 |
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.
IIRC this can probably be removed now, but we can do in a follow-up
What this PR does / why we need it:
Moves MHC controller and MachineSet to use conditions instead of MHC deleting them directly. This is the first part of #2976
@vincepri @fabriziopandini