Re: [PATCH 2/2] dir.c: add retry logic to relocate_gitdir

2017-01-04 Thread Duy Nguyen
On Tue, Dec 20, 2016 at 6:19 AM, Stefan Beller wrote: >> On 12/19, Stefan Beller wrote: > This code is heavily inspired by refs/files-backend.c which upon > closer inspection only retries directory things within the git directory > (which is assumed to be accessed in parallel by different invocati

Re: [PATCH 2/2] dir.c: add retry logic to relocate_gitdir

2016-12-19 Thread Stefan Beller
On Mon, Dec 19, 2016 at 2:25 PM, Brandon Williams wrote: > On 12/19, Stefan Beller wrote: >> Relocating a git directory consists of 3 steps: >> 1) Move the directory. >> 2) Update the gitlink file. >> 3) Set core.worktree correctly. >> >> In an ideal world all three steps would be part of one tran

Re: [PATCH 2/2] dir.c: add retry logic to relocate_gitdir

2016-12-19 Thread Brandon Williams
On 12/19, Stefan Beller wrote: > Relocating a git directory consists of 3 steps: > 1) Move the directory. > 2) Update the gitlink file. > 3) Set core.worktree correctly. > > In an ideal world all three steps would be part of one transaction, such > that either all of them happen correctly or none

[PATCH 2/2] dir.c: add retry logic to relocate_gitdir

2016-12-19 Thread Stefan Beller
Relocating a git directory consists of 3 steps: 1) Move the directory. 2) Update the gitlink file. 3) Set core.worktree correctly. In an ideal world all three steps would be part of one transaction, such that either all of them happen correctly or none of them. However currently we just execute th