com.ibm.broker.config.proxy
Class ConfigManagerProxy

java.lang.Object
  extended by com.ibm.broker.config.proxy.AdministeredObject
      extended by com.ibm.broker.config.proxy.ConfigManagerProxy

public class ConfigManagerProxy
extends AdministeredObject

This class allows applications to connect to and manipulate Configuration Managers. All domain objects are accessible through this one.

In order to use ConfigManagerProxy objects, applications must first obtain handles to them. Here is an example of how to do this:

     ConfigManagerConnectionParameters cmcp =
         new MQConfigManagerConnectionParameters("localhost", 1414, "QMGR");
     ConfigManagerProxy cmp = ConfigManagerProxy.getInstance(cmcp);
 

com.ibm.broker.config.proxy.ConfigManagerProxy extends com.ibm.broker.config.proxy.AdministeredObject

Responsibilities
  • Represents a container for all managed objects within a Configuration Manager's domain.
  • Each instance also represents a connection to a Configuration Manager.
  • Provides shortcuts to individual object types managed by the API, and to global Configuration Manager operations (e.g. system trace)
Internal Collaborators com.ibm.broker.config.proxy.TopologyProxy
com.ibm.broker.config.proxy.LogProxy
com.ibm.broker.config.proxy.TopicRootProxy
com.ibm.broker.config.proxy.ConfigManagerConnectionParameters
com.ibm.broker.config.proxy.SubscriptionsProxy

 Change Activity:
 -------- ----------- -------------   ------------------------------------
 Reason:  Date:       Originator:     Comments:
 -------- ----------- -------------   ------------------------------------
 f19590.1 2004-03-19  HDMPL           v6 Release
 f44739.7 2007-07-30  HDMPL           v6.1 release:
                                         Methods now return genericized types where relevant
                                         Added setAutoDiscoveryIntervalMins(int)
                                         Added getAutoDiscoveryIntervalMins()

 

Version:
Config/com/ibm/broker/config/proxy/ConfigManagerProxy.java, CMP, S000 1.91

Field Summary
static long MAX_WAIT_TIME
          The maximum amount of time the Configuration Manager Proxy can be told to wait for Configuration Manager messages until a ConfigManagerProxyPropertyNotInitialisedException is thrown.
 
Method Summary
 void addAccessControlEntries(AccessControlEntry[] accessControlList)
          Adds this list to the list of access control entries that applies to this object.
 void beginUpdates()
          Tells the ConfigManagerProxy to hold back from sending any subsequent state-changing requests to the Configuration Manager, so multiple requests can be later sent off in a single message (or "batch").
 void cancelDeployment()
          Tells the Configuration Manager to remove all of the deployment locks that are currently in place.
 DeployResult cancelDeployment(long timeToWaitMs)
          Tells the Configuration Manager to remove all of the deployment locks that are currently in place.
 void clearUpdates()
          Tells the ConfigManagerProxy to discard any state-changing requests received since the last call to beginUpdates().
 void deregisterListeners()
          Deregisters ALL external listeners associated with the current ConfigManagerProxy connection.
static void disableConfigManagerProxyTracing()
          Stops Configuration Manager Proxy service tracing.
 void disconnect()
          Deregisters all listeners registered to this ConfigManagerProxy instance and closes the link to the Config Manager.
static void enableConfigManagerProxyTracing(java.lang.String filename)
          Enables Configuration Manager Proxy service tracing, sending output to the file with the supplied name.
 AccessControlEntry[] getAccessControlEntries()
          Creates and returns a set of AccessControlEntry objects that describes the set of (principal,permission) tuples that have been applied specifically to this object.
 int getAutoDiscoveryIntervalMins()
          Returns the period of time (in minutes) between automatic discoveries of broker information from the Configuration Manager.
 java.lang.String getConfigManagerFullVersion()
          Returns the full version string of the Configuration Manager to which this Configuration Manager Proxy instance is connected.
 java.lang.String getConfigManagerOSArch()
          Returns a string describing the architecture of the Configuration Manager machine to which this Configuration Manager Proxy is connected.
 java.lang.String getConfigManagerOSName()
          Returns a string describing the name of the operating system running on the Configuration Manager machine to which this Configuration Manager Proxy is connected.
 java.lang.String getConfigManagerOSVersion()
          Returns a string describing the version of the operation system on the Configuration Manager machine to which this Configuration Manager Proxy is connected.
