Download: 3.6.0
Documentation: 3.6.0
Gerrit deprecates the use of Prolog for definition of custom logic in the submit rules. From this version onwards the rules can be expressed using the new concept of Submit Requirements.
Submit Requirements have several advantages, compared to the legacy Prolog rules:
Existing projects relying on Prolog will still work as expected, allowing a smoother project transition.
Submit requirements also introduce new handy functions that allow to achieve complex rules equivalent to the old Prolog rules but with an easier syntax:
file:
operator.distinctvoters
predicate allows gating submission on N distinct voters across more than one label.authoremail
operator similar to the older commit_author
Prolog predicatemessage
predicate to support regular expression on the commit message as a condition.NOTE: With the new submit requirements, submit records are no longer emitted. This means that any queries with the label formats (
label:Code-Review=NEED
orlabel:Code-Review=OK
) will no longer match with changes. See more details in Change 330203.
This release doesn't formally contain schema changes, however the NoteDb format has evolved and includes the following amendments:
Change 324937: The label in NoteDb has a UUID suffix
Change 323897: The review score is only read from the latest patch-set
NOTE: Because of the above incompatibilities, upgrade is supported only from Gerrit v3.5.2 onwards, because of the need of the extra
copy-approvals
tool and the backward compatibility fix on UUID suffixed labels. Failing to run thecopy-approvals
tool in v3.5.2 would leave the changes with a potentially stale approval score once the site is migrated to v3.6.
The changes
index version has been increased to version 77. By default the index is automatically rebuilt upon the Gerrit startup after the upgrade.
Upgrade to Gerrit v3.5.2 or later and make sure that the copy-approvals
site program has been run at least once.
java -jar gerrit.war copy-approvals -d site_path
Download the Gerrit v3.6.0 war and run the init
program:
java -jar gerrit-3.6.0.war init -d site_path
Run offline reindexing of the changes:
java -jar gerrit.war reindex --index changes -d site_path
Gerrit v3.6.x supports zero-downtime upgrade from Gerrit v3.5.2 or later when configured using a high-availability configuration, and the Git repositories are stored in a shared filesystem such as NFS or similar.
During the zero-downtime upgrade, Gerrit end-users would not notice any outage or service disruption. They will be able to perform any read/write Gerrit operation on the GUI or using using any API.
The zero-downtime upgrade consists of the following steps:
copy-approvals
SSH command against one of the Gerrit servers and wait for completion on all changes for all projects.Change 321607: Assignee feature is completely removed from the Gerrit UI
The Attention Set feature has been launched in Gerrit v3.3, and assignee has been turned off by default for three releases. The feature is now completely removed and cannot be enabled anymore by config.
Project Owners implicit delete reference permission has been removed.
Before this release all Project Owners had implicit delete permission to all refs unless force-push was blocked for the user. Admins that are relying on previous behavior or wish to maintain it for their users can simply add the permission explicitly in All-Projects:
[access "refs/*"] delete = Project Owners
NOTE: If you choose to do so, blocking force-push no longer has any effect on permission to delete refs by means other than git (REST, UI).
Support for CentOS is dropped and the base image replaced by AlmaLinux
RedHat anticipated the EOL of CentOS to December 2021 making hard for the Gerrit community to continue to support existing Docker setups on CentOS. The default base image now uses AlmaLinux 8 which promises to have a much longer life as open-source OS and has an easy migration tool from CentOS 8 available.
Apache Commons Lang v2 is removed
Gerrit moved to Apache Commons Lang v3 replacing all legacy use of the older lang v2 from its dependencies. Existing plugins and scripts that are using Apache Commons Lang v2 must be rebuilt to use the new library or declare the older Apache Commons Lang v2 as an explicit dependency.
Change 331259: Deprecate the registerStyleModule()
JS plugin API
Change 330403: Support validation options for branch creation to be used in RefOperationValidationListener implemented in plugins.
Change 330200: Add support for specifying validation options in rebase and cherry-pick REST endpoint and implemented in plugins.
Upgrade to gitiles v1.0.0
Change 324242: Add syntax highlighting for Markdown
Reuse and enable highlight.js syntax highlighting of Markdown files.
Issue 15715: Fix the editing workflow in the web app
Change 330301: Adding tab navigation for hovercards
Change 330919: Show Change actions regardless if logged in or not, because the gr-change-actions correctly hides the actions that the current user cannot do.
Change 333299: Remove the front-end metric diffViewFullyLoaded
replaced by diffViewDiplayed
to represent highlighting a whole file.
Change 330204: Adds changes and dashboard link to account hovercard.
Change 330084: Status field renamed to About me and no icon is shown.
New test properties are available in the End-to-End tests:
Update jgit to v6.1.0.202203080745-r
most important changes since 5.13:
Update sshd to 2.8.0
The highlights of SSHD update from Gerrit's perspective are:
SSHD-1216: Server-side implementation of the RFC 8332 server-sig-algs extension: the server announces that it prefers the SHA-2 signatures for RSA keys.
SSHD-1197: A race condition in key exchange fixed.
SSHD-1163: DH group exchange got a fix relating to RSA SHA-2 signatures.
Additionally, sshd 2.8.0 now supports (and prefers) the chacha20-poly1305@openssh.com cipher SSHD-1017, and supports the curve25519 and curve448 KEX algorithms SSHD-704.
Update codemirror-minified to 5.65.0
Update highlight.js to 11.5.0
Update rules_nodejs version to 5.1.0
Update rules_go version to 0.30
Update protobuf version to 3.19.4
Change 334747: Fixed missing return type in e2e-tests
Change 334557: Make the computing of the diff cache thread-safe.
The computation previously failed with a zlib exception that was logged as if the packfile was corrupt even though it wasn't.
Change 333706: Added support for ‘is:’ in approval copy condition queries to make arbitrary voting values sticky
Change 332139: Stop adding project-owners to To:
of the emails for new changes.