List of usage examples for com.amazonaws.services.route53.model ListHealthChecksResult getHealthChecks
public java.util.List<HealthCheck> getHealthChecks()
A complex type that contains one HealthCheck
element for each health check that is associated with the current AWS account.
From source file:com.deploymentio.ec2namer.helpers.DnsRegistrar.java
License:Apache License
protected void deleteHealthChecks(NamerRequest req, LambdaContext context) { String marker = null;// ww w . j a v a 2 s . com do { ListHealthChecksResult result = route53 .listHealthChecks(new ListHealthChecksRequest().withMarker(marker)); for (HealthCheck hc : result.getHealthChecks()) { if (hc.getCallerReference().startsWith(req.getInstanceId())) { String hcId = hc.getId(); route53.deleteHealthCheck(new DeleteHealthCheckRequest().withHealthCheckId(hcId)); context.log("Deleted health-check: Id=" + hcId + " FQDN=" + hc.getHealthCheckConfig().getFullyQualifiedDomainName()); } } } while (!StringUtils.isEmpty(marker)); }