|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.softamis.cluster4spring.support.invocation.LastAccessTimeEndpointSelectionPolicy<E,SI>
SI
- type of data used to invoke remote service (such as remote service URL)E
- type of endpoints that could be created by this factorypublic class LastAccessTimeEndpointSelectionPolicy<E extends Endpoint<SI>,SI extends ServiceMoniker>
Policy that performs selection of endpoint for invocation from the given list of available endpoints. This implementation simply selects the endpoint with minimal last access time.
Endpoint.getLastAccessTime()
Field Summary | |
---|---|
protected static org.apache.commons.logging.Log |
fLog
|
Constructor Summary | |
---|---|
LastAccessTimeEndpointSelectionPolicy()
|
Method Summary | |
---|---|
E |
selectServiceEndpoint(java.util.List<E> aEndpoints)
Selects endpoint for invocation from the given list of endpoints based on value of last access time for every endpoint. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final org.apache.commons.logging.Log fLog
Constructor Detail |
---|
public LastAccessTimeEndpointSelectionPolicy()
Method Detail |
---|
public E selectServiceEndpoint(java.util.List<E> aEndpoints) throws org.springframework.remoting.RemoteAccessException
selectServiceEndpoint
in interface EndpointSelectionPolicy<E extends Endpoint<SI>,SI extends ServiceMoniker>
aEndpoints
- list of endpoints available for invocation of remote service
org.springframework.remoting.RemoteAccessException
- throw if some error occured during seleting endpoint for invocationEndpoint.getLastAccessTime()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |