Package io.mats3.impl.jms
Class JmsMatsInternalExecutionContext
java.lang.Object
io.mats3.impl.jms.JmsMatsInternalExecutionContext
This is an internal context object, for execution of initiations and stage processing in JMS-Mats - one instance is
made per initiation and per message reception. This is used to communicate back and forth between JmsMats proper, the
JmsMatsJmsSessionHandler
and JmsMatsTransactionManager
.-
Method Summary
Modifier and TypeMethodDescriptionlong
Optional<javax.jms.MessageConsumer>
long
boolean
void
setDbCommitNanos
(long dbCommitNanos) void
setMessageSystemCommitNanos
(long messageSystemCommitNanos) void
setSqlTxConnectionSuppliers
(Supplier<Connection> sqlConnectionSupplier, Supplier<Boolean> sqlConnectionEmployedSupplier) If the currentJmsMatsTransactionManager
is managing a SQL Connection, then it SHALL set a way to get the current transactional SQL Connection, and a way to determine whether the SQL Connection was actually employed (if this is not possible to determine, then return whether it was gotten).void
-
Method Details
-
getJmsSessionHolder
-
getMessageConsumer
- Returns:
- the
MessageConsumer
in effect if this is within aJmsMatsStageProcessor
, returns Optional.empty() if this is within aJmsMatsInitiator
.
-
setSqlTxConnectionSuppliers
public void setSqlTxConnectionSuppliers(Supplier<Connection> sqlConnectionSupplier, Supplier<Boolean> sqlConnectionEmployedSupplier) If the currentJmsMatsTransactionManager
is managing a SQL Connection, then it SHALL set a way to get the current transactional SQL Connection, and a way to determine whether the SQL Connection was actually employed (if this is not possible to determine, then return whether it was gotten).- Parameters:
sqlConnectionSupplier
- a supplier for the current transactional SQL ConnectionsqlConnectionEmployedSupplier
- a supplier for whether the SQL Connection was actually employed (if this is not possible to determine, then return whether it was gotten).
-
setUserLambdaExceptionLogged
public void setUserLambdaExceptionLogged() -
isUserLambdaExceptionLogged
public boolean isUserLambdaExceptionLogged() -
setDbCommitNanos
public void setDbCommitNanos(long dbCommitNanos) -
getDbCommitNanos
public long getDbCommitNanos() -
setMessageSystemCommitNanos
public void setMessageSystemCommitNanos(long messageSystemCommitNanos) -
getMessageSystemCommitNanos
public long getMessageSystemCommitNanos()
-