Examples of TerminateInstancesRequest


Examples of com.amazonaws.services.ec2.model.TerminateInstancesRequest

        Optional<List<String>> instanceIds =
                Optional.fromNullable((List<String>) execution.getVariable(ProcessVariables.INSTANCE_IDS));

        LOG.info(">> Terminating instances: {}", instanceIds);
        if (instanceIds.isPresent() && instanceIds.get().size() > 0) {
            client.terminateInstances(new TerminateInstancesRequest().withInstanceIds(instanceIds.get()));
        }
    }
View Full Code Here

Examples of com.amazonaws.services.ec2.model.TerminateInstancesRequest

    @Override
    public void tearDown() throws Exception {
        @SuppressWarnings("unchecked")
        List<String> instanceIds = (List<String>) collector.getVariable(ProcessVariables.INSTANCE_IDS);
        client.terminateInstances(new TerminateInstancesRequest().withInstanceIds(instanceIds));

        // TODO: this behaves strangely, if it tries to delete the security group
        // and the instances are not yet killed, the test fails with an error
        Uninterruptibles.sleepUninterruptibly(45, TimeUnit.SECONDS);
        super.tearDown();
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.