org.jclouds.rackspace.cloudloadbalancers.v1.domain.internal
Class BaseLoadBalancer<N extends BaseNode<N>,T extends BaseLoadBalancer<N,T>>

java.lang.Object
  extended by org.jclouds.rackspace.cloudloadbalancers.v1.domain.internal.BaseLoadBalancer<N,T>
All Implemented Interfaces:
Comparable<BaseLoadBalancer<N,T>>
Direct Known Subclasses:
CreateLoadBalancer, LoadBalancer

public class BaseLoadBalancer<N extends BaseNode<N>,T extends BaseLoadBalancer<N,T>>
extends Object
implements Comparable<BaseLoadBalancer<N,T>>


Nested Class Summary
static class BaseLoadBalancer.Algorithm
          All load balancers utilize an algorithm that defines how traffic should be directed between back-end nodes.
static class BaseLoadBalancer.Builder<N extends BaseNode<N>,T extends BaseLoadBalancer<N,T>>
           
 
Field Summary
protected  BaseLoadBalancer.Algorithm algorithm
           
protected  Map<String,Boolean> connectionLogging
           
protected  ConnectionThrottle connectionThrottle
           
protected  Boolean halfClosed
           
protected  HealthMonitor healthMonitor
           
protected  String name
           
protected  SortedSet<N> nodes
           
protected  Integer port
           
protected  String protocol
           
protected  Map<String,SessionPersistence> sessionPersistence
           
protected  Integer timeout
           
static BaseLoadBalancer.Algorithm[] WEIGHTED_ALGORITHMS
           
 
Constructor Summary
protected BaseLoadBalancer()
           
  BaseLoadBalancer(String name, String protocol, Integer port, Iterable<N> nodes, BaseLoadBalancer.Algorithm algorithm, Integer timeout, Boolean halfClosed, Map<String,SessionPersistence> sessionPersistence, Map<String,Boolean> connectionLogging, ConnectionThrottle connectionThrottle, HealthMonitor healthMonitor)
           
 
Method Summary
static
<N extends BaseNode<N>,T extends BaseLoadBalancer<N,T>>
BaseLoadBalancer.Builder<N,T>
builder()
           
 int compareTo(BaseLoadBalancer<N,T> arg0)
           
 boolean equals(Object obj)
           
 BaseLoadBalancer.Algorithm getAlgorithm()
           
 ConnectionThrottle getConnectionThrottle()
           
 HealthMonitor getHealthMonitor()
           
 String getName()
           
 Set<N> getNodes()
           
 Integer getPort()
           
 String getProtocol()
           
 SessionPersistence getSessionPersistenceType()
           
 Integer getTimeout()
           
 int hashCode()
           
 boolean isConnectionLogging()
           
 Boolean isHalfClosed()
           
protected  com.google.common.base.Objects.ToStringHelper string()
           
 BaseLoadBalancer.Builder<N,T> toBuilder()
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

WEIGHTED_ALGORITHMS

public static BaseLoadBalancer.Algorithm[] WEIGHTED_ALGORITHMS

name

protected String name

protocol

protected String protocol

port

protected Integer port

nodes

protected SortedSet<N extends BaseNode<N>> nodes

algorithm

protected BaseLoadBalancer.Algorithm algorithm

timeout

protected Integer timeout

halfClosed

protected Boolean halfClosed

sessionPersistence

protected Map<String,SessionPersistence> sessionPersistence

connectionLogging

protected Map<String,Boolean> connectionLogging

connectionThrottle

protected ConnectionThrottle connectionThrottle

healthMonitor

protected HealthMonitor healthMonitor
Constructor Detail

BaseLoadBalancer

protected BaseLoadBalancer()

BaseLoadBalancer

public BaseLoadBalancer(String name,
                        @Nullable
                        String protocol,
                        @Nullable
                        Integer port,
                        Iterable<N> nodes,
                        @Nullable
                        BaseLoadBalancer.Algorithm algorithm,
                        @Nullable
                        Integer timeout,
                        @Nullable
                        Boolean halfClosed,
                        @Nullable
                        Map<String,SessionPersistence> sessionPersistence,
                        @Nullable
                        Map<String,Boolean> connectionLogging,
                        @Nullable
                        ConnectionThrottle connectionThrottle,
                        @Nullable
                        HealthMonitor healthMonitor)
Method Detail

compareTo

public int compareTo(BaseLoadBalancer<N,T> arg0)
Specified by:
compareTo in interface Comparable<BaseLoadBalancer<N extends BaseNode<N>,T extends BaseLoadBalancer<N,T>>>

getName

public String getName()

getProtocol

@Nullable
public String getProtocol()
Returns:
protocol, which may be null if the load balancer is deleted.

getPort

@Nullable
public Integer getPort()
Returns:
port, which may be null if port has not been set.

getNodes

public Set<N> getNodes()

getAlgorithm

@Nullable
public BaseLoadBalancer.Algorithm getAlgorithm()
Returns:
algorithm, which may be null if the load balancer is deleted.

getTimeout

@Nullable
public Integer getTimeout()
Returns:
timeout, which may be null if no timeout has been set.

isHalfClosed

@Nullable
public Boolean isHalfClosed()
Returns:
halfClosed, which may be null if halfClosed has not been set.

getSessionPersistenceType

@Nullable
public SessionPersistence getSessionPersistenceType()
Returns:
sessionPersistenceType, which may be null if sessionPersistenceType has not been set.

isConnectionLogging

public boolean isConnectionLogging()

getConnectionThrottle

@Nullable
public ConnectionThrottle getConnectionThrottle()
Returns:
connectionThrottle, which may be null if connectionThrottle has not been set.

getHealthMonitor

@Nullable
public HealthMonitor getHealthMonitor()
Returns:
healthMonitor, which may be null if healthMonitor has not been set.

string

protected com.google.common.base.Objects.ToStringHelper string()

toString

public String toString()
Overrides:
toString in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

builder

public static <N extends BaseNode<N>,T extends BaseLoadBalancer<N,T>> BaseLoadBalancer.Builder<N,T> builder()

toBuilder

public BaseLoadBalancer.Builder<N,T> toBuilder()


Copyright © 2009-2014 The Apache Software Foundation. All Rights Reserved.