@Configurable public class LoadBalance extends AbstractTargetDispatchRule
<web-app xmlns:resin="urn:java:com.caucho.resin"> <resin:LoadBalance regexp="^/remote" cluster="a"/> </web-app>
Modifier and Type | Class and Description |
---|---|
static class |
LoadBalance.LoadBalanceFilterChain |
static class |
LoadBalance.LoadBalanceRequest |
Constructor and Description |
---|
LoadBalance() |
Modifier and Type | Method and Description |
---|---|
void |
add(StickyRequestHashGenerator gen) |
FilterChain |
createDispatch(DispatcherType type,
java.lang.String uri,
java.lang.String queryString,
java.lang.String target,
FilterChain next) |
void |
init() |
protected java.lang.String |
rewriteDefault(java.lang.String uri,
java.lang.String queryString) |
void |
setCluster(java.lang.String cluster)
Sets the target cluster for the load balancer
|
void |
setSessionCookie(java.lang.String sessionId) |
void |
setStickySessions(boolean isSticky) |
void |
setStrategy(java.lang.String strategy)
Sets the strategy for the load balancer
|
getTarget, rewriteTarget, setAbsoluteTarget, setTarget, setTargetHost
@Configurable public void setCluster(java.lang.String cluster)
@Configurable public void setStrategy(java.lang.String strategy)
@Configurable public void setStickySessions(boolean isSticky)
@Configurable public void setSessionCookie(java.lang.String sessionId)
@Configurable public void add(StickyRequestHashGenerator gen)
protected java.lang.String rewriteDefault(java.lang.String uri, java.lang.String queryString)
rewriteDefault
in class AbstractTargetDispatchRule
@PostConstruct public void init() throws ConfigException
init
in class AbstractTargetDispatchRule
ConfigException
public FilterChain createDispatch(DispatcherType type, java.lang.String uri, java.lang.String queryString, java.lang.String target, FilterChain next)
createDispatch
in class AbstractRegexpDispatchRule