it.imolinfo.jbi4corba.jbi.component.runtime
Class RuntimeConfiguration

java.lang.Object
  extended by it.imolinfo.jbi4corba.jbi.component.runtime.RuntimeConfiguration
All Implemented Interfaces:
RuntimeConfigurationMBean, NotificationBroadcaster, NotificationEmitter

public class RuntimeConfiguration
extends Object
implements RuntimeConfigurationMBean, NotificationEmitter

Runtime configuration MBean, allow configuration to be changed at run-time


Field Summary
static CompositeType APPVAR_ROW_TYPE
           
static TabularType APPVAR_TABULAR_TYPE
           
static String CONFIG_THREADS
           
static String PERSIST_APPLICATION_VARIABLE_CONFIG_FILE_NAME
           
 
Fields inherited from interface it.imolinfo.jbi4corba.jbi.component.runtime.RuntimeConfigurationMBean
CONFIG_APPLICATION_CONFIGURATIONS
 
Constructor Summary
RuntimeConfiguration(String workspaceRoot, String configSchema, String configData)
          Creates a new instance of InstallerExt
 
Method Summary
 void addApplicationConfiguration(String name, CompositeData appConfig)
          Add an application configuration.
 void addApplicationVariable(String name, CompositeData appVar)
          This operation adds a new applicationvariable.
 void addNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback)
           
 int countVariables()
           
 void deleteApplicationConfiguration(String name)
          Delete an application configuration.
 void deleteApplicationVariable(String name)
          This operation deletes an application variable, if a variable with the specified name does not exist, it's an error.
 TabularData getApplicationConfigurations()
          Get a Map of all application configurations for the component.
 TabularData getApplicationVariables()
          Get the Application Variable set for a component.
 MBeanNotificationInfo[] getNotificationInfo()
           
 Integer getOutboundThreads()
           
 CompositeType queryApplicationConfigurationType()
          Get the CompositeType definition for the components application configuration
 void removeNotificationListener(NotificationListener listener)
           
 void removeNotificationListener(NotificationListener listener, NotificationFilter filter, Object handback)
           
 Map retrieveApplicationConfigurationsMap()
          Retrieves the application configuration map.
 Map<String,String[]> retrieveApplicationVariablesMap()
          Retrieves the application variables map.
 String retrieveConfigurationDisplayData()
          Retrieves the configuration display data
 String retrieveConfigurationDisplaySchema()
          Retrieves the configuration display schema
 void setApplicationConfiguration(String name, CompositeData appConfig)
          Update a application configuration.
 void setApplicationVariable(String name, CompositeData appVar)
          This operation sets an application variable.
 void setOutboundThreads(Integer val)
           
 void updateApplicationConfigurationsMap(Map appConfigMap)
          Updates the application configuration map.
 void updateApplicationVariablesMap(Map<String,String[]> map)
          Updates the application variable map.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CONFIG_THREADS

public static final String CONFIG_THREADS
See Also:
Constant Field Values

PERSIST_APPLICATION_VARIABLE_CONFIG_FILE_NAME

public static final String PERSIST_APPLICATION_VARIABLE_CONFIG_FILE_NAME
See Also:
Constant Field Values

APPVAR_ROW_TYPE

public static CompositeType APPVAR_ROW_TYPE

APPVAR_TABULAR_TYPE

public static TabularType APPVAR_TABULAR_TYPE
Constructor Detail

RuntimeConfiguration

public RuntimeConfiguration(String workspaceRoot,
                            String configSchema,
                            String configData)
                     throws javax.jbi.JBIException
Creates a new instance of InstallerExt

Throws:
javax.jbi.JBIException
Method Detail

getOutboundThreads

public Integer getOutboundThreads()
Specified by:
getOutboundThreads in interface RuntimeConfigurationMBean
Returns:

setOutboundThreads

public void setOutboundThreads(Integer val)
                        throws InvalidAttributeValueException,
                               MBeanException
Specified by:
setOutboundThreads in interface RuntimeConfigurationMBean
Parameters:
val -
Throws:
InvalidAttributeValueException
MBeanException

getNotificationInfo

public MBeanNotificationInfo[] getNotificationInfo()
Specified by:
getNotificationInfo in interface NotificationBroadcaster
Returns:

addNotificationListener

public void addNotificationListener(NotificationListener listener,
                                    NotificationFilter filter,
                                    Object handback)
Specified by:
addNotificationListener in interface NotificationBroadcaster
Parameters:
listener -
filter -
handback -

removeNotificationListener

public void removeNotificationListener(NotificationListener listener)
                                throws ListenerNotFoundException
Specified by:
removeNotificationListener in interface NotificationBroadcaster
Parameters:
listener -
Throws:
ListenerNotFoundException

removeNotificationListener

public void removeNotificationListener(NotificationListener listener,
                                       NotificationFilter filter,
                                       Object handback)
                                throws ListenerNotFoundException
Specified by:
removeNotificationListener in interface NotificationEmitter
Parameters:
listener -
filter -
handback -
Throws:
ListenerNotFoundException

queryApplicationConfigurationType

public CompositeType queryApplicationConfigurationType()
Get the CompositeType definition for the components application configuration

Specified by:
queryApplicationConfigurationType in interface RuntimeConfigurationMBean
Returns:
the CompositeType for the components application configuration.

addApplicationConfiguration

public void addApplicationConfiguration(String name,
                                        CompositeData appConfig)
                                 throws InvalidAttributeValueException,
                                        MBeanException
