|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mobicents.tools.sip.balancer.DefaultBalancerAlgorithm
public abstract class DefaultBalancerAlgorithm
| Field Summary | |
|---|---|
protected java.util.Properties |
properties
|
| Constructor Summary | |
|---|---|
DefaultBalancerAlgorithm()
|
|
| Method Summary | |
|---|---|
void |
assignToNode(java.lang.String id,
SIPNode node)
Assign callid to node |
BalancerContext |
getBalancerContext()
Get the balancer context, which exposes useful information such as the available AS nodes at the moment or the listening points if you need the local address. |
java.util.Properties |
getProperties()
Get the properties used to load the load balancer. |
void |
jvmRouteSwitchover(java.lang.String fromJvmRoute,
java.lang.String toJvmRoute)
Move load from one node to another to follow mod_jk/mod_cluster |
void |
nodeAdded(SIPNode node)
Notify the algorithm when a node is added. |
void |
nodeRemoved(SIPNode node)
Notifying the algorithm when a node is dead. |
SIPNode |
processAssignedExternalRequest(javax.sip.message.Request request,
SIPNode assignedNode)
|
void |
processExternalResponse(javax.sip.message.Response response)
Allow algorithms to process responses |
SIPNode |
processHttpRequest(org.jboss.netty.handler.codec.http.HttpRequest request)
Handle HttpRequests here. |
void |
processInternalRequest(javax.sip.message.Request request)
|
void |
processInternalResponse(javax.sip.message.Response response)
|
void |
setProperties(java.util.Properties properties)
Also allows to change the properties completely when it makes sense |
void |
start()
|
void |
stop()
Lifecycle method. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface org.mobicents.tools.sip.balancer.BalancerAlgorithm |
|---|
init, processExternalRequest |
| Field Detail |
|---|
protected java.util.Properties properties
| Constructor Detail |
|---|
public DefaultBalancerAlgorithm()
| Method Detail |
|---|
public void setProperties(java.util.Properties properties)
BalancerAlgorithm
setProperties in interface BalancerAlgorithmpublic BalancerContext getBalancerContext()
BalancerAlgorithm
getBalancerContext in interface BalancerAlgorithmpublic java.util.Properties getProperties()
BalancerAlgorithm
getProperties in interface BalancerAlgorithmpublic void processInternalRequest(javax.sip.message.Request request)
processInternalRequest in interface BalancerAlgorithmpublic SIPNode processHttpRequest(org.jboss.netty.handler.codec.http.HttpRequest request)
BalancerAlgorithm
processHttpRequest in interface BalancerAlgorithm
public SIPNode processAssignedExternalRequest(javax.sip.message.Request request,
SIPNode assignedNode)
processAssignedExternalRequest in interface BalancerAlgorithmpublic void processInternalResponse(javax.sip.message.Response response)
processInternalResponse in interface BalancerAlgorithmpublic void processExternalResponse(javax.sip.message.Response response)
BalancerAlgorithm
processExternalResponse in interface BalancerAlgorithmpublic void start()
public void stop()
BalancerAlgorithm
stop in interface BalancerAlgorithmpublic void nodeAdded(SIPNode node)
BalancerAlgorithm
nodeAdded in interface BalancerAlgorithmpublic void nodeRemoved(SIPNode node)
BalancerAlgorithm
nodeRemoved in interface BalancerAlgorithm
public void jvmRouteSwitchover(java.lang.String fromJvmRoute,
java.lang.String toJvmRoute)
BalancerAlgorithm
jvmRouteSwitchover in interface BalancerAlgorithm
public void assignToNode(java.lang.String id,
SIPNode node)
BalancerAlgorithm
assignToNode in interface BalancerAlgorithm
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||