Package com.netflix.simianarmy.client.aws

Examples of com.netflix.simianarmy.client.aws.AWSClient.describeSnapshots()


        Assert.assertEquals(snapshot.getLaunchTime(), startTime);
    }

    private AWSClient createMockAWSClient(List<Snapshot> snapshotList, String... ids) {
        AWSClient awsMock = mock(AWSClient.class);
        when(awsMock.describeSnapshots(ids)).thenReturn(snapshotList);
        when(awsMock.region()).thenReturn("us-east-1");
        return awsMock;
    }

    private List<Snapshot> createSnapshotList(Date startTime) {
View Full Code Here


        refreshSnapshotToAMIs();

        List<Resource> resources = new LinkedList<Resource>();
        AWSClient awsClient = getAWSClient();

        for (Snapshot snapshot : awsClient.describeSnapshots(snapshotIds)) {
            Resource snapshotResource = new AWSResource().withId(snapshot.getSnapshotId())
                    .withRegion(getAWSClient().region()).withResourceType(AWSResourceType.EBS_SNAPSHOT)
                    .withLaunchTime(snapshot.getStartTime()).withDescription(snapshot.getDescription());
            for (Tag tag : snapshot.getTags()) {
                LOGGER.debug(String.format("Adding tag %s = %s to resource %s",
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.