static int getConfigManagerProxyVersion()
          Returns the major version string for the Configuration Manager Proxy (the constant AttributeConstants.VERSION_6_1).
 int getConfigManagerVersion()
          Returns the major version identifier of the Configuration Manager to which the Configuration Manager Proxy is connected.
 ConfigurationObjectType getConfigurationObjectType()
          Returns the ConfigurationObjectType associated with this AdministeredObject type.
 ConfigurationObjectType getConfigurationObjectTypeOfParent()
          Returns the ConfigurationObjectType associated with the logical parent of this AdministeredObject type.
static ConfigManagerProxy getInstance(ConfigManagerConnectionParameters cmcp)
          Asks the Configuration Manager Proxy to connect to a Configuration Manager with the supplied parameters.
 LogProxy getLog()
          Asks the Configuration Manager to register for all log records associated with the current user, through a LogProxy instance.
 SubscriptionsProxy getSubscriptions(java.lang.String topic, java.lang.String brokers, java.lang.String users, java.lang.String subscriptionsPoints, java.util.GregorianCalendar startDate, java.util.GregorianCalendar endDate)
          Generates a SubscriptionsProxy that represents those subscriptions fulfilling the supplied criteria.
 TopicRootProxy getTopicRoot()
          Returns the RootTopicProxy object associated with this Configuration Manager.
 TopologyProxy getTopology()
          Returns the TopologyProxy object associated with this Configuration Manager.
 boolean isBatching()
          Returns true if and only if the creation of a batch is currently in progress.
 boolean isIncompatible()
          Returns true if and only if the Configuration Manager Proxy has received a message from the Configuration Manager which indicates that the Configuration Manager is unable to process requests from this Configuration Manager Proxy because the versions are not compatible.
 boolean isIncompatible(boolean waitIfNotUpdated)
          Returns true if and only if the Configuration Manager Proxy has received a message from the Configuration Manager which indicates that the Configuration Manager is unable to process requests from this Configuration Manager Proxy because the versions are not compatible.
 void removeAccessControlEntries(AccessControlEntry[] accessControlList)
          Deletes this list from the list of access control entries that applies to this object.
 void sendUpdates()
          Tells the ConfigManagerProxy to send to the Configuration Manager all requests received since the beginUpdates() call.
 void sendUpdates(int correlationID)
          Tells the ConfigManagerProxy to send to the Configuration Manager all requests received since the beginUpdates() call.
 void setAccessControlEntries(AccessControlEntry[] accessControlList)
          Sets the complete list of access control entries that apply to this object.
 void setAutoDiscoveryIntervalMins(int newIntervalMins)
          Sets the period of time between attempts by the Configuration Manager to automatically discover broker information.
static void setLogger(java.lang.String className)
          If directed to gather Configuration Manager Proxy trace for IBM service, do not use this method - use enableTracing(String) and disableTracing() instead.
static void setLogger(java.lang.String className, java.lang.String params)
          Initializes a Configuration Manager Proxy logger.
static void setRetryCharacteristics(int maxRetries, int baseRetryWaitTime, int retryWaitTimeIncrement)
          Sets the retry characteristics for the Configuration Manager Proxy.
static void setRetryCharacteristics(long maxWaitTimeMs)
          Sets the retry characteristics for the Configuration Manager Proxy.
 void startDebugSystemTrace()
          Asks the Configuration Manager to start debug system trace.
 void startSystemTrace()
          Asks the Configuration Manager to start system trace.
 void stopSystemTrace()
          Asks the Configuration Manager to stop system trace.
static java.util.Properties withUUID(java.lang.String uuid)
          Returns a new Properties object that has the UUID attribute set to the supplied String, and the type attribute to be the name of the subclass of AdministeredObject being used.
 
Methods inherited from class com.ibm.broker.config.proxy.AdministeredObject
deregisterListener, deregisterListener, elements, getLastBIPMessages, getLastCompletionCode, getLastUpdateUser, getLongDescription, getManagedSubcomponent, getManagedSubcomponentFromStringRepresentation, getManagedSubcomponents, getManagedSubcomponents, getManagedSubcomponents, getManagedSubcomponents, getManagedSubcomponentsAsStrings, getManagedSubcomponentsAsStrings, getName, getNumberOfSubcomponents, getParent, getProperties, getProperty, getProperty, getProperty, getProperty, getRepositoryTimestamp, getShortDescription, getTimeOfLastCompletionCode, getTimeOfLastUpdate, getType, getUUID, hasBeenRestrictedByConfigManager, hasBeenRestrictedByConfigManager, hasBeenUpdatedByConfigManager, hasBeenUpdatedByConfigManager, isAwaitingSubmissionForCreation, isAwaitingSubmissionForDeletion, isDeployed, isShared, refresh, registerListener, registerListener, registerListener, setLongDescription, setName, setProperties, setShortDescription, toString, toVerboseString, unsubscribeFromConfigurationManagerUpdates, withName
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

