-
Notifications
You must be signed in to change notification settings - Fork 26
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
neonvm-controller: add spec.cpuScalingMode #1104
Conversation
e860c64
to
5212dc9
Compare
CpuScalingModeQMP string = "qmp_scaling" | ||
|
||
// CpuScalingModeCpuSysfsState is the value of the VirtualMachineSpec.CpuScalingMode field that | ||
// indicates that the VM should use the CPU sysfs state interface to scale CPUs. | ||
CpuScalingModeCpuSysfsState string = "cpu_sysfs_state_scaling" |
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.
Let's use upper camel case here instead of snake case, but otherwise lgtm
0ecb11d
to
5184a2a
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.
Suggested simpler names; otherwise LGTM.
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.
One last thought: Does this PR get us anything without #1111? If no: should it be combined into that PR? if yes: what?
(asking genuinely, not for any particular outcome)
@sharnoff this PR is required for #1111, but we first need to have a controller version in place that overwrites current VM instances to have defaulted at the time value (qmp based scaling), as we discussed so we could enable sysfs-based scaling only for new instances when we start rolling it out. I think that aligns well with what we discussed last week about the way to update CRDs? |
…xplicitly default the field value if it is not set Signed-off-by: Misha Sakhnov <[email protected]>
5184a2a
to
be2ad48
Compare
Merging this branch will increase overall coverage
Coverage by fileChanged files (no unit tests)
Please note that the "Total", "Covered", and "Missed" counts above refer to code statements instead of lines of code. The value in brackets refers to the test coverage of that file in the old version of the code. Changed unit test files
HTML Report |
close in favor of #1111, which already has the changes for the current PR |
Add the new field to the VirtualMachine spec, and change the VM-controller to explicitly update a VM with the default value of the field.
Add temporary e2e test to ensure that VM without spec.cpuScalingMode is updated as expected.
Part of the preparations for #1082