Skip to content

Code monitors: fix issues with concurrent access to transactions

Administrator requested to merge cc/no-parallel-transactions into main

Created by: camdencheek

This is a super hacky fix for the fact that creating a code monitor executes in a transaction which must not be used concurrently.

Honestly, this is a really scary problem across the whole codebase. We have no idea whether the database handles we are using are actually transactions, so we have no idea whether we can use them concurrently.

I plan to spend some time immediately on fixing this problem because I expect I'm not the only one who hits this.

Test plan

Manually tested that creating a code monitor for a bunch of repos succeeds.

Merge request reports

Loading