MAX_WAIT_TIME

public static final long MAX_WAIT_TIME
The maximum amount of time the Configuration Manager Proxy can be told to wait for Configuration Manager messages until a ConfigManagerProxyPropertyNotInitialisedException is thrown. The actual value used can be set using ConfigManagerProxy.setRetryCharacteristics(long).

See Also:
Constant Field Values
Method Detail

getInstance

public static ConfigManagerProxy getInstance(ConfigManagerConnectionParameters cmcp)
                                      throws ConfigManagerProxyLoggedException
Asks the Configuration Manager Proxy to connect to a Configuration Manager with the supplied parameters. The sole parameter to this method is a ConfigManagerConnectionParameters object, of which there are two implementors currently:

Parameters:
cmcp - An object describing the connection parameters to the Configuration Manager. Cannot be null.
Returns:
ConfigManagerProxy a object that represents the connection to a Configuration Manager.
Throws:
ConfigManagerProxyLoggedException - if a connection could not be established for whatever reason.

disconnect

public void disconnect()
Deregisters all listeners registered to this ConfigManagerProxy instance and closes the link to the Config Manager. This makes client APIs unusable. After calling this method, the only way to re-establish the link to the Config Manager is by reissuing the ConfigManagerProxy.getInstance() call.


cancelDeployment

public void cancelDeployment()
                      throws ConfigManagerProxyLoggedException
Tells the Configuration Manager to remove all of the deployment locks that are currently in place. This method does not recall deployment messages that have already been sent to the broker, nor does it tell the broker to ignore any previous deployment requests. Therefore after cancelling deployment, it is essential that any unprocessed deployment messages are manually removed from the brokers' SYSTEM.BROKER.ADMIN.QUEUE queues. If this is not done, and a broker subsequently processes a deployment message that was cancelled, the Configuration Manager may become out of sync with the broker.

Only use this method if multiple brokers are not responding and you are sure that the outstanding deployment messages will never be processed by the brokers to which they are addressed.

If a single broker is not responding and the Configuration Manager Proxy is connected to a Configuration Manager of at least version 6, consider BrokerProxy.cancelDeployment() instead.

Throws:
ConfigManagerProxyLoggedException - if the request could not be sent to the Configuration Manager.

cancelDeployment

public DeployResult cancelDeployment(long timeToWaitMs)
                              throws ConfigManagerProxyLoggedException
Tells the Configuration Manager to remove all of the deployment locks that are currently in place. This method does not recall deployment messages that have already been sent to the broker, nor does it tell the broker to ignore any previous deployment requests. Therefore after cancelling deployment, it is essential that any unprocessed deployment messages are manually removed from the brokers' SYSTEM.BROKER.ADMIN.QUEUE queues. If this is not done, and a broker subsequently processes a deployment message that was cancelled, the Configuration Manager may become out of sync with the broker.

Only use this method if multiple brokers are not responding and you are sure that the outstanding deployment messages will never be processed by the brokers to which they are addressed.

If a single broker is not responding and the Configuration Manager Proxy is connected to a Configuration Manager of at least version 6, consider BrokerProxy.cancelDeployment() instead.

Parameters:
timeToWaitMs - A positive value describes the maximum length of time to wait for a response from the Configuration Manager (in milliseconds) before returning the DeployResult. Alternatively:
  • A value of 0 causes the method to return immediately after the message has been successfully sent to the Configuration Manager.
  • A value of AttributeConstants.DEPLOYRESULT_SUPPRESSION causes the method to return null immediately after the message has been successfully sent to the Configuration Manager. DeployResult objects are relatively expensive to create and maintain, and so supplying this constant should be used if the DeployResult is not parsed, or if performance of the Configuration Manager Proxy application is critical.
  • A value of AttributeConstants.DEPLOYRESULT_WAIT_INDEFINITELY causes the method to wait indefinitely for the response from the Configuration Manager.
  • If batch mode is enabled the method returns immediately regardless of the value of this parameter. All completion codes in the returned DeployResult object will be 'pending' unless the value of timeToWaitMs is AttributeConstants.DEPLOYRESULT_SUPPRESSION, in which case the DeployResult will be null (as usual).
