-
Notifications
You must be signed in to change notification settings - Fork 153
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
Introduce virtualMachineOptions to hco cr #2356
Introduce virtualMachineOptions to hco cr #2356
Conversation
Skipping CI for Draft Pull Request. |
1 similar comment
Skipping CI for Draft Pull Request. |
8d5e11f
to
770f5df
Compare
770f5df
to
71ef97c
Compare
71ef97c
to
3c0b17c
Compare
3c0b17c
to
77de595
Compare
/test pull-hyperconverged-cluster-operator-e2e-k8s-1.27 |
@fossedihelm: The specified target(s) for
The following commands are available to trigger optional jobs:
Use In response to this:
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. |
/unhold |
Pull Request Test Coverage Report for Build 5464448074
💛 - Coveralls |
/retest |
@fossedihelm: The specified target(s) for
The following commands are available to trigger optional jobs:
Use In response to this:
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. |
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 for the PR, @fossedihelm.
Added some inline comments.
g.Expect(hc.Spec.VirtualMachineOptions).Should(Equal(defaultVirtualMachineOptions), "virtualMachineOptions should be equal to default") | ||
}).WithTimeout(2 * time.Second).WithPolling(100 * time.Millisecond).Should(Succeed()) | ||
}, | ||
Entry("when removing /spec/virtualMachineOptions", "/spec/virtualMachineOptions"), |
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.
maybe also add Entry("when removing /spec/virtualMachineOptions", "/spec/virtualMachineOptions/disableFreePageReporting")
?
if hc.Spec.VirtualMachineOptions != nil && hc.Spec.VirtualMachineOptions.DisableFreePageReporting { | ||
config.VirtualMachineOptions = &kubevirtcorev1.VirtualMachineOptions{DisableFreePageReporting: &kubevirtcorev1.DisableFreePageReporting{}} | ||
} | ||
|
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.
We got a code smell here. The getKVConfig
is too complex. Please consider to somehow refactor this function.
Not Blocking!!
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.
I have some ideas, do you agree on addressing this with a followup PR?
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.
yes. Either that or we'll take it.
5e80f0d
to
81a546a
Compare
31816fe
to
4a4fea3
Compare
VirtualMachineOptions holds the cluster level information regarding the virtual machine. This defines the default behavior of some features related to the virtual machines. - `DisableFreePageReporting` With freePageReporting the guest OS informs the hypervisor about pages which are not in use by the guest anymore. The hypervisor can use this information for freeing these pages. freePageReporting is an attribute that can be defined at [Memory balloon device](https://libvirt.org/formatdomain.html#memory-balloon-device) in libvirt. freePageReporting will NOT be enabled for the vmis which does not have the Memballoon driver, OR which are requesting any high performance components. A vmi is considered as high performance if one of the following is true: - the vmi requests a dedicated cpu. - the realtime flag is enabled. - the vmi requests hugepages. With `DisableFreePageReporting` freePageReporting will never be enabled in any vmi. `DisableFreePageReporting` is an empty struct and freePageReporting is disabled by default. Signed-off-by: fossedihelm <[email protected]>
4a4fea3
to
083a214
Compare
Kudos, SonarCloud Quality Gate passed! 0 Bugs No Coverage information |
/retest |
/unhold |
@fossedihelm: The following tests failed, say
Full PR test history. Your PR dashboard. 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. |
/hold cancel |
hco-e2e-kv-smoke-gcp lane succeeded. |
@tiraboschi: Overrode contexts on behalf of tiraboschi: ci/prow/hco-e2e-kv-smoke-azure In response to this:
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. |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: tiraboschi 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 |
/retest |
What this PR does / why we need it:
VirtualMachineOptions holds the cluster level information regarding the virtual machine. This defines the default behavior of some features related to the virtual machines.
DisableFreePageReporting
With freePageReporting the guest OS informs the hypervisor about pages which are not in use by the guest anymore. The hypervisor can use this information for freeing these pages.freePageReporting is an attribute that can be defined at Memory balloon device
in libvirt. freePageReporting will NOT be enabled for the vmis which does not have the Memballoon driver, OR which are requesting any high performance components. A vmi is considered as high performance if one of the following is true:
With
DisableFreePageReporting
freePageReporting will never be enabled in any vmi.DisableFreePageReporting
is a boolean and freePageReporting is disabled by default.Reviewer Checklist
Jira Ticket:
Release note: