com.metamatrix.dqp.service
Interface ConfigurationService

All Superinterfaces:
ApplicationService
All Known Implementing Classes:
EmbeddedConfigurationService

public interface ConfigurationService
extends ApplicationService

Configuration Service, this is responsible for all the configuration for other services and also DQP configuration.

Since:
4.3

Field Summary
static java.lang.String NEXT_VDB_VERSION
           
static java.lang.String USER_DEFINED_FUNCTION_MODEL
           
 
Method Summary
 ConnectorBinding addConnectorBinding(java.lang.String connectorBindingName, ConnectorBinding binding, boolean replace)
          Add the connector binding to the persistent store
 VDBArchive addVDB(VDBArchive vdb, boolean replaceBindings)
          Add the VDB to the configuration
 void assignConnectorBinding(java.lang.String vdbName, java.lang.String version, java.lang.String modelName, ConnectorBinding[] bindings)
          Assign a connector binding to the Model
 void deleteConnectorBinding(java.lang.String connectorBindingName)
          Delete the connector binding from the persistent store
 void deleteConnectorType(java.lang.String connectorType)
          Delete the Given component type to the persistent store
 void deleteExtensionModule(java.lang.String extModuleName)
          Delete the extension module from the configuration with name supplied
 void deleteVDB(VDBArchive vdb)
          Delete the VDB from the underlying persistent mechanism used by this configuration service
 java.lang.String getBufferMemorySize()
          Size of Memory in MB allocated to be used by the Resultset Management before disk buffering kicks in.
 java.util.Set<ServerConnection> getClientConnections()
          This returns the active client connections that have been made to the DQP
 java.net.URL[] getCommonExtensionClasspath()
          Get the user defined extension file classpath.
 java.net.URL getConfigFile()
          Gets the reference URL to the Configuration File for the DQP.
 ServerConnectionListener getConnectionListener()
          Client Connection Listener object for the service; This will get notifications about the connections currently available to DQP.
 java.lang.String getConnectorBatchSize()
          Gets the connector batch size
 ConnectorBinding getConnectorBinding(java.lang.String connectorBindingName)
          get the connector binding from the persistent store
 java.util.List<ConnectorBinding> getConnectorBindings()
          Get the list of connector bindings available in the configuration.
 ConnectorBindingType getConnectorType(java.lang.String connectorType)
          Get Component type for the given id
 java.util.List<ComponentType> getConnectorTypes()
          Get list of all the connector types available in the System.
 java.util.Properties getDefaultProperties(ConnectorBinding binding)
          Get the default properties for the Connector binding
 java.io.File getDiskBufferDirectory()
          Get the directory to use for the disk buffering
 java.net.URL getEncryptionKeyStore()
          Get the URL to the "metamatrixpki.keystore" file
 ExtensionModule getExtensionModule(java.lang.String extModuleName)
          Get the extension module by the given identifier
 java.util.List getExtensionModules()
          Get the list of extension modules available in the store
 java.net.URL getExtensionPath()
          Retun the context class path to be used by all the extension modules to use.
 java.lang.String getInstanceIdenifier()
          Return some identifier which uniquely identifies the DQP.
 java.net.URL getLogFile()
          URL to Log file name
 java.lang.String getLogLevel()
          Log Level
 java.lang.String getProcessorBatchSize()
          Gets the processor batch size
 ConfigurationModelContainer getSystemConfiguration()
          Get the system Configuration object loaded from the configuration object, this is currently only needed to support the exportConfiguration admin call.
 java.util.Properties getSystemProperties()
          Get DQP properties
 java.net.URL getSystemVdb()
          Get the VDB contents for the "System.VDB"
 java.net.URL getUDFFile()
          Get the user defined functions file name
 VDBArchive getVDB(java.lang.String vdbName, java.lang.String vdbVersion)
          Get the list of VDB files available with the Configuration Service, this includes all status (active, inactive)
 java.net.URL[] getVDBLocations()
          Get path(s) for VDB(s) that are availble from the configuration to the DQP engine.
 java.util.List<VDBArchive> getVDBs()
          Get a list of available VDBS from the configuration
 boolean isFullyConfiguredVDB(VDBArchive vdb)
           
 void loadUDF()
          Load the UDF function model
 void register(ConnectorBindingLifeCycleListener listener)
          Register a listener for the connector binding life cycle events, and get notified for when connector binding is loded and unloaded
 void register(VDBLifeCycleListener listener)
          Register a listener for the VDB life cycle events, and get notified for when vdb is loded and unloaded
 void saveConnectorType(ConnectorBindingType type)
          Add the Given component type to the persistent store
 void saveExtensionModule(ExtensionModule extModule)
          Save the given extension module
 void saveVDB(VDBArchive vdb, java.lang.String version)
          Save the given vdb file into underlying persistent mechanism used by this configuration service
 void setSystemProperty(java.lang.String key, java.lang.String value)
          Set System property (Contents of ServerConfig.xml file)
 void unloadUDF()
          Unload the User defined functions file.
 void unregister(ConnectorBindingLifeCycleListener listener)
           
 void unregister(VDBLifeCycleListener listener)
           
 ConnectorBinding updateConnectorBinding(ConnectorBinding binding)
          Update the Connector Binding, the assumption here that we kept the name same
 void updateSystemProperties(java.util.Properties properties)
          Set several System properties (Contents of ServerConfig.xml file).
 boolean useDiskBuffering()
          Use disk for buffering for result set management during the processing
 boolean useExtensionClasspath()
          Use the extension classpath defined in the connector bindins and load jars in different class loader or in the same class loader as calling code
 
