aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/config-options.md
diff options
context:
space:
mode:
authorKaushik Lingarkar <quic_kaushikl@quicinc.com>2023-01-11 21:25:30 -0800
committerMatthias Sohn <matthias.sohn@sap.com>2023-01-13 18:44:35 +0100
commitfed1a54935c0180e95804d42c1700b1f1819de3d (patch)
treedabe3b8d33e0eaac0a1ad7eb47e0497e91e0ed03 /Documentation/config-options.md
parent82b5aaf7e3e3f881056dd2d4486e02537b0493da (diff)
downloadjgit-fed1a54935c0180e95804d42c1700b1f1819de3d.tar.gz
jgit-fed1a54935c0180e95804d42c1700b1f1819de3d.zip
Refresh 'objects' dir and retry if a loose object is not found
A new loose object may not be immediately visible on a NFS client if it was created on another client. Refreshing the 'objects' dir and trying again can help work around the NFS behavior. Here's an E2E problem that this change can help fix. Consider a Gerrit multi-primary setup with repositories based on NFS. Add a new patch-set to an existing change and then immediately fetch the new patch-set of that change. If the fetch is handled by a Gerrit primary different that the one which created the patch-set, then we sometimes run into a MissingObjectException that causes the fetch to fail. Bug: 581317 Change-Id: Iccc6676c68ef13a1e8b2ff52b3eeca790a89a13d Signed-off-by: Kaushik Lingarkar <quic_kaushikl@quicinc.com>
Diffstat (limited to 'Documentation/config-options.md')
-rw-r--r--Documentation/config-options.md2
1 files changed, 1 insertions, 1 deletions
diff --git a/Documentation/config-options.md b/Documentation/config-options.md
index 9cb3c62a35..5b61df04bc 100644
--- a/Documentation/config-options.md
+++ b/Documentation/config-options.md
@@ -45,7 +45,7 @@ For details on native git options see also the official [git config documentatio
| `core.streamFileThreshold` | `50 MiB` | &#x20DE; | The size threshold beyond which objects must be streamed. |
| `core.supportsAtomicFileCreation` | `true` | &#x20DE; | Whether the filesystem supports atomic file creation. |
| `core.symlinks` | Auto detect if filesystem supports symlinks| &#x2705; | If false, symbolic links are checked out as small plain files that contain the link text. |
-| `core.trustFolderStat` | `true` | &#x20DE; | Whether to trust the pack folder's and packed-refs file's file attributes (Java equivalent of stat command on *nix). When looking for pack files, if `false` JGit will always scan the `.git/objects/pack` folder and if set to `true` it assumes that pack files are unchanged if the file attributes of the pack folder are unchanged. When getting the list of packed refs, if `false` JGit will always read the packed-refs file and if set to `true` it uses the file attributes of the packed-refs file and will only read it if a file attribute has changed. Setting this option to `false` can help to workaround caching issues on NFS, but reduces performance.|
+| `core.trustFolderStat` | `true` | &#x20DE; | Whether to trust the pack folder's, packed-refs file's and loose-objects folder's file attributes (Java equivalent of stat command on *nix). When looking for pack files, if `false` JGit will always scan the `.git/objects/pack` folder and if set to `true` it assumes that pack files are unchanged if the file attributes of the pack folder are unchanged. When getting the list of packed refs, if `false` JGit will always read the packed-refs file and if set to `true` it uses the file attributes of the packed-refs file and will only read it if a file attribute has changed. When looking for loose objects, if `false` and if a loose object is not found, JGit will open and close a stream to `.git/objects` folder (which can refresh its directory listing, at least on some NFS clients) and retry looking for that loose object. Setting this option to `false` can help to workaround caching issues on NFS, but reduces performance. |
| `core.trustPackedRefsStat` | `unset` | &#x20DE; | Whether to trust the file attributes (Java equivalent of stat command on *nix) of the packed-refs file. If `never` JGit will ignore the file attributes of the packed-refs file and always read it. If `always` JGit will trust the file attributes of the packed-refs file and will only read it if a file attribute has changed. `after_open` behaves the same as `always`, except that the packed-refs file is opened and closed before its file attributes are considered. An open/close of the packed-refs file is known to refresh its file attributes, at least on some NFS clients. If `unset`, JGit will use the behavior described in `trustFolderStat`. |
| `core.worktree` | Root directory of the working tree if it is not the parent directory of the `.git` directory | &#x2705; | The path to the root of the working tree. |