use of software.amazon.awssdk.services.route53.model.HealthCheck in project aws-doc-sdk-examples by awsdocs.
the class ListHealthChecks method listAllHealthChecks.
// snippet-start:[route53.java2.list_health_checks.main]
public static void listAllHealthChecks(Route53Client route53Client) {
try {
ListHealthChecksResponse checksResponse = route53Client.listHealthChecks();
List<HealthCheck> checklist = checksResponse.healthChecks();
for (HealthCheck check : checklist) {
System.out.println("The health check id is: " + check.id());
System.out.println("The health threshold is: " + check.healthCheckConfig().healthThreshold());
System.out.println("The type is: " + check.healthCheckConfig().typeAsString());
}
} catch (Route53Exception e) {
System.err.println(e.getMessage());
System.exit(1);
}
}
Aggregations