Returns:
DeployResult object that can be used to query the results of the deployment. Note that the cancel deployment operation does not require any interaction with the brokers in the domain, and so the DeployResult object will not contain any broker-specific results (for example, getDeployedBrokers() will return an empty enumeration).
Throws:
ConfigManagerProxyLoggedException - if the request could not be sent to the Configuration Manager.

deregisterListeners

public void deregisterListeners()
Deregisters ALL external listeners associated with the current ConfigManagerProxy connection.

Note: The same effect can be achieved by using ConfigManagerProxy.disconnect(). The difference is that this call doesn't close the link to the Configuration Manager- it is possible to use call this method and still make use of the APIs and the listener registration mechanism.


getTopology

public TopologyProxy getTopology()
                          throws ConfigManagerProxyPropertyNotInitializedException
Returns the TopologyProxy object associated with this Configuration Manager.

Returns:
TopologyProxy - a reference to the topology object associated with the Configuration Manager, or null if there is no topology information available in the Configuration Manager.
Throws:
ConfigManagerProxyPropertyNotInitializedException - if the Topology subcomponent could not be loaded because the Config Manager has not yet supplied the required information.

getConfigManagerProxyVersion

public static int getConfigManagerProxyVersion()
Returns the major version string for the Configuration Manager Proxy (the constant AttributeConstants.VERSION_6_1). Future versions of the Configuration Manager Proxy may return different values.

Returns:
int

getTopicRoot

public TopicRootProxy getTopicRoot()
                            throws ConfigManagerProxyPropertyNotInitializedException
Returns the RootTopicProxy object associated with this Configuration Manager.

Returns:
RootTopicProxy - a reference to the root topic object associated with the Configuration Manager. Returns null if there is no root topic associated with this Configuration Manager.
Throws:
ConfigManagerProxyPropertyNotInitializedException - if the Topology subcomponent could not be loaded because the Config Manager has not yet supplied the required information.

getSubscriptions

public SubscriptionsProxy getSubscriptions(java.lang.String topic,
                                           java.lang.String brokers,
                                           java.lang.String users,
                                           java.lang.String subscriptionsPoints,
                                           java.util.GregorianCalendar startDate,
                                           java.util.GregorianCalendar endDate)
                                    throws ConfigManagerProxyLoggedException
Generates a SubscriptionsProxy that represents those subscriptions fulfilling the supplied criteria.

Parameters:
topic - Name of the topic to search, or null to search all topic names. '%' can be used within the string to denote a wildcard.
brokers - Which brokers to search, or null to search all brokers. '%' can be used within the string to denote a wildcard.
users - Which users to search, or null to search all users. '%' can be used within the string to denote a wildcard.
subscriptionsPoints - Which subscriptions points to search, or null to search all subscriptions points. '%' can be used within the string to denote a wildcard.
startDate - The earliest date to search, or null to not specify a start date.
endDate - The latest date to search, or null to not specify an end date.
Returns:
SubscriptionsProxy Object that describes the query. The object will be asynchronously populated with the matching results.
Throws:
ConfigManagerProxyLoggedException - if the request could not be sent to the Configuration Manager.

getLog

public LogProxy getLog()
                throws ConfigManagerProxyPropertyNotInitializedException
Asks the Configuration Manager to register for all log records associated with the current user, through a LogProxy instance.

Returns:
LogProxy represents all log records associated with the current user.
Throws:
ConfigManagerProxyPropertyNotInitializedException - if the Topology subcomponent could not be loaded because the Config Manager has not yet supplied the required information.

getConfigurationObjectTypeOfParent

public ConfigurationObjectType getConfigurationObjectTypeOfParent()
Returns the ConfigurationObjectType associated with the logical parent of this AdministeredObject type. As the ConfigManagerProxy is the root of the hierarchy, this method returns null.

Specified by:
getConfigurationObjectTypeOfParent in class AdministeredObject
Returns:
ConfigurationObjectType associated with the logical parent of this class.

setRetryCharacteristics

public static void setRetryCharacteristics(int maxRetries,
                                           int baseRetryWaitTime,
                                           int retryWaitTimeIncrement)
Sets the retry characteristics for the Configuration Manager Proxy. These settings are used for all ConfigManagerProxy connections in the JVM.

