com.sun.sgs.service
Interface RecoveryListener


public interface RecoveryListener

A service can register a RecoveryListener to be notified when that service on the local node needs to recover for the service on a failed node.

See Also:
WatchdogService.addRecoveryListener(RecoveryListener)

Method Summary
 void recover(Node node, SimpleCompletionHandler handler)
          Notifies this listener that the specified node has failed and that this listener needs to orchestrate recovery.
 

Method Detail

recover

void recover(Node node,
             SimpleCompletionHandler handler)
Notifies this listener that the specified node has failed and that this listener needs to orchestrate recovery. This method is invoked outside of a transaction.

When recovery for this listener for the specified node is complete, the completed method of the specified handler must be invoked.

Recovery does not need to be performed in this method, but may be performed asynchronously.

The implementation of this method should be idempotent because it may be invoked multiple times. If it is invoked multiple times, the completed method must be called for each handler provided.

Parameters:
node - a failed node to recover
handler - a handler to notify when recovery is complete

RedDwarf, Version 0.10.1
2010-03-14 10:56:12

Copyright © 2010 The RedDwarf Authors. All rights reserved
Copyright © 2007-2010 Sun Microsystems, Inc. All rights reserved