Re: concurrent fetches to update same mirror
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Jan 5, 2011, 23:29 UTC
- Message-ID
- <7vbp3vc4k4.fsf@alter.siamese.dyndns.org>
- In-Reply-To
- <20110105211313.GB7808@sigill.intra.peff.net>
Jeff King <peff@peff.net> writes:
Show 9 quoted lines
> Interestingly, in the case of ref _creation_, not update, like this: > > mkdir repo && cd repo && git init > git remote add origin some-remote-repo-that-takes-a-few-seconds > xterm -e 'git fetch -v; read' & xterm -e 'git fetch -v; read' > > then both will happily update, the second one overwriting the results of > the first. It seems in the case of locking a ref which previously didn't > exist, we don't enforce that it still doesn't exist.
We probably should, especially when there is no --force or +prefix is involved.