|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
org.terracotta.modules.ehcache.store Class EhcacheEvaluator
java.lang.Object org.terracotta.modules.ehcache.store.EhcacheEvaluator
- All Implemented Interfaces:
- Evaluator<EhcacheConstraint>
public class EhcacheEvaluator
- extends Object
- implements Evaluator<EhcacheConstraint>
Ehcache evaluator, which lets Jobs be executed on certain node, depending of the locality of the data in a Ehcache
- Author:
- Alex Snaps
Constructor Summary | |
---|---|
EhcacheEvaluator(ConcurrentMap<String,String> nodeIdToInstanceId)
Constructor |
Method Summary | |
---|---|
boolean |
matches(EhcacheConstraint constraint)
Evaluates the constraint against local node. |
List<String> |
suitedNodes(EhcacheConstraint constraint)
Returns a list of best suited node (instanceId) based on the constraint |
void |
verify(EhcacheConstraint constraint)
Doesn't do anything |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
EhcacheEvaluator
public EhcacheEvaluator(ConcurrentMap<String,String> nodeIdToInstanceId)
- Constructor
- Parameters:
nodeIdToInstanceId
- the Map of nodeId (Terracotta) to instanceId (Quartz) mapping file (read only)
Method Detail |
---|
matches
public boolean matches(EhcacheConstraint constraint)
- Evaluates the constraint against local node.
- Specified by:
matches
in interfaceEvaluator<EhcacheConstraint>
- Parameters:
constraint
- The constraint to evaluate- Returns:
- true if local node is a match
- See Also:
Constraint#matches(Object)
suitedNodes
public List<String> suitedNodes(EhcacheConstraint constraint)
- Returns a list of best suited node (instanceId) based on the constraint
- Specified by:
suitedNodes
in interfaceEvaluator<EhcacheConstraint>
- Parameters:
constraint
- To find best suited nodes for- Returns:
- List of best suited Quartz instanceId
verify
public void verify(EhcacheConstraint constraint)
- Doesn't do anything
- Specified by:
verify
in interfaceEvaluator<EhcacheConstraint>
- Parameters:
constraint
- The constraint to validate
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright 2001-2011, Terracotta, Inc.