Methods inherited from interface com.metamatrix.common.application.ApplicationService
initialize, start, stop
 

Field Detail

NEXT_VDB_VERSION

static final java.lang.String NEXT_VDB_VERSION
See Also:
Constant Field Values

USER_DEFINED_FUNCTION_MODEL

static final java.lang.String USER_DEFINED_FUNCTION_MODEL
See Also:
Constant Field Values
Method Detail

getSystemVdb

java.net.URL getSystemVdb()
Get the VDB contents for the "System.VDB"

Returns:
URL - URL to System.vdb file; null if one not found

getSystemProperties

java.util.Properties getSystemProperties()
Get DQP properties

Returns:
Properties - properties
Throws:
MetaMatrixComponentException

setSystemProperty

void setSystemProperty(java.lang.String key,
                       java.lang.String value)
                       throws MetaMatrixComponentException
Set System property (Contents of ServerConfig.xml file)

Parameters:
key -
value -
Throws:
MetaMatrixComponentException

updateSystemProperties

void updateSystemProperties(java.util.Properties properties)
                            throws MetaMatrixComponentException
Set several System properties (Contents of ServerConfig.xml file). Any properties not specified will remain unchanged.

Parameters:
properties - The properties to set.
Throws:
MetaMatrixComponentException

getSystemConfiguration

ConfigurationModelContainer getSystemConfiguration()
                                                   throws MetaMatrixComponentException
Get the system Configuration object loaded from the configuration object, this is currently only needed to support the exportConfiguration admin call.

Returns:
Throws:
MetaMatrixComponentException
Since:
4.3

getUDFFile

java.net.URL getUDFFile()
Get the user defined functions file name

Returns:
URL - URL to the User defined file; null if one not defined

getCommonExtensionClasspath

java.net.URL[] getCommonExtensionClasspath()
Get the user defined extension file classpath. The jar files are loaded usually as the extension modules.

Returns:
URL[] - Classpath for the UDF jar files

getLogFile

java.net.URL getLogFile()
URL to Log file name

Returns:
URL or null if one not available

getLogLevel

java.lang.String getLogLevel()
Log Level

Returns:
configured log level or default one supplied.

saveVDB

void saveVDB(VDBArchive vdb,
             java.lang.String version)
             throws MetaMatrixComponentException
Save the given vdb file into underlying persistent mechanism used by this configuration service

Parameters:
vdb - - VDB to be saved
version - - Version to be saved as; when used text "NEXT_VDB_VERSION" as version save as the next available version.
Throws:
MetaMatrixComponentException

addVDB

VDBArchive addVDB(VDBArchive vdb,
                  boolean replaceBindings)
                  throws MetaMatrixComponentException
Add the VDB to the configuration

Parameters:
vdb - - vdb to be added
replaceBindings - - flag which specifies action to be taken in case there are conflicts in connector bindings.
Returns:
- added VDB instance.
Throws:
MetaMatrixComponentException

deleteVDB