The Configuration Manager Proxy may not always have been supplied a required piece of information that is needed to perform an operation (e.g. it can't return a broker's execution group list if that broker's information has not been supplied to it by the Configuration Manager). This can happen if the proxy has a slow link to the Configuration Manager, or if the Configuration Manager is heavily burdened or just not running.

Collectively, the parameters supplied to this method represent the maximum amount of time to wait for the required information to arrive before the exception is thrown. Specifically, three parameters are required which describe how many times the Configuration Manager Proxy should poll incoming messages from the Configuration Manager to see if the required information has arrived. The three parameters are: the number of times to retry, the initial amount of time to wait between failure (in milliseconds) and the amount of time to increase the wait time by on successive failure (again in milliseconds).

So supplying (10,1000,1000) to this method (which happens to be the default) means that retries will occur one, two, four, seven, eleven seconds after the first failure (and so on). If the required information still cannot be found after the number of maxRetries is exhausted, a ConfigManagerProxyPropertyNotInitializedException will be thrown to the calling application.

Parameters:
maxRetries - the maximum number of consecutive failures before an exception is thrown to the calling application.
baseRetryWaitTime - The initial time to wait between retries (in milliseconds)
retryWaitTimeIncrement - How much to increase the retry wait time by after each consecutive failure.

setRetryCharacteristics

public static void setRetryCharacteristics(long maxWaitTimeMs)
Sets the retry characteristics for the Configuration Manager Proxy. These settings are used for all ConfigManagerProxy connections in the JVM.

The Configuration Manager Proxy may not always have been supplied a required piece of information that is needed to perform an operation (e.g. it can't return a broker's execution group list if that broker's information has not been supplied to it by the Configuration Manager). This can happen if the proxy has a slow link to the Configuration Manager, or if the Configuration Manager is heavily burdened or just not running.

Parameters:
maxWaitTimeMs - the maximum length of time the Configuration Manager Proxy can wait for a response from the Configuration Manager before a ConfigManagerProxyPropertyNotInitalizedException is thrown. The maximum value allowed value is ConfigManagerProxy.MAX_WAIT_TIME If the supplied value is greater than this, ConfigManagerProxy.MAX_WAIT_TIME will be used instead.

enableConfigManagerProxyTracing

public static void enableConfigManagerProxyTracing(java.lang.String filename)
                                            throws ConfigManagerProxyLoggedException
Enables Configuration Manager Proxy service tracing, sending output to the file with the supplied name. Enabling service trace will cause the Configuration Manager Proxy to work more slowly than usual.

Not to be confused with startSystemTrace() and startDebugSystemTrace(), which enables tracing of the Configuration Manager.

Parameters:
filename - File spec of the output file, which cannot be null.
Throws:
ConfigManagerProxyLoggedException - if the logger could not be instantiated.

disableConfigManagerProxyTracing

public static void disableConfigManagerProxyTracing()
Stops Configuration Manager Proxy service tracing.

Not to be confused with stopSystemTrace(), which enables tracing of the Configuration Manager.


setLogger

public static void setLogger(java.lang.String className,
                             java.lang.String params)
                      throws ConfigManagerProxyLoggedException
Initializes a Configuration Manager Proxy logger. If directed to gather Configuration Manager Proxy trace for IBM service, do not use this method - use enableConfigManagerProxyTracing(String) and disableConfigManagerProxyTracing() instead. Use startDebugSystemTrace(), startSystemTrace() and stopSystemTrace() to control Configuration Manager tracing. Use MessageFlowProxy.setUserTrace() to control tracing of message flows.

Parameters:
className - Fully qualified name of the logger class (must extend com.ibm.broker.config.proxy.Logger) A null or blank value here will disable logging.
params - any parameters required by the logger
Throws:
ConfigManagerProxyLoggedException - if the logger could not be instantiated.

setLogger

public static void setLogger(java.lang.String className)
                      throws ConfigManagerProxyLoggedException
If directed to gather Configuration Manager Proxy trace for IBM service, do not use this method - use enableTracing(String) and disableTracing() instead. Use startDebugSystemTrace(), startSystemTrace() and stopSystemTrace() to control Configuration Manager tracing. Use MessageFlowProxy.setUserTrace() to control tracing of message flows.

This method sets up an logger that does not require parameters.

Parameters:
className - Fully qualified name of the logger class (must extend com.ibm.broker.config.proxy.Logger). A null or blank value here will disable logging.
Throws:
ConfigManagerProxyLoggedException - if the logger could not be instantiated.

beginUpdates

public void beginUpdates()
                  throws ConfigManagerProxyLoggedException
Tells the ConfigManagerProxy to hold back from sending any subsequent state-changing requests to the Configuration Manager, so multiple requests can be later sent off in a single message (or "batch"). Requests for information (for instance, requests to discover an object's attributes) will not be batched. The scope of this method is for any requests using this ConfigManagerProxy connection to the Configuration Manager.

Throws:
ConfigManagerProxyLoggedException - - if a batch is already in progress.
See Also:
sendUpdates(), clearUpdates(), isBatching()

sendUpdates

public void sendUpdates()
                 throws ConfigManagerProxyLoggedException
Tells the ConfigManagerProxy to send to the Configuration Manager all requests received since the beginUpdates() call. After this method completes, subsequent requests will not be batched unless another beginUpdates() is called.

Throws:
ConfigManagerProxyLoggedException - If a batch was not in progress, if the batch contained no requests, or if the request could not be sent to the Configuration Manager.
See Also:
beginUpdates(), clearUpdates(), isBatching()

sendUpdates

public void sendUpdates(int correlationID)
                 throws ConfigManagerProxyLoggedException
Tells the ConfigManagerProxy to send to the Configuration Manager all requests received since the beginUpdates() call. After this method completes, subsequent requests will not be batched unless another beginUpdates() is called.

Parameters:
correlationID - Identifier that will accompany any actionresponse messages sent back to the caller through the AdministeredObjectListener interface.
Throws:
ConfigManagerProxyLoggedException - if a batch was not in progress, if the batch contained no requests or if the request could not be sent to the Configuration Manager.
See Also:
beginUpdates(), sendUpdates(), clearUpdates(), isBatching()

clearUpdates

public void clearUpdates()
Tells the ConfigManagerProxy to discard any state-changing requests received since the last call to beginUpdates(). If a batch was not in progress, or if the current batch has already been submitted using sendUpdates(), this call does nothing.

See Also:
beginUpdates(), sendUpdates(), isBatching()

isBatching

public boolean isBatching()
Returns true if and only if the creation of a batch is currently in progress.

Returns:
boolean status of batch mode
See Also:
beginUpdates(), sendUpdates(), clearUpdates()

isIncompatible

public boolean isIncompatible()
Returns true if and only if the Configuration Manager Proxy has received a message from the Configuration Manager which indicates that the Configuration Manager is unable to process requests from this Configuration Manager Proxy because the versions are not compatible. If the ConfigManagerProxy object has not yet received any update from the Configuration Manager, the call will block until the first response (e.g. 'Proxy is incompatible' message) is received (or the timeout configured in ConfigManagerProxy.setRetryCharacteristics() occurs).

Note that the timeout condition will result in the response of false being returned, correctly indicating that no 'object-restricted' response has been received. Callers wishing to programmatically detect the timeout condition should use hasBeenUpdatedByConfigManager(true).

Returns:
boolean true if and only if the Configuration Manager is unable to successfully communicate with this Proxy.

isIncompatible

public boolean isIncompatible(boolean waitIfNotUpdated)
Returns true if and only if the Configuration Manager Proxy has received a message from the Configuration Manager which indicates that the Configuration Manager is unable to process requests from this Configuration Manager Proxy because the versions are not compatible.

Parameters:
waitIfNotUpdated - If this is set to true and the administered object has not yet received an update from the Configuration Manager, the call will block until the first response (e.g. the 'Proxy is incompatible' message) is received (or the timeout configured in ConfigManagerProxy.setRetryCharacteristics() occurs). This parameter allows the caller to ensure correctness of the returned value (if the value of the incompatible flag is sought before the first response from the Config Manager has necessarily been returned, the method may confusingly return 'false' even though the Config Manager is not compatible).
Returns:
boolean true if and only if the Configuration Manager is unable to successfully communicate with this Proxy because of a version incompatibility.

startSystemTrace

public void startSystemTrace()
                      throws ConfigManagerProxyLoggedException
Asks the Configuration Manager to start system trace. Not to be confused with enableTracing(), which enables tracing of the Configuration Manager Proxy application.

Throws:
ConfigManagerProxyLoggedException - if the request to start system trace could not be sent to the Configuration Manager.

stopSystemTrace

public void stopSystemTrace()
                     throws ConfigManagerProxyLoggedException
Asks the Configuration Manager to stop system trace. Not to be confused with disableTracing(), which enables tracing of the Configuration Manager Proxy application.

Throws:
ConfigManagerProxyLoggedException - if the request to stop system trace could not be sent to the Configuration Manager.

startDebugSystemTrace

public void startDebugSystemTrace()
                           throws ConfigManagerProxyLoggedException
Asks the Configuration Manager to start debug system trace.

Throws:
ConfigManagerProxyLoggedException - if the request to start system trace could not be sent to the Configuration Manager.

getConfigManagerVersion

public int getConfigManagerVersion()
                            throws ConfigManagerProxyPropertyNotInitializedException
Returns the major version identifier of the Configuration Manager to which the Configuration Manager Proxy is connected. The returned value will be one of the following:

getAutoDiscoveryIntervalMins

public int getAutoDiscoveryIntervalMins()
                                 throws ConfigManagerProxyPropertyNotInitializedException
Returns the period of time (in minutes) between automatic discoveries of broker information from the Configuration Manager. If the value returned is less than zero, automatic discoveries are disabled.

Note: AdministeredObjectListeners of the ConfigManagerProxy object will not be notified if this setting is changed. Use the refresh() method (or reconnect to the Configuration Manager), followed by getAutoDiscoveryIntervalMins() to determine the active value for this property.

If the Configuration Manager Proxy is connected to a Configuration Manager of less than v6.1 level, this method returns -1. Use ConfigManagerProxy.getConfigManagerVersion() to return the version of the connected Configuration Manager.

Returns:
int time (in minutes) that the Configuration Manager waits between automatic discovery attempts
Throws:
ConfigManagerProxyNotInitializedException - if the information was not supplied by the Configuration Manager before a timeout occurred.
ConfigManagerProxyPropertyNotInitializedException

setAutoDiscoveryIntervalMins

public void setAutoDiscoveryIntervalMins(int newIntervalMins)
                                  throws ConfigManagerProxyLoggedException
Sets the period of time between attempts by the Configuration Manager to automatically discover broker information. If the supplied value is greater than 10080 (the equivalent of one week), the value will be set to 10080. Use -1 to disable the automatic discovery of broker information.

Note: AdministeredObjectListeners of the ConfigManagerProxy object will not be notified if this setting is changed. Use the refresh() method (or reconnect to the Configuration Manager), followed by getAutoDiscoveryIntervalMins() to determine the active value for this property.

If the Configuration Manager Proxy is connected to a Configuration Manager of less than v6.1 level, this method does nothing.

Parameters:
newIntervalMins - The new interval (up to a maximum of 10080) or -1.
Throws:
ConfigManagerProxyLoggedException - if the request could not be sent to the Configuration Manager.

getConfigManagerFullVersion

public java.lang.String getConfigManagerFullVersion()
                                             throws ConfigManagerProxyPropertyNotInitializedException
Returns the full version string of the Configuration Manager to which this Configuration Manager Proxy instance is connected. The format of the string is not guaranteed.

If the Configuration Manager Proxy is connected to a Configuration Manager of less than v6 level, this method returns null.

Returns:
String full version
Throws:
ConfigManagerProxyNotInitializedException - if the version information was not supplied by the Configuration Manager before a timeout occurred.
ConfigManagerProxyPropertyNotInitializedException

getConfigManagerOSName

public java.lang.String getConfigManagerOSName()
                                        throws ConfigManagerProxyPropertyNotInitializedException
Returns a string describing the name of the operating system running on the Configuration Manager machine to which this Configuration Manager Proxy is connected. The returned value is the value of the 'os.name' system property in the Configuration Manager.

If the Configuration Manager Proxy is connected to a Configuration Manager of less than v6 level, this method returns null.

Returns:
String system property
Throws:
ConfigManagerProxyNotInitializedException - if the required information was not supplied by the Configuration Manager before a timeout occurred.
ConfigManagerProxyPropertyNotInitializedException

getConfigManagerOSArch

public java.lang.String getConfigManagerOSArch()
                                        throws ConfigManagerProxyPropertyNotInitializedException
Returns a string describing the architecture of the Configuration Manager machine to which this Configuration Manager Proxy is connected. The returned value is the value of the 'os.arch' system property in the Configuration Manager.

If the Configuration Manager Proxy is connected to a Configuration Manager of less than v6 level, this method returns null.

Returns:
String system property
Throws:
ConfigManagerProxyNotInitializedException - if the required information was not supplied by the Configuration Manager before a timeout occurred.
ConfigManagerProxyPropertyNotInitializedException

getConfigManagerOSVersion

public java.lang.String getConfigManagerOSVersion()
                                           throws ConfigManagerProxyPropertyNotInitializedException
Returns a string describing the version of the operation system on the Configuration Manager machine to which this Configuration Manager Proxy is connected. The returned value is the value of the 'os.version' system property in the Configuration Manager.

If the Configuration Manager Proxy is connected to a Configuration Manager of less than v6 level, this method returns null.

Returns:
String system property
Throws:
ConfigManagerProxyNotInitializedException - if the required information was not supplied by the Configuration Manager before a timeout occurred.
ConfigManagerProxyPropertyNotInitializedException

withUUID

public static java.util.Properties withUUID(java.lang.String uuid)
Returns a new Properties object that has the UUID attribute set to the supplied String, and the type attribute to be the name of the subclass of AdministeredObject being used. This provides an easy way of supplying filters to the get*() methods. For example, broker1.getExecutionGroup(ExecutionGroup.withUUID("1234")); will return the Execution Group with UUID "1234" that exists in broker1.

Parameters:
uuid - property to set
Returns:
Properties a new Properties object with the relevant key/value pairs set.

getConfigurationObjectType

public ConfigurationObjectType getConfigurationObjectType()
Returns the ConfigurationObjectType associated with this AdministeredObject type.

Specified by:
getConfigurationObjectType in class AdministeredObject
Returns:
ConfigurationObjectType associated with this class.

getAccessControlEntries

public AccessControlEntry[] getAccessControlEntries()
Creates and returns a set of AccessControlEntry objects that describes the set of (principal,permission) tuples that have been applied specifically to this object.

This method does not return details of permissions that have been implicitly granted by inherited access control entries.

Returns:
AccessControlEntry[] array of AccessControlEntry objects that apply to this object.
Throws:
ConfigManagerProxyPropertyNotInitializedException - if this objects list of Access Control Entries was not supplied by the Configuration Manager before a timeout occurred.

setAccessControlEntries

public void setAccessControlEntries(AccessControlEntry[] accessControlList)
                             throws ConfigManagerProxyLoggedException
Sets the complete list of access control entries that apply to this object. Null elements in the array are ignored. If the array itself is null or empty, all access control entries for this object are removed.

This method submits only changed access control entries to the Configuration Manager. It converts the supplied array into a set of access control entries to add and a set of access control entries to remove, based on the information currently supplied from the Configuration Manager. The add and remove operations are processed separately by the Configuration Manager as two atomic, transactional requests.

If the Configuration Manager to which the Configuration Manager Proxy is connected is of a version less than v6, this method will have no effect.

Parameters:
accessControlList - Array of access control entries which are to apply to this object.
Throws:
ConfigManagerProxyLoggedException - if the request to update the object could not be sent to the Configuration Manager.
ConfigManagerProxyPropertyNotInitializedException - if this objects current list of Access Control Entries was not supplied by the Configuration Manager before a timeout occurred.

addAccessControlEntries

public void addAccessControlEntries(AccessControlEntry[] accessControlList)
                             throws ConfigManagerProxyLoggedException
Adds this list to the list of access control entries that applies to this object. Null elements in the array are ignored.

This operation is completely transactional. If the Configuration Manager successfully processes this request, all access control entries from the supplied array will be associated with this administered object. If not, the access control list for this object will have not been modified.

If the Configuration Manager to which the Configuration Manager Proxy is connected is of a version less than v6, this method will have no effect.

Parameters:
accessControlList - Array of access control entries which are to be added to this object.
Throws:
ConfigManagerProxyLoggedException
ConfigManagerProxyLoggedException - if the request to update the object could not be sent to the Configuration Manager.

removeAccessControlEntries

public void removeAccessControlEntries(AccessControlEntry[] accessControlList)
                                throws ConfigManagerProxyLoggedException
Deletes this list from the list of access control entries that applies to this object. Null elements in the array are ignored. In addition, if any elements of the array are not associated with the administered object, they will be ignored.

This operation is completely transactional. If the Configuration Manager successfully processes this request, no access control entries from the supplied array will be associated with this administered object. If not, the access control list for this object will have not been modified.

If the Configuration Manager to which the Configuration Manager Proxy is connected is of a version less than v6, this method will have no effect.

Parameters:
accessControlList - Array of access control entries which are to be removed from this object.
Throws:
ConfigManagerProxyLoggedException - if the request to update the object could not be sent to the Configuration Manager.