> +            .name(Constants.NAME)
> +            .protocol("MYSQL")
> +            .port(3306)
> +            .algorithm(LoadBalancer.Algorithm.RANDOM)
> +            .nodes(addNodes)
> +            .virtualIPType(VirtualIP.Type.PUBLIC)
> +            .build();
> +      
> +      
> +      // Retry - If the DNS record has not propagated this will fail to 
> resolve on the cloud load balancer service-side
> +      // Note that this will fail if the service cannot resolve the hostname 
> of the database instance
> +      LoadBalancer loadBalancer;
> +      do {
> +         loadBalancer = lbApi.create(createLB);
> +         try {
> +            Thread.sleep(30000);

Was not sure if that is a good idea in an example. Most would use the default 
java approach with Thread.sleep. I will switch it though.

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-examples/pull/6/files#r5284506

Reply via email to