Enum LoadBalancingMethod.Method
- java.lang.Object
-
- java.lang.Enum<LoadBalancingMethod.Method>
-
- com.oracle.bmc.waas.model.LoadBalancingMethod.Method
-
- All Implemented Interfaces:
BmcEnum
,Serializable
,Comparable<LoadBalancingMethod.Method>
- Enclosing class:
- LoadBalancingMethod
public static enum LoadBalancingMethod.Method extends Enum<LoadBalancingMethod.Method> implements BmcEnum
Load balancing methods are algorithms used to efficiently distribute traffic among origin servers.- **[IP_HASH](https://docs.oracle.com/iaas/api/#/en/waas/latest/datatypes/IPHashLoadBalancingMethod):** All the incoming requests from the same client IP address should go to the same content origination server. IP_HASH load balancing method uses origin weights when choosing which origin should the hash be assigned to initially.
- **[ROUND_ROBIN](https://docs.oracle.com/iaas/api/#/en/waas/latest/datatypes/RoundRobinLoadBalancingMethod):** Forwards requests sequentially to the available origin servers. The first request - to the first origin server, the second request - to the next origin server, and so on. After it sends a request to the last origin server, it starts again with the first origin server. When using weights on origins, Weighted Round Robin assigns more requests to origins with a greater weight. Over a period of time, origins will receive a number of requests in proportion to their weight.
- **[STICKY_COOKIE](https://docs.oracle.com/iaas/api/#/en/waas/latest/datatypes/StickyCookieLoadBalancingMethod):** Adds a session cookie to the first response from the origin server and identifies the server that sent the response. The client's next request contains the cookie value, and nginx routes the request to the origin server that responded to the first request. STICKY_COOKIE load balancing method falls back to Round Robin for the first request.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description IpHash
RoundRobin
StickyCookie
UnknownEnumValue
This value is used if a service returns a value for this enum that is not recognized by this version of the SDK.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static LoadBalancingMethod.Method
create(String key)
String
getValue()
static LoadBalancingMethod.Method
valueOf(String name)
Returns the enum constant of this type with the specified name.static LoadBalancingMethod.Method[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
IpHash
public static final LoadBalancingMethod.Method IpHash
-
RoundRobin
public static final LoadBalancingMethod.Method RoundRobin
-
StickyCookie
public static final LoadBalancingMethod.Method StickyCookie
-
UnknownEnumValue
public static final LoadBalancingMethod.Method UnknownEnumValue
This value is used if a service returns a value for this enum that is not recognized by this version of the SDK.
-
-
Method Detail
-
values
public static LoadBalancingMethod.Method[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (LoadBalancingMethod.Method c : LoadBalancingMethod.Method.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static LoadBalancingMethod.Method valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
create
public static LoadBalancingMethod.Method create(String key)
-
-