commit | 59c9ae73771c2da8409dd7f2836cfd201f1c920e | [log] [tgz] |
---|---|---|
author | Nasser Grainawi <nasser.grainawi@linaro.org> | Wed Dec 07 18:20:06 2022 +0100 |
committer | Matthias Sohn <matthias.sohn@sap.com> | Fri Dec 09 17:43:39 2022 +0100 |
tree | 97efa9dbcb66a56218a60dfed8f2560237110d46 | |
parent | c24e11dd43ca15c9da5c255c235b25ca58170dc4 [diff] |
Custom git gc-preserve command which can preserve packs for JGit Implement a custom git command "git-gc-preserve" preserving old packs to prevent races between git gc running on a large repository concurrently to fetch/clone requests. This is similar to the implementation in JGit in [1] which can be used to avoid errors in such situations [2]. New custom git config options configure how to handle preserving packs: gc.prunepreserved: if set to "true" preserved packs from the last gc run are pruned before current packs are preserved. gc.preserveoldpacks: if set to "true" current packs will be hard linked to objects/pack/preserved before git gc is executed. JGit will fallback to the preserved packs in this directory in case it comes across missing objects which might be caused by a concurrent run of git gc. This command does not attempt to implement the file locking git gc --auto implements [3]. Kudos to Nasser Grainawi for the core of this implementation. [1] https://git.eclipse.org/r/c/jgit/jgit/+/87969 [2] https://git.eclipse.org/r/c/jgit/jgit/+/122288 [3] https://github.com/git/git/commit/64a99eb4760de2ce2f0c04e146c0a55c34f50f20 Release-Notes: Custom git gc-preserve command which can preserve packs for JGit Change-Id: I59c02ea86d75b5787a20422d4000ffef55f0249b
Gerrit is a code review and project management tool for Git based projects.
Gerrit makes reviews easier by showing changes in a side-by-side display, and allowing inline comments to be added by any reviewer.
Gerrit simplifies Git based project maintainership by permitting any authorized user to submit changes to the master Git repository, rather than requiring all approved changes to be merged in by hand by the project maintainer.
For information about how to install and use Gerrit, refer to the documentation.
Our canonical Git repository is located on googlesource.com. There is a mirror of the repository on Github.
Please report bugs on the issue tracker.
Gerrit is the work of hundreds of contributors. We appreciate your help!
Please read the contribution guidelines.
Note that we do not accept Pull Requests via the Github mirror.
The Developer Mailing list is repo-discuss on Google Groups.
Gerrit is provided under the Apache License 2.0.
Install Bazel and run the following:
git clone --recurse-submodules https://gerrit.googlesource.com/gerrit cd gerrit && bazel build release
The instruction how to configure GerritForge/BinTray repositories is here
On Debian/Ubuntu run:
apt-get update && apt-get install gerrit=<version>-<release>
NOTE: release is a counter that starts with 1 and indicates the number of packages that have been released with the same version of the software.
On CentOS/RedHat run:
yum clean all && yum install gerrit-<version>[-<release>]
On Fedora run:
dnf clean all && dnf install gerrit-<version>[-<release>]
Docker images of Gerrit are available on DockerHub
To run a CentOS 8 based Gerrit image:
docker run -p 8080:8080 gerritcodereview/gerrit[:version]-centos8
To run a Ubuntu 20.04 based Gerrit image:
docker run -p 8080:8080 gerritcodereview/gerrit[:version]-ubuntu20
NOTE: release is optional. Last released package of the version is installed if the release number is omitted.