void deleteVDB(VDBArchive vdb)
               throws MetaMatrixComponentException
Delete the VDB from the underlying persistent mechanism used by this configuration service

Parameters:
vdbName - - Name of the VDB
vdbVersion - - VDB version
Throws:
MetaMatrixComponentException

assignConnectorBinding

void assignConnectorBinding(java.lang.String vdbName,
                            java.lang.String version,
                            java.lang.String modelName,
                            ConnectorBinding[] bindings)
                            throws MetaMatrixComponentException
Assign a connector binding to the Model

Parameters:
vdbName - - Name of the VDB
version - - version of the VDB
modelName - - Model Name
bindings - - bindings to be assigned
Throws:
MetaMatrixComponentException

getVDB

VDBArchive getVDB(java.lang.String vdbName,
                  java.lang.String vdbVersion)
                  throws MetaMatrixComponentException
Get the list of VDB files available with the Configuration Service, this includes all status (active, inactive)

Parameters:
vdbName - - Name of the VDB
vdbVersio - - VDB version.
Returns:
VDBArchive
Throws:
MetaMatrixComponentException

getVDBs

java.util.List<VDBArchive> getVDBs()
                                   throws MetaMatrixComponentException
Get a list of available VDBS from the configuration

Returns:
list of VDBArchive
Throws:
MetaMatrixComponentException
Since:
4.3

addConnectorBinding

ConnectorBinding addConnectorBinding(java.lang.String connectorBindingName,
                                     ConnectorBinding binding,
                                     boolean replace)
                                     throws MetaMatrixComponentException
Add the connector binding to the persistent store

Parameters:
connectorBindingName - - Connector Binding Name
binding - - Connector binding to Add
replace - - flag to replace in case a duplicate found.
Throws:
MetaMatrixComponentException

deleteConnectorBinding

void deleteConnectorBinding(java.lang.String connectorBindingName)
                            throws MetaMatrixComponentException
Delete the connector binding from the persistent store

Parameters:
connectorBindingName - - Connector Binding Name
Throws:
MetaMatrixComponentException

getConnectorBinding

ConnectorBinding getConnectorBinding(java.lang.String connectorBindingName)
                                     throws MetaMatrixComponentException
get the connector binding from the persistent store

Parameters:
connectorBindingName - - Connector Binding Name
Returns:
Connector binding by the name given.
Throws:
MetaMatrixComponentException

getDefaultProperties

java.util.Properties getDefaultProperties(ConnectorBinding binding)
Get the default properties for the Connector binding

Parameters:
binding -
Returns:
properties

updateConnectorBinding

ConnectorBinding updateConnectorBinding(ConnectorBinding binding)
                                        throws MetaMatrixComponentException
Update the Connector Binding, the assumption here that we kept the name same

Parameters:
binding - - Connector Binding to be modified
Returns:
modified connector; usually same referenced object.
Throws:
MetaMatrixComponentException

getConnectorBindings

java.util.List<ConnectorBinding> getConnectorBindings()
                                                      throws MetaMatrixComponentException
Get the list of connector bindings available in the configuration.

Returns:
list of ConnectorBinding
Throws:
MetaMatrixComponentException
Since:
4.3

getConnectorType

ConnectorBindingType getConnectorType(java.lang.String connectorType)
                                      throws MetaMatrixComponentException
Get Component type for the given id

Parameters:
id -
Returns:
Throws:
MetaMatrixComponentException

saveConnectorType

void saveConnectorType(ConnectorBindingType type)
                       throws MetaMatrixComponentException
Add the Given component type to the persistent store

Parameters:
type -
Throws:
MetaMatrixComponentException

deleteConnectorType

void deleteConnectorType(java.lang.String connectorType)
                         throws MetaMatrixComponentException
Delete the Given component type to the persistent store

Parameters:
connectorType - - Name of the connector Type
Throws:
MetaMatrixComponentException

getConnectorTypes

java.util.List<ComponentType> getConnectorTypes()
                                                throws MetaMatrixComponentException
Get list of all the connector types available in the System.

Returns:
list of ComponentType
Throws:
MetaMatrixComponentException

getExtensionPath

java.net.URL getExtensionPath()
Retun the context class path to be used by all the extension modules to use. if one not specified a default must be supplied. Usally this is directory where all the extension jars are stored or a URL

Returns:
String URL - url to extension path; null if extensions are not used
Since:
4.3

getExtensionModules

java.util.List getExtensionModules()
                                   throws MetaMatrixComponentException
Get the list of extension modules available in the store

Returns:
list of Extension Modules ExtensionModule
Throws:
MetaMatrixComponentException
Since:
4.3

getExtensionModule

ExtensionModule getExtensionModule(java.lang.String extModuleName)
                                   throws MetaMatrixComponentException
Get the extension module by the given identifier

Parameters:
extModuleName - - Module name
Returns:
ExtensionModule; null if not found
Throws:
MetaMatrixComponentException
Since:
4.3

saveExtensionModule

void saveExtensionModule(ExtensionModule extModule)
                         throws MetaMatrixComponentException
Save the given extension module

Throws:
MetaMatrixComponentException
Since:
4.3

deleteExtensionModule

void deleteExtensionModule(java.lang.String extModuleName)
                           throws MetaMatrixComponentException
Delete the extension module from the configuration with name supplied

Parameters:
extModuleName - - extension module name
Throws:
MetaMatrixComponentException
Since:
4.3

getConnectionListener

ServerConnectionListener getConnectionListener()
Client Connection Listener object for the service; This will get notifications about the connections currently available to DQP.

Throws:
MetaMatrixComponentException
Since:
4.3.2

register

void register(VDBLifeCycleListener listener)
Register a listener for the VDB life cycle events, and get notified for when vdb is loded and unloaded

Parameters:
listener - - lister object

unregister

void unregister(VDBLifeCycleListener listener)

register

void register(ConnectorBindingLifeCycleListener listener)
Register a listener for the connector binding life cycle events, and get notified for when connector binding is loded and unloaded

Parameters:
listener - - lister object

unregister

void unregister(ConnectorBindingLifeCycleListener listener)

getEncryptionKeyStore

java.net.URL getEncryptionKeyStore()
Get the URL to the "metamatrixpki.keystore" file

Returns:
URL to the "metamatrixpki.keystore" file; null if not defined
Since:
4.4

getConfigFile

java.net.URL getConfigFile()
Gets the reference URL to the Configuration File for the DQP.

Returns:
URL to configuration file; null otherwise
Since:
4.4

useExtensionClasspath

boolean useExtensionClasspath()
Use the extension classpath defined in the connector bindins and load jars in different class loader or in the same class loader as calling code

Returns:
true - to load different class loader, false otherwise

getVDBLocations

java.net.URL[] getVDBLocations()
Get path(s) for VDB(s) that are availble from the configuration to the DQP engine.

Returns:
URLs to the resources.

useDiskBuffering

boolean useDiskBuffering()
Use disk for buffering for result set management during the processing

Returns:
true if yes to use buffering; false otherwise

getDiskBufferDirectory

java.io.File getDiskBufferDirectory()
Get the directory to use for the disk buffering

Returns:
must a return a location

getBufferMemorySize

java.lang.String getBufferMemorySize()
Size of Memory in MB allocated to be used by the Resultset Management before disk buffering kicks in.

Returns:
must a return a location

getInstanceIdenifier

java.lang.String getInstanceIdenifier()
Return some identifier which uniquely identifies the DQP. Usally this is an integer value which is set at the creation of the DQP

Returns:
unique number for DQP in a given JVM

getClientConnections

java.util.Set<ServerConnection> getClientConnections()
This returns the active client connections that have been made to the DQP

Returns:
list of connections which are currently available;never null

getProcessorBatchSize

java.lang.String getProcessorBatchSize()
Gets the processor batch size

Returns:
Since:
4.3

getConnectorBatchSize

java.lang.String getConnectorBatchSize()
Gets the connector batch size

Returns:
Since:
4.3

unloadUDF

void unloadUDF()
               throws MetaMatrixComponentException
Unload the User defined functions file.

Throws:
MetaMatrixComponentException

loadUDF

void loadUDF()
             throws MetaMatrixComponentException
Load the UDF function model

Throws:
MetaMatrixComponentException

isFullyConfiguredVDB

boolean isFullyConfiguredVDB(VDBArchive vdb)
                             throws MetaMatrixComponentException
Throws:
MetaMatrixComponentException


Copyright © 2009. All Rights Reserved.