]> source.dussan.org Git - jgit.git/log
jgit.git
3 years agoMerge branch 'master' into next 91/182491/2
Matthias Sohn [Sat, 26 Jun 2021 14:39:44 +0000 (16:39 +0200)]
Merge branch 'master' into next

* master:
  searchForReuse might impact performance in large repositories
  Retry loose object read upon "Stale file handle" exception
  Ignore missing javadoc in test bundles
  Upgrade maven-dependency-plugin to 3.2.0
  Upgrade jacoco-maven-plugin to 0.8.7
  Upgrade maven-jxr-plugin to 3.1.1
  Fix garbage collection failing to delete pack file
  Fix PathSuffixFilter: can decide only on full paths
  Update jetty to 9.4.42.v20210604
  [sshd] Log the full KEX negotiation result
  [releng] japicmp: update last release version
  CONTRIBUTING: add explicit link to ECA
  CONTRIBUTING: Use standard markdown format
  Add Eclipse code of conduct and security policy

Change-Id: I9e31cb6e22f5398db6e220f71693e87475c598bd

3 years agoMerge branch 'stable-5.12' 90/182490/1
Matthias Sohn [Sat, 26 Jun 2021 14:37:59 +0000 (16:37 +0200)]
Merge branch 'stable-5.12'

* stable-5.12:
  Retry loose object read upon "Stale file handle" exception
  Ignore missing javadoc in test bundles

Change-Id: I67c613c066a3252f9b0d0a3dcc026b57e10bfe1d

3 years agoMerge branch 'stable-5.11' into stable-5.12 89/182489/1
Matthias Sohn [Sat, 26 Jun 2021 14:36:55 +0000 (16:36 +0200)]
Merge branch 'stable-5.11' into stable-5.12

* stable-5.11:
  Retry loose object read upon "Stale file handle" exception
  Ignore missing javadoc in test bundles

Change-Id: Ia4dc886c920cec3c9da86e1a90a0af68bd016b4f

3 years agoMerge branch 'stable-5.10' into stable-5.11 88/182488/2
Matthias Sohn [Sat, 26 Jun 2021 13:41:19 +0000 (15:41 +0200)]
Merge branch 'stable-5.10' into stable-5.11

* stable-5.10:
  Retry loose object read upon "Stale file handle" exception
  Ignore missing javadoc in test bundles

Change-Id: Ia385fa6b5d2fee64476793e06860a279bf2f6e36

3 years agoMerge branch 'stable-5.9' into stable-5.10 80/182480/1
Matthias Sohn [Fri, 25 Jun 2021 20:23:47 +0000 (22:23 +0200)]
Merge branch 'stable-5.9' into stable-5.10

* stable-5.9:
  Retry loose object read upon "Stale file handle" exception
  Ignore missing javadoc in test bundles

Change-Id: I56fc2c47193a891285a705d44b3507f23982dc8a

3 years agosearchForReuse might impact performance in large repositories 55/181355/20
Fabio Ponciroli [Thu, 3 Jun 2021 14:15:17 +0000 (16:15 +0200)]
searchForReuse might impact performance in large repositories

The search for reuse phase for *all* the objects scans *all*
the packfiles, looking for the best candidate to serve back to the
client.

This can lead to an expensive operation when the number of
packfiles and objects is high.

Add parameter "pack.searchForReuseTimeout" to limit the time spent
on this search.

Change-Id: I54f5cddb6796fdc93ad9585c2ab4b44854fa6c48

3 years agoRetry loose object read upon "Stale file handle" exception 95/181295/12
Antonio Barone [Wed, 2 Jun 2021 15:13:17 +0000 (18:13 +0300)]
Retry loose object read upon "Stale file handle" exception

When reading loose objects over NFS it is possible that the OS syscall
would fail with ESTALE errors: This happens when the open file
descriptor no longer refers to a valid file.

Notoriously it is possible to hit this scenario when git data is shared
among multiple clients, for example by multiple gerrit instances in HA.

If one of the two clients performs a GC operation that would cause the
packing and then the pruning of loose objects, the other client might
still hold a reference to those objects, which would cause an exception
to bubble up the stack.

The Linux NFS FAQ[1] (at point A.10), suggests that the proper way to
handle such ESTALE scenarios is to:

"[...] close the file or directory where the error occurred, and reopen
it so the NFS client can resolve the pathname again and retrieve the new
file handle."

In case of a stale file handle exception, we now attempt to read the
loose object again (up to 5 times), until we either succeed or encounter
a FileNotFoundException, in which case the search can continue to
Packfiles and alternates.

The limit of 5 provides an arbitrary upper bounds that is consistent to
the one chosen when handling stale file handles for packed-refs
files (see [2] for context).

[1] http://nfs.sourceforge.net/
[2] https://git.eclipse.org/r/c/jgit/jgit/+/54350

Bug: 573791
Change-Id: I9950002f772bbd8afeb9c6108391923be9d0ef51

3 years agoIgnore missing javadoc in test bundles 25/182425/1
Matthias Sohn [Thu, 24 Jun 2021 21:13:51 +0000 (23:13 +0200)]
Ignore missing javadoc in test bundles

Change-Id: I83ed20823dc6b22ff48c2a554acb2f7d3b6067b7

3 years agoUpgrade maven-dependency-plugin to 3.2.0 10/182110/3
Marco Miller [Thu, 17 Jun 2021 11:34:24 +0000 (07:34 -0400)]
Upgrade maven-dependency-plugin to 3.2.0

Change-Id: I9dea176e8b30658bcb6a9dee8c54184c0fa86de8
Signed-off-by: Marco Miller <marco.miller@ericsson.com>
3 years agoUpgrade jacoco-maven-plugin to 0.8.7 23/180523/3
Marco Miller [Wed, 12 May 2021 12:50:29 +0000 (08:50 -0400)]
Upgrade jacoco-maven-plugin to 0.8.7

Change-Id: I6742b2d8ec75422542a55a9840bfe43e8cf17400
Signed-off-by: Marco Miller <marco.miller@ericsson.com>
3 years agoUpgrade maven-jxr-plugin to 3.1.1 08/180008/3
Marco Miller [Thu, 29 Apr 2021 18:44:48 +0000 (14:44 -0400)]
Upgrade maven-jxr-plugin to 3.1.1

Change-Id: I66d7589ea1b823305d908acb13367ef78ef55f7a
Signed-off-by: Marco Miller <marco.miller@ericsson.com>
3 years agoFix garbage collection failing to delete pack file 18/182018/7
andrewxian2000 [Mon, 14 Jun 2021 21:58:52 +0000 (09:58 +1200)]
Fix garbage collection failing to delete pack file

The loosen() method has opened pack file and the open pack file handle
may prevent it from being deleted e.g. on Windows. Fix this by closing
the pack file only after loosen() finished.

Bug: 574178
Change-Id: Icd59931a218d84c9c97b450eea87b21ed01248ff
Signed-off-by: andrew.xian2000@gmail.com
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoFix PathSuffixFilter: can decide only on full paths 26/182126/2
Thomas Wolf [Thu, 17 Jun 2021 15:50:31 +0000 (17:50 +0200)]
Fix PathSuffixFilter: can decide only on full paths

On a subtree, a PathSuffixFilter must return -1 ("indeterminate"),
not 0 ("include"), otherwise negation goes wrong: an indeterminate
result (-1) is passed on, but a decision (0/1) is inverted.

As a result a negated PathSuffixFilter would skip all folders.

Bug: 574253
Change-Id: I27fe785c0d772392a5b5efe0a7b1c9cafcb6e566
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
3 years agoUpdate jetty to 9.4.42.v20210604 54/182054/2
Matthias Sohn [Wed, 16 Jun 2021 15:43:25 +0000 (17:43 +0200)]
Update jetty to 9.4.42.v20210604

Change-Id: Ie0abae5686064ccfeb34e8af0d98471162036b00

3 years ago[sshd] Log the full KEX negotiation result 23/182223/1
Thomas Wolf [Sat, 19 Jun 2021 13:41:37 +0000 (15:41 +0200)]
[sshd] Log the full KEX negotiation result

Apache MINA sshd doesn't log all values, but it'd be very helpful to
debug KEX problems.

Change-Id: I5a19023c929f39caccde489d51a6fdca711fe5ff
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
3 years ago[releng] japicmp: update last release version 58/182058/1
Thomas Wolf [Wed, 16 Jun 2021 16:14:17 +0000 (18:14 +0200)]
[releng] japicmp: update last release version

The baseline for the 5.13 release is 5.12.0.202106070339-r.

Change-Id: Ic4730ca296117d7a7f6e86228ce2393a748c3c06
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
3 years agoCONTRIBUTING: add explicit link to ECA 91/181991/1
Matthias Sohn [Tue, 15 Jun 2021 12:01:00 +0000 (14:01 +0200)]
CONTRIBUTING: add explicit link to ECA

This was requested in the 5.12 release review.

Bug: https://gitlab.eclipse.org/eclipsefdn/emo-team/emo/-/issues/58
Change-Id: I21abe960412a7bc7a0d2f3bdfc4a1d031a700c3b

3 years agoCONTRIBUTING: Use standard markdown format 90/181990/1
Matthias Sohn [Tue, 15 Jun 2021 11:59:23 +0000 (13:59 +0200)]
CONTRIBUTING: Use standard markdown format

Change-Id: Ic64a62ca29950fb6a4c3c8a31bee8173c005ea4e

3 years agoAdd Eclipse code of conduct and security policy 86/181986/1
Matthias Sohn [Tue, 15 Jun 2021 11:44:58 +0000 (13:44 +0200)]
Add Eclipse code of conduct and security policy

This was requested in the 5.12 release review.

Bug: https://gitlab.eclipse.org/eclipsefdn/emo-team/emo/-/issues/58
Change-Id: Ifbfa4c239e8ce0da6d5571362a12c20c399b64e4

3 years agoMerge branch 'master' into next 50/181950/1
Matthias Sohn [Mon, 14 Jun 2021 22:05:14 +0000 (00:05 +0200)]
Merge branch 'master' into next

* master: (47 commits)
  Fix @since from commit 64d0aaa2
  Prepare 5.13.0-SNAPSHOT builds
  Prepare 5.12.1-SNAPSHOT builds
  Teach independent negotiation (no pack file) using an option "wait-for-done"
  JGit v5.12.0.202106070339-r
  [license-check] Update list of project dependencies
  [errorprone] Fix warning InputStreamSlowMultibyteRead
  [errorprone] Make operator precedence explicit in OpenSshConfigFile
  Update jetty to 9.4.41.v20210516
  Prepare 5.1.17-SNAPSHOT builds
  JGit v5.1.16.202106041830-r
  Update Orbit to R20210602031627
  Prepare 5.12.0-SNAPSHOT builds
  Fixing visibility for HostEntry constructors.
  JGit v5.12.0.202106021050-rc1
  Prepare 5.12.0-SNAPSHOT builds
  JGit v5.12.0.202106011439-rc1
  Clarify operator precedence to fix errorprone error
  Prepare 5.12.0-SNAPSHOT builds
  Update Orbit to S20210518003616 and ant to 1.10.10.v20210426-1926
  ...

Change-Id: I76a1f155201648a62df11a41a9e02d97f522d00f

3 years agoFix @since from commit 64d0aaa2 38/181938/1
Thomas Wolf [Mon, 14 Jun 2021 19:22:13 +0000 (21:22 +0200)]
Fix @since from commit 64d0aaa2

That commit was submitted on master between the 5.12.0 release and
the 5.13.0 version bump.

Change-Id: I679e818bfc5a4695b66548add9a83a22c89a4ffc
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
3 years agoPrepare 5.13.0-SNAPSHOT builds 92/181892/1
Matthias Sohn [Sun, 13 Jun 2021 23:49:05 +0000 (01:49 +0200)]
Prepare 5.13.0-SNAPSHOT builds

Change-Id: Ie9cfc1eeb0eda7b2bbe744a22a7e4cfe6d59bc37

3 years agoMerge branch 'stable-5.12' 91/181891/1
Matthias Sohn [Sun, 13 Jun 2021 23:32:21 +0000 (01:32 +0200)]
Merge branch 'stable-5.12'

* stable-5.12:
  Prepare 5.12.1-SNAPSHOT builds
  JGit v5.12.0.202106070339-r
  [license-check] Update list of project dependencies
  [errorprone] Fix warning InputStreamSlowMultibyteRead
  [errorprone] Make operator precedence explicit in OpenSshConfigFile
  Update jetty to 9.4.41.v20210516
  Prepare 5.1.17-SNAPSHOT builds
  JGit v5.1.16.202106041830-r
  BatchRefUpdate: Skip saving conflicting ref names and prefixes in memory
  BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired
  Optimize RefDirectory.isNameConflicting()
  Update bazlets and bazel version

Change-Id: I9bd4dfc3796a5034be7b3e86b35ef591bb516a2c

3 years agoMerge branch 'stable-5.11' into stable-5.12 90/181890/1
Matthias Sohn [Sun, 13 Jun 2021 23:31:16 +0000 (01:31 +0200)]
Merge branch 'stable-5.11' into stable-5.12

* stable-5.11:

Change-Id: Ifdbddcde74dda9895bcdd90f1be201c3ceca2b29

3 years agoMerge branch 'stable-5.10' into stable-5.11 89/181889/1
Matthias Sohn [Sun, 13 Jun 2021 23:13:18 +0000 (01:13 +0200)]
Merge branch 'stable-5.10' into stable-5.11

* stable-5.10:
  Prepare 5.1.17-SNAPSHOT builds
  JGit v5.1.16.202106041830-r
  BatchRefUpdate: Skip saving conflicting ref names and prefixes in memory
  BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired
  Optimize RefDirectory.isNameConflicting()
  Update bazlets and bazel version

Change-Id: I265425194c24fd82cbeff869ce41cbc9b73571a2

3 years agoMerge "Prepare 5.12.1-SNAPSHOT builds" into stable-5.12
Matthias Sohn [Sun, 13 Jun 2021 22:52:44 +0000 (18:52 -0400)]
Merge "Prepare 5.12.1-SNAPSHOT builds" into stable-5.12

3 years agoMerge "Merge branch 'stable-5.10' into stable-5.11" into stable-5.12
Matthias Sohn [Sun, 13 Jun 2021 22:48:42 +0000 (18:48 -0400)]
Merge "Merge branch 'stable-5.10' into stable-5.11" into stable-5.12

3 years agoPrepare 5.12.1-SNAPSHOT builds 84/181884/1
Matthias Sohn [Sun, 13 Jun 2021 21:58:34 +0000 (23:58 +0200)]
Prepare 5.12.1-SNAPSHOT builds

Change-Id: Idf266c34aa9a04cf9c5e0e09bcb415c13d773d4c

3 years agoMerge branch 'stable-5.10' into stable-5.11 83/181883/1
Matthias Sohn [Sun, 13 Jun 2021 21:57:08 +0000 (23:57 +0200)]
Merge branch 'stable-5.10' into stable-5.11

* stable-5.10:
  Prepare 5.1.17-SNAPSHOT builds
  JGit v5.1.16.202106041830-r
  BatchRefUpdate: Skip saving conflicting ref names and prefixes in memory
  BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired
  Optimize RefDirectory.isNameConflicting()
  Update bazlets and bazel version

Change-Id: I50dcc037a96f3a4237c09516c82e1c18acbd2e0b

3 years agoMerge branch 'stable-5.9' into stable-5.10 82/181882/1
Matthias Sohn [Sun, 13 Jun 2021 21:55:46 +0000 (23:55 +0200)]
Merge branch 'stable-5.9' into stable-5.10

* stable-5.9:
  Prepare 5.1.17-SNAPSHOT builds
  JGit v5.1.16.202106041830-r
  BatchRefUpdate: Skip saving conflicting ref names and prefixes in memory
  BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired
  Optimize RefDirectory.isNameConflicting()
  Update bazlets and bazel version

Change-Id: Ib1299564a4cfb9c01f422d7ada05fcfac29700f8

3 years agoMerge branch 'stable-5.8' into stable-5.9 81/181881/1
Matthias Sohn [Sun, 13 Jun 2021 21:55:03 +0000 (23:55 +0200)]
Merge branch 'stable-5.8' into stable-5.9

* stable-5.8:
  Prepare 5.1.17-SNAPSHOT builds
  JGit v5.1.16.202106041830-r
  BatchRefUpdate: Skip saving conflicting ref names and prefixes in memory
  BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired
  Optimize RefDirectory.isNameConflicting()
  Update bazlets and bazel version

Change-Id: I9abf7dd8b8e5eb3199fd6b43a4653c4e4cf4bf1b

3 years agoMerge branch 'stable-5.7' into stable-5.8 80/181880/1
Matthias Sohn [Sun, 13 Jun 2021 21:54:06 +0000 (23:54 +0200)]
Merge branch 'stable-5.7' into stable-5.8

* stable-5.7:
  Prepare 5.1.17-SNAPSHOT builds
  JGit v5.1.16.202106041830-r
  BatchRefUpdate: Skip saving conflicting ref names and prefixes in memory
  BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired
  Optimize RefDirectory.isNameConflicting()
  Update bazlets and bazel version

Change-Id: I1ee0d01c14fb7dca151b4e7ae1b989da5a3a01e3

3 years agoMerge branch 'stable-5.6' into stable-5.7 79/181879/1
Matthias Sohn [Sun, 13 Jun 2021 21:52:46 +0000 (23:52 +0200)]
Merge branch 'stable-5.6' into stable-5.7

* stable-5.6:
  Prepare 5.1.17-SNAPSHOT builds
  JGit v5.1.16.202106041830-r
  BatchRefUpdate: Skip saving conflicting ref names and prefixes in memory
  BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired
  Optimize RefDirectory.isNameConflicting()
  Update bazlets and bazel version

Change-Id: I4570cce185877cb4c50eee519a1cf9467a766dea

3 years agoMerge branch 'stable-5.5' into stable-5.6 79/181479/5
Matthias Sohn [Sun, 6 Jun 2021 08:45:57 +0000 (10:45 +0200)]
Merge branch 'stable-5.5' into stable-5.6

* stable-5.5:
  Prepare 5.1.17-SNAPSHOT builds
  JGit v5.1.16.202106041830-r
  BatchRefUpdate: Skip saving conflicting ref names and prefixes in
    memory
  BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired
  Optimize RefDirectory.isNameConflicting()
  Update bazlets and bazel version

Change-Id: I504483a4dc979c5e7af18bad45dc18675e32afd2

3 years agoTeach independent negotiation (no pack file) using an option "wait-for-done" 24/181324/16
Ronald Bhuleskar [Wed, 9 Jun 2021 22:41:09 +0000 (15:41 -0700)]
Teach independent negotiation (no pack file) using an option "wait-for-done"

From Git commit 9c1e657a8f:
  Currently, the packfile negotiation step within a Git fetch cannot be
  done independent of sending the packfile, even though there is at
  least one application wherein this is useful - push negotiation.
  Therefore, make it possible for this negotiation step to be done
  independently.

  This feature is for protocol v2 only.

  In the protocol, the main hindrance towards independent negotiation is
  that the server can unilaterally decide to send the packfile. This is
  solved by a "wait-for-done" argument: the server will then wait for
  the client to say "done". In practice, the client will never say it;
  instead it will cease requests once it is satisfied.

Advertising the server capability option "wait-for-done" is behind the
transport config: uploadpack.advertisewaitfordone, which by default is
false.

Change-Id: I5ebd3e99ad76b8943597216e23ced2ed38eb5224

3 years agoJGit v5.12.0.202106070339-r 00/181500/1 v5.12.0.202106070339-r
Matthias Sohn [Mon, 7 Jun 2021 07:38:29 +0000 (09:38 +0200)]
JGit v5.12.0.202106070339-r

Change-Id: I0fbfea2c83f1ce83f75130cc97591547032f1104
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years ago[license-check] Update list of project dependencies 90/181490/1
Matthias Sohn [Sun, 6 Jun 2021 23:20:01 +0000 (01:20 +0200)]
[license-check] Update list of project dependencies

Change-Id: I94530902bdcc93e160416750742cc2bf63d7c411

3 years ago[errorprone] Fix warning InputStreamSlowMultibyteRead 87/181487/1
Matthias Sohn [Sun, 6 Jun 2021 22:28:48 +0000 (00:28 +0200)]
[errorprone] Fix warning InputStreamSlowMultibyteRead

Change-Id: I50dace6e310016c04f524eb0cfcce0da05fadd47

3 years ago[errorprone] Make operator precedence explicit in OpenSshConfigFile 86/181486/1
Matthias Sohn [Sun, 6 Jun 2021 22:25:32 +0000 (00:25 +0200)]
[errorprone] Make operator precedence explicit in OpenSshConfigFile

This fixes the errorprone warning OperatorPrecedence.

Change-Id: I4c7dafa5ac8e1d58fa15cf91fe1b3cf3f182d536

3 years agoUpdate jetty to 9.4.41.v20210516 85/181485/1
Matthias Sohn [Sun, 6 Jun 2021 22:23:30 +0000 (00:23 +0200)]
Update jetty to 9.4.41.v20210516

Change-Id: I98d569ce9a69c48c3c99b9b5f500d6419c943094

3 years agoMerge branch 'stable-5.4' into stable-5.5 78/181478/1
Matthias Sohn [Sat, 5 Jun 2021 20:49:56 +0000 (22:49 +0200)]
Merge branch 'stable-5.4' into stable-5.5

* stable-5.4:
  Prepare 5.1.17-SNAPSHOT builds
  JGit v5.1.16.202106041830-r
  BatchRefUpdate: Skip saving conflicting ref names and prefixes in memory
  BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired
  Optimize RefDirectory.isNameConflicting()
  Update bazlets and bazel version

Change-Id: If5232b68d3e25df7b71e417cbcbb39476e925f22

3 years agoMerge branch 'stable-5.3' into stable-5.4 77/181477/1
Matthias Sohn [Sat, 5 Jun 2021 20:49:07 +0000 (22:49 +0200)]
Merge branch 'stable-5.3' into stable-5.4

* stable-5.3:
  Prepare 5.1.17-SNAPSHOT builds
  JGit v5.1.16.202106041830-r
  BatchRefUpdate: Skip saving conflicting ref names and prefixes in memory
  BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired
  Optimize RefDirectory.isNameConflicting()
  Update bazlets and bazel version

Change-Id: I1338fc79a7be6b77fb28df511dd7504fb19b6d1a

3 years agoMerge branch 'stable-5.2' into stable-5.3 76/181476/1
Matthias Sohn [Sat, 5 Jun 2021 20:48:01 +0000 (22:48 +0200)]
Merge branch 'stable-5.2' into stable-5.3

* stable-5.2:
  Prepare 5.1.17-SNAPSHOT builds
  JGit v5.1.16.202106041830-r
  BatchRefUpdate: Skip saving conflicting ref names and prefixes in memory
  BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired
  Optimize RefDirectory.isNameConflicting()
  Update bazlets and bazel version

Change-Id: I7838f7d237a3598bf55995426d7ba1de146cb6ad

3 years agoMerge branch 'stable-5.1' into stable-5.2 75/181475/1
Matthias Sohn [Sat, 5 Jun 2021 20:19:47 +0000 (22:19 +0200)]
Merge branch 'stable-5.1' into stable-5.2

* stable-5.1:
  Prepare 5.1.17-SNAPSHOT builds
  JGit v5.1.16.202106041830-r
  BatchRefUpdate: Skip saving conflicting ref names and prefixes in memory
  BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired
  Optimize RefDirectory.isNameConflicting()
  Update bazlets and bazel version

Change-Id: If1b5a2b380cf155e66bf5d5c6d216f86c919bb37

3 years agoPrepare 5.1.17-SNAPSHOT builds 72/181472/1
Matthias Sohn [Fri, 4 Jun 2021 22:45:08 +0000 (00:45 +0200)]
Prepare 5.1.17-SNAPSHOT builds

Change-Id: I20c69728465f956a5744a75eb548ef18962286dd
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoJGit v5.1.16.202106041830-r 71/181471/1 v5.1.16.202106041830-r
Matthias Sohn [Fri, 4 Jun 2021 22:31:03 +0000 (00:31 +0200)]
JGit v5.1.16.202106041830-r

Change-Id: I526ed2a08553bc0b2678aaefaff9e0c6529baefc
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoMerge changes I853ac6c7,I01878116,Ie994fc18 into stable-5.1
Matthias Sohn [Fri, 4 Jun 2021 22:21:31 +0000 (18:21 -0400)]
Merge changes I853ac6c7,I01878116,Ie994fc18 into stable-5.1

* changes:
  BatchRefUpdate: Skip saving conflicting ref names and prefixes in memory
  BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired
  Optimize RefDirectory.isNameConflicting()

3 years agoMerge branch 'stable-5.12' 17/181417/1
Matthias Sohn [Thu, 3 Jun 2021 21:50:51 +0000 (23:50 +0200)]
Merge branch 'stable-5.12'

* stable-5.12:
  Update Orbit to R20210602031627
  Prepare 5.12.0-SNAPSHOT builds
  JGit v5.12.0.202106021050-rc1
  Prepare 5.12.0-SNAPSHOT builds
  JGit v5.12.0.202106011439-rc1
  Prepare 5.12.0-SNAPSHOT builds
  JGit v5.12.0.202105261145-m3

Change-Id: Iaf5d65a6e23c4d262fcb3dd3eda42bd634a38aad

3 years agoUpdate Orbit to R20210602031627 02/181402/1
Matthias Sohn [Thu, 3 Jun 2021 19:35:32 +0000 (21:35 +0200)]
Update Orbit to R20210602031627

Change-Id: I480093d9da393dae0c3b608762d38cba3db2f2b9
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoPrepare 5.12.0-SNAPSHOT builds 97/181397/1
Matthias Sohn [Thu, 3 Jun 2021 18:04:28 +0000 (20:04 +0200)]
Prepare 5.12.0-SNAPSHOT builds

Change-Id: Ifc72d3f3ac84b9c4055b95ec0093d877ffb09ab0
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoFixing visibility for HostEntry constructors. 23/181323/1
Demetr Starshov [Wed, 2 Jun 2021 23:19:39 +0000 (16:19 -0700)]
Fixing visibility for HostEntry constructors.

HostEntry class was public with empty constructor, so adding
constructors with default visibility actually reduced visibility of
constructor.

Change-Id: I4c996c0559102084946ba49a71afe10dda5e0f95

3 years agoJGit v5.12.0.202106021050-rc1 96/181296/1 v5.12.0.202106021050-rc1
Matthias Sohn [Wed, 2 Jun 2021 14:49:17 +0000 (16:49 +0200)]
JGit v5.12.0.202106021050-rc1

Change-Id: I622ee049f14f37504ff4a062f03d6fc25465d0ec
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoPrepare 5.12.0-SNAPSHOT builds 50/181250/1
Matthias Sohn [Wed, 2 Jun 2021 06:47:28 +0000 (08:47 +0200)]
Prepare 5.12.0-SNAPSHOT builds

Change-Id: I25e4efc9b40ae4e7168b37385445c73992c5beb0

3 years agoJGit v5.12.0.202106011439-rc1 34/181234/1 v5.12.0.202106011439-rc1
Matthias Sohn [Tue, 1 Jun 2021 18:38:31 +0000 (20:38 +0200)]
JGit v5.12.0.202106011439-rc1

Change-Id: Ieac1d02879defe0f4791062448d4efc328a2f652
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoClarify operator precedence to fix errorprone error 34/179734/5
Matthias Sohn [Fri, 23 Apr 2021 14:52:54 +0000 (16:52 +0200)]
Clarify operator precedence to fix errorprone error

