2014-12-11 07:17:29 -05:00
|
|
|
# Resource Manager Configuration
|
2014-12-04 10:25:29 -05:00
|
|
|
|
2015-04-27 17:32:30 -04:00
|
|
|
Apache ActiveMQ Artemis has its own Resource Manager for handling the lifespan of JTA
|
2014-12-04 10:25:29 -05:00
|
|
|
transactions. When a transaction is started the resource manager is
|
|
|
|
notified and keeps a record of the transaction and its current state. It
|
|
|
|
is possible in some cases for a transaction to be started but then
|
|
|
|
forgotten about. Maybe the client died and never came back. If this
|
|
|
|
happens then the transaction will just sit there indefinitely.
|
|
|
|
|
2015-04-27 17:32:30 -04:00
|
|
|
To cope with this Apache ActiveMQ Artemis can, if configured, scan for old transactions
|
2014-12-04 10:25:29 -05:00
|
|
|
and rollback any it finds. The default for this is 3000000 milliseconds
|
|
|
|
(5 minutes), i.e. any transactions older than 5 minutes are removed.
|
|
|
|
This timeout can be changed by editing the `transaction-timeout`
|
2015-04-29 05:30:31 -04:00
|
|
|
property in `broker.xml` (value must be in
|
2014-12-04 10:25:29 -05:00
|
|
|
milliseconds). The property `transaction-timeout-scan-period` configures
|
|
|
|
how often, in milliseconds, to scan for old transactions.
|
|
|
|
|
2015-04-27 17:32:30 -04:00
|
|
|
Please note that Apache ActiveMQ Artemis will not unilaterally rollback any XA
|
2014-12-04 10:25:29 -05:00
|
|
|
transactions in a prepared state - this must be heuristically rolled
|
|
|
|
back via the management API if you are sure they will never be resolved
|
|
|
|
by the transaction manager.
|