Commit 4623264
Fix submodule initialization in interleaved sync mode
With the introduction of interleaved sync mode, the submodule activation
logic broke because the 'has_submodules' attribute was no longer being
populated when needed. With this change, each submodule is initialized
when it enters the Sync_LocalHalf stage, whereas previously all
submodules were initialized at once when the parent repository entered
the Sync_LocalHalf stage. The init is now retried if it fails, as
submodules may concurrently modify the parent’s git config, potentially
causing contention when attempting to obtain a lock on it.
This change makes the submodule activation logic more robust and less
prone to breakage.
Bug: 444366154
Change-Id: I25eca4ea2a6868219045cfa088988eb01ded47d2
Reviewed-on: https://gerrit-review.googlesource.com/c/git-repo/+/509041
Reviewed-by: Gavin Mak <[email protected]>
Tested-by: Kaushik Lingarkar <[email protected]>
Reviewed-by: Nasser Grainawi <[email protected]>
Commit-Queue: Kaushik Lingarkar <[email protected]>
Reviewed-by: Scott Lee <[email protected]>1 parent 67383bd commit 4623264
1 file changed
+31
-14
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
642 | 642 | | |
643 | 643 | | |
644 | 644 | | |
645 | | - | |
646 | | - | |
647 | | - | |
648 | | - | |
649 | 645 | | |
650 | 646 | | |
651 | 647 | | |
| |||
1563 | 1559 | | |
1564 | 1560 | | |
1565 | 1561 | | |
1566 | | - | |
1567 | | - | |
| 1562 | + | |
| 1563 | + | |
1568 | 1564 | | |
1569 | 1565 | | |
1570 | 1566 | | |
| |||
2359 | 2355 | | |
2360 | 2356 | | |
2361 | 2357 | | |
2362 | | - | |
2363 | | - | |
2364 | 2358 | | |
2365 | 2359 | | |
2366 | 2360 | | |
| |||
3030 | 3024 | | |
3031 | 3025 | | |
3032 | 3026 | | |
3033 | | - | |
3034 | | - | |
| 3027 | + | |
| 3028 | + | |
3035 | 3029 | | |
3036 | 3030 | | |
3037 | 3031 | | |
3038 | | - | |
3039 | | - | |
3040 | | - | |
3041 | | - | |
| 3032 | + | |
| 3033 | + | |
| 3034 | + | |
| 3035 | + | |
| 3036 | + | |
| 3037 | + | |
| 3038 | + | |
| 3039 | + | |
| 3040 | + | |
| 3041 | + | |
| 3042 | + | |
3042 | 3043 | | |
| 3044 | + | |
| 3045 | + | |
| 3046 | + | |
| 3047 | + | |
| 3048 | + | |
| 3049 | + | |
| 3050 | + | |
| 3051 | + | |
| 3052 | + | |
| 3053 | + | |
| 3054 | + | |
| 3055 | + | |
| 3056 | + | |
| 3057 | + | |
| 3058 | + | |
| 3059 | + | |
3043 | 3060 | | |
3044 | 3061 | | |
3045 | 3062 | | |
| |||
0 commit comments