Conversation
|
@blueorangutan package |
|
@hsato03 a [SL] Jenkins job has been kicked to build packages. It will be bundled with no SystemVM templates. I'll keep you posted as I make progress. |
|
Packaging result [SF]: ✔️ el8 ✔️ el9 ✔️ el10 ✔️ debian ✔️ suse15. SL-JID 17163 |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #12819 +/- ##
============================================
- Coverage 17.95% 17.94% -0.01%
- Complexity 16259 16264 +5
============================================
Files 5954 5959 +5
Lines 534838 535094 +256
Branches 65423 65440 +17
============================================
+ Hits 96010 96043 +33
- Misses 428053 428273 +220
- Partials 10775 10778 +3
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
| private Long nicId; | ||
|
|
||
| @Parameter(name = ApiConstants.STATE, type = CommandType.STRING, description = "Whether the NIC link state is enabled or disabled") | ||
| private String linkState; |
There was a problem hiding this comment.
Maybe using a boolean instead of a String would be a better choice. There are only two possible options anyway right? Or do you se a new link state being added in the future?
There was a problem hiding this comment.
+1 on this. If there are only two options, I believe it should be a boolean and be called Enabled instead of State. Disregard this if there is a possibility of having more states in the future.
There was a problem hiding this comment.
@hsato03
Code lgtm (apart from @JoaoJandre's review)
I also tested locally by enabling/disabling the NIC and using ip a inside the VM, I also tested:
- Using the API through the UI and CMK.
- Editing the default NIC when the VM has multiple NICs.
- Editing the NIC with the VM stopped and then starting it.
Everything worked as expected.
Description
This PR introduces the
updateVmNicAPI, allowing users to enable or disable their VMs network interface cards (NICs).Currently, this API supports only KVM with the following parameters:
nicidstateEnabledorDisabledFuture updates will extend this API to support additional NIC properties and hypervisors.
Types of changes
Feature/Enhancement Scale or Bug Severity
Feature/Enhancement Scale
Bug Severity
Screenshots (if appropriate):
How Has This Been Tested?
All tests were performed using only one NIC in the VM. Furthermore, the results of all tests were obtained using the
ip acommand executed inside the VM.EnabledtoDisabledDisabledtoEnabledEnabledstateDisabledstateHow did you try to break this feature and the system with this change?