com.sun.enterprise.ee.cms.impl.common
Interface GMSContext

All Known Implementing Classes:
GMSContext, GMSContextBase

public interface GMSContext

Provides contextual information about all useful GMS artifacts. These are GMS objects that are tied to a particular group identity and thus scoped to provide information within the group's context. There can be as many GMSContext objects as there are groups within a single JVM process.

Version:
$Revision: 1.16 $
Author:
Shreedhar Ganapathy Date: Jan 12, 2004

Method Summary
 boolean addToSuspectList(String token)
           
 void announceGroupShutdown(String groupName, GMSConstants.shutdownState shutdownState)
           
 void announceGroupStartup(String groupName, GMSConstants.groupStartupState startupState, List<String> memberTokens)
           
 void assumeGroupLeadership()
          lets this instance become a group leader explicitly Typically this can be employed by an administrative member to become a group leader prior to shutting down a group of members simultaneously.
 DistributedStateCache getDistributedStateCache()
           
 GroupCommunicationProvider getGroupCommunicationProvider()
           
 GroupHandle getGroupHandle()
          returns Group handle
 String getGroupName()
          returns the name of the group this context represents.
 GroupManagementService.MemberType getMemberType()
           
 Router getRouter()
          returns the router
 String getServerIdentityToken()
          returns the serverIdentityToken pertaining to the process that owns this GMS instance
 ShutdownHelper getShutdownHelper()
           
 long getStartTime()
           
 List<String> getSuspectList()
           
 boolean isGroupBeingShutdown(String groupName)
           
 boolean isGroupStartup()
           
 boolean isShuttingDown()
           
 boolean isSuspected(String token)
           
 boolean isWatchdog()
           
 void join()
           
 void leave(GMSConstants.shutdownType shutdownType)
           
 void removeFromSuspectList(String token)
           
 void setGroupStartup(boolean value)
           
 

Method Detail

getServerIdentityToken

String getServerIdentityToken()
returns the serverIdentityToken pertaining to the process that owns this GMS instance

Returns:
java.lang.String

getGroupName

String getGroupName()
returns the name of the group this context represents.

Returns:
the name of the group.

getGroupHandle

GroupHandle getGroupHandle()
returns Group handle

Returns:
Group handle

getRouter

Router getRouter()
returns the router

Returns:
router

getDistributedStateCache

DistributedStateCache getDistributedStateCache()

join

void join()
          throws GMSException
Throws:
GMSException

leave

void leave(GMSConstants.shutdownType shutdownType)

isShuttingDown

boolean isShuttingDown()

getStartTime

long getStartTime()

announceGroupStartup

void announceGroupStartup(String groupName,
                          GMSConstants.groupStartupState startupState,
                          List<String> memberTokens)

announceGroupShutdown

void announceGroupShutdown(String groupName,
                           GMSConstants.shutdownState shutdownState)

addToSuspectList

boolean addToSuspectList(String token)

removeFromSuspectList

void removeFromSuspectList(String token)

isSuspected

boolean isSuspected(String token)

getSuspectList

List<String> getSuspectList()

getShutdownHelper

ShutdownHelper getShutdownHelper()

getGroupCommunicationProvider

GroupCommunicationProvider getGroupCommunicationProvider()

assumeGroupLeadership

void assumeGroupLeadership()
lets this instance become a group leader explicitly Typically this can be employed by an administrative member to become a group leader prior to shutting down a group of members simultaneously. For underlying Group Communication Providers who don't support the feature of a explicit leader role assumption, the implementation of this method would be a no-op.


isGroupBeingShutdown

boolean isGroupBeingShutdown(String groupName)

isGroupStartup

boolean isGroupStartup()

setGroupStartup

void setGroupStartup(boolean value)

getMemberType

GroupManagementService.MemberType getMemberType()

isWatchdog

boolean isWatchdog()


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