From 79bec412a134fa08306ea74f855fb5c657d9c357 Mon Sep 17 00:00:00 2001 From: Matthias Sohn Date: Wed, 12 Feb 2020 01:00:31 +0100 Subject: [PATCH] Update JGit to 5.1.13.202002110435-r JGit 5.1.13.202002110435-r adds - new WindowCache metrics - and enables using strong references to reference cache pages in the WindowCache. Set core.packedGitUseStrongRefs = true to enable using strong references to reference packfile pages cached in the WindowCache. If this option is set Java gc can no longer flush the WindowCache to free memory if the used heap comes close to the maximum heap size. On the other hand this provides more predictable performance. Change-Id: I895369a8596dfc5adce76c65202ecf37e6a8386d --- Documentation/config-gerrit.txt | 15 +++++++++++++++ lib/jgit/jgit.bzl | 12 ++++++------ 2 files changed, 21 insertions(+), 6 deletions(-) diff --git a/Documentation/config-gerrit.txt b/Documentation/config-gerrit.txt index 67fabb5c1a..167f1cb07f 100644 --- a/Documentation/config-gerrit.txt +++ b/Documentation/config-gerrit.txt @@ -1577,6 +1577,21 @@ Default on JGit is 10 MiB on all platforms. + Common unit suffixes of 'k', 'm', or 'g' are supported. +[[core.packedGitUseStrongRefs]]core.packedGitUseStrongRefs:: ++ +Set to `true` in order to use strong references to reference packfile +pages cached in the WindowCache. Otherwise SoftReferences are used. +If this option is set to `false`, the Java garbage collector will +flush the WindowCache to free memory if the used heap comes close to +the maximum heap size. This has the advantage that it can quickly +reclaim memory which was used by the WindowCache but comes at the +price that the previously cached pack file content needs to be again +copied from the file system cache to the Gerrit process. +Setting this option to `true` prevents flushing the WindowCache +which provides more predictable performance. ++ +Default is `false`. + [[core.deltaBaseCaseLimit]]core.deltaBaseCacheLimit:: + Maximum number of bytes to reserve for caching base objects diff --git a/lib/jgit/jgit.bzl b/lib/jgit/jgit.bzl index 22e3999d65..ed82c56269 100644 --- a/lib/jgit/jgit.bzl +++ b/lib/jgit/jgit.bzl @@ -1,6 +1,6 @@ load("//tools/bzl:maven_jar.bzl", "MAVEN_CENTRAL", "maven_jar") -_JGIT_VERS = "5.1.12.201910011832-r" +_JGIT_VERS = "5.1.13.202002110435-r" _DOC_VERS = _JGIT_VERS # Set to _JGIT_VERS unless using a snapshot @@ -40,28 +40,28 @@ def jgit_maven_repos(): name = "jgit-lib", artifact = "org.eclipse.jgit:org.eclipse.jgit:" + _JGIT_VERS, repository = _JGIT_REPO, - sha1 = "62c60aa985aa8dcfa6ad7308d130c319a1d01073", - src_sha1 = "6260138710f82d9084ab55e97aba8981e63c6ac2", + sha1 = "dc99e6ef37038090561bd5253c71b150791bea58", + src_sha1 = "882b62cac802a26e5fe383cd1a16f8b2d557e2fe", unsign = True, ) maven_jar( name = "jgit-servlet", artifact = "org.eclipse.jgit:org.eclipse.jgit.http.server:" + _JGIT_VERS, repository = _JGIT_REPO, - sha1 = "7e32173b3d1958627950f1b675e5a3f1f35e9b53", + sha1 = "5860d7828839db9a41b664488540704f783d0280", unsign = True, ) maven_jar( name = "jgit-archive", artifact = "org.eclipse.jgit:org.eclipse.jgit.archive:" + _JGIT_VERS, repository = _JGIT_REPO, - sha1 = "c86ea9a5771bc966a3b0e4bba4c7113e5423c0f4", + sha1 = "fb8538a090daa5dfb6674cdf860dd34d6a4078ed", ) maven_jar( name = "jgit-junit", artifact = "org.eclipse.jgit:org.eclipse.jgit.junit:" + _JGIT_VERS, repository = _JGIT_REPO, - sha1 = "2d957b5b515f9510792659277b5df049b6e795d8", + sha1 = "1e45351d6c19f65135ee4b693c0346772307671d", unsign = True, )