Github user DaanHoogland commented on a diff in the pull request:

    https://github.com/apache/cloudstack/pull/1474#discussion_r59342176
  
    --- Diff: 
server/src/com/cloud/network/router/VpcVirtualNetworkApplianceManagerImpl.java 
---
    @@ -260,6 +261,15 @@ public boolean finalizeVirtualMachineProfile(final 
VirtualMachineProfile profile
                     if (defaultDns2 != null) {
                         buf.append(" dns2=").append(defaultDns2);
                     }
    +
    +                VpcGatewayVO privateGatewayForVpc = 
_vpcGatewayDao.getPrivateGatewayForVpc(domainRouterVO.getVpcId());
    +                if (privateGatewayForVpc != null) {
    +                    String ip4Address = 
privateGatewayForVpc.getIp4Address();
    +                    buf.append(" privategateway=").append(ip4Address);
    +                    s_logger.debug("Set privategateway field in 
cmd_line.json to " + ip4Address);
    +                } else {
    +                    buf.append(" privategateway=None");
    +                }
    --- End diff --
    
    matter of style: I would have assigned "None" to ip4Assress and appended 
the buffer outside the conditional and maybe factorred the block out as method. 
no issue.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

Reply via email to