Errorprone raised error OperatorPrecedence in bazel build.

Change-Id: Ibab601e67d4d5cafe9a7d900c78b0d432181a073
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoMerge branch 'master' into stable-5.12 22/181222/1
Matthias Sohn [Tue, 1 Jun 2021 14:36:43 +0000 (16:36 +0200)]
Merge branch 'master' into stable-5.12

* master:
  Update Orbit to S20210518003616 and ant to 1.10.10.v20210426-1926
  Skip detecting content renames for binary files
  RepoCommand: Retry commit on LockFailure
  Finish upgrading eclipse-jarsigner-plugin to 1.3.1
  Upgrade maven-javadoc-plugin to 3.3.0
  Update maven-project-info-reports-plugin to 3.1.2
  Update spotbugs-maven-plugin to 4.2.3

Change-Id: I3b77b0ef21bdf69a3009fb64af0d23d79b518009

3 years agoPrepare 5.12.0-SNAPSHOT builds 21/181221/1
Matthias Sohn [Tue, 1 Jun 2021 14:13:41 +0000 (16:13 +0200)]
Prepare 5.12.0-SNAPSHOT builds

Change-Id: If563be77aab768ac1f31ae2211fb0892d0205a2a
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoUpdate Orbit to S20210518003616 and ant to 1.10.10.v20210426-1926 03/181203/1
Matthias Sohn [Mon, 31 May 2021 22:18:10 +0000 (00:18 +0200)]
Update Orbit to S20210518003616 and ant to 1.10.10.v20210426-1926

Change-Id: I87df882d4434c4fb107b8bd662ce63749078f1bd
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoMerge "Skip detecting content renames for binary files"
Han-Wen NIenhuys [Mon, 31 May 2021 12:57:13 +0000 (08:57 -0400)]
Merge "Skip detecting content renames for binary files"

3 years agoSkip detecting content renames for binary files 39/178739/5
Youssef Elghareeb [Wed, 12 May 2021 13:35:45 +0000 (15:35 +0200)]
Skip detecting content renames for binary files

This is similar to change Idbc2c29bd that skipped detecting content
renames for large files. With this change, we added a new option in
RenameDetector called "skipContentRenamesForBinaryFiles", that when set,
causes binary files with any slight modification to be identified as
added/deleted. The default for this boolean is false, so preserving
current behaviour.

Change-Id: I4770b1f69c60b1037025ddd0940ba86df6047299

3 years agoMerge changes I34319d70,I43fad374,Ie531a253,Id0dfcfd0
Matthias Sohn [Fri, 28 May 2021 22:33:52 +0000 (18:33 -0400)]
Merge changes I34319d70,I43fad374,Ie531a253,Id0dfcfd0

* changes:
  Finish upgrading eclipse-jarsigner-plugin to 1.3.1
  Upgrade maven-javadoc-plugin to 3.3.0
  Update maven-project-info-reports-plugin to 3.1.2
  Update spotbugs-maven-plugin to 4.2.3

3 years agoRepoCommand: Retry commit on LockFailure 49/180949/8
Ivan Frade [Mon, 24 May 2021 16:53:08 +0000 (09:53 -0700)]
RepoCommand: Retry commit on LockFailure

When the target repository is receiving commits from other sources,
the repo command commit can fail with a LOCK_FAILURE. We could let
callers retry, but then the command needs to redo all the work (opening
all subrepos to recreate the tree).

Retry the commit in LOCK_FAILURE inside the command. The commit
rewrites the whole tree, so it shouldn't have merge errors. Use an
exponential delay with jitter for the retries.

Change-Id: I517b6f2afd16a4b695e6cf471b5d6cf492024ec4
Signed-off-by: Ivan Frade <ifrade@google.com>
3 years agoFinish upgrading eclipse-jarsigner-plugin to 1.3.1 76/181076/1
Marco Miller [Wed, 26 May 2021 19:55:32 +0000 (15:55 -0400)]
Finish upgrading eclipse-jarsigner-plugin to 1.3.1

Commit 46b0f8a04 started that upgrade while missing this additional
change.

Change-Id: I34319d7006be13534497499e97536a8278906b1f
Signed-off-by: Marco Miller <marco.miller@ericsson.com>
3 years agoUpgrade maven-javadoc-plugin to 3.3.0 75/181075/1
Marco Miller [Wed, 26 May 2021 19:47:00 +0000 (15:47 -0400)]
Upgrade maven-javadoc-plugin to 3.3.0

Change-Id: I43fad374b6af1700c078b29f5ff45e2fd0b4cd00
Signed-off-by: Marco Miller <marco.miller@ericsson.com>
3 years agoUpdate maven-project-info-reports-plugin to 3.1.2 73/181073/2
Marco Miller [Wed, 26 May 2021 19:42:03 +0000 (15:42 -0400)]
Update maven-project-info-reports-plugin to 3.1.2

Change-Id: Ie531a253a37459ee55ddb7f5ed7bad414fe6b67e
Signed-off-by: Marco Miller <marco.miller@ericsson.com>
3 years agoUpdate spotbugs-maven-plugin to 4.2.3 71/181071/1
Marco Miller [Wed, 26 May 2021 19:38:33 +0000 (15:38 -0400)]
Update spotbugs-maven-plugin to 4.2.3

Change-Id: Id0dfcfd060e19fb84fd5ec0cb7bafc9d13153660
Signed-off-by: Marco Miller <marco.miller@ericsson.com>
3 years agoJGit v5.12.0.202105261145-m3 62/181062/1 v5.12.0.202105261145-m3
Matthias Sohn [Wed, 26 May 2021 15:43:55 +0000 (17:43 +0200)]
JGit v5.12.0.202105261145-m3

Change-Id: I3b1af2032227900e6e0c6189f47bace1df67f0ab
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoMerge branch 'master' into stable-5.12 58/181058/1
Matthias Sohn [Wed, 26 May 2021 15:21:02 +0000 (17:21 +0200)]
Merge branch 'master' into stable-5.12

* master:
  RepoCommand: Do not set 'branch' if the revision is a tag
  pgm: rewrite parents when --parents flag is passed
  ApplyCommand: fix "no newline at end" detection
  ApplyCommand: handle completely empty context lines in text patches
  ApplyCommand: use byte arrays for text patches, not strings
  ApplyCommand: support binary patches
  ApplyCommand: add a stream to apply a delta patch
  ApplyCommand: add streams to read/write binary patch hunks
  ApplyCommand: add a base-85 codec
  ApplyCommand: convert to git internal format before applying patch
  SSH config: fix whitespace handling
  SSH config: fix negated patterns
  Fix @since tag for introduction of PUBKEY_ACCEPTED_ALGORITHMS
  Prepare 5.11.2-SNAPSHOT builds
  JGit v5.11.1.202105131744-r
  Add a cgit interoperability test for LockFile
  Add TemporaryBuffer.toString(int limit)
  LockFile: create OutputStream only when needed
  Add git config for conflict style merge/diff3

