Hello booters !
userTransactionService
Factory method inside org.springframework.boot.autoconfigure.transaction.jta.AtomikosJtaConfiguration
is configured with destroyMethod="shutdownForce"
which gives no time for active transactions to terminate properly, this uselessly increases the need for recovery.
We suggest to change It to destroyMethod="shutdownWait"
. In 4.0.5 It's possible to configure the com.atomikos.icatch.default_max_wait_time_on_shutdown property
to set a custom max wait delay.
Comment From: philwebb
Seems like a sensible change to make in Boot 2.0
Comment From: nklmish
I can take this issue. Initial thoughts, we can change destroyMethod=shutDownWait
in AtomikosJtaConfiguration and introduce a new property defaultMaxWaitTimeOnShutdown
in AtomikosProperties. If sounds good, I can push the PR
Comment From: snicoll
@nklmish I think the property is there automatically as we bind to the factory. If you're willing to do this in the coming days, please do so.
Comment From: nklmish
@snicoll
I think the property is there automatically as we bind to the factory
May be I am missing something but In order to provide a user with the possibility to configure custom default_max_wait_time_on_shutdown
, shouldn't we add a new property
private long defaultMaxWaitTimeOnShutdown = Long.MAX_VALUE;
and use it in asProperties()
set(properties, "default_max_wait_time_on_shutdown", getDefaultMaxWaitTimeOnShutdown());
Otherwise the user will always have Long.MAX_VALUE
for default_max_wait_time_on_shutdown
.
Thank you
Comment From: snicoll
@nklmish Right, I forgot we had that. Carry on :)
Comment From: nklmish
@snicoll PR on the way :)
Comment From: snicoll
Closing in favour of PR ~#11245~ #11237
Comment From: GuyPardon
Hi,
What exactly is the status of this issue? Has it been implemented?
The status has been marked as duplicate of PR #11245 - which seems an unrelated issue?
Thanks
Comment From: snicoll
I just made a typo (that I've edited now), you can see the commit right above your comment. It was pr #11237