Re: [PATCH 5/6] fetch: make `--atomic` flag cover backfilling of tags
- From
- Jonathan Tan <jonathantanmy@google.com>
- Date
- Feb 16, 2022, 23:41 UTC
- Message-ID
- <20220216234157.1976077-1-jonathantanmy@google.com>
- In-Reply-To
- <CAP8UFD1bdLESqzbZcYKYfib836vrDTfyCmYfT-9B-1ToJB0EWg@mail.gmail.com>
Christian Couder <christian.couder@gmail.com> writes:
Show 7 quoted lines
> > Fix this by pulling up creation of the reference transaction such that > > we can pass the same transaction to both the code which updates local > > references and to the code which backfills tags. This allows us to only > > commit the transaction in case both actions succeed. > > Maybe this could be seen as a regression by users who are mostly > interested in the local references though.
I don't think we need to worry about this - as far as I know, backfilling of tags only happens when the server doesn't support include-tag, which was introduced in 2009 (and in my experience, they all do). And in the rare case that backfilling happens, I think the user would want to have atomicity in the also rare case that the first fetch succeeds and the second fails.