Change-Id: If7751ff99079eaea31ed1fce811d141ecf209727
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoRepoCommand: Do not set 'branch' if the revision is a tag 53/180953/5
Ivan Frade [Tue, 25 May 2021 00:31:25 +0000 (17:31 -0700)]
RepoCommand: Do not set 'branch' if the revision is a tag

The "branch" field in the .gitmodules is the signal for gerrit to keep
the superproject autoupdated. Tags are immutable and there is no need to
track them, plus the cgit client requires the field to be a "remote
branch name" but not a tag.

Do not set the "branch" field if the revision is a tag. Keep those tags
in another field ("ref") as they help other tools to find the commit in
the destination repository.

We can still have false negatives when a refname is not fully qualified,
but this check covers e.g. the most common case in android.

Note that the javadoc of #setRecordRemoteBranch already mentions that
"submodules that request a tag will not have branch name recorded".

Change-Id: Ib1c321a4d3b7f8d51ca2ea204f72dc0cfed50c37
Signed-off-by: Ivan Frade <ifrade@google.com>
3 years agoMerge "Add git config for conflict style merge/diff3"
Matthias Sohn [Wed, 26 May 2021 12:30:41 +0000 (08:30 -0400)]
Merge "Add git config for conflict style merge/diff3"

3 years agoMerge changes from topic "apply"
Matthias Sohn [Wed, 26 May 2021 12:12:17 +0000 (08:12 -0400)]
Merge changes from topic "apply"

* changes:
  ApplyCommand: fix "no newline at end" detection
  ApplyCommand: handle completely empty context lines in text patches
  ApplyCommand: use byte arrays for text patches, not strings
  ApplyCommand: support binary patches
  ApplyCommand: add a stream to apply a delta patch
  ApplyCommand: add streams to read/write binary patch hunks
  ApplyCommand: add a base-85 codec
  ApplyCommand: convert to git internal format before applying patch

3 years agopgm: rewrite parents when --parents flag is passed 57/178557/5
kylezhao [Tue, 30 Mar 2021 03:04:12 +0000 (11:04 +0800)]
pgm: rewrite parents when --parents flag is passed

According to [1], we should rewrite parents in RevWalkTextBuiltin
when variable parents is true.
[1]
https://git-scm.com/docs/git-rev-list#Documentation/git-rev-list.txt---parents

Change-Id: If5dca3b280366969d0488fa895bc37253a797394
Signed-off-by: kylezhao <kylezhao@tencent.com>
3 years agoApplyCommand: fix "no newline at end" detection 98/177598/6
Thomas Wolf [Wed, 10 Mar 2021 18:26:39 +0000 (19:26 +0100)]
ApplyCommand: fix "no newline at end" detection

Check the last line of the last hunk of a file, not the last line of
the whole patch.

Note that C git only checks that this line starts with "\ " and is at
least 12 characters long because of possible different texts when non-
English messages are used.

Change-Id: I0db81699eb3e99ed7b536a3e2b8dc97df1f58a89
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
3 years agoApplyCommand: handle completely empty context lines in text patches 97/177597/6
Thomas Wolf [Wed, 10 Mar 2021 17:04:25 +0000 (18:04 +0100)]
ApplyCommand: handle completely empty context lines in text patches

C git treats completely empty lines as empty context lines (which
traditionally have a single blank). Apparently newer GNU diff may
produce such lines; see [1]. ("Newer" meaning "since 2006"...)

[1] https://github.com/git/git/commit/b507b465f7831

Change-Id: I80c1f030edb17a46289b1dabf11a2648d2660d38
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
3 years agoApplyCommand: use byte arrays for text patches, not strings 96/177596/6
Thomas Wolf [Wed, 10 Mar 2021 13:25:37 +0000 (14:25 +0100)]
ApplyCommand: use byte arrays for text patches, not strings

Instead of converting the patch bytes to strings apply the patch on
byte level, like C git does. Converting the input lines and the hunk
lines from bytes to strings and then applying the patch based on
strings may give surprising results if a patch converts a text file
from one encoding to another. Moreover, in the end we don't know which
encoding to use to write the result.

Previous code just wrote the result as UTF-8, which forcibly changed
the encoding if the original input had some other encoding (even if the
patch had the same non-UTF-8 encoding). It was also wrong if the input
was UTF-8, and the patch should have changed the encoding to something
else.

So use ByteBuffers instead of Strings. This has the additional advantage
that all these ByteBuffers can share the underlying byte arrays of the
input and of the patch, so it also reduces memory consumption.

Change-Id: I450975f2ba0e7d0bec8973e3113cc2e7aea187ee
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
3 years agoApplyCommand: support binary patches 95/177595/5
Thomas Wolf [Sun, 7 Mar 2021 17:50:23 +0000 (18:50 +0100)]
ApplyCommand: support binary patches

Implement applying binary patches. Handles both literal and delta
patches. Note that C git also runs binary files through the clean
and smudge filters. Implement the same safeguards against corrupted
patches as in C git: require the full OIDs to be present in the patch
file, and apply a binary patch only if both pre- and post-image hashes
match.

Add tests for applying literal and delta patches.

Bug: 371725
Change-Id: I71dc214fe4145d7cc8e4769384fb78c7d0d6c220
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
3 years agoApplyCommand: add a stream to apply a delta patch 94/177594/4
Thomas Wolf [Sun, 7 Mar 2021 17:49:01 +0000 (18:49 +0100)]
ApplyCommand: add a stream to apply a delta patch

Add a new BinaryDeltaInputStream that applies a delta provided by
another InputStream to a given base. Because delta application needs
random access to the base, the base itself cannot be yet another
InputStream. But at least this enables streaming of the result.

Add a simple test using delta hunks generated by C git.

Bug: 371725
Change-Id: Ibd26fa2f49860737ad5c5387f7f4870d3e85e628
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoApplyCommand: add streams to read/write binary patch hunks 93/177593/4
Thomas Wolf [Fri, 5 Mar 2021 23:00:15 +0000 (00:00 +0100)]
ApplyCommand: add streams to read/write binary patch hunks

Add streams that can encode or decode git binary patch data on the fly.
Git writes binary patches base-85 encoded, at most 52 un-encoded bytes,
with the unencoded data length prefixed in a one-character encoding, and
suffixed with a newline character.

Add a test for both the new input and the output stream. The test
roundtrips binary data of different lengths in different ways.

Bug: 371725
Change-Id: Ic3faebaa4637520f5448b3d1acd78d5aaab3907a
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
3 years agoApplyCommand: add a base-85 codec 92/177592/4
Thomas Wolf [Fri, 5 Mar 2021 22:55:18 +0000 (23:55 +0100)]
ApplyCommand: add a base-85 codec

Add an implementation for base-85 encoding and decoding [1]. Git binary
patches use this format.

