jgroup.relacs.rmi
Class AsynchAckListener

java.lang.Object
  extended by jgroup.relacs.rmi.AsynchAckListener
All Implemented Interfaces:
java.rmi.Remote, AckListener

public final class AsynchAckListener
extends java.lang.Object
implements AckListener

Acknowledgement listener for asynchronous invocations, that is invocations for which the client does not wait for the reply.

Since:
Jgroup 0.9
Author:
Alberto Montresor, Hein Meling

Constructor Summary
AsynchAckListener(Callback cb)
           
 
Method Summary
 void ack(MemberId id, int vpos, java.lang.Object obj)
          Upcalls invoked by Jgroup to notify the ack listener that the member identified by id has responded with obj to the multicast message associated with this ack listener.
 AckListener getRemoteAckListener()
          Get a reference for the remote AckListener.
 void notifyView(View view)
          Upcalls invoked by Jgroup to notify the ack listener about the view in which the multicast message is delivered.
 void viewChange()
          Upcalls invoked by Jgroup to notify the ack listener that a new view has been installed after the view in which the message has been delivered.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AsynchAckListener

public AsynchAckListener(Callback cb)
                  throws java.rmi.RemoteException
Throws:
java.rmi.RemoteException
Method Detail

getRemoteAckListener

public AckListener getRemoteAckListener()
                                 throws java.rmi.server.ExportException
Get a reference for the remote AckListener.

Returns:
A remote proxy for the AsynchAckListener.
Throws:
java.rmi.server.ExportException - Raised if the AsyncAckListener could not be exported.

notifyView

public void notifyView(View view)
                throws java.rmi.RemoteException
Description copied from interface: AckListener
Upcalls invoked by Jgroup to notify the ack listener about the view in which the multicast message is delivered. Note that following the Jgroup specification, a message may be delivered in a view different from the one in which the message has been multicast; this is motivated by the fact that during agreement protocols, no new messages can be delivered; in fact, cascading sequences of delivered messages could prevent the completion of agreement protocols.

This property corresponds to the Same View Delivery property of the GCS-Survery paper of Chockler et al, which states that all those who deliver a message must do so in the same view, however without requiring that this occur in the same view as it was sent.

Specified by:
notifyView in interface AckListener
Parameters:
view - the view in which the multicast message is delivered
Throws:
java.rmi.RemoteException

ack

public void ack(MemberId id,
                int vpos,
                java.lang.Object obj)
         throws java.rmi.RemoteException
Description copied from interface: AckListener
Upcalls invoked by Jgroup to notify the ack listener that the member identified by id has responded with obj to the multicast message associated with this ack listener.

Member id is contained in the view notified by notifyView.

Specified by:
ack in interface AckListener
Parameters:
id - the identifier of the member responding to the multicast message
vpos - position of the member in the last installed view
obj - the response message
Throws:
java.rmi.RemoteException

viewChange

public void viewChange()
                throws java.rmi.RemoteException
Description copied from interface: AckListener
Upcalls invoked by Jgroup to notify the ack listener that a new view has been installed after the view in which the message has been delivered. After this event, no missing response messages for the multicast message associated with this ack listener will ever be accepted.

Specified by:
viewChange in interface AckListener
Throws:
java.rmi.RemoteException


Copyright © 1998-2006 The Jgroup/ARM development team. All Rights Reserved.