Class CloudLoadBalancersLoadBalanceNodesStrategy
- java.lang.Object
-
- org.jclouds.rackspace.cloudloadbalancers.v1.loadbalancer.strategy.CloudLoadBalancersLoadBalanceNodesStrategy
-
- All Implemented Interfaces:
LoadBalanceNodesStrategy
@Singleton public class CloudLoadBalancersLoadBalanceNodesStrategy extends Object implements LoadBalanceNodesStrategy
-
-
Field Summary
Fields Modifier and Type Field Description protected CloudLoadBalancersApi
client
protected GetLoadBalancerMetadataStrategy
getLB
protected Logger
logger
-
Constructor Summary
Constructors Modifier Constructor Description protected
CloudLoadBalancersLoadBalanceNodesStrategy(CloudLoadBalancersApi client, GetLoadBalancerMetadataStrategy getLB)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LoadBalancerMetadata
createLoadBalancerInLocation(Location location, String name, String protocol, int loadBalancerPort, int instancePort, Iterable<? extends NodeMetadata> nodes)
-
-
-
Field Detail
-
logger
@Named("jclouds.loadbalancer") protected Logger logger
-
client
protected final CloudLoadBalancersApi client
-
getLB
protected final GetLoadBalancerMetadataStrategy getLB
-
-
Constructor Detail
-
CloudLoadBalancersLoadBalanceNodesStrategy
@Inject protected CloudLoadBalancersLoadBalanceNodesStrategy(CloudLoadBalancersApi client, GetLoadBalancerMetadataStrategy getLB)
-
-
Method Detail
-
createLoadBalancerInLocation
public LoadBalancerMetadata createLoadBalancerInLocation(Location location, String name, String protocol, int loadBalancerPort, int instancePort, Iterable<? extends NodeMetadata> nodes)
- Specified by:
createLoadBalancerInLocation
in interfaceLoadBalanceNodesStrategy
- Parameters:
location
- null if defaultprotocol
- LoadBalancer transport protocol to use for routing - TCP or HTTP. This property cannot be modified for the life of the LoadBalancer.loadBalancerPort
- The external TCP port of the LoadBalancer. Valid LoadBalancer ports are - 80, 443 and 1024 through 65535. This property cannot be modified for the life of the LoadBalancer.instancePort
- The InstancePort data type is simple type of type: integer. It is the TCP port on which the server on the instance is listening. Valid instance ports are one (1) through 65535. This property cannot be modified for the life of the LoadBalancer.nodes
- nodes to loadbalance- Returns:
- newly created loadbalancer
- See Also:
ComputeService
-
-