Previous versions of JBoss EAP 6 could encounter an `IllegalStateException` during some transaction recovery operations.
The transaction recovery system operates by querying resources for their view of 'in-doubt' transaction branches. It uses a "RecoveryHelper" which JCA registers to achieve this.
When a resource is removed from the system, the RecoveryHelper is de-registered. In previous versions of the product there was a race condition in the code whereby if the removal happened during a "recovery scan" then the helper was not removed.
This resulted in the possibility that transaction recovery would continue using resources even though they had been removed from the server (which could produce the `IllegalStateExceptions`).
In this release, if the current recovery scan is using the resource, it waits for it to finish and then remove the helper.