|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.gcube.common.core.utils.handlers.GCUBEServiceClientImpl
org.gcube.common.core.state.GCUBEStatefulResource<org.gcube.common.core.state.GCUBEWSResourceKey>
org.gcube.common.core.state.GCUBEWSResource
org.gcube.indexmanagement.common.IndexWSResource
org.gcube.indexmanagement.common.IndexLookupWSResource
public abstract class IndexLookupWSResource
| Nested Class Summary | |
|---|---|
class |
IndexLookupWSResource.ConsumerNotification
Class that handles the consuming of received notifications |
| Nested classes/interfaces inherited from class org.gcube.indexmanagement.common.IndexWSResource |
|---|
IndexWSResource.DestructionMode |
| Nested classes/interfaces inherited from class org.gcube.common.core.state.GCUBEStatefulResource |
|---|
org.gcube.common.core.state.GCUBEStatefulResource.LOCK, org.gcube.common.core.state.GCUBEStatefulResource.TaskContext |
| Field Summary | |
|---|---|
protected org.globus.wsrf.Topic |
indexChangeTopic
The index update notification topic |
static String |
RP_CONNECTION_ID
The list of standard resource properties defined by every lookup index resource |
static String |
RP_DOCCOUNT
|
static String |
RP_SUPPORTED_RELATIONS
|
protected QName |
sharedStateChangeTopicName
The state change notification topic QName |
| Fields inherited from class org.gcube.indexmanagement.common.IndexWSResource |
|---|
bInitializing, destructionMode, initLock, namespace, propNames, RP_COLLECTION_ID, RP_CREATED, RP_FIELDS, RP_INDEX_ID, RP_INDEX_TYPE_NAME, RP_MODIFIED, topicRegistrar |
| Fields inherited from class org.gcube.common.core.state.GCUBEStatefulResource |
|---|
uuidGen |
| Constructor Summary | |
|---|---|
IndexLookupWSResource()
|
|
| Method Summary | |
|---|---|
void |
addConnectionID(Integer connectionID)
Adds a connection ID. |
void |
changeDocumentCount(int change)
Modifies the DocumentCount Resource Property |
int |
getConnectionID()
Getter method for the ConnectionID Resource Property |
int |
getDocumentCount()
Getter method for the DocumentCount Resource Property |
String |
getIndexDataDirectory()
Returns the local directory where index data is stored |
String |
getManagementResourceNamespace()
Returns the namespace of the management resource associated with this lookup resource |
String[] |
getSupportedRelations()
Getter method for the SupportedRelations list Resource Property |
void |
initialise(String namespace,
String managementServiceNamespace,
String indexID,
String indexTypeName,
String[] collectionID,
String dataDir,
String[] supportedRelations)
Initializes the index management resource. |
protected void |
onLoad(ObjectInputStream ois,
boolean firstLoad)
Invoked when a resource is being created from a serialized, previously saved state. |
abstract void |
onLookupNotificationReceived(Element message)
Invoked whenever a message is received for this consumer. |
void |
onResourceRemoval()
Performs clean-up operations before the resource is removed from the home |
protected void |
onStore(ObjectOutputStream oos)
Invoked when the state of the resource must be saved (resource serialization) |
void |
sendIndexChangeNotification(Object message)
Sends a state change notification message |
void |
setConnectionID(int connectionID)
Setter method for the ConnectionID Resource Property. |
void |
setDocumentCount(int documentCount)
Setter method for the DocumentCount Resource Property |
void |
setSupportedRelations(String[] relations)
Setter method for the SupportedRelations list Resource Property |
| Methods inherited from class org.gcube.indexmanagement.common.IndexWSResource |
|---|
addCollectionID, addField, createProperty, createProperty, createTopic, createTopic, filterFieldInfo, getCollectionID, getCreated, getDestructionMode, getFields, getIndexID, getIndexTypeName, getModified, getNamespace, getPropertyNames, initialise, isInitializing, isTopicRegistered, publish, setCollectionID, setCreated, setDestructionMode, setFields, setIndexID, setIndexTypeName, setIsInitializing, setModified, store, waitUntilInitialized |
| Methods inherited from class org.gcube.common.core.state.GCUBEWSResource |
|---|
getCurrentTime, getEPR, getPorttypeContext, getProperty, getPublisher, getResourcePropertySet, getServiceContext, getTerminationTime, getTopicList, getTopicNames, initialise, initialise, initialiseContainers, inScope, load, setPortTypeContext, setTerminationTime, unpublish |
| Methods inherited from class org.gcube.common.core.state.GCUBEStatefulResource |
|---|
getID, getLock, getScheduledTasks, getScope, launchTask, onRemove, setID, setPersistenceDelegate, stopTask |
| Methods inherited from class org.gcube.common.core.utils.handlers.GCUBEServiceClientImpl |
|---|
getPortTypeMap, setPortTypeMap |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String RP_CONNECTION_ID
public static final String RP_DOCCOUNT
public static final String RP_SUPPORTED_RELATIONS
protected QName sharedStateChangeTopicName
protected org.globus.wsrf.Topic indexChangeTopic
| Constructor Detail |
|---|
public IndexLookupWSResource()
| Method Detail |
|---|
public void initialise(String namespace,
String managementServiceNamespace,
String indexID,
String indexTypeName,
String[] collectionID,
String dataDir,
String[] supportedRelations)
throws Exception
namespace - the namespace of the service that this resource belongs tomanagementServiceNamespace - the namespace of the corresponding index management serviceindexID - the indexID of this resourceindexTypeName - the index type name of this resourcecollectionID - the list of collection IDs of this resourcedataDir - the local directory where index data is stored
Exception - an error occured
protected void onLoad(ObjectInputStream ois,
boolean firstLoad)
throws Exception
onLoad in class IndexWSResourceois - the input stream through which the state can be readindicates - if the resource is being loaded for the first time (hard load) or not (soft load)
Exception - an error occured during resource deserialization
protected void onStore(ObjectOutputStream oos)
throws Exception
onStore in class IndexWSResourceoos - the output stream to write the resource state to
Exception - an error occured during resource serializationpublic void sendIndexChangeNotification(Object message)
message - the notification message to sendpublic int getConnectionID()
int the requested connection numberpublic void setConnectionID(int connectionID)
connectionID - - the id of the connectionpublic void addConnectionID(Integer connectionID)
connectionID - public void setDocumentCount(int documentCount)
documentCount - int the new document countpublic int getDocumentCount()
int.public String[] getSupportedRelations()
String[] the requested SupportedRelations
public void setSupportedRelations(String[] relations)
throws Exception
String[] - the new SupportedRelations
Exceptionpublic void changeDocumentCount(int change)
public String getIndexDataDirectory()
public String getManagementResourceNamespace()
public void onResourceRemoval()
IndexWSResource
onResourceRemoval in class IndexWSResourcepublic abstract void onLookupNotificationReceived(Element message)
message - the received message
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||