com.sun.enterprise.ee.cms.core
Interface Signal

All Known Subinterfaces:
FailureNotificationSignal, FailureRecoverySignal, FailureSuspectedSignal, GroupLeadershipNotificationSignal, JoinedAndReadyNotificationSignal, JoinNotificationSignal, MessageSignal, PlannedShutdownSignal

public interface Signal

A Signal denotes a group event or a message event. Subtypes of Signal will define operations specific to their Signal functionalities i.e specific group events or a message event. Actions consume Signals. Each Signal is delivered on its own thread.

Version:
$Revision: 1012 $
Author:
Shreedhar Ganapathy Date: November 07, 2003

Method Summary
 void acquire()
          Signal is acquired prior to processing of the signal to protect group resources being acquired from being affected by a race condition Signal must be mandatorily acquired before any processing for recovery operations.
 java.lang.String getGroupName()
          returns the group to which the member involved in the Signal belonged to
 java.util.Map<java.io.Serializable,java.io.Serializable> getMemberDetails()
          returns the details of the member who caused this Signal to be generated returns a Map containing key-value pairs constituting data pertaining to the member's details
 java.lang.String getMemberToken()
          returns the identity token of the member that caused this signal to be generated.
 long getStartTime()
          returns the start time of the member involved in this Signal.
 void release()
          Signal is released after processing of the signal to bring the group resources to a state of availability Signal should be madatorily released after recovery process is completed.
 

Method Detail

acquire

void acquire()
             throws SignalAcquireException
Signal is acquired prior to processing of the signal to protect group resources being acquired from being affected by a race condition Signal must be mandatorily acquired before any processing for recovery operations.

Throws:
SignalAcquireException

release

void release()
             throws SignalReleaseException
Signal is released after processing of the signal to bring the group resources to a state of availability Signal should be madatorily released after recovery process is completed.

Throws:
SignalReleaseException

getMemberToken

java.lang.String getMemberToken()
returns the identity token of the member that caused this signal to be generated. For instance, in the case of a MessageSignal, this member token would be the sender. In the case of a FailureNotificationSignal, this member token would be the failed member. In the case of a JoinNotificationSignal or GracefulShutdownSignal, the member token would be the member who joined or is being gracefully shutdown, respectively.

Returns:
returns the identity token of the member

getMemberDetails

java.util.Map<java.io.Serializable,java.io.Serializable> getMemberDetails()
returns the details of the member who caused this Signal to be generated returns a Map containing key-value pairs constituting data pertaining to the member's details

Returns:
Map

getGroupName

java.lang.String getGroupName()
returns the group to which the member involved in the Signal belonged to

Returns:
String

getStartTime

long getStartTime()
returns the start time of the member involved in this Signal.

Returns:
long - time stamp of when this member started


Copyright © 2010. All Rights Reserved.