public class RemoteWorker extends RemoteNode<RemoteWorker>
RemoteCallManager.getWorker() interface.
For each remote worker, there should be at most one RemoteWorker
object representing that worker.name| Constructor and Description |
|---|
RemoteWorker(java.lang.String name)
This should only be called by fabric.worker.Worker.
|
| Modifier and Type | Method and Description |
|---|---|
void |
abortTransaction(TransactionID tid)
Informs the remote worker that a transaction is aborting.
|
boolean |
checkForStaleObjects(TransactionID tid)
Asks the worker to check that the objects used in a given transaction are
up-to-date.
|
void |
commitTransaction(long tid) |
Principal |
getPrincipal() |
java.lang.Object |
issueRemoteCall(Object._Proxy receiver,
java.lang.String methodName,
java.lang.Class<?>[] parameterTypes,
java.lang.Object[] args) |
java.util.List<java.lang.Long> |
notifyObjectUpdates(java.util.List<java.lang.Long> updatedOnums,
java.util.List<ObjectGroup> updates)
Notifies the worker that a set of objects has been updated.
|
java.util.List<java.lang.Long> |
notifyObjectUpdates(java.lang.String store,
LongKeyMap<ObjectGlob> updates)
Notifies the dissemination node at the given worker that an object has been
updated.
|
void |
prepareTransaction(long tid) |
void |
readObject(TransactionID tid,
Object._Impl obj)
Reads the given object from the remote worker, updating the object's state.
|
Pair<Store,SerializedObject> |
readObject(TransactionID tid,
Store store,
long onum) |
void |
takeOwnership(TransactionID tid,
Store store,
long onum)
Unsets the ownership bit for the given object at the remote worker.
|
java.lang.String |
toString() |
getSocket, name, recycle, sendpublic RemoteWorker(java.lang.String name)
public java.lang.Object issueRemoteCall(Object._Proxy receiver, java.lang.String methodName, java.lang.Class<?>[] parameterTypes, java.lang.Object[] args) throws UnreachableNodeException, RemoteCallException
public void prepareTransaction(long tid)
throws UnreachableNodeException,
TransactionPrepareFailedException
public void commitTransaction(long tid)
throws UnreachableNodeException,
TransactionCommitFailedException
public void abortTransaction(TransactionID tid) throws AccessException, UnreachableNodeException
tid - the tid for the transaction that is aborting.AccessExceptionUnreachableNodeExceptionpublic void readObject(TransactionID tid, Object._Impl obj)
tid - the tid for the current transaction.public Pair<Store,SerializedObject> readObject(TransactionID tid, Store store, long onum) throws AccessException
AccessExceptionpublic void takeOwnership(TransactionID tid, Store store, long onum)
tid - the tid for the current transaction.public Principal getPrincipal()
getPrincipal in class RemoteNode<RemoteWorker>public java.lang.String toString()
toString in class java.lang.Objectpublic java.util.List<java.lang.Long> notifyObjectUpdates(java.lang.String store,
LongKeyMap<ObjectGlob> updates)
public java.util.List<java.lang.Long> notifyObjectUpdates(java.util.List<java.lang.Long> updatedOnums,
java.util.List<ObjectGroup> updates)
public boolean checkForStaleObjects(TransactionID tid)