|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--uk.org.ogsadai.activity.Activity | +--uk.org.ogsadai.activity.sql.SQLQueryMultipleActivity
This is abstract class for activities which query multiple
relational resources e.g. SQLResilientQueryActivity
and
SQLBagActivity
.
The activity's perform document is defined by
schema/ogsadai/xsd/activities/sql_query_multiple.xsd
.
The activity calls multiple data service resources each one being executed in its own thread.
Field Summary | |
private static java.lang.String |
COPYRIGHT_NOTICE
Copyright statement |
private static DAILogger |
LOG
Logger object for logging in this class. |
protected long |
mClientTimeout
Timeout in millisecond set by client: 0 for unlimited, -1 for n/a else a long. |
protected DataServiceInfo[] |
mMultipleDS
Information about each data service and data service resource |
protected BlockWriter |
mOutput
Activity output - WebRowSet containing result |
protected java.lang.String |
mOutputString
The merged query result |
protected java.lang.String |
mSqlStatement
SQL query statement from request |
protected boolean |
mTimeoutStatus
Indicator of whether a thread has timed out or not |
protected java.util.Timer |
mTimer
The timer that will be used by the threads to check the timout. |
Fields inherited from class uk.org.ogsadai.activity.Activity |
mContext, mExternalInputs, mExternalOutputs, mInternalInputs, mInternalOutputs |
Constructor Summary | |
SQLQueryMultipleActivity(org.w3c.dom.Element element)
|
Method Summary | |
protected void |
cleanUp()
This method can be overridden by any Activity
implementations that need to free up resources in the event of
an error or intermediate termination of the activity
processing. |
void |
initialise()
This method should be overridden by subclasses to perform any initialisation they require before the process
method invocations begin. |
(package private) boolean |
isTimeout()
Check if the thread of each of the data service resources has timed out. |
(package private) void |
setTimeout(boolean status)
Set the time out of each of the data service resources has timed out. |
Methods inherited from class uk.org.ogsadai.activity.Activity |
connectsTo, createOutputPipe, getActivityConfiguration, getActivityName, getCause, getName, getObservableStatus, getProperties, getSession, getStatus, hasActivityConfiguration, hasProperties, process, processBlock, processFirst, setActivityName, setCompleted, setError |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static final java.lang.String COPYRIGHT_NOTICE
private static final DAILogger LOG
protected BlockWriter mOutput
protected java.lang.String mSqlStatement
protected java.lang.String mOutputString
protected DataServiceInfo[] mMultipleDS
protected long mClientTimeout
protected java.util.Timer mTimer
protected boolean mTimeoutStatus
Constructor Detail |
public SQLQueryMultipleActivity(org.w3c.dom.Element element) throws ActivitySpecificationException, ActivityCreationException
Method Detail |
boolean isTimeout()
true
if so, false
if not.void setTimeout(boolean status)
status
- true
if so, false
if not.public void initialise() throws ActivitySpecificationException, ActivityExecutionException
Activity
process
method invocations begin. This might be used for setting up
convenient fields to reference objects contained in the
context. It shouldn't be used for opening resources.
That should be done in processFirst
.
initialise
in class Activity
ActivityExecutionException
- If some system problem prevents the activity from
initialising.
ActivitySpecificationException
- If a problem with settings provided by a client prevents
the activity from initialising.protected void cleanUp()
Activity
Activity
implementations that need to free up resources in the event of
an error or intermediate termination of the activity
processing.
cleanUp
in class Activity
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |