|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Resizer
Pool
routers with dynamically resizable number of routees are implemented by providing a Resizer
implementation in the Pool
configuration.
Method Summary | |
---|---|
boolean |
isTimeForResize(long messageCounter)
Is it time for resizing. |
int |
resize(scala.collection.immutable.IndexedSeq<Routee> currentRoutees)
Decide if the capacity of the router need to be changed. |
Method Detail |
---|
boolean isTimeForResize(long messageCounter)
CAUTION: this method is invoked from the thread which tries to send a message to the pool, i.e. the ActorRef.!() method, hence it may be called concurrently.
messageCounter
- (undocumented)
int resize(scala.collection.immutable.IndexedSeq<Routee> currentRoutees)
isTimeForResize
returns true and no other resize is in progress.
Return the number of routees to add or remove. Negative value will remove that number of routees. Positive value will add that number of routess. 0 will not change the routees.
This method is invoked only in the context of the Router actor.
currentRoutees
- (undocumented)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |