Examples of DetailVO


Examples of com.cloud.host.DetailVO

                if (gslbProvider) {
                    lbDeviceVO.setGslbSitePublicIP(gslbSitePublicIp);
                    lbDeviceVO.setGslbSitePrivateIP(gslbSitePrivateIp);
                }
                _externalLoadBalancerDeviceDao.persist(lbDeviceVO);
                DetailVO hostDetail = new DetailVO(host.getId(), ApiConstants.LOAD_BALANCER_DEVICE_ID, String.valueOf(lbDeviceVO.getId()));
                _hostDetailDao.persist(hostDetail);

                txn.commit();
                return lbDeviceVO;
            } else {
View Full Code Here

Examples of com.cloud.host.DetailVO

        HostVO externalLoadBalancer = _hostDao.findById(hostId);
        if (externalLoadBalancer == null) {
            throw new InvalidParameterValueException("Could not find an external load balancer with ID: " + hostId);
        }

        DetailVO lbHostDetails = _hostDetailDao.findDetail(hostId, ApiConstants.LOAD_BALANCER_DEVICE_ID);
        long lbDeviceId = Long.parseLong(lbHostDetails.getValue());

        ExternalLoadBalancerDeviceVO lbDeviceVo = _externalLoadBalancerDeviceDao.findById(lbDeviceId);
        if (lbDeviceVo.getAllocationState() == LBDeviceAllocationState.Provider) {
            // check if cloudstack has provisioned any load balancer appliance on the device before deleting
            List<ExternalLoadBalancerDeviceVO> lbDevices = _externalLoadBalancerDeviceDao.listAll();
View Full Code Here

Examples of com.cloud.host.DetailVO

                    // release the private IP back to dc pool, as the load balancer appliance is now destroyed
                    _dcDao.releasePrivateIpAddress(lbHost.getPrivateIpAddress(), guestConfig.getDataCenterId(), null);

                    // release the public IP allocated for this LB appliance
                    DetailVO publicIpDetail = _hostDetailDao.findDetail(lbHost.getId(), "publicip");
                    IPAddressVO ipVo = _ipAddressDao.findByIpAndDcId(guestConfig.getDataCenterId(), publicIpDetail.toString());
                    _networkMgr.disassociatePublicIpAddress(ipVo.getId(), _accountMgr.getSystemUser().getId(), _accountMgr.getSystemAccount());
                } else {
                    deviceMapLock.unlock();
                }
View Full Code Here

Examples of com.cloud.host.DetailVO

            ExternalFirewallDeviceVO fwDevice = new ExternalFirewallDeviceVO(externalFirewall.getId(), pNetwork.getId(), ntwkSvcProvider.getProviderName(),
                    deviceName, capacity, dedicatedUse);

            _externalFirewallDeviceDao.persist(fwDevice);

            DetailVO hostDetail = new DetailVO(externalFirewall.getId(), ApiConstants.FIREWALL_DEVICE_ID, String.valueOf(fwDevice.getId()));
            _hostDetailDao.persist(hostDetail);

            txn.commit();
            return fwDevice;
        } else {
View Full Code Here

Examples of com.cloud.host.DetailVO

        HostVO externalFirewall = _hostDao.findById(hostId);
        if (externalFirewall == null) {
            throw new InvalidParameterValueException("Could not find an external firewall with ID: " + hostId);
        }

        DetailVO fwHostDetails = _hostDetailDao.findDetail(hostId, ApiConstants.FIREWALL_DEVICE_ID);
        long fwDeviceId = Long.parseLong(fwHostDetails.getValue());

        // check if any networks are using this balancer device
        List<NetworkExternalFirewallVO> networks = _networkExternalFirewallDao.listByFirewallDeviceId(fwDeviceId);
        if ((networks != null) && !networks.isEmpty()) {
            throw new CloudRuntimeException("Delete can not be done as there are networks using the firewall device ");
View Full Code Here

Examples of com.cloud.host.DetailVO

                    @Override
                    public NiciraNvpDeviceVO doInTransaction(TransactionStatus status) {
                        NiciraNvpDeviceVO niciraNvpDevice = new NiciraNvpDeviceVO(host.getId(), physicalNetworkId, ntwkSvcProvider.getProviderName(), deviceName);
                        niciraNvpDao.persist(niciraNvpDevice);

                        DetailVO detail = new DetailVO(host.getId(), "niciranvpdeviceid", String.valueOf(niciraNvpDevice.getId()));
                        hostDetailsDao.persist(detail);

                        return niciraNvpDevice;
                    }
                });
View Full Code Here

Examples of com.cloud.host.DetailVO

                    public BigSwitchVnsDeviceVO doInTransaction(TransactionStatus status) {
                        BigSwitchVnsDeviceVO bigswitchVnsDevice =
                            new BigSwitchVnsDeviceVO(host.getId(), physicalNetworkId, ntwkSvcProvider.getProviderName(), deviceName);
                        _bigswitchVnsDao.persist(bigswitchVnsDevice);

                        DetailVO detail = new DetailVO(host.getId(), "bigswitchvnsdeviceid", String.valueOf(bigswitchVnsDevice.getId()));
                        _hostDetailsDao.persist(detail);

                        return bigswitchVnsDevice;
                    }
                });
View Full Code Here

Examples of com.cloud.host.DetailVO

                    @Override
                    public CiscoVnmcController doInTransaction(TransactionStatus status) {
                        CiscoVnmcController ciscoVnmcResource = new CiscoVnmcControllerVO(host.getId(), physicalNetworkId, ntwkSvcProvider.getProviderName(), deviceName);
                        _ciscoVnmcDao.persist((CiscoVnmcControllerVO)ciscoVnmcResource);

                        DetailVO detail = new DetailVO(host.getId(), "deviceid", String.valueOf(ciscoVnmcResource.getId()));
                        _hostDetailsDao.persist(detail);

                        return ciscoVnmcResource;
                    }
                });
View Full Code Here

Examples of com.cloud.host.DetailVO

    public DetailVO findDetail(long hostId, String name) {
        SearchCriteria<DetailVO> sc = DetailSearch.create();
        sc.setParameters("hostId", hostId);
        sc.setParameters("name", name);

        DetailVO detail = findOneIncludingRemovedBy(sc);
        if ("password".equals(name) && detail != null) {
            detail.setValue(DBEncryptionUtil.decrypt(detail.getValue()));
        }
        return detail;
    }
View Full Code Here

Examples of com.cloud.host.DetailVO

                txn.start();

                ciscoVnmcResource = new CiscoVnmcControllerVO(host.getId(), physicalNetworkId, ntwkSvcProvider.getProviderName(), deviceName);
                _ciscoVnmcDao.persist((CiscoVnmcControllerVO)ciscoVnmcResource);
               
                DetailVO detail = new DetailVO(host.getId(), "deviceid", String.valueOf(ciscoVnmcResource.getId()));
                _hostDetailsDao.persist(detail);

                txn.commit();
                return ciscoVnmcResource;
            } else {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.