Search in sources :

Example 6 with EcsClient

use of software.amazon.awssdk.services.ecs.EcsClient in project aws-doc-sdk-examples by awsdocs.

the class ListClusters method main.

public static void main(String[] args) {
    Region region = Region.US_EAST_1;
    EcsClient ecsClient = EcsClient.builder().region(region).build();
    listAllClusters(ecsClient);
    ecsClient.close();
}
Also used : Region(software.amazon.awssdk.regions.Region) EcsClient(software.amazon.awssdk.services.ecs.EcsClient)

Example 7 with EcsClient

use of software.amazon.awssdk.services.ecs.EcsClient in project aws-doc-sdk-examples by awsdocs.

the class DescribeClusters method main.

public static void main(String[] args) {
    final String usage = "\n" + "Usage:\n" + "  <clusterArn>  \n\n" + "Where:\n" + "  clusterArn - the ARN of the ECS cluster to describe.\n";
    if (args.length != 1) {
        System.out.println(usage);
        System.exit(1);
    }
    String clusterArn = args[0];
    Region region = Region.US_EAST_1;
    EcsClient ecsClient = EcsClient.builder().region(region).build();
    descCluster(ecsClient, clusterArn);
}
Also used : Region(software.amazon.awssdk.regions.Region) EcsClient(software.amazon.awssdk.services.ecs.EcsClient)

Aggregations

Region (software.amazon.awssdk.regions.Region)7 EcsClient (software.amazon.awssdk.services.ecs.EcsClient)7