Download: 3.9.0-rc5
Documentation: 3.9.0-rc5
The language level used for Gerrit source code stays on Java 11, however, Gerrit is built and distributed for Java 17, which is the recommended JVM version for running it in production.
batch-refupdate
Gerrit notifies all the refs of a single batch-refupdate as a single stream event JSON payload Issue 40015567. The new batch-ref-updated
event is controlled by configuration and can be switched off for backward compatibility with legacy CI/CD systems.
ref-update for draft-comments
Gerrit generates the ref-update event for all the additions and removals of draft comments in the All-Users
project (Change 382819). This is needed for replicating the All-Users
project across sites, thanks to the replication plugins being notified of the updates.
Due to the nature of drafts, on busy installations the amount of ref-updated
events created on draft operations could be high, possibly having an impact on performance.
For this reason this is disabled by default, you can enable it by configuring event.stream-events.enableDraftCommentEvents=true
in gerrit.config
Change 385714
There are new limit definitions which can be used to protect Gerrit from improper client activity.
change.topicLimit
: defines the maximum number of changes in the same topic (Change 381055.
change.maxFileSizeDownload
: prevents memory overload caused by clients downloading large files from REST-API (Change 381595).
change.maxFileSizeDiff
: prevents memory overload caused by rendering large files diffs in a browser.
A new change.diff3ConflictView
option allows to enable a richer diff3 rendering of changes with conflict markers (Change 382894).
Gerrit can return changes to the original attention set assignment if any of the new assignees do not provide feedback within a specific time (Issue 40015204). The behaviour is controlled by two new settings, attentionSet.readdAfter
and attentionSet.readdMessage
.
Allow to limit the queries that do not specify a default limit and also can now reindex changes with an asynchronous process when a change is updated from the UI, controlled by the index.indexChangesAsync
.
The new option yields a much more responsive user-experience by releasing UI elements without waiting for the backend reindex execution to complete.
Users can now delete their own account, making it possible to be forgotten by the Gerrit Code Review platform. Please note that existing commits in the projects will stay and the account's e-mail stored in Git commits will be preserved beyond account deletion.
User suggest Edits
was introduced in 3.7.2
as an experimental feature, disabled by default. With Gerrit 3.9
, this feature is no longer experimental and User Suggest Edits
is enabled by default.
Plugins may store additional string key/value pairs to change notes in NoteDb.
Change 372694 Added APIs to set/get custom keyed-value change metadata
Plugins can communicate and declare dependencies to other plugins thanks to the introduction of Gerrit-ApiModule
Guice modules in plugin manifest (Issue 292114807).
This release doesn't contain schema changes.
The changes
index version has been increased to version 85. The projects
index version has been increased to version 8.
By default, if you're upgrading from 3.8, the index is automatically rebuilt upon Gerrit startup after the upgrade.
If you're upgrading from 3.7 or an earlier version, you must use the Offline upgrade steps below.
java -jar gerrit.war init -d site_path --batch
If you are upgrading from a 3.8 version you don't need to run reindex (see Online index schema upgrade from 3.8
above). If you still want to you will only need to run reindex of changes
:
java -jar gerrit.war reindex --index changes -d site_path java -jar gerrit.war reindex --index projects -d site_path
If you are upgrading from a 3.7 version, or an earlier version, you must run a reindex of all indexes:
java -jar gerrit.war reindex -d site_path
See the reindex program for other options.
Gerrit v3.9.x supports zero-downtime upgrade from Gerrit v3.8.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 any API.
The zero-downtime upgrade consists of the following steps:
gerrit.experimentalRollingUpgrade
to true
in gerrit.config
on both Gerrit primaries.gerrit.experimentalRollingUpgrade
from gerrit.config
on both Gerrit primaries.Downgrade to any Gerrit v3.8.x release is possible, but requires the following manual steps:
java -jar gerrit.war init -d site_path --batch java -jar gerrit.war reindex --index changes -d site_path
Change 369234 Return 400 BAD_REQUEST when a reviewer cannot be added by email
When trying to add a user that cannot be added as a reviewer on a change, the API was returning a 200 Status Code with an error message.
Change 379475 Don't call Java gc explicitly, remove --gc option from show-caches ssh command and REST API /config/server/summary
Change 378638 Remove change.stars
field from ChangeInfo
Remove the stars
field from the ChangeInfo
response. You should check whether you were relying on this field when using any REST endpoint returning ChangeInfo
.
Change 373780 removed all performance/operations/*
metrics because of the performance issues introduced (details)
Change 371198 Add option to populate ‘starred’ field for change queries
star
option can must now be provided to include the starred
field in ChangeInfo
, which indicates if the change is starred by the current user or not.
Change 387435 refreshAfterWrite
and maxAge
settings in gerrit config are now honored for both persistent and in-memory caches.
Previously these settings were erroneously ignored for persistent caches. If you rely on them for persistent caches you should be aware they will be honoured now.
Change 379154 New patch sets will prefer the previous patch set's committer email
If one of the user's secondary emails was used as the committer email in previous patchset, continue using it instead of preferred email.
Change 392517: Added ‘m’ alias for the ‘message’ operator
Change 392515 Groups Audit Log API - Gerrit now parses all commits in refs/groups/... branch
Change 392514 Support tracing requests that match a header
Gerrit supports tracing requests that match a configured trace configuration. With this change we add a new parameter to the tracing configuration that allows matching requests by a header. E.g. this allows matching requests that are sent with a certain user agent (e.g. headerPattern = User-Agent=foo-.*).
Change 392518 Change .scl
files to be highlighted as python
Change 392175 Reviewer's votes are not restored back after the reviewer is deleted and added back
When a reviewer votes for the patchset and then the reviewer is removed, Gerrit removes votes from this reviewer too. However if the reviewer is added back (to the same patchset) previous votes are restored back.
This change ensures that after a reviewer is deleted, all votes from this reviewer are permanently removed.
Change 390897 Option to skip projects during change reindexing
Introduce index.excludeProjectFromChangeReindex
: A list of projects that will be excluded from reindexing. This can be used to exclude projects which are expensive to reindex to prioritize the other projects.
Change 390895 The revert UI now defaults to Revert^2 instead of "Revert "Revert “...”
Change 390614 Users can now upload changes to group refs except changes to group files
Change 389115 Improved error message when change cannot be submitted due to a missing dependency
Change 388914 Changing preferred email does not result in duplicate email
Change 368335 Rebase can be performed with a secondary email using REST API
Change 388336 Added ‘description’, ‘d’ aliases for the ‘message’ operator
Change 388554 committer_email
field is removed from topic cherry-pick payload
Change 392534 Return approver/rejector for a label if DETAILED_LABELS is passed
Change 388054 Eliminated startup warning for plugins whose SshModule only provides Ssh* CommandInterceptors
Change 387217 Fixed case where an exception in change visibility checking could break visibility of all refs in that repo
Change 377154 REST API supports cherry-pick using a registered secondary email
Change 387055 SSH set-topic cmd is fixed to consider edit topic permission
Change 387103 Avoid NullPointerException when deleting a single ref
Change 387216 Fixed potential OOM due to SubmitRuleEvaluator creating new metrics whenever an instance was created
Change 387017 Fix NPE when auth.httpDisplaynameHeader
is configured but header is unset
Change 387054 force topic edit
'` permission is fixed to work with change owner rule
Change 386976 Fixed potential OOM due to *QueryProcessor classes creating new metrics whenever an instance was provided
Change 386974 SSH command set-reviewers
now handles lock failures with retries
Change 386994 Fixed InactiveAccountDisconnector NPE due to race condition
Change 386777 Allow modules to provide different logic for the HTTP canonicalWebUrl
This is useful to allow adding some logic to the way the canonical Web URL is computed. A use-case for this need is the virtualhost
module, where the canonical Web URL is replaced by a virtual host name instead Change 386616
Change 383334 Allow to set instance ID from java system property
Change 385556 Allow pagination using continuation token for ‘list branches’
Issue 295457464 SSH queries now show copied approvals on respective patch-sets
Change 383955 Allow SubmitRequirement errors to be HTTP 500 errors
Change 384096 Exposed default branch in GerritInfo
Issue 296889346 Added placeholder text for “Default Branch” field in the create repo wizard
Change 383034 List/Query projects: Set flag in last returned project when result is limited
If the number of projects matching a query exceeds either the internal limit or a supplied limit
query parameter, the last project object has a _more_projects: true
JSON field set now.
Change 382557 Added support for searching projects by substring
The new substring:SUBSTRING
predicate matches projects that have a name that contains SUBSTRING
(case-insensitive).
Change 382295 Added support for querying projects by prefix.
the new prefix:PREFIX
predicate matches projects that have a name that starts with PREFIX
.
Change 381915 Added support for matching all project by an empty project query
Change 382258 Fixed setting parent field in project index for direct children of All-Projects
Change 381594 Added response_format_options
param to /review
API
Allow specifying a list of formatting options to the the /changes/{change-id}/revisions/{revision-id}/review
endpoint.
If response_format_options
was provided, the response payload will contain a new change_info
field showing post-update change information formatted by response_format_options
.
Change 380914 Fixed NPE when submitting changes
Change 380916 Fixed ThreadMXBeanSun to only report allocated bytes when supported by the JVM
Change 379054 Fixed create merge patch-set API to use identity of caller as committer
Change 380314 Named queries are now supported on group refs
You can now use group
with the query
predicate: query:group="GROUP"
Change 379714 Named destinations are now supported on group refs
You can now use group
with the destination
predicate: destination:group="GROUP"
Change 379513 Add CustomKeyedValues
field to change index, requires schema upgrade
Change 378999 Fail ‘Get Diff’ requests for file sizes that exceed 50Mb
Change 378899 ApplyPatch: Do not fail with 500 ISE if no patch is provided
Change 378535 Added config option that allows to disable change ID link footers
Introduce the receive.enableChangeIdLinkFooters
configuration to enables a Link
footer to be used as an alternative Change-Id
footer.
Change 376877 Add a new parents_data
field in RevisionInfo
The new field is a list of ParentInfo entities and provides more information about the parent commit of the patch-set.
Change 377174 Add branch
as a new field in RevisionInfo
The name of the target branch that this revision is set to be merged into.
Change 375155 Fix GetRelated if multiple changes for the same commit exist
Change 356465 Add API method for deleting self account
Change 374995 Adding GET and POST requests for custom_keyed_values
Change 374695 Add verbose version output
provide noteDb and index versions, in addition to the Gerrit version
Change 373997 Return 500 when a request is canceled due to an exceeded server deadline
Change 373854 The commit-msg hook now detects existing Link
trailers.
An additional $
was making detection of Link trailers to fail, causing Link trailers to repeatedly be added when amending a commit.
Change 370194 Add merge strategy to rebase REST API
The strategy of the merge, can be recursive
, resolve
, simple-two-way-in-core
, ours
or theirs
, default will use project settings.
Change 362774 Adds a new footer for changes for key-value storage.
These can be used to store metadata on a change. The format on the change-message is for a given <key>
<value>
is: Custom-Values: <key>=<value>
Change 366776 Provide change number to patch set link plugins
Change 392474 Add session support in FakeHttpServletRequest for tests
Change 392454 Include HTTP testutil package in the Gerrit acceptance framework
Change 392455 Fix FakeHttpServletRequest getRequestURI() returning query string
Change 385115 Fixed updating and publishing draft comment on old patch set
Issue 309849905: Account external IDs are updated in a single commit
Change 390919 Skip already reindexed changes during reindexing
During online reindexing after an upgrade, all changes were reindexed, even if they were already present in the new index. If the Gerrit instance was restarted before the index was ready, this caused a lot of repeated indexing.
Now, changes that are already present in the newest index version won't be reindexed anymore. However, they will still be checked for staleness and reindexed if necessary.
Change 376094 Add cache to speedup ref advertisements (particularly on replicas) and receive-pack
Change 224772 Reduced memory and storage needs for TagSet
Change 377814 Bloom filters are no longer built during offline reindex
Change 380594 Reduced memory and storage needs for TagSet by using RoaringBitmaps
Change 389894 Track diff page sidebar state as a user preference
Change 389700 Add a user preference for sidebar on the diff page
Change 376934 Rebase can be performed using a secondary email via UI
updates the UI to show a list of relevant emails to choose from when rebasing a change.
Issue 303075739 New frontend extension point: auth-link
Change 387695 Show diff as User Suggested Edit Preview instead of code block
Issue 301481564 Fix the repository configuration loading and rendering when switching tabs
Change 382555 Introduce “showdiff” plugin event
Any listeners are notified any time a diff is shown on the screen.
Change 379095 Add diff page sidebar for plugins
Change 378634 Experimental plugin endpoint for diff hover events
Change 378436 Fix copying Change-Id in dropdown
Change 373477 Fire SHOW_CHANGE
event to plugins from diff page
Change 390454 Document gerrit set-head
SSH command and fix old UI references
Change 388936 Explain in ls-projects
SSH API when the “parent” field is “?-N”
Change 388936 Explain in /projects/
REST API when the “parent” field is “?-N”
Change 387736 Be more explicit about using Bazelisk in dev docs
Change 382794 Update blurb for ldap.accountFullName
Change 378094 Add example for GerritSiteHeader.html
Change 372854 Add example to blurb for ldap.mandatoryGroup
Change 387495 Bump JGit version to b6b1e0a0a. You can retrieve the full list of changes with:
git log --no-merges --format=oneline 74fa245b3c3ccf13afcbec7911c7c8459e48527d..b6b1e0a0adda605f7a62c915d1aef606b961e36f
notable changes are:
Change 388177 Update error_prone_annotations to 2.22.0
Change 372276 Update guice version to 6.0.0
Change 388038 Add java-prettify as git submodule
Change 387998 Update gitiles version to 1.3.0
Change 387999 Update SSHD version to 2.10.0
Issue 302090044: Update plugins/download-commands
--recurse-submodules
flag to supporting commandsChange 336947 Upgrade guava to 32.1-jre
Change 384754 Update plugins/replication
Change 378434 Update Resemble to 5.0
Change 219455 Update Lucene version to 8.11.2