Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

alma::acs::commandcenter::meta::MaciSupervisor Class Reference

Inheritance diagram for alma::acs::commandcenter::meta::MaciSupervisor:

Inheritance graph
[legend]
Collaboration diagram for alma::acs::commandcenter::meta::MaciSupervisor:

Collaboration graph
[legend]
List of all members.

Public Member Functions

void setConnectsAutomatically (boolean b)
synchronized void start () throws NoPermissionEx, CannotRetrieveManagerException, CorbaTransientException, CorbaNotExistException, UnknownErrorException
synchronized void stop ()
synchronized void dismissManager ()
boolean isConnected ()
int myMaciHandle () throws NotConnectedToManagerException
String getManagerLocation ()
MaciInfo getMaciInfo () throws NoPermissionEx, NotConnectedToManagerException, CorbaTransientException, CorbaNotExistException, UnknownErrorException
MaciInfo getMaciInformation ()
void refreshSoon ()
synchronized void refreshNow () throws NoPermissionEx, NotConnectedToManagerException, SystemException, CorbaTransientException, CorbaNotExistException, UnknownErrorException
Override String toString ()

Protected Member Functions

 MaciSupervisor (String clientName, String managerLoc, ORB orb, Logger log)
Manager myManagerReference () throws NotConnectedToManagerException
void connectToManager () throws CannotRetrieveManagerException, NoPermissionEx, SystemException
void disconnectFromManager ()
ContainerInfo[] retrieveContainerInfo (String name_wildcard) throws NotConnectedToManagerException, NoPermissionEx, SystemException
ClientInfo[] retrieveClientInfo (String name_wildcard) throws NotConnectedToManagerException, NoPermissionEx, SystemException
ComponentInfo[] retrieveComponentInfo (String name_wildcard) throws NotConnectedToManagerException, NoPermissionEx, SystemException
void refreshNowFailed (Exception exc)
SortingTreeNode createNode (Object info)
SortingTreeNode createNode (Object info, boolean allowInfoDetails)
String extractLocation (org.omg.CORBA.Object reference)

Protected Attributes

String name = null
String managerLoc = null
ORB orb = null
Logger log = null
boolean connectsAutomatically = true
ManagerConnectionExceptionHandler mcehandler
final MaciInfo maciInfo
RefreshIfNeeded refreshTask
Timer timer = new Timer("MaciSupervisor.Refresher", true)
Manager managerRef = null
volatile boolean infoShouldBeRefreshed
ClientInfo administratorClientInfo = null
AdministratorImplementation acImpl

Detailed Description

Author:
mschilli


Constructor & Destructor Documentation

alma::acs::commandcenter::meta::MaciSupervisor::MaciSupervisor String  clientName,
String  managerLoc,
ORB  orb,
Logger  log
[inline, protected]
 

Creates a MaciSupervisor running on the given ORB, it will connect to the specified manager.

Parameters:
clientName name-prefix like "AcsCommandCenter" or "OMC"
managerLoc the manager corbaloc
orb the orb to use


Member Function Documentation

void alma::acs::commandcenter::meta::MaciSupervisor::connectToManager  )  throws CannotRetrieveManagerException, NoPermissionEx, SystemException [inline, protected]
 

SortingTreeNode alma::acs::commandcenter::meta::MaciSupervisor::createNode Object  info,
boolean  allowInfoDetails
[inline, protected]
 

Factory method, the boolean parameter supresses auto-generated sub-nodes

SortingTreeNode alma::acs::commandcenter::meta::MaciSupervisor::createNode Object  info  )  [inline, protected]
 

Factory method

void alma::acs::commandcenter::meta::MaciSupervisor::disconnectFromManager  )  [inline, protected]
 

synchronized void alma::acs::commandcenter::meta::MaciSupervisor::dismissManager  )  [inline]
 

