com.sun.enterprise.ee.cms.impl.common
Class RecoveryTargetSelector

java.lang.Object
  extended by com.sun.enterprise.ee.cms.impl.common.RecoveryTargetSelector

public class RecoveryTargetSelector
extends Object

Uses a specified algorithm to determine a member that will be selected to handle recovery operations on failure of a member. The algorithms are specified through a RecoverySelectorMode object that specifies typ safe enums such as SIMPLESELECT indicating a simple ordered selection algorithm and HOSTSELECT indicating a selection algorithm that ensures that the recovery target is always on a different host from a single host.

Version:
$Revision: 1.7 $
Author:
Shreedhar Ganapathy Date: Jan 20, 2004

Nested Class Summary
static class RecoveryTargetSelector.RecoverySelectorMode
           
 
Method Summary
static boolean resolveRecoveryTarget(RecoveryTargetSelector.RecoverySelectorMode mode, List<GMSMember> members, String failedMemberToken, GMSContext ctx)
          Uses a resolution algorithm to determine whether the member this process represents is indeed responsible for performing recovery operations.
static void setRecoverySelectionState(String recovererMemberToken, String failedMemberToken, String groupName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

resolveRecoveryTarget

public static boolean resolveRecoveryTarget(RecoveryTargetSelector.RecoverySelectorMode mode,
                                            List<GMSMember> members,
                                            String failedMemberToken,
                                            GMSContext ctx)
Uses a resolution algorithm to determine whether the member this process represents is indeed responsible for performing recovery operations.

Parameters:
mode - - as specified by the RecoverySelectorMode
members - - a vector of members from a view that existed prior to the failure. Ideally, this view contains the failedMemberToken.
failedMemberToken - - failed member's identity token
ctx - - The GMSContext pertaining to the failed member;s group.
Returns:
boolean

setRecoverySelectionState

public static void setRecoverySelectionState(String recovererMemberToken,
                                             String failedMemberToken,
                                             String groupName)


Copyright © 2003 Copyright 2004 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.