|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.wadi.location.partitionmanager.facade.VersionAwarePartitionFacade
public class VersionAwarePartitionFacade
Nested Class Summary | |
---|---|
protected class |
VersionAwarePartitionFacade.PartitionRunnable
|
Constructor Summary | |
---|---|
VersionAwarePartitionFacade(int key,
Dispatcher dispatcher,
PartitionInfo partitionInfo,
long partitionUpdateWaitTime)
|
Method Summary | |
---|---|
Envelope |
exchange(SessionRequestMessage request,
long timeout)
Send a message/request to the Partition and wait for a message/response... |
int |
getKey()
|
PartitionInfo |
getPartitionInfo()
|
protected void |
handleVersionTooHigh(Envelope message,
SessionRequestMessage request,
java.lang.Runnable attemptAction,
java.util.concurrent.CountDownLatch latch)
|
protected void |
handleVersionTooLow(Envelope message,
SessionResponseMessage responseMessage)
|
boolean |
isLocal()
|
void |
onMessage(Envelope message,
DeleteIMToPM request)
A Peer has destroyed a Session... |
void |
onMessage(Envelope message,
EvacuateIMToPM request)
A Peer wishes to evacuate a Session... |
void |
onMessage(Envelope message,
InsertIMToPM request)
A Peer has created a Session... |
void |
onMessage(Envelope message,
MoveIMToPM request)
A Peer has an Invocation for a Session of which it is not the owner... |
protected void |
onMessage(Envelope message,
SessionRequestMessage request,
java.lang.Runnable attemptAction,
VersionAwarePartitionFacade.PartitionRunnable delegateAction)
|
Partition |
setContent(PartitionInfo partitionInfo,
LocalPartition content)
|
Partition |
setContentRemote(PartitionInfo partitionInfo,
Peer peer)
|
void |
setPartitionInfo(PartitionInfo partitionInfo)
|
protected Partition |
setPartitionInfo(PartitionInfo partitionInfo,
Partition partition)
|
boolean |
waitForBoot(long attemptPeriod)
|
protected Envelope |
waitForUpdateAndExchange(SessionRequestMessage request,
long timeout,
java.util.concurrent.CountDownLatch latch)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public VersionAwarePartitionFacade(int key, Dispatcher dispatcher, PartitionInfo partitionInfo, long partitionUpdateWaitTime)
Method Detail |
---|
public boolean waitForBoot(long attemptPeriod) throws java.lang.InterruptedException
waitForBoot
in interface PartitionFacade
java.lang.InterruptedException
public Envelope exchange(SessionRequestMessage request, long timeout) throws MessageExchangeException
Partition
exchange
in interface Partition
request
- The requesttimeout
- The number of milliseconds to wait for a response
MessageExchangeException
public int getKey()
getKey
in interface Partition
public boolean isLocal()
isLocal
in interface Partition
public void onMessage(Envelope message, DeleteIMToPM request)
Partition
onMessage
in interface Partition
public void onMessage(Envelope message, EvacuateIMToPM request)
Partition
onMessage
in interface Partition
public void onMessage(Envelope message, InsertIMToPM request)
Partition
onMessage
in interface Partition
public void onMessage(Envelope message, MoveIMToPM request)
Partition
onMessage
in interface Partition
public Partition setContent(PartitionInfo partitionInfo, LocalPartition content)
setContent
in interface PartitionFacade
public Partition setContentRemote(PartitionInfo partitionInfo, Peer peer)
setContentRemote
in interface PartitionFacade
public PartitionInfo getPartitionInfo()
getPartitionInfo
in interface PartitionFacade
public void setPartitionInfo(PartitionInfo partitionInfo)
setPartitionInfo
in interface PartitionFacade
protected Partition setPartitionInfo(PartitionInfo partitionInfo, Partition partition)
protected Envelope waitForUpdateAndExchange(SessionRequestMessage request, long timeout, java.util.concurrent.CountDownLatch latch) throws MessageExchangeException
MessageExchangeException
protected void onMessage(Envelope message, SessionRequestMessage request, java.lang.Runnable attemptAction, VersionAwarePartitionFacade.PartitionRunnable delegateAction)
protected void handleVersionTooHigh(Envelope message, SessionRequestMessage request, java.lang.Runnable attemptAction, java.util.concurrent.CountDownLatch latch)
protected void handleVersionTooLow(Envelope message, SessionResponseMessage responseMessage)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |