org.globus.ogsa.impl.base.aggregator
Class DataAggregationManager

java.lang.Object
  extended byorg.globus.ogsa.impl.base.aggregator.DataAggregationManager
All Implemented Interfaces:
NotificationSinkCallback, OperationProvider, ServiceProperties

public class DataAggregationManager
extends java.lang.Object
implements OperationProvider, NotificationSinkCallback

Service delegation component which aggregates and "caches" service data from other services into the local service data container using notification sinks. Should be compatible with any service that implements NotificationSinkPortType


Field Summary
static java.lang.String DEFAULT_NAMESPACE
           
static java.lang.String DEFAULT_PARAM_NAME
           
static java.lang.String MANAGER_INSTANCE
           
 
Fields inherited from interface org.globus.ogsa.ServiceProperties
ACTIVATE_ON_STARTUP, ACTIVATION, BASE_CLASS_NAME, BOOTSTRAP, CONFIG_PATH, CONTAINS_REFERENCE, CREATION_EXTENSIBILITY, CREATION_EXTENSIBILITY_OUTPUT, CUSTOM_EXTENSIBILITY_DESERIALIZER, CUSTOM_EXTENSIBILITY_SERIALIZER, CUSTOM_MAPPING_REGISTERED, DEACTIVATED_PERSISTENT, DEACTIVATED_STATE, DEACTIVATED_TRANSIENT, DEACTIVATION, DESTROY_LISTENER, DESTRUCTION_SKELETON, DISABLE_FACTORY_REGISTRY, ENDPOINT, ENTRY_INSTANCE_CREATION, FACTORY, FACTORY_CALLBACK, FACTORY_HANDLE, FACTORY_PROVIDER, FACTORY_REGISTRY, GSR_DESCRIPTION, HANDLE, HANDLE_PORT, HANDLE_PROTOCOL, INSTANCE_CLASS, INSTANCE_DEACTIVATION, INSTANCE_GSR_DESCRIPTION, INSTANCE_LIFECYCLE, INSTANCE_PORT_TYPE, INSTANCE_PORT_TYPE_NS, INSTANCE_PREFIX, INSTANCE_REGISTRY, INSTANCE_SCHEMA_PATH, INSTANCE_WSDL, INTERFACE_CLASS_NAME, INVOCATION_ID, LAZY_CREATION, LIFECYCLE, LIFECYCLE_MONITOR, LIFECYCLE_MONITOR_CLASS, NAME, NOTIFICATION_ENGINE, NOTIFICATION_FACTORY, NOTIFICATION_SOURCE, OPERATION_PROVIDERS, PERSISTENT, PERSISTENT_PROPERTIES, PORT, PORT_TYPE, PORT_TYPE_NS, PRIMARY_KEY, PROTOCOL, QUERY_ENGINE, REDIRECT_RESOLVER, REGISTRY, RESOLVER_CACHE, ROUTER_HEADER, ROUTER_VIA, SCHEMA_LOCATION, SCHEMA_PATH, SERVICE_ACTIVATOR, SERVICE_DATA, SERVICE_DEPLOYMENT, SERVICE_GROUP_ENTRY, SERVICE_GROUP_PROVIDER, SERVICE_LOADER, SERVICE_NODE, SERVICE_PATH, SINK_ID, STARTUP_STATE, SWEEP_SERVICE_DATA, TIMEOUT, TIMESTAMP, TRANSIENT, TYPE, USER, WEBSTART_PANEL_NAME, WEBSTART_URL, WSDL
 
Constructor Summary
DataAggregationManager()
          Constructs an aggregator that performs basic GT3.0-style service data aggregation.
DataAggregationManager(DataAggregationSource dataSource, DataAggregationSink[] dataSinks)
          Constructs an Data Aggregation Manager that delegates functionality to the supplied DataAggregationSource and DataAggregationSink objects.
 
Method Summary
 java.lang.String addDataAggregation(DataAggregationType dataAggregation)
          Causes the aggregator to begin collecting data from a remote service.
 void addDataSink(DataAggregationSink sink)
           
 void deliverNotification(ExtensibilityType message)
           
 void flush()
          gives a hint that this property should be checkpointed to the deployment descriptor, it is however not guaranteed that the properties have been persisted when the method returns
 DataAggregationSink[] getDataSinks()
           
 DataAggregationSource getDataSource()
           
 QName[] getOperations()
          Called during initialization when the Grid service needs to find out what operations are supported by this provider.
 java.lang.Object getPersistentProperty(java.lang.String name)
          gets a persistent property (checkpointed to deployment descriptor) keyed by name
 java.lang.Object getProperty(java.lang.String name)
          gets a property keyed by name
 void initialize(GridServiceBase serviceBase)
          Called when the operation provider is added to a grid service.
 boolean isValidSession(java.lang.String sessionID)
           
 void processConfig()
           
 void removeDataAggregation(java.lang.String sessionID)
           
 void removeDataSink(DataAggregationSink sink)
           
 void setPersistentProperty(java.lang.String name, java.lang.Object obj)
          sets a persistent property (checkpointed to deployment descriptor) keyed by name
 void setProperty(java.lang.String name, java.lang.Object obj)
          sets a property keyed by name
 void terminate()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DEFAULT_NAMESPACE

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

DEFAULT_PARAM_NAME

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

MANAGER_INSTANCE

public static final java.lang.String MANAGER_INSTANCE
See Also:
Constant Field Values
Constructor Detail

DataAggregationManager

public DataAggregationManager()
Constructs an aggregator that performs basic GT3.0-style service data aggregation.


DataAggregationManager

public DataAggregationManager(DataAggregationSource dataSource,
                              DataAggregationSink[] dataSinks)
Constructs an Data Aggregation Manager that delegates functionality to the supplied DataAggregationSource and DataAggregationSink objects.

Parameters:
dataSource - a class that implments the DataAggregationSource interface
dataSinks - an array of classes that implment the dataSink interface
Method Detail

getOperations

public QName[] getOperations()
Description copied from interface: OperationProvider
Called during initialization when the Grid service needs to find out what operations are supported by this provider.

Specified by:
getOperations in interface OperationProvider
Returns:
an array of operation qnames as defined in WSDL. An OperationProvider can use the empty string "" to denote that all operations with a certain local name are implemented. Similarly the wildcard "*" can be used in the local part of the qname to denote that all operations within a certain namespace are implemented. Combining these two approaches and returning: new QName[] {new QName("","*")}, will result in all incoming operations being redirected to this provider (apart from the OGSI defined GridService interface operations provided by the GridServiceBase implementation. Note that individual operations in the OGSI namespace could still be overridded with this approach, but not using the 'all namespaces and all operation' wildcard.

getProperty

public java.lang.Object getProperty(java.lang.String name)
Description copied from interface: ServiceProperties
gets a property keyed by name

Specified by:
getProperty in interface ServiceProperties
Parameters:
name - property key
Returns:
property value or null

setProperty

public void setProperty(java.lang.String name,
                        java.lang.Object obj)
Description copied from interface: ServiceProperties
sets a property keyed by name

Specified by:
setProperty in interface ServiceProperties
Parameters:
name - property key
obj - property value, if null the property will be removed (if it exists)

flush

public void flush()
           throws ServicePropertiesException
Description copied from interface: ServiceProperties
gives a hint that this property should be checkpointed to the deployment descriptor, it is however not guaranteed that the properties have been persisted when the method returns

Specified by:
flush in interface ServiceProperties
Throws:
ServicePropertiesException - if the properties could not be persisted

getPersistentProperty

public java.lang.Object getPersistentProperty(java.lang.String name)
Description copied from interface: ServiceProperties
gets a persistent property (checkpointed to deployment descriptor) keyed by name

Specified by:
getPersistentProperty in interface ServiceProperties
Parameters:
name - property key
Returns:
property value or null

setPersistentProperty

public void setPersistentProperty(java.lang.String name,
                                  java.lang.Object obj)
Description copied from interface: ServiceProperties
sets a persistent property (checkpointed to deployment descriptor) keyed by name

Specified by:
setPersistentProperty in interface ServiceProperties
Parameters:
name - property key
obj - property value, if null the property will be removed (if it exists)

getDataSource

public DataAggregationSource getDataSource()

getDataSinks

public DataAggregationSink[] getDataSinks()

addDataSink

public void addDataSink(DataAggregationSink sink)

removeDataSink

public void removeDataSink(DataAggregationSink sink)

isValidSession

public boolean isValidSession(java.lang.String sessionID)
                       throws java.lang.Exception
Throws:
java.lang.Exception

initialize

public void initialize(GridServiceBase serviceBase)
                throws GridServiceException
Description copied from interface: OperationProvider
Called when the operation provider is added to a grid service.

Specified by:
initialize in interface OperationProvider
Parameters:
serviceBase - the service this provider is being associated with
Throws:
GridServiceException - if the initialization (and service creation is to be aborted)

terminate

public void terminate()

processConfig

public void processConfig()
                   throws ConfigException
Throws:
ConfigException

addDataAggregation

public java.lang.String addDataAggregation(DataAggregationType dataAggregation)
                                    throws GridServiceException
Causes the aggregator to begin collecting data from a remote service.

Parameters:
dataAggregation - Implementation-specific parameters of the data to be collected.
Returns:
The session ID of the Data Aggregation session that has just been created by this method.
Throws:
GridServiceException

removeDataAggregation

public void removeDataAggregation(java.lang.String sessionID)
                           throws GridServiceException
Throws:
GridServiceException

deliverNotification

public void deliverNotification(ExtensibilityType message)
                         throws GridServiceException
Throws:
GridServiceException