flux
Interface DatabaseConditionTrigger

All Superinterfaces:
Action, java.lang.Cloneable, DatabaseActionInfo, DatabaseConditionAction, RuntimeDataMap, java.io.Serializable, Trigger

public interface DatabaseConditionTrigger
extends DatabaseConditionAction, Trigger

According to a certain frequency, executes an SQL SELECT statement and then, using the first row of JDBC result set information returned from the query, evaluates a condition expression to see if it is satisfied. Useful for determining when the data in a database meets certain conditions and satisfies certain criteria.

For this purpose, the database connection available to the flow context can be used, or alternately, database connection information can be provided to connect to a data source or use a direct JDBC connection.

The frequency at which this trigger queries a database is governed by the polling delay. When the flow of control reaches this trigger, the database is queried immediately. If the condition is not satisfied, the trigger waits for the polling delay period of time to pass before querying the database again.

Essentially the same as the DatabaseConditionAction, the DatabaseConditionTrigger simply keeps polling a database until the condition becomes satisfied. Of course, execution control flow can break away from this trigger for other reasons common to all triggers and actions such as a timeout.

The Database Condition Trigger returns its result in the same format as the Database Condition Action. For more information on accessing and using the result, see DatabaseConditionAction.

Author:
Copyright 2014 Flux Corporation. All rights reserved.

Nested Class Summary
 
Nested classes/interfaces inherited from interface flux.DatabaseConditionAction
DatabaseConditionAction.DatabaseConditionActionResult
 
Method Summary
 java.lang.String getPollingDelay()
          Returns the delay that occurs between database queries.
 void setPollingDelay(java.lang.String timeExpression)
          Sets the delay that occurs between database queries.
 
Methods inherited from interface flux.DatabaseConditionAction
getCondition, getParameters, getQuery, setCondition, setParameters, setQuery
 
Methods inherited from interface flux.DatabaseActionInfo
getDataSource, getDataSourceInitialContextFactory, getDataSourceInitialContextPassword, getDataSourceInitialContextProviderUrl, getDataSourceInitialContextUsername, getDataSourcePassword, getDataSourceUsername, getJdbcDriver, getJdbcPassword, getJdbcUrl, getJdbcUsername, isBuiltinDatabaseConnectionUsed, setBuiltinDatabaseConnectionUsed, setDataSource, setDataSourceInitialContextFactory, setDataSourceInitialContextPassword, setDataSourceInitialContextProviderUrl, setDataSourceInitialContextUsername, setDataSourcePassword, setDataSourceUsername, setJdbcDriver, setJdbcPassword, setJdbcUrl, setJdbcUsername
 
Methods inherited from interface flux.Action
addFlow, addFlow, addSignalFlow, clone, execute, getDescription, getFlows, getHiddenVariableNames, getJoinExpression, getName, getPostscript, getPostscriptLanguage, getPrescript, getPrescriptLanguage, getResultInfo, getSignalsToMonitor, getTimeoutBusinessInterval, getTimeoutBusinessIntervalNamespace, getTimeoutExpression, getVariableManager, isEndOfRun, isJoinPoint, isSkippable, isStartAction, isStartOfRun, isTransactionBreak, removeFlow, reset, setDescription, setElseFlow, setEndOfRun, setErrorFlow, setErrorFlowWithoutRollback, setErrorFlowWithRollback, setJoinExpression, setJoinPoint, setName, setPostscript, setPostscriptLanguage, setPrescript, setPrescriptLanguage, setSignalsToMonitor, setSkippable, setStartAction, setStartOfRun, setTimeoutBusinessInterval, setTimeoutBusinessIntervalNamespace, setTimeoutExpression, setTimeoutFlow, setTransactionBreak, verify, verifyOnClient
 
Methods inherited from interface flux.runtimedatamap.RuntimeDataMap
getRuntimeDataMap, setRuntimeDataMap
 

Method Detail

getPollingDelay

java.lang.String getPollingDelay()
Returns the delay that occurs between database queries. Defaults to "+m", one minute.

Returns:
The delay that occurs between database queries.

setPollingDelay

void setPollingDelay(java.lang.String timeExpression)
                     throws EngineException
Sets the delay that occurs between database queries.

Parameters:
timeExpression - The delay that occurs between database queries.
Throws:
EngineException


© 2014 Flux Corporation. All rights reserved.