Reconnection settings
Apama applications can automatically reconnect if a disconnection error is encountered. The reconnection capability is optional and the default is to not reconnect when a disconnection error occurs. The following reconnection actions are defined in the com.apama.database.DBUtil event.
action setReconnectPolicy(string reconnectPolicy) — This action sets the policy for dealing with adapter connection errors. The
reconnectPolicy parameter must be one of the constants specified in the
DBReconnectPolicy event. The policy constants are as follows:
RECONNECT_AND_RETRY_LAST_REQUEST — Try to reconnect and leave the pending requests unchanged, retry the last request on a successful database reconnection.
DO_NOT_RECONNECT — Do not try to reconnect. This is the default reconnect policy.
action setReconnectTimeout(float timeOut) — This action sets the timeout for the reconnection after a connection error. A value specified by the
setReconnectTimeout action overrides the default timeout value, which is equal to twice as long as specified by the open action's
timeOut parameter.