This approach seems fine to me -- keeping it all out of the reconciliation tracking code, and checking with the ref is locked, makes it seem fairly straightforward.