msc (2004-11-09): This was requested, suggested, and agreed upon as a workaround for the situation where a manager has gone down (and the application using this macisupervisor knows that the manager is down, e.g. because it made it go down) while this macisupervisor does not yet know that the manager is down. It will only realize that the next time it tries to access it. Doing so will provoke some no_permission error messages in the manager log. To enable the application to avoid these error messages this API method was added.

Implements alma::acs::commandcenter::meta::IMaciSupervisor.

String alma::acs::commandcenter::meta::MaciSupervisor::extractLocation org.omg.CORBA.Object  reference  )  [inline, protected]
 

Helper for createNode()

Returns:
{host, port}, or null on failure

MaciInfo alma::acs::commandcenter::meta::MaciSupervisor::getMaciInfo  )  throws NoPermissionEx, NotConnectedToManagerException, CorbaTransientException, CorbaNotExistException, UnknownErrorException [inline]
 

Returns a TreeModel compiled from information from the Acs manager. The returned model will never become invalid during the lifetime of this MaciSupervisor, and it will be automatically updated.

A call to this method will automatically trigger a refresh, possibly throwing an exception or blocking the current thread for a long time. Calling getMaciInformation() and refreshSoon() will shield you from these effects.

Returns:
a stable maciInfo instance, never null
Exceptions:
NotConnectedToManagerException 
NoPermissionEx 
UnknownErrorException 
CorbaNotExistException 
CorbaTransientException 

Implements alma::acs::commandcenter::meta::IMaciSupervisor.

MaciInfo alma::acs::commandcenter::meta::MaciSupervisor::getMaciInformation  )  [inline]
 

Returns a TreeModel compiled from information from the Acs manager. The returned model will never become invalid during the lifetime of this MaciSupervisor, and it will be automatically updated.

The returned model may be out-of-date. Call refreshSoon() to have it updated.

Returns:
a stable maciInfo instance, never null

String alma::acs::commandcenter::meta::MaciSupervisor::getManagerLocation  )  [inline]
 

Some people are interested in the weirdest things..

Implements alma::acs::commandcenter::meta::IMaciSupervisor.

boolean alma::acs::commandcenter::meta::MaciSupervisor::isConnected  )  [inline]
 

Whether this is connected

Implements alma::acs::commandcenter::meta::IMaciSupervisor.

int alma::acs::commandcenter::meta::MaciSupervisor::myMaciHandle  )  throws NotConnectedToManagerException [inline]
 

Exceptions:
NotConnectedToManagerException 

Implements alma::acs::commandcenter::meta::IMaciSupervisor.

Manager alma::acs::commandcenter::meta::MaciSupervisor::myManagerReference  )  throws NotConnectedToManagerException [inline, protected]
 

Exceptions:
NotConnectedToManagerException 

synchronized void alma::acs::commandcenter::meta::MaciSupervisor::refreshNow  )  throws NoPermissionEx, NotConnectedToManagerException, SystemException, CorbaTransientException, CorbaNotExistException, UnknownErrorException [inline]
 

Tries to refresh the component-section, container-section, and client-section of the info tree model. The treemodel will be updated when things go well and also when things fail.

A call to this method will instantly perform a refresh, possibly throwing an exception or blocking the current thread for a long time. Calling getMaciInformation() and refreshSoon() will shield you from these effects.

Exceptions:
NoPermissionEx error during refresh
NotConnectedToManagerException error during refresh
CorbaTransientException 
CorbaNotExistException 
UnknownErrorException 

void alma::acs::commandcenter::meta::MaciSupervisor::refreshNowFailed Exception  exc  )  [inline, protected]
 

Helper for refreshNow() - i like when the nodes disappear in case of error

void alma::acs::commandcenter::meta::MaciSupervisor::refreshSoon  )  [inline]
 

Request the MaciInfo be refreshed in the background.

ClientInfo [] alma::acs::commandcenter::meta::MaciSupervisor::retrieveClientInfo String  name_wildcard  )  throws NotConnectedToManagerException, NoPermissionEx, SystemException [inline, protected]
 