Base-85 encoding assembles bytes as 32-bit MSB values, then converts
these values to base-85 numbers (always 5 bytes) encoded as printable
ASCII characters. Decoding base-85 is the reverse operation. Note
that decoding may overflow on invalid input as 85^5 > 2^32. Encodings
always have a length that is a multiple of 5. If input length is not
divisible by 4, padding bytes are (logically) added, which are ignored
when decoding. The encoding for n bytes has thus always exactly length
(n + 3) / 4 * 5 in integer arithmetic (truncating division).

Includes tests.

[1] https://datatracker.ietf.org/doc/html/rfc1924

Bug: 371725
Change-Id: Ib5b9a503cd62cf70e080a4fb38c8cd1eeeaebcfe
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoBatchRefUpdate: Skip saving conflicting ref names and prefixes in memory 97/180697/4
Kaushik Lingarkar [Wed, 12 May 2021 23:12:27 +0000 (16:12 -0700)]
BatchRefUpdate: Skip saving conflicting ref names and prefixes in memory

Rather than getting all ref names and prefixes and saving them
in memory to perform the check for conflicting names, rely on
RefDirectory.isNameConflicting as it is no longer an expensive
call after it was optimized in Ie994fc.

The old optimization to save ref names and prefixes in memory
was targeted towards making clones faster. With this change,
the clone performance is unaffected when tests were done with
repos containing many(~500k) refs.

Here are few recorded elapsed times for creating 10 branches
using BatchRefUpdate on NFS based repositories with varying
loose refs count. As seen here, this change helps improve the
BatchRefUpdate performance from O(n^2) to O(1).

loose_refs_count  with_change  without_change
50                241 ms        310 ms
300               263 ms        1502 ms
1k                181 ms        4241 ms
2k                204 ms        6440 ms
9k                158 ms        25930 ms
20k               154 ms        60443 ms
50k               171 ms        135199 ms
110k              157 ms        329450 ms
160k              209 ms        396328 ms

This update improves the Gerrit notedb migration performance
as it uses BatchRefUpdate to write change meta refs similar to
the test performed above.

Change-Id: I853ac6c7feb4b39c3156c01876b38cbd182accfe
Signed-off-by: Kaushik Lingarkar <quic_kaushikl@quicinc.com>
3 years agoBatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired 96/180696/7
Kaushik Lingarkar [Fri, 14 May 2021 21:24:41 +0000 (14:24 -0700)]
BatchRefUpdateTest: Accurately assert RefsChangedEvent(s) fired

Update tests to record the number of events fired post-setup and only
assert for events fired during BatchRefUpdate.execute. For tests which
use writeLooseRef to setup refs, create new tests which assert the
number of RefsChangedEvent(s) rather than updating the existing ones
to call RefDirectory.exactRef as it changes the code path.

Change-Id: I0187811628d179d9c7e874c9bb8a7ddb44dd9df4
Signed-off-by: Kaushik Lingarkar <quic_kaushikl@quicinc.com>
3 years agoOptimize RefDirectory.isNameConflicting() 59/180559/4
Kaushik Lingarkar [Wed, 12 May 2021 21:57:49 +0000 (14:57 -0700)]
Optimize RefDirectory.isNameConflicting()

Avoid having to scan over ALL loose refs to determine if the
name is nested within or is a container of an existing reference.
This can get really expensive if there are too many loose refs.
Instead use exactRef and getRefsByPrefix which scan based on a
prefix.

With a simple shell script(like below) using jgit client to create
1k refs in a new repository on NFS, this change brings down the time
from 12mins to 7mins.

for ref in $(seq 1 1000); do
    jgit branch "$ref"
done

Here are few recorded elapsed times to create a new branch on NFS
based repositories with varying loose refs count. As we see here,
this change improves the name conflicting check from O(n^2) to O(1).

loose_refs_count  with_change  without_change
50                44 ms        164 ms
300               45 ms        1193 ms
1k                38 ms        2610 ms
2k                44 ms        6003 ms
9k                46 ms        27860 ms
20k               45 ms        48591 ms
50k               51 ms        135471 ms
110k              43 ms        294252 ms
160k              52 ms        430976 ms

Change-Id: Ie994fc184b8f82811bfb37b111eb9733dbe3e6e0
Signed-off-by: Kaushik Lingarkar <quic_kaushikl@quicinc.com>
3 years agoApplyCommand: convert to git internal format before applying patch 91/177591/3
Thomas Wolf [Tue, 2 Mar 2021 08:53:08 +0000 (09:53 +0100)]
ApplyCommand: convert to git internal format before applying patch

Applying a patch on Windows failed if the patch had the (normal)
single-LF line endings, but the file on disk had the usual Windows
CR-LF line endings.

Git (and JGit) compute diffs on the git-internal blob, i.e., after
CR-LF transformation and clean filtering. Applying patches to files
directly is thus incorrect and may fail if CR-LF settings don't
match, or if clean/smudge filtering is involved.

Change ApplyCommand to run the file content through the check-in
filters before applying the patch, and run the result through the
check-out filters. This makes patch application succeed even if the
patch has single-LFs, but the file has CR-LF and core.autocrlf is
true.

Add tests for various combinations of line endings in the file and in
the patch, and a test to verify the clean/smudge handling.

See also [1].

Running the file though clean/smudge may give strange results with
LFS-managed files. JGit's DiffFormatter has some extra code and
applies the smudge filter again after having run the file through
the check-in filters (CR-LF and clean). So JGit can actually produce
a diff on LFS-managed files using the normal diff machinery. (If it
doesn't run out of memory, that is. After all, LFS is intended for
_large_ files.) How such a diff would be applied with either C git
or JGit is entirely unclear; neither has any code for this special
case. Compare also [2].

Note that C git just doesn't know about LFS and always diffs after
the check-in filter chain, so for LFS files, it'll produce a diff
of the LFS pointers.

[1] https://github.com/git/git/commit/c24f3abac
[2] https://github.com/git-lfs/git-lfs/issues/440

Bug: 571585
Change-Id: I8f71ff26313b5773ff1da612b0938ad2f18751f5
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
3 years agoSSH config: fix whitespace handling 33/180633/2
Thomas Wolf [Sat, 15 May 2021 16:25:52 +0000 (18:25 +0200)]
SSH config: fix whitespace handling

Use Character.isWhitespace() instead of Character.isSpaceChar() to
treat TABs as whitespace, too.

Change-Id: Iffc59c13357d981ede6a1e0feb6ea6ff03fb3064
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
3 years agoSSH config: fix negated patterns 32/180632/2
Thomas Wolf [Sat, 15 May 2021 16:13:04 +0000 (18:13 +0200)]
SSH config: fix negated patterns

Negated patterns were handled wrongly. According to the OpenBSD
ssh_config man page,[1] a negated pattern never matches. Negated
patterns make only sense if there are positive patterns; the
negated pattern then can define exceptions for the positive
patterns.

OpenSshConfigFile did this wrongly. It handled "!foo" as "matching
everything but foo", but actually the semantics is "if the input is
"foo", this entry doesn't apply. If the input is anything else,
other patterns determine whether the entry may apply.".

[1] https://man.openbsd.org/ssh_config

