cloudstack-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fmaximus <...@git.apache.org>
Subject [GitHub] cloudstack pull request #1578: CLOUDSTACK-9401 : Support for Internal DNS in...
Date Wed, 31 Aug 2016 13:55:31 GMT
Github user fmaximus commented on a diff in the pull request:

    https://github.com/apache/cloudstack/pull/1578#discussion_r76991270
  
    --- Diff: plugins/network-elements/nuage-vsp/src/com/cloud/network/guru/NuageVspGuestNetworkGuru.java
---
    @@ -403,4 +448,25 @@ private HostVO getNuageVspHost(long physicalNetworkId) {
             }
             return nuageVspHost;
         }
    +
    +    private boolean networkHasDns(Network network) {
    +
    +        if (network != null) {
    +            List<String> dnsProvider = _ntwkOfferingSrvcDao.listProvidersForServiceForNetworkOffering(network.getNetworkOfferingId(),
Network.Service.Dns);
    +            if (dnsProvider.contains("VirtualRouter") || dnsProvider.contains("VpcVirtualRouter"))
{
    +                return true;
    +            }
    +        }
    +        return false;
    +    }
    +
    +
    +    private NetworkVO getDefaultNetwork (long vmId) {
    +
    +        NicVO defaultNic = _nicDao.findDefaultNicForVM(vmId);
    +        if (defaultNic != null ) return _networkDao.findById(_nicDao.findById(defaultNic.getId()).getNetworkId());
    --- End diff --
    
    Not necessary to fetch the nic from DB twice.


---
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 infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

Mime
View raw message