Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jta-dev] Question on registerInterposedSynchronization() when marked for rollback

Thank you for raising the topic, Norbert. I would also like to hear from vendors if they are would like to share their interpretation of whether the specification clearly defines whether an active transaction must be in STATUS_ACTIVE [1].

On Mon, 11 Oct 2021 at 09:06, Norbert Wirges <norbert.wirges00+eclipse@xxxxxxxxx> wrote:

I already tried asking this on the JTA forum
(, but did not
get a response.

Most methods of TransactionSynchronizationRegistry throw an
IllegalStateException "if no transaction is active", most notably :

Does "if no transaction is active" mean
a) if no transaction is present on the current thread
b) if no transaction in state ACTIVE is present on the current thread
(or something entirely different)?
More concrete: how should registerInterposedSynchronization() behave
in case the current transaction is marked for rollback? Should it
reject the action with an IllegalStateException or accept the
registered synchronization and execute afterCompletion() when the
rollback actually happens?
(Maybe  for the next version the wording could be made non-ambiguous?)

For reference: I'm asking because of the discussion on

Thanks in advance,
jta-dev mailing list
To unsubscribe from this list, visit

Back to the top