Examples of describeAddresses()


Examples of com.amazon.ec2.AmazonEC2SkeletonInterface.describeAddresses()

        return ec2Service.deregisterImage(deregisterImage);
    }

    public DescribeAddressesResponse describeAddresses(DescribeAddresses describeAddresses) {
        AmazonEC2SkeletonInterface ec2Service = ServiceProvider.getInstance().getServiceImpl(AmazonEC2SkeletonInterface.class);
        return ec2Service.describeAddresses(describeAddresses);
    }

    public DescribeAvailabilityZonesResponse describeAvailabilityZones(DescribeAvailabilityZones describeAvailabilityZones) {
        AmazonEC2SkeletonInterface ec2Service = ServiceProvider.getInstance().getServiceImpl(AmazonEC2SkeletonInterface.class);
        return ec2Service.describeAvailabilityZones(describeAvailabilityZones);
View Full Code Here

Examples of com.amazonaws.services.ec2.AmazonEC2.describeAddresses()

            try {
                String associatedInstanceId;

                // Check with AWS, if this EIP is already been used by another instance
                DescribeAddressesRequest describeAddressRequest = new DescribeAddressesRequest().withPublicIps(eipEntry);
                DescribeAddressesResult result = ec2Service.describeAddresses(describeAddressRequest);
                if ((result.getAddresses() != null) && (!result.getAddresses().isEmpty())) {
                    Address eipAddress = result.getAddresses().get(0);
                    associatedInstanceId = eipAddress.getInstanceId();
                    // This EIP is not used by any other instance, hence mark it for selection if it is not
                    // already marked.
View Full Code Here

Examples of com.amazonaws.services.ec2.AmazonEC2.describeAddresses()

            .get(MetaDataKey.publicIpv4);
            try {
                AmazonEC2 ec2Service = getEC2Service();
                DescribeAddressesRequest describeAddressRequest = new DescribeAddressesRequest()
                .withPublicIps(myPublicIP);
                DescribeAddressesResult result = ec2Service
                .describeAddresses(describeAddressRequest);
                if ((result.getAddresses() != null)
                        && (!result.getAddresses().isEmpty())) {
                    Address eipAddress = result.getAddresses().get(0);
                    DisassociateAddressRequest dissociateRequest = new DisassociateAddressRequest();
View Full Code Here

Examples of com.cloud.bridge.service.core.ec2.EC2Engine.describeAddresses()

                afs.addFilter( filterSet[i] );
            ec2Request.setFilterSet( afs );
        }
        // -> execute the request
        EC2Engine engine = ServiceProvider.getInstance().getEC2Engine();
        serializeResponse(response, EC2SoapServiceImpl.toDescribeAddressesResponse( engine.describeAddresses( ec2Request)));
    }

    private void allocateAddress( HttpServletRequest request, HttpServletResponse response )
            throws ADBException, XMLStreamException, IOException {
View Full Code Here

Examples of com.cloud.bridge.service.core.ec2.EC2Engine.describeAddresses()

                afs.addFilter(filterSet[i]);
            ec2Request.setFilterSet(afs);
        }
        // -> execute the request
        EC2Engine engine = ServiceProvider.getInstance().getEC2Engine();
        serializeResponse(response, EC2SoapServiceImpl.toDescribeAddressesResponse(engine.describeAddresses(ec2Request)));
    }

    private void allocateAddress(HttpServletRequest request, HttpServletResponse response) throws ADBException, XMLStreamException, IOException {

        EC2Engine engine = ServiceProvider.getInstance().getEC2Engine();
View Full Code Here

Examples of com.cloud.bridge.service.core.ec2.EC2Engine.describeAddresses()

                if (null != value && 0 < value.length) ec2Request.addPublicIp( value[0] );
            }
        }
        // -> execute the request
        EC2Engine engine = ServiceProvider.getInstance().getEC2Engine();
        serializeResponse(response, EC2SoapServiceImpl.toDescribeAddressesResponse( engine.describeAddresses( ec2Request)));
    }

    private void allocateAddress( HttpServletRequest request, HttpServletResponse response )
        throws ADBException, XMLStreamException, IOException {
     
View Full Code Here

Examples of com.cloud.bridge.service.core.ec2.EC2Engine.describeAddresses()

                if (null != value && 0 < value.length) ec2Request.addPublicIp( value[0] );
            }
        }
        // -> execute the request
        EC2Engine engine = ServiceProvider.getInstance().getEC2Engine();
        serializeResponse(response, EC2SoapServiceImpl.toDescribeAddressesResponse( engine.describeAddresses( ec2Request)));
    }

    private void allocateAddress( HttpServletRequest request, HttpServletResponse response )
        throws ADBException, XMLStreamException, IOException {
     
View Full Code Here

Examples of com.cloud.bridge.service.core.ec2.EC2Engine.describeAddresses()

                afs.addFilter( filterSet[i] );
            ec2Request.setFilterSet( afs );
        }
        // -> execute the request
        EC2Engine engine = ServiceProvider.getInstance().getEC2Engine();
        serializeResponse(response, EC2SoapServiceImpl.toDescribeAddressesResponse( engine.describeAddresses( ec2Request)));
    }

    private void allocateAddress( HttpServletRequest request, HttpServletResponse response )
            throws ADBException, XMLStreamException, IOException {
View Full Code Here

Examples of com.cloud.bridge.service.core.ec2.EC2Engine.describeAddresses()

                afs.addFilter( filterSet[i] );
            ec2Request.setFilterSet( afs );
        }
        // -> execute the request
        EC2Engine engine = ServiceProvider.getInstance().getEC2Engine();
        serializeResponse(response, EC2SoapServiceImpl.toDescribeAddressesResponse( engine.describeAddresses( ec2Request)));
    }

    private void allocateAddress( HttpServletRequest request, HttpServletResponse response )
            throws ADBException, XMLStreamException, IOException {
View Full Code Here

Examples of org.wso2.carbon.ec2client.EC2Client.describeAddresses()

        try {
            EC2Client ec2Client = new EC2Client(args[0], args[1]);
            String elasticIP = System.getenv("ELASTIC_IP");

            // Assign the elastic IP to itself, if not already assigned
            List<Address> addressList = ec2Client.describeAddresses(new String[]{elasticIP});
            String localInstanceId = System.getenv("instance_id");

            // Associate this address with this instance only if any other instance has not assigned it to itself
            for (Address address : addressList) {
                if (address.getInstance() == null) {
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.