Exceptions:
NoPermissionEx 
NotConnectedToManagerException 
SystemException 

ComponentInfo [] alma::acs::commandcenter::meta::MaciSupervisor::retrieveComponentInfo String  name_wildcard  )  throws NotConnectedToManagerException, NoPermissionEx, SystemException [inline, protected]
 

Exceptions:
NoPermissionEx 
NotConnectedToManagerException 
SystemException 

ContainerInfo [] alma::acs::commandcenter::meta::MaciSupervisor::retrieveContainerInfo String  name_wildcard  )  throws NotConnectedToManagerException, NoPermissionEx, SystemException [inline, protected]
 

The containerHandles argument cannot be specified here. Reason: There's apparently a bug in Manager.get_activator_info() in ACS2.x (nothing known about ACS3.x): The containerHandles argument is not evaluated properly, instead empty (therefore useless) ContainerInfos are returned.

Parameters:
name_wildcard not verified to work as expected, recommended to use '*'.
Returns:
Exceptions:
NoPermissionEx 
NotConnectedToManagerException 
SystemException 

void alma::acs::commandcenter::meta::MaciSupervisor::setConnectsAutomatically boolean  b  )  [inline]
 

synchronized void alma::acs::commandcenter::meta::MaciSupervisor::start  )  throws NoPermissionEx, CannotRetrieveManagerException, CorbaTransientException, CorbaNotExistException, UnknownErrorException [inline]
 

This start implementation is smart, it can be called repeatedly.

Exceptions:
NoPermissionEx 
CorbaTransientException 
CorbaNotExistException 
UnknownErrorException 

Implements alma::acs::commandcenter::meta::IMaciSupervisor.

synchronized void alma::acs::commandcenter::meta::MaciSupervisor::stop  )  [inline]
 

Tear down this instance.

Implements alma::acs::commandcenter::meta::IMaciSupervisor.

Override String alma::acs::commandcenter::meta::MaciSupervisor::toString  )  [inline]
 

Overridden to provide pretty description.


Member Data Documentation

AdministratorImplementation alma::acs::commandcenter::meta::MaciSupervisor::acImpl [protected]
 

Instantiated in constructor. The retrieved descriptor will be stored in field administratorClientInfo.

ClientInfo alma::acs::commandcenter::meta::MaciSupervisor::administratorClientInfo = null [protected]
 

assigned in connectToManager(). unassigned in disconnectFromManager(). This means, this field indicates the "connected" status.

boolean alma::acs::commandcenter::meta::MaciSupervisor::connectsAutomatically = true [protected]
 

volatile boolean alma::acs::commandcenter::meta::MaciSupervisor::infoShouldBeRefreshed [protected]
 

The 'refresh needed' flag used by the lazy-refresh timer task.

Logger alma::acs::commandcenter::meta::MaciSupervisor::log = null [protected]
 

final MaciInfo alma::acs::commandcenter::meta::MaciSupervisor::maciInfo [protected]
 

String alma::acs::commandcenter::meta::MaciSupervisor::managerLoc = null [protected]
 

Manager alma::acs::commandcenter::meta::MaciSupervisor::managerRef = null [protected]
 

assigned in connectToManager()

ManagerConnectionExceptionHandler alma::acs::commandcenter::meta::MaciSupervisor::mcehandler [protected]
 

String alma::acs::commandcenter::meta::MaciSupervisor::name = null [protected]
 

ORB alma::acs::commandcenter::meta::MaciSupervisor::orb = null [protected]
 

RefreshIfNeeded alma::acs::commandcenter::meta::MaciSupervisor::refreshTask [protected]
 

Timer alma::acs::commandcenter::meta::MaciSupervisor::timer = new Timer("MaciSupervisor.Refresher", true) [protected]
 


The documentation for this class was generated from the following file:
Generated on Thu Apr 30 02:52:12 2009 for ACS Java API by doxygen 1.3.8