Skip to content

Repo syncer: construct stores on the fly

Administrator requested to merge cc/construct-on-fly into main

Created by: camdencheek

This constructs other stores from repos.Store on the fly rather than storing them on the store struct. This is just to increase confidence that, when we start a transaction, the next time we use a store, it holds a handle to that transaction. I was really struggling to convince myself that it was okay that we would start a transaction on the basestore, but then use the untransacted store that we hold a reference to on the store struct. I wasn't able to construct any failures, but this still feels safer.

Note that I'm not confident this fixes incident 99 since I couldn't reproduce it locally, but it might. I'm probably not going to be the one to un-revert it and try though 🙂

Test plan

Depending on existing tests here, but I think this should be a safe change based on what I've read of the code.

Merge request reports

Loading