Add an application configuration. The configuration name is a part of the CompositeData. The itemName for the configuration name is "configurationName" and the type is SimpleType.STRING

Specified by:
addApplicationConfiguration in interface RuntimeConfigurationMBean
Parameters:
name - - configuration name, must match the value of the field "name" in the namedConfig
appConfig - - application configuration composite
Throws:
MBeanException - if the application configuration cannot be added.
InvalidAttributeValueException

deleteApplicationConfiguration

public void deleteApplicationConfiguration(String name)
                                    throws MBeanException
Delete an application configuration.

Specified by:
deleteApplicationConfiguration in interface RuntimeConfigurationMBean
Parameters:
name - - identification of the application configuration to be deleted
Throws:
MBeanException - if the configuration cannot be deleted.

setApplicationConfiguration

public void setApplicationConfiguration(String name,
                                        CompositeData appConfig)
                                 throws InvalidAttributeValueException,
                                        MBeanException
Update a application configuration. The configuration name is a part of the CompositeData. The itemName for the configuration name is "configurationName" and the type is SimpleType.STRING

Specified by:
setApplicationConfiguration in interface RuntimeConfigurationMBean
Parameters:
name - - configuration name, must match the value of the field "configurationName" in the appConfig
appConfig - - application configuration composite
Throws:
MBeanException - if there are errors encountered when updating the configuration.
InvalidAttributeValueException

getApplicationConfigurations

public TabularData getApplicationConfigurations()
Get a Map of all application configurations for the component.

Specified by:
getApplicationConfigurations in interface RuntimeConfigurationMBean
Returns:
a TabularData of all the application configurations for a component keyed by the configuration name.

retrieveApplicationConfigurationsMap

public Map retrieveApplicationConfigurationsMap()
Description copied from interface: RuntimeConfigurationMBean
Retrieves the application configuration map. The map key is the configuration name, the value is a String representing a HTTP URL. This method is used to communicate application configuration data within the component and is not intended for MBean clients.

Specified by:
retrieveApplicationConfigurationsMap in interface RuntimeConfigurationMBean
Returns:
a Map containing application configuration information

updateApplicationConfigurationsMap

public void updateApplicationConfigurationsMap(Map appConfigMap)
                                        throws MBeanException
Description copied from interface: RuntimeConfigurationMBean
Updates the application configuration map. This method is used to communicate application configuration data within the component, and not intended for MBean clients

Specified by:
updateApplicationConfigurationsMap in interface RuntimeConfigurationMBean
Throws:
MBeanException

retrieveConfigurationDisplaySchema

public String retrieveConfigurationDisplaySchema()
Retrieves the configuration display schema

Specified by:
retrieveConfigurationDisplaySchema in interface RuntimeConfigurationMBean

retrieveConfigurationDisplayData

public String retrieveConfigurationDisplayData()
Retrieves the configuration display data

Specified by:
retrieveConfigurationDisplayData in interface RuntimeConfigurationMBean

retrieveApplicationVariablesMap

public Map<String,String[]> retrieveApplicationVariablesMap()
Description copied from interface: RuntimeConfigurationMBean
Retrieves the application variables map. The map key is the application variable name, the value is a String[] containing detailed information about the application variable. This method is used to communicate application variable data with in the component and is not intended for MBean clients

Specified by:
retrieveApplicationVariablesMap in interface RuntimeConfigurationMBean
Returns:
a Map containing application variable information

countVariables

public int countVariables()
Specified by:
countVariables in interface RuntimeConfigurationMBean

updateApplicationVariablesMap

public void updateApplicationVariablesMap(Map<String,String[]> map)
                                   throws MBeanException
Description copied from interface: RuntimeConfigurationMBean
Updates the application variable map. This method is used to communicate application configuration data within the component, and not intended for MBean clients

Specified by:
updateApplicationVariablesMap in interface RuntimeConfigurationMBean
Throws:
MBeanException

addApplicationVariable

public void addApplicationVariable(String name,
                                   CompositeData appVar)
                            throws MBeanException
This operation adds a new applicationvariable. If a variable already exists with the same name as that specified then the operation fails.

Specified by:
addApplicationVariable in interface RuntimeConfigurationMBean
Parameters:
name - - name of the application variable
appVar - - this is the application variable compoiste
Throws:
MBeanException - if an error occurs in adding the application variables to the component.

setApplicationVariable

public void setApplicationVariable(String name,
                                   CompositeData appVar)
                            throws MBeanException
This operation sets an application variable. If a variable does not exist with the same name, its an error.

Specified by:
setApplicationVariable in interface RuntimeConfigurationMBean
Parameters:
name - - name of the application variable
appVar - - this is the application variable compoiste to be updated.
Throws:
MBeanException - if one or more application variables cannot be deleted

deleteApplicationVariable

public void deleteApplicationVariable(String name)
                               throws MBeanException
This operation deletes an application variable, if a variable with the specified name does not exist, it's an error.

Specified by:
deleteApplicationVariable in interface RuntimeConfigurationMBean
Parameters:
name - - name of the application variable
Throws:
MBeanException - on errors.

getApplicationVariables

public TabularData getApplicationVariables()
Get the Application Variable set for a component.

Specified by:
getApplicationVariables in interface RuntimeConfigurationMBean
Returns:
a TabularData which has all the applicationvariables set on the component.


Copyright © 2005-2010 Imola Informatica. All Rights Reserved.