Change-Id: I50f6e46581b7ece4c949eddf62f4a265573ec29e
Signed-off-by: Thomas Wolf <thomas.wolf@paranor.ch>
3 years agoUpdate bazlets and bazel version 22/180622/1
Matthias Sohn [Thu, 16 Jan 2020 12:07:20 +0000 (13:07 +0100)]
Update bazlets and bazel version

- bazlets need to be updated to react on Maven central no longer
supporting http protocol but only https
- update bazel to 2.0

Change-Id: I07f5f050f3b1db2014a5198a28b6bbf893434814
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
(cherry picked from commit d74daad1e064da9614c5ca2c0138c8046cfb0829)

3 years agoFix @since tag for introduction of PUBKEY_ACCEPTED_ALGORITHMS 93/180593/1
Matthias Sohn [Fri, 14 May 2021 07:02:46 +0000 (09:02 +0200)]
Fix @since tag for introduction of PUBKEY_ACCEPTED_ALGORITHMS

This constant was shipped with 5.11.1.

Change-Id: I480dbefab1cccca78cefbc709b79e5405f8bf8cd
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoMerge branch 'stable-5.11' 91/180591/3
Matthias Sohn [Fri, 14 May 2021 06:39:14 +0000 (08:39 +0200)]
Merge branch 'stable-5.11'

* stable-5.11:
  Prepare 5.11.2-SNAPSHOT builds
  JGit v5.11.1.202105131744-r

Change-Id: I940216261e25d7bb24e912a8971655198762703a
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoPrepare 5.11.2-SNAPSHOT builds 90/180590/2
Matthias Sohn [Fri, 14 May 2021 06:25:09 +0000 (08:25 +0200)]
Prepare 5.11.2-SNAPSHOT builds

Change-Id: Idfd81bd3bbcd99034f69fffb1a562bf07b0f8209
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoJGit v5.11.1.202105131744-r 85/180585/1 v5.11.1.202105131744-r
Matthias Sohn [Thu, 13 May 2021 21:42:10 +0000 (23:42 +0200)]
JGit v5.11.1.202105131744-r

Change-Id: Id74eecbde63edbc58b6262ae01ef34d8bebc0f88
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoMerge branch 'master' into next 02/180502/2
Matthias Sohn [Wed, 12 May 2021 06:59:07 +0000 (08:59 +0200)]
Merge branch 'master' into next

* master: (34 commits)
  Remove texts which were added by mistake in 00386272
  Fix formatting which was broken in 00386272
  LockFile: create OutputStream only when needed
  Add a cgit interoperability test for LockFile
  Add TemporaryBuffer.toString(int limit)
  LockFile: create OutputStream only when needed
  Prepare 5.12.0-SNAPSHOT builds
  JGit v5.12.0.202105051250-m2
  Update jetty to 9.4.40.v20210413
  [releng] Update eclipse-jarsigner-plugin to 1.3.1
  Implement ours/theirs content conflict resolution
  ssh: ensure list is modifiable before using Iterator.remove().
  Update orbit to S20210406213021 and add 4.20-staging target
  Fix typo in test method name
  Allow file mode conflicts in virtual base commit on recursive merge.
  sshd: don't lock the known_hosts files on reading
  Allow info messages in UsernamePasswordCredentialsProvider
  ssh config: do environment variable replacement
  sshd: implement server-sig-algs SSH extension (client side)
  Upgrade ecj to 3.25.0
  ...

Change-Id: Ibc39a9c4e431d15b67ab4a307241f47a7f3740a9

3 years agoMerge branch 'stable-5.12' 01/180501/2
Matthias Sohn [Wed, 12 May 2021 06:58:09 +0000 (08:58 +0200)]
Merge branch 'stable-5.12'

* stable-5.12:
  Remove texts which were added by mistake in 00386272
  Fix formatting which was broken in 00386272

Change-Id: I1c936183e1fa17ea95ada7849a75bc76af275fa3

3 years agoMerge branch 'stable-5.11' into stable-5.12 00/180500/2
Matthias Sohn [Wed, 12 May 2021 06:57:20 +0000 (08:57 +0200)]
Merge branch 'stable-5.11' into stable-5.12

* stable-5.11:
  Remove texts which were added by mistake in 00386272
  Fix formatting which was broken in 00386272

Change-Id: I6184772bdeca1b9ccecf6e400ae15604ab4f5a69

3 years agoMerge branch 'stable-5.10' into stable-5.11 12/180512/1
Matthias Sohn [Wed, 12 May 2021 06:56:27 +0000 (08:56 +0200)]
Merge branch 'stable-5.10' into stable-5.11

* stable-5.10:
  Remove texts which were added by mistake in 00386272
  Fix formatting which was broken in 00386272

Change-Id: I0f1511be5375716d41565e72b271cb956c3e847b

3 years agoMerge branch 'stable-5.9' into stable-5.10 98/180498/2
Matthias Sohn [Wed, 12 May 2021 06:55:17 +0000 (08:55 +0200)]
Merge branch 'stable-5.9' into stable-5.10

* stable-5.9:
  Remove texts which were added by mistake in 00386272
  Fix formatting which was broken in 00386272

Change-Id: Ifa135077d8d07d2317df3b479822e30d87eca950

3 years agoMerge branch 'stable-5.8' into stable-5.9 97/180497/2
Matthias Sohn [Tue, 11 May 2021 22:03:00 +0000 (00:03 +0200)]
Merge branch 'stable-5.8' into stable-5.9

* stable-5.8:
  Remove texts which were added by mistake in 00386272
  Fix formatting which was broken in 00386272

Change-Id: I9ca7a0237f87d1d4bcaba81e709eaa67902f27e5

3 years agoMerge branch 'stable-5.7' into stable-5.8 96/180496/1
Matthias Sohn [Tue, 11 May 2021 21:34:30 +0000 (23:34 +0200)]
Merge branch 'stable-5.7' into stable-5.8

* stable-5.7:
  Remove texts which were added by mistake in 00386272
  Fix formatting which was broken in 00386272

Change-Id: I7ed3f47cb46e6c1bf483702c8925a24e88658e47

3 years agoMerge branch 'stable-5.6' into stable-5.7 95/180495/1
Matthias Sohn [Tue, 11 May 2021 21:32:22 +0000 (23:32 +0200)]
Merge branch 'stable-5.6' into stable-5.7

* stable-5.6:
  Remove texts which were added by mistake in 00386272
  Fix formatting which was broken in 00386272

Change-Id: I45d444b360485564744bf3dfad2c2f5a5e7fcdf6

3 years agoRemove texts which were added by mistake in 00386272 87/180487/1
Matthias Sohn [Tue, 11 May 2021 16:37:37 +0000 (18:37 +0200)]
Remove texts which were added by mistake in 00386272

Change-Id: Iaed25dac0bc9af8f3fda6138a5f9fe553bff5d39
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
3 years agoFix formatting which was broken in 00386272 86/180486/1
Matthias Sohn [Tue, 11 May 2021 16:36:05 +0000 (18:36 +0200)]
Fix formatting which was broken in 00386272

Change-Id: I10a3e2b117e790f64386a8e9e7663db8e59230d9
Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>