Context
SERVER-84623 changed the entry point to return to the router the actual error that caused the transaction to fail. Before SERVER-84623, every transient error would’ve been masked as StaleConfig and propagated back to the router. That was wrong and you can find more information in SERVER-84623.
Problem
Specifically for access_collection_in_transaction_after_catalog_changes.js, the findAndModify, which runs within a transaction, is experiencing several “Exceeded time limit” waiting on the critical section being taken by another operation. Specifically, the command will attempt to refresh on the server, which blocks the transaction for the reason explained. If the critical section does not resolve within the limit time (500ms) we throw an ExceedTimeLimit which is now correctly propagated back to the router.
The test always presented this behavior. The difference is that before SERVER-84623., that would’ve resulted in a StaleConfig error which is present among the expected errors.
Proposed solution
“Exceeded time limit” should be added among the expected errors.