Yes, all in flight transactions will remain in-flight until the transaction
manager can heuristically determine that they should be rolled back or
committed, which happen when the transaction manager is informed about the
state of the various transactional resources (in our case, the JDBC
connection).
So if the JDBC connection pool does not recover, the transactions that were
in flight at the time of the crash will never be committed or rolled back.
Unfortunately, the recovery can only be done using interfaces that are
specific to a given transaction manager, hence the pax-jdbc-pool-aries and
pax-jdbc-pool-narayana which can support the aries/geronimo and narayana
transaction manager respectively.

2016-11-03 11:55 GMT+01:00 Christian Schneider <ch...@die-schneider.net>:

> I fully agree.. The even bigger problem is that people do not really
> understand what recoverable means at all.
> Until recently my understanding was that without recovery all running
> transactions would simply be rolled back in case of a crash .. but this
> does not seem to be the case.
>
> Luckily I met Tim Ward at eclipsecon last week and he explained to me what
> happens with and without recovery but we need to spread the word more about
> this.
>
> So if I understood correctly the problem without recovery is that if the
> server crashes while one resource in an XA transaction is already committed
> and the other is not then
> it will remain in this way.
>

> So I think some people can live with it as it is a rare case but it is
> really important to make people aware of the risk so they can make an
> informed decision.
>
> Christian
>
>
> On 03.11.2016 11:47, Guillaume Nodet wrote:
>
> I think we should clearly document the level of safety using those pooling
> mechanism.
> Afaik, hikari and dbcp2 do not support automatic transaction recovery, the
> only combinations I'm aware of are:
>  *  aries transaction manager + pax-jdbc-pooling-aries
>  * narayana transaction manager + pax-jdbc-pooling-narayana
>
> I think this is really important to document, as people may wrongly think
> they are using something safe (because of XA) while it's not really in case
> of a crash.
>
>
>
> 2016-11-03 11:32 GMT+01:00 Christian Schneider <ch...@die-schneider.net>:
>
>> I have documented how the new pooling and XA support works.
>>
>> I think the new support is much more straightforward to use and gives
>> better error reporting.
>>
>> For example in the old pooling support if you use the pooling and xa
>> enabled DSF "H2-pool-xa" and forget to install a TransactionManager or the
>> pooling module the
>> DataSource is simply not created. There is no error in the log as the
>> config module can not know if the enhanced DSF is just not yet there or
>> will never come up.
>>
>> In the new pooling and XA support there will be a good error in the log
>> if either the pooling or the TransactionManager are missing.
>>
>> See
>>
>> https://ops4j1.jira.com/wiki/display/PAXJDBC/Pooling+and+XA+
>> support+in+1.0.0
>>
>> Christian
>>
>> --
>> Christian Schneider
>> http://www.liquid-reality.de
>>
>> Open Source Architect
>> http://www.talend.com
>>
>> --
>> --
>> ------------------
>> OPS4J - http://www.ops4j.org - ops4j@googlegroups.com
>>
>> --- You received this message because you are subscribed to the Google
>> Groups "OPS4J" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to ops4j+unsubscr...@googlegroups.com.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>
>
> --
> ------------------------
> Guillaume Nodet
> ------------------------
> Red Hat, Open Source Integration
>
> Email: gno...@redhat.com
> Web: http://fusesource.com
> Blog: http://gnodet.blogspot.com/
>
> --
> --
> ------------------
> OPS4J - http://www.ops4j.org - ops4j@googlegroups.com
>
> ---
> You received this message because you are subscribed to the Google Groups
> "OPS4J" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to ops4j+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>
>
>
> --
> Christian Schneiderhttp://www.liquid-reality.de
>
> Open Source Architecthttp://www.talend.com
>
> --
> --
> ------------------
> OPS4J - http://www.ops4j.org - ops4j@googlegroups.com
>
> ---
> You received this message because you are subscribed to the Google Groups
> "OPS4J" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to ops4j+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.
>



-- 
------------------------
Guillaume Nodet
------------------------
Red Hat, Open Source Integration

Email: gno...@redhat.com
Web: http://fusesource.com
Blog: http://gnodet.blogspot.com/

-- 
-- 
------------------
OPS4J - http://www.ops4j.org - ops4j@googlegroups.com

--- 
You received this message because you are subscribed to the Google Groups 
"OPS4J" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ops4j+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to