|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.gcube.common.core.state.GCUBEResourceHome<String,String,GCUBELocalResource>
org.gcube.common.core.state.GCUBELocalHome
public abstract class GCUBELocalHome
A specialisation of GCUBEResourceHome for GCUBELocalResources.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class org.gcube.common.core.state.GCUBEResourceHome |
|---|
GCUBEResourceHome.Mode |
| Field Summary |
|---|
| Fields inherited from class org.gcube.common.core.state.GCUBEResourceHome |
|---|
cache, lockManager, logger, mode, persistenceDelegate, resourceClass, resourceLog |
| Constructor Summary | |
|---|---|
GCUBELocalHome()
|
|
| Method Summary | |
|---|---|
protected void |
onInitialisation()
Invoked during initialisation of the Running Instance to initialise the home. |
protected boolean |
onRemove(GCUBELocalResource resource)
Invoked as a precondition to the removal of a resource. |
protected void |
onReuse(GCUBELocalResource resource)
Invoked when a resource is reused across two or more calls to GCUBEResourceHome.create(Object, Object...) . |
protected void |
preInitialise(GCUBELocalResource resource)
Invoked during the creation of a resource and before its initialisation. |
| Methods inherited from class org.gcube.common.core.state.GCUBEResourceHome |
|---|
add, create, create, createInternal, find, get, getIdentifiers, getResourceClass, getResources, getServiceContext, initialize, newInstance, onFailure, onLoad, onReady, onStateChange, onUpdate, postInitialise, remove, remove, reuse, setCacheTimeout, setPersistenceDelegateClass, setResourceClass |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public GCUBELocalHome()
| Method Detail |
|---|
protected void onInitialisation()
throws Exception
<resource name="[name]" type="[FQN of a subclass of GCUBEResourceHome]">
<resourceParams>
<parameter>
<name>factory</name>
<value>org.globus.wsrf.jndi.BeanFactory</value>
</parameter>
<parameter>
<name>resourceClass</name>
<value>[FQN of a concrete subclass of GCUBEStatefulResource]</value>
</parameter>
<parameter>
<name>persistenceDelegateClass</name>
<value>[FQN of a concrete subclass of GCUBEPersistenceDelegate]</value>
</parameter>
<parameter>
<name>cacheTimeout</name>
<value>[seconds]</value>
</parameter>
</resourceParams>
</resource>
where:
-) the name of the JNDI resource and its resourceClass parameter may be further
constrained by subclasses.
-) persistenceDelegateClass and cacheTimeout are optional and related.
If neither is present, the mode of operation is TRANSIENT.
If the first is present but the second is absent, then the mode of operation is SOFTPERSISTENT.
If both are present, then the mode of operation is
HARDPERSISTENT if the second has a value of 0 and CACHEDPERSISTENT
in all other cases.
Finally, the second cannot occur without the first.
onInitialisation in class GCUBEResourceHome<String,String,GCUBELocalResource>Exception - if the callback did not complete successfully (causes service failure).
protected void onReuse(GCUBELocalResource resource)
throws org.globus.wsrf.ResourceException
GCUBEResourceHome.create(Object, Object...) .
onReuse in class GCUBEResourceHome<String,String,GCUBELocalResource>resource - the resource.
org.globus.wsrf.ResourceException - if the resource could not be reused.
protected void preInitialise(GCUBELocalResource resource)
throws org.globus.wsrf.ResourceException
If overriding this method, please note that the resource may not have been assigned an identifier yet.
preInitialise in class GCUBEResourceHome<String,String,GCUBELocalResource>resource - the resource.
org.globus.wsrf.ResourceException - if the resource could not be pre-initialised.
protected boolean onRemove(GCUBELocalResource resource)
throws org.globus.wsrf.ResourceException
onRemove in class GCUBEResourceHome<String,String,GCUBELocalResource>resource - the resource.
org.globus.wsrf.ResourceException - if the precondition could not be verified.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||