com.metamatrix.server.dqp.service
Class PlatformDataService

java.lang.Object
  extended by com.metamatrix.server.dqp.service.PlatformDataService
All Implemented Interfaces:
ApplicationService, DataService

public class PlatformDataService
extends java.lang.Object
implements DataService

Platform DataService.

A DQP service used to lookup ConnectorServices.


Constructor Summary
PlatformDataService()
          DQPDataService Default ctor.
 
Method Summary
 void cancelRequest(AtomicRequestID request, com.metamatrix.dqp.internal.datamgr.ConnectorID connectorId)
           
 void clearConnectorBindingCache(java.lang.String connectorBindingName)
          Clear any caches for the connector binding.
 void closeRequest(AtomicRequestID request, com.metamatrix.dqp.internal.datamgr.ConnectorID connectorId)
           
 void executeRequest(AtomicRequestMessage request, com.metamatrix.dqp.internal.datamgr.ConnectorID connectorId, ResultsReceiver<AtomicResultsMessage> resultListener)
          Execute the given request on a Connector.
 SourceCapabilities getCapabilities(RequestMessage request, org.teiid.dqp.internal.process.DQPWorkContext dqpWorkContext, com.metamatrix.dqp.internal.datamgr.ConnectorID connectorId)
          Find the capabilities of this source.
 java.util.Collection getConnectionPoolStatistics(java.lang.String connectorBindingName)
          Get connection pool statistics for connector binding
 ConnectorBinding getConnectorBinding(java.lang.String connectorBindingName)
          Get the connector binding specifed the name
 java.util.List getConnectorBindings()
          Get the list of connector bindings deployed in the system.
 ConnectorStatus getConnectorBindingState(java.lang.String connectorBindingName)
          Get the State of the connector binding name
 java.util.Collection getConnectorBindingStatistics(java.lang.String connectorBindingName)
          Get connector bindings queue statistics
 ConnectorMetadata getConnectorMetadata(java.lang.String vdbName, java.lang.String vdbVersion, java.lang.String modelName, java.util.Properties importProperties)
          Return the metadata for a given connector
 void initialize(java.util.Properties props)
          Initialize the service with the specified properties.
 void requestBatch(AtomicRequestID request, com.metamatrix.dqp.internal.datamgr.ConnectorID connectorId)
           
 com.metamatrix.dqp.internal.datamgr.ConnectorID selectConnector(java.lang.String connectorBindingID)
          Select a connector to use for the given connector binding.
 void start(ApplicationEnvironment environment)
          Start the service with the specified environment.
 void startConnectorBinding(java.lang.String connectorBindingName)
          Start the Connector Binding by the name given, if it is already added and not srarted.
 void stop()
          Stop the service.
 void stopConnectorBinding(java.lang.String connectorBindingName)
          Stop the Connector Binding by the given name
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PlatformDataService

public PlatformDataService()
DQPDataService Default ctor.

Method Detail

selectConnector

public com.metamatrix.dqp.internal.datamgr.ConnectorID selectConnector(java.lang.String connectorBindingID)
Select a connector to use for the given connector binding.

Specified by:
selectConnector in interface DataService
Parameters:
connectorBindingID - Connector binding identifier
Returns:
ConnectorID identifying a connector instance

executeRequest

public void executeRequest(AtomicRequestMessage request,
                           com.metamatrix.dqp.internal.datamgr.ConnectorID connectorId,
                           ResultsReceiver<AtomicResultsMessage> resultListener)
                    throws MetaMatrixComponentException
Execute the given request on a Connector.

Specified by:
executeRequest in interface DataService
Parameters:
request - The request for data.
Throws:
MetaMatrixComponentException

cancelRequest

public void cancelRequest(AtomicRequestID request,
                          com.metamatrix.dqp.internal.datamgr.ConnectorID connectorId)
                   throws MetaMatrixComponentException
Specified by:
cancelRequest in interface DataService
Throws:
MetaMatrixComponentException

closeRequest

public void closeRequest(AtomicRequestID request,
                         com.metamatrix.dqp.internal.datamgr.ConnectorID connectorId)
                  throws MetaMatrixComponentException
Specified by:
closeRequest in interface DataService
Throws:
MetaMatrixComponentException

requestBatch

public void requestBatch(AtomicRequestID request,
                         com.metamatrix.dqp.internal.datamgr.ConnectorID connectorId)
                  throws MetaMatrixComponentException
Specified by:
requestBatch in interface DataService
Throws:
MetaMatrixComponentException

getCapabilities

public SourceCapabilities getCapabilities(RequestMessage request,
                                          org.teiid.dqp.internal.process.DQPWorkContext dqpWorkContext,
                                          com.metamatrix.dqp.internal.datamgr.ConnectorID connectorId)
                                   throws MetaMatrixComponentException
Description copied from interface: DataService
Find the capabilities of this source.

Specified by:
getCapabilities in interface DataService
Parameters:
request - Original request message, used to extract security information
connectorId - Connector to retrieve capabilities from
Returns:
All capability information as key-value pairs
Throws:
MetaMatrixComponentException

initialize

public void initialize(java.util.Properties props)
                throws ApplicationInitializationException
Initialize the service with the specified properties.

Specified by:
initialize in interface ApplicationService
Parameters:
props - Initialialization properties
Throws:
ApplicationInitializationException - If an error occurs during initialization

start

public void start(ApplicationEnvironment environment)
           throws ApplicationLifecycleException
Start the service with the specified environment. The environment can be used to find other services or resources.

Specified by:
start in interface ApplicationService
Parameters:
environment - Environment
Throws:
ApplicationLifecycleException - If an error occurs while starting

stop

public void stop()
          throws ApplicationLifecycleException
Stop the service.

Specified by:
stop in interface ApplicationService
Throws:
ApplicationLifecycleException - If an error occurs while starting

startConnectorBinding

public void startConnectorBinding(java.lang.String connectorBindingName)
                           throws ApplicationLifecycleException,
                                  ComponentNotFoundException
Description copied from interface: DataService
Start the Connector Binding by the name given, if it is already added and not srarted.

Specified by:
startConnectorBinding in interface DataService
Throws:
ApplicationLifecycleException
ComponentNotFoundException
Since:
4.3
See Also:
DataService.startConnectorBinding(java.lang.String)

stopConnectorBinding

public void stopConnectorBinding(java.lang.String connectorBindingName)
                          throws ApplicationLifecycleException,
                                 ComponentNotFoundException
Description copied from interface: DataService
Stop the Connector Binding by the given name

Specified by:
stopConnectorBinding in interface DataService
Throws:
ApplicationLifecycleException
ComponentNotFoundException
Since:
4.3
See Also:
DataService.stopConnectorBinding(java.lang.String)

getConnectorBindings

public java.util.List getConnectorBindings()
                                    throws ComponentNotFoundException
Description copied from interface: DataService
Get the list of connector bindings deployed in the system.

Specified by:
getConnectorBindings in interface DataService
Returns:
list ConnectorBinding
Throws:
ComponentNotFoundException
Since:
4.3
See Also:
DataService.getConnectorBindings()

getConnectorBindingState

public ConnectorStatus getConnectorBindingState(java.lang.String connectorBindingName)
                                         throws MetaMatrixComponentException
Description copied from interface: DataService
Get the State of the connector binding name

Specified by:
getConnectorBindingState in interface DataService
Returns:
ConnectorStatus
Throws:
MetaMatrixComponentException
Since:
4.3
See Also:
DataService.getConnectorBindingState(java.lang.String)

getConnectorBinding

public ConnectorBinding getConnectorBinding(java.lang.String connectorBindingName)
                                     throws MetaMatrixComponentException
Description copied from interface: DataService
Get the connector binding specifed the name

Specified by:
getConnectorBinding in interface DataService
Returns:
ConnectorBinding
Throws:
ComponentNotFoundException
MetaMatrixComponentException
Since:
4.3
See Also:
DataService.getConnectorBinding(java.lang.String)

getConnectorBindingStatistics

public java.util.Collection getConnectorBindingStatistics(java.lang.String connectorBindingName)
                                                   throws MetaMatrixComponentException
Description copied from interface: DataService
Get connector bindings queue statistics

Specified by:
getConnectorBindingStatistics in interface DataService
Parameters:
connectorBindingName - - Name of the connector binding
Returns:
a list of WorkerPoolStats
Throws:
MetaMatrixComponentException
Since:
4.3
See Also:
DataService.getConnectorBindingStatistics(java.lang.String)

getConnectionPoolStatistics

public java.util.Collection getConnectionPoolStatistics(java.lang.String connectorBindingName)
                                                 throws MetaMatrixComponentException
Description copied from interface: DataService
Get connection pool statistics for connector binding

Specified by:
getConnectionPoolStatistics in interface DataService
Parameters:
connectorBindingName - - Name of the connector binding
Returns:
a list of com.metamatrix.admin.objects.ConnectionPoolStatsImpl
Throws:
MetaMatrixComponentException
Since:
6.1
See Also:
DataService.getConnectionPoolStatistics(java.lang.String)

clearConnectorBindingCache

public void clearConnectorBindingCache(java.lang.String connectorBindingName)
                                throws MetaMatrixComponentException
Description copied from interface: DataService
Clear any caches for the connector binding. Incase of the JDBC Connector clear the result set cache.

Specified by:
clearConnectorBindingCache in interface DataService
Throws:
MetaMatrixComponentException
Since:
4.3
See Also:
DataService.clearConnectorBindingCache(java.lang.String)

getConnectorMetadata

public ConnectorMetadata getConnectorMetadata(java.lang.String vdbName,
                                              java.lang.String vdbVersion,
                                              java.lang.String modelName,
                                              java.util.Properties importProperties)
Description copied from interface: DataService
Return the metadata for a given connector

Specified by:
getConnectorMetadata in interface DataService
Returns:


Copyright © 2009. All Rights Reserved.