gmueller-ewerk commented on a change in pull request #3186: Add possibility to
set KVM MTU size for NIC
URL: https://github.com/apache/cloudstack/pull/3186#discussion_r265885365
##########
File path:
plugins/hypervisors/kvm/src/main/java/com/cloud/hypervisor/kvm/resource/LibvirtDomainXMLParser.java
##########
@@ -203,6 +202,12 @@ public boolean parseDomainXML(String domXML) {
String model = getAttrValue("model", "type", nic);
String slot = StringUtils.removeStart(getAttrValue("address",
"slot", nic), "0x");
+ String mtuAttrValue = getAttrValue("mtu", "size", nic);
+ int mtu = 1500;
+ if (mtuAttrValue != null) {
+ mtu = Integer.parseInt(mtuAttrValue);
+ }
Review comment:
Correct. I change it the an **Integer** with default null value.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services