diff options
267 files changed, 7729 insertions, 5092 deletions
@@ -1,6 +1,10 @@ +# TODO(davido): Migrate all dependencies from WORKSPACE to MODULE.bazel +# https://issues.gerritcodereview.com/issues/303819949 +common --noenable_bzlmod + build --workspace_status_command="python ./tools/workspace_status.py" build --repository_cache=~/.gerritcodereview/bazel-cache/repository -build --experimental_strict_action_env +build --incompatible_strict_action_env build --action_env=PATH build --disk_cache=~/.gerritcodereview/bazel-cache/cas @@ -17,7 +21,7 @@ build:remote11 --tool_java_language_version=11 build:remote11 --tool_java_runtime_version=remotejdk_11 build:remote11 --config=remote -# Builds using remote_jdk17, executes using remote_jdk11 or local_jdk +# Builds using remote_jdk17, executes using remote_jdk17 or local_jdk build:java17 --java_language_version=17 build:java17 --java_runtime_version=remotejdk_17 build:java17 --tool_java_language_version=17 @@ -30,6 +34,19 @@ build:remote17 --tool_java_language_version=17 build:remote17 --tool_java_runtime_version=remotejdk_17 build:remote17 --config=remote +# Builds using remote_jdk21, executes using remote_jdk21 or local_jdk +build:java21 --java_language_version=21 +build:java21 --java_runtime_version=remotejdk_21 +build:java21 --tool_java_language_version=21 +build:java21 --tool_java_runtime_version=remotejdk_21 + +# Builds and executes on RBE using remotejdk_21 +build:remote21 --java_language_version=21 +build:remote21 --java_runtime_version=remotejdk_21 +build:remote21 --tool_java_language_version=21 +build:remote21 --tool_java_runtime_version=remotejdk_21 +build:remote21 --config=remote + test --build_tests_only test --test_output=errors test --flaky_test_attempts=3 diff --git a/.bazelversion b/.bazelversion index 91e4a9f262..21c8c7b46b 100644 --- a/.bazelversion +++ b/.bazelversion @@ -1 +1 @@ -6.3.2 +7.1.1 diff --git a/.github/pull_request_template.md b/.github/pull_request_template.md new file mode 100644 index 0000000000..19909ac016 --- /dev/null +++ b/.github/pull_request_template.md @@ -0,0 +1,5 @@ +Thank you for contributing to JGit! + +JGit uses [GerritHub](https://eclipse.gerrithub.io) for code changes and review, therefore **pull requests in this repository cannot be merged**. + +Please make sure you have read the section on [contributing patches](https://github.com/eclipse-egit/egit/wiki/Contributor-Guide#contributing-patches) of the [Contributor Guide](https://github.com/eclipse-egit/egit/wiki/Contributor-Guide).
\ No newline at end of file diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index bb9df9ff6c..7496cf993d 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -8,7 +8,9 @@ Contributions require that you sign the [Eclipse Contributor Agreement](https:// For anything other than small changes, it's a good idea to open a bug report for it (in case one doesn't already exist). This gives others the chance to give input and is useful for tracking. -[Create JGit bugs here](https://bugs.eclipse.org/bugs/enter_bug.cgi?product=JGit). +[Open JGit issues on GitHub](https://github.com/eclipse-jgit/jgit/issues). + +Older bugs can be found [in Bugzilla](https://bugs.eclipse.org/bugs/buglist.cgi?bug_status=__open__&component=JGit&list_id=21379030&product=JGit). ## Submitting changes diff --git a/MODULE.bazel b/MODULE.bazel new file mode 100644 index 0000000000..0b932b8d8c --- /dev/null +++ b/MODULE.bazel @@ -0,0 +1,2 @@ +# TODO(davido): Migrate all dependencies from WORKSPACE to MODULE.bazel +# https://issues.gerritcodereview.com/issues/303819949 @@ -11,12 +11,24 @@ load( ) http_archive( - name = "rbe_jdk11", - sha256 = "dbcfd6f26589ef506b91fe03a12dc559ca9c84699e4cf6381150522287f0e6f6", - strip_prefix = "rbe_autoconfig-3.1.0", + name = "rules_java", + sha256 = "4da3761f6855ad916568e2bfe86213ba6d2637f56b8360538a7fb6125abf6518", urls = [ - "https://gerrit-bazel.storage.googleapis.com/rbe_autoconfig/v3.1.0.tar.gz", - "https://github.com/davido/rbe_autoconfig/archive/v3.1.0.tar.gz", + "https://github.com/bazelbuild/rules_java/releases/download/7.5.0/rules_java-7.5.0.tar.gz", + ], +) + +load("@rules_java//java:repositories.bzl", "rules_java_dependencies", "rules_java_toolchains") + +rules_java_dependencies() + +http_archive( + name = "ubuntu2204_jdk17", + sha256 = "8ea82b81c9707e535ff93ef5349d11e55b2a23c62bcc3b0faaec052144aed87d", + strip_prefix = "rbe_autoconfig-5.1.0", + urls = [ + "https://gerrit-bazel.storage.googleapis.com/rbe_autoconfig/v5.1.0.tar.gz", + "https://github.com/davido/rbe_autoconfig/releases/download/v5.1.0/v5.1.0.tar.gz", ], ) @@ -24,6 +36,14 @@ register_toolchains("//tools:error_prone_warnings_toolchain_java11_definition") register_toolchains("//tools:error_prone_warnings_toolchain_java17_definition") +register_toolchains("//tools:error_prone_warnings_toolchain_java21_definition") + +# Order of registering toolchains matters. rules_java toolchains take precedence +# over the custom toolchains, so the default jdk21 toolchain gets picked +# (one without custom package_config). That's why the `rules_java_toolchains()` +# must be called after the `register_toolchain()` invocation. +rules_java_toolchains() + JMH_VERS = "1.37" maven_jar( @@ -90,18 +110,18 @@ maven_jar( sha1 = "51cf043c87253c9f58b539c9f7e44c8894223850", ) -SSHD_VERS = "2.12.0" +SSHD_VERS = "2.12.1" maven_jar( name = "sshd-osgi", artifact = "org.apache.sshd:sshd-osgi:" + SSHD_VERS, - sha1 = "32b8de1cbb722ba75bdf9898e0c41d42af00ce57", + sha1 = "45b0501857603881ab472c927852ffa406932aef", ) maven_jar( name = "sshd-sftp", artifact = "org.apache.sshd:sshd-sftp:" + SSHD_VERS, - sha1 = "0f96f00a07b186ea62838a6a4122e8f4cad44df6", + sha1 = "3ef6ded49799618c9438aa1044c6bf01124133bb", ) JNA_VERS = "5.14.0" @@ -120,14 +140,14 @@ maven_jar( maven_jar( name = "commons-codec", - artifact = "commons-codec:commons-codec:1.16.0", - sha1 = "4e3eb3d79888d76b54e28b350915b5dc3919c9de", + artifact = "commons-codec:commons-codec:1.17.0", + sha1 = "0dbe8eef6e14460e73da07f7b11bf994d6626355", ) maven_jar( name = "commons-logging", - artifact = "commons-logging:commons-logging:1.2", - sha1 = "4bfc12adfe4842bf07b657f0369c4cb522955686", + artifact = "commons-logging:commons-logging:1.3.2", + sha1 = "3dc966156ef19d23c839715165435e582fafa753", ) maven_jar( @@ -150,14 +170,20 @@ maven_jar( maven_jar( name = "commons-compress", - artifact = "org.apache.commons:commons-compress:1.26.0", - sha1 = "659feffdd12280201c8aacb8f7be94f9a883c824", + artifact = "org.apache.commons:commons-compress:1.26.2", + sha1 = "eb1f823447af685208e684fce84783b43517960c", +) + +maven_jar( + name = "commons-lang3", + artifact = "org.apache.commons:commons-lang3:3.14.0", + sha1 = "1ed471194b02f2c6cb734a0cd6f6f107c673afae", ) maven_jar( name = "commons-io", - artifact = "commons-io:commons-io:2.15.1", - sha1 = "f11560da189ab563a5c8e351941415430e9304ea", + artifact = "commons-io:commons-io:2.16.1", + sha1 = "377d592e740dc77124e0901291dbfaa6810a200e", ) maven_jar( @@ -168,8 +194,8 @@ maven_jar( maven_jar( name = "args4j", - artifact = "args4j:args4j:2.33", - sha1 = "bd87a75374a6d6523de82fef51fc3cfe9baf9fc9", + artifact = "args4j:args4j:2.37", + sha1 = "244f60c057d72a785227c0562d3560f42a7ea54b", ) maven_jar( @@ -186,119 +212,119 @@ maven_jar( maven_jar( name = "mockito", - artifact = "org.mockito:mockito-core:5.10.0", - sha1 = "b3812fa2ee069f1d0b41c1c0155da79d0e1dcde0", + artifact = "org.mockito:mockito-core:5.12.0", + sha1 = "22f8bbaf478e6789164787fa411a3b5ed986e110", ) maven_jar( name = "assertj-core", - artifact = "org.assertj:assertj-core:3.25.3", - sha1 = "792b270e73aa1cfc28fa135be0b95e69ea451432", + artifact = "org.assertj:assertj-core:3.26.0", + sha1 = "fc4a3d051da838946f9dffe725efbd06cd7d1eec", ) -BYTE_BUDDY_VERSION = "1.14.12" +BYTE_BUDDY_VERSION = "1.14.16" maven_jar( name = "bytebuddy", artifact = "net.bytebuddy:byte-buddy:" + BYTE_BUDDY_VERSION, - sha1 = "6e37f743dc15a8d7a4feb3eb0025cbc612d5b9e1", + sha1 = "e1b9a06e131b7d5b183c8ccc7c29b9e5a8dba077", ) maven_jar( name = "bytebuddy-agent", artifact = "net.bytebuddy:byte-buddy-agent:" + BYTE_BUDDY_VERSION, - sha1 = "be4984cb6fd1ef1d11f218a648889dfda44b8a15", + sha1 = "4a451ee6484abac3a498df0f3b33ed00a6fced4d", ) maven_jar( name = "objenesis", - artifact = "org.objenesis:objenesis:3.3", - sha1 = "1049c09f1de4331e8193e579448d0916d75b7631", + artifact = "org.objenesis:objenesis:3.4", + sha1 = "675cbe121a68019235d27f6c34b4f0ac30e07418", ) maven_jar( name = "gson", - artifact = "com.google.code.gson:gson:2.10.1", - sha1 = "b3add478d4382b78ea20b1671390a858002feb6c", + artifact = "com.google.code.gson:gson:2.11.0", + sha1 = "527175ca6d81050b53bdd4c457a6d6e017626b0e", ) -JETTY_VER = "10.0.20" +JETTY_VER = "10.0.21" maven_jar( name = "jetty-servlet", artifact = "org.eclipse.jetty:jetty-servlet:" + JETTY_VER, - sha1 = "e3661d28d5f2e2185fb085ce5560b2969e8f7c1e", - src_sha1 = "23b97219833769e3e69a071abab3811f49077e2e", + sha1 = "6de2f73e1edbd368b14c485597d555d1190e6221", + src_sha1 = "6a82804a625a730a13dfcb9fbd3c9d09016bae92", ) maven_jar( name = "jetty-security", artifact = "org.eclipse.jetty:jetty-security:" + JETTY_VER, - sha1 = "f082f9198038e4781ff4cdf4d32db9f90fa8f38a", - src_sha1 = "a1acb8cb40bd495ba67562cb342f371425dba47b", + sha1 = "fec31c853de43a15a5a75f2e1492e930366d4595", + src_sha1 = "ef7660113cae5cfbf4fb24c6c8d832a74d4fd800", ) maven_jar( name = "jetty-server", artifact = "org.eclipse.jetty:jetty-server:" + JETTY_VER, - sha1 = "66deea078236e21ae9dd7443716b7642766526aa", - src_sha1 = "e2ddea07b6c85dbc7cf078e408f68d69e504b33c", + sha1 = "1e49b8b6d0ce2f8e484e4eec3d8b0a55c4cc599c", + src_sha1 = "a6b18935ddbe227a717bea6343603a8cf2629e0c", ) maven_jar( name = "jetty-http", artifact = "org.eclipse.jetty:jetty-http:" + JETTY_VER, - sha1 = "d76bf933db81e9f530f1e59f1858bceddb7c4a43", - src_sha1 = "5fd939e4e5000ac76eb686e68e978747802c8a5f", + sha1 = "26c21d1d16f2929c8f58f177a246687444217cbe", + src_sha1 = "fa315f1a44b11759c14373c5bafe4014c837d3a6", ) maven_jar( name = "jetty-io", artifact = "org.eclipse.jetty:jetty-io:" + JETTY_VER, - sha1 = "269cea7949f739e41707f3d574782c9f227fe188", - src_sha1 = "1d30687503a0256da23706e1ebf597658d8c0011", + sha1 = "21bb67ceae5fa145ee86ce88a5609c908b880bf8", + src_sha1 = "44afc9e83169cc40b6b13ab49789693da1298860", ) maven_jar( name = "jetty-util", artifact = "org.eclipse.jetty:jetty-util:" + JETTY_VER, - sha1 = "c628108266e75f17dffee34191b74a696fe21746", - src_sha1 = "63c17b20a8ca5c3bc1740bd807ad446f842749b4", + sha1 = "141f604e6ae732bf2c5e7488ddf82697eb7d8b86", + src_sha1 = "91da8bf1f086a98dbb11c8ef63f79dd9f0f66c33", ) maven_jar( name = "jetty-util-ajax", artifact = "org.eclipse.jetty:jetty-util-ajax:" + JETTY_VER, - sha1 = "049dcc0ad4190786e17389b257195fe936ed3d27", - src_sha1 = "b012c053d25d902cc64a5c4432a8eedab3241d94", + sha1 = "8bc368c8619dee1e30de0ca57189569ba17bd86e", + src_sha1 = "17c7eb1571d944cee942d43d160cb6547afa6e07", ) -BOUNCYCASTLE_VER = "1.77" +BOUNCYCASTLE_VER = "1.78.1" maven_jar( name = "bcpg", artifact = "org.bouncycastle:bcpg-jdk18on:" + BOUNCYCASTLE_VER, - sha1 = "bb0be51e8b378baae6e0d86f5282cd3887066539", - src_sha1 = "33ff3269cede7165dac44033a3b150cc9f9f11cf", + sha1 = "6c8dbcec20355278ec54840e735f63db2479150e", + src_sha1 = "2ddef60d84dd8c14ebce4c13100f0bc55fed6922", ) maven_jar( name = "bcprov", artifact = "org.bouncycastle:bcprov-jdk18on:" + BOUNCYCASTLE_VER, - sha1 = "2cc971b6c20949c1ff98d1a4bc741ee848a09523", - src_sha1 = "14ea9a3d759261358c6a1f59490ded125b5273a6", + sha1 = "39e9e45359e20998eb79c1828751f94a818d25f8", + src_sha1 = "70f58ec93da543dda6a21614b768cb2e386fd512", ) maven_jar( name = "bcutil", artifact = "org.bouncycastle:bcutil-jdk18on:" + BOUNCYCASTLE_VER, - sha1 = "de3eaef351545fe8562cf29ddff4a403a45b49b7", - src_sha1 = "6f8f56ab009e7a3204817a0d45ed9638f5e30116", + sha1 = "5353ca39fe2f148dab9ca1d637a43d0750456254", + src_sha1 = "8d2e0747f5d806f39a602f7f91610444d88c4e2c", ) maven_jar( name = "bcpkix", artifact = "org.bouncycastle:bcpkix-jdk18on:" + BOUNCYCASTLE_VER, - sha1 = "ed953791ba0229747dd0fd9911e3d76a462acfd3", - src_sha1 = "fdff397d5de0306db014f0a17e91717150db2768", + sha1 = "17b3541f736df97465f87d9f5b5dfa4991b37bb3", + src_sha1 = "3aeaf221772ad0c9c04593688cb86c6eb74d48b9", ) @@ -20,6 +20,16 @@ java_library( ) java_library( + name = "commons-lang3", + visibility = [ + "//org.eclipse.jgit.archive:__pkg__", + "//org.eclipse.jgit.pgm.test:__pkg__", + "//org.eclipse.jgit.test:__pkg__", + ], + exports = ["@commons-lang3//jar"], +) + +java_library( name = "commons-io", visibility = [ "//org.eclipse.jgit.archive:__pkg__", diff --git a/org.eclipse.jgit.ant.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.ant.test/META-INF/MANIFEST.MF index 44cf7b0957..58526deac9 100644 --- a/org.eclipse.jgit.ant.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ant.test/META-INF/MANIFEST.MF @@ -5,13 +5,13 @@ Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.ant.test Bundle-SymbolicName: org.eclipse.jgit.ant.test Bundle-Vendor: %Bundle-Vendor -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-ActivationPolicy: lazy Bundle-RequiredExecutionEnvironment: JavaSE-11 Import-Package: org.apache.tools.ant, - org.eclipse.jgit.ant.tasks;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", + org.eclipse.jgit.ant.tasks;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", org.hamcrest.core;version="[1.1.0,3.0.0)", org.junit;version="[4.13,5.0.0)" diff --git a/org.eclipse.jgit.ant.test/pom.xml b/org.eclipse.jgit.ant.test/pom.xml index f4049af032..11cca38244 100644 --- a/org.eclipse.jgit.ant.test/pom.xml +++ b/org.eclipse.jgit.ant.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ant.test</artifactId> diff --git a/org.eclipse.jgit.ant/META-INF/MANIFEST.MF b/org.eclipse.jgit.ant/META-INF/MANIFEST.MF index 7d416dadbd..113896f15d 100644 --- a/org.eclipse.jgit.ant/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ant/META-INF/MANIFEST.MF @@ -3,13 +3,13 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.ant Bundle-SymbolicName: org.eclipse.jgit.ant -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-RequiredExecutionEnvironment: JavaSE-11 Import-Package: org.apache.tools.ant, - org.eclipse.jgit.storage.file;version="[6.9.1,6.10.0)" + org.eclipse.jgit.storage.file;version="[6.10.1,6.11.0)" Bundle-Localization: OSGI-INF/l10n/plugin Bundle-Vendor: %Bundle-Vendor -Export-Package: org.eclipse.jgit.ant;version="6.9.1", - org.eclipse.jgit.ant.tasks;version="6.9.1"; +Export-Package: org.eclipse.jgit.ant;version="6.10.1", + org.eclipse.jgit.ant.tasks;version="6.10.1"; uses:="org.apache.tools.ant, org.apache.tools.ant.types" diff --git a/org.eclipse.jgit.ant/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.ant/META-INF/SOURCE-MANIFEST.MF index 1ec6d789bd..2616909676 100644 --- a/org.eclipse.jgit.ant/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.ant/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.ant - Sources Bundle-SymbolicName: org.eclipse.jgit.ant.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.ant;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.ant;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.ant/pom.xml b/org.eclipse.jgit.ant/pom.xml index 6639067109..c128eacefd 100644 --- a/org.eclipse.jgit.ant/pom.xml +++ b/org.eclipse.jgit.ant/pom.xml @@ -15,7 +15,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ant</artifactId> diff --git a/org.eclipse.jgit.archive/BUILD b/org.eclipse.jgit.archive/BUILD index 3d7dbd21f1..d4f53405d7 100644 --- a/org.eclipse.jgit.archive/BUILD +++ b/org.eclipse.jgit.archive/BUILD @@ -12,6 +12,7 @@ java_library( resources = glob(["resources/**"]), deps = [ "//lib:commons-compress", + "//lib:commons-lang3", # We want these deps to be provided_deps "//org.eclipse.jgit:jgit", ], diff --git a/org.eclipse.jgit.archive/META-INF/MANIFEST.MF b/org.eclipse.jgit.archive/META-INF/MANIFEST.MF index ec7df3c89f..78904fd583 100644 --- a/org.eclipse.jgit.archive/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.archive/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.archive Bundle-SymbolicName: org.eclipse.jgit.archive -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: OSGI-INF/l10n/plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -13,17 +13,17 @@ Import-Package: org.apache.commons.compress.archivers;version="[1.4,2.0)", org.apache.commons.compress.compressors.bzip2;version="[1.4,2.0)", org.apache.commons.compress.compressors.gzip;version="[1.4,2.0)", org.apache.commons.compress.compressors.xz;version="[1.4,2.0)", - org.eclipse.jgit.api;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.nls;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", + org.eclipse.jgit.api;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.nls;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", org.osgi.framework;version="[1.3.0,2.0.0)" Bundle-ActivationPolicy: lazy Bundle-Activator: org.eclipse.jgit.archive.FormatActivator -Export-Package: org.eclipse.jgit.archive;version="6.9.1"; +Export-Package: org.eclipse.jgit.archive;version="6.10.1"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.api, org.apache.commons.compress.archivers, org.osgi.framework", - org.eclipse.jgit.archive.internal;version="6.9.1";x-internal:=true + org.eclipse.jgit.archive.internal;version="6.10.1";x-internal:=true diff --git a/org.eclipse.jgit.archive/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.archive/META-INF/SOURCE-MANIFEST.MF index f8169464c6..459e145cd7 100644 --- a/org.eclipse.jgit.archive/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.archive/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.archive - Sources Bundle-SymbolicName: org.eclipse.jgit.archive.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.archive;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.archive;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.archive/pom.xml b/org.eclipse.jgit.archive/pom.xml index ed2a64c648..af5695d9fb 100644 --- a/org.eclipse.jgit.archive/pom.xml +++ b/org.eclipse.jgit.archive/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.archive</artifactId> diff --git a/org.eclipse.jgit.benchmarks/pom.xml b/org.eclipse.jgit.benchmarks/pom.xml index 614f346bbe..16b1e2bdf1 100644 --- a/org.eclipse.jgit.benchmarks/pom.xml +++ b/org.eclipse.jgit.benchmarks/pom.xml @@ -16,7 +16,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.benchmarks</artifactId> diff --git a/org.eclipse.jgit.coverage/pom.xml b/org.eclipse.jgit.coverage/pom.xml index 8c97734efb..4c91d2c9ab 100644 --- a/org.eclipse.jgit.coverage/pom.xml +++ b/org.eclipse.jgit.coverage/pom.xml @@ -14,7 +14,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <modelVersion>4.0.0</modelVersion> @@ -27,88 +27,88 @@ <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.ant</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.archive</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.http.apache</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.http.server</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.lfs</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.lfs.server</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.pgm</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.ui</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.ssh.apache</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.test</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.ant.test</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.http.test</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.pgm.test</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.lfs.test</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.lfs.server.test</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> <dependency> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit.ssh.apache.test</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> </dependencies> diff --git a/org.eclipse.jgit.gpg.bc.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.gpg.bc.test/META-INF/MANIFEST.MF index ba4acf169c..4e3c849c17 100644 --- a/org.eclipse.jgit.gpg.bc.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.gpg.bc.test/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.gpg.bc.test Bundle-SymbolicName: org.eclipse.jgit.gpg.bc.test -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -13,9 +13,9 @@ Import-Package: org.bouncycastle.jce.provider;version="[1.65.0,2.0.0)", org.bouncycastle.openpgp.operator;version="[1.65.0,2.0.0)", org.bouncycastle.openpgp.operator.jcajce;version="[1.65.0,2.0.0)", org.bouncycastle.util.encoders;version="[1.65.0,2.0.0)", - org.eclipse.jgit.gpg.bc.internal;version="[6.9.1,6.10.0)", - org.eclipse.jgit.gpg.bc.internal.keys;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util.sha1;version="[6.9.1,6.10.0)", + org.eclipse.jgit.gpg.bc.internal;version="[6.10.1,6.11.0)", + org.eclipse.jgit.gpg.bc.internal.keys;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util.sha1;version="[6.10.1,6.11.0)", org.junit;version="[4.13,5.0.0)", org.junit.runner;version="[4.13,5.0.0)", org.junit.runners;version="[4.13,5.0.0)" diff --git a/org.eclipse.jgit.gpg.bc.test/pom.xml b/org.eclipse.jgit.gpg.bc.test/pom.xml index d62bedafee..dbb3dcd3c7 100644 --- a/org.eclipse.jgit.gpg.bc.test/pom.xml +++ b/org.eclipse.jgit.gpg.bc.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.gpg.bc.test</artifactId> diff --git a/org.eclipse.jgit.gpg.bc.test/tst-rsrc/org/eclipse/jgit/gpg/bc/internal/keys/62D43D7F117F7A5E4998ECB6617EE9942D069C14.asc b/org.eclipse.jgit.gpg.bc.test/tst-rsrc/org/eclipse/jgit/gpg/bc/internal/keys/62D43D7F117F7A5E4998ECB6617EE9942D069C14.asc new file mode 100644 index 0000000000..ee8207ec41 --- /dev/null +++ b/org.eclipse.jgit.gpg.bc.test/tst-rsrc/org/eclipse/jgit/gpg/bc/internal/keys/62D43D7F117F7A5E4998ECB6617EE9942D069C14.asc @@ -0,0 +1,9 @@ +-----BEGIN PGP PUBLIC KEY BLOCK----- + +mDMEZet5vRYJKwYBBAHaRw8BAQdA1lUwXTD4ia1i4+ckhPr0O0a9aQAarg6U8prB +6H85XJG0GFRlc3RlciA8dGVzdGVyQHRlc3QuY29tPoiQBBMWCgA4FiEEwLQ/UWQ8 +ydO7u8ea7hn0dWq7fbwFAmXreb0CGwEFCwkIBwMFFQoJCAsFFgIDAQACHgECF4AA +CgkQ7hn0dWq7fbxhPwEA3a0COi4sV7Uxd91H9P5DXJA2XzYtyvYsxZJEICFZPo8B +AO6fF9Ii5ATO5USSMf6bNCevcBlDFBNXIO+pwjemrBYJ +=LYEV +-----END PGP PUBLIC KEY BLOCK----- diff --git a/org.eclipse.jgit.gpg.bc.test/tst-rsrc/org/eclipse/jgit/gpg/bc/internal/keys/62D43D7F117F7A5E4998ECB6617EE9942D069C14.key b/org.eclipse.jgit.gpg.bc.test/tst-rsrc/org/eclipse/jgit/gpg/bc/internal/keys/62D43D7F117F7A5E4998ECB6617EE9942D069C14.key new file mode 100644 index 0000000000..03ed01cb0b --- /dev/null +++ b/org.eclipse.jgit.gpg.bc.test/tst-rsrc/org/eclipse/jgit/gpg/bc/internal/keys/62D43D7F117F7A5E4998ECB6617EE9942D069C14.key @@ -0,0 +1,7 @@ +Key: (protected-private-key (ecc (curve Ed25519)(flags eddsa)(q + #40D655305D30F889AD62E3E72484FAF43B46BD69001AAE0E94F29AC1E87F395C91#) + (protected openpgp-s2k3-ocb-aes ((sha1 #EBA45EE5104E7ED6# + "24672256")#36CB86BDBEA4947789F555B6#)#2D3CBB52F66DED8E0E7B0A1FEE9732 + 4FC1624B32069CD1ED507877E26B3099E62C2AC615DA7E8DAAD335EC613AD2CD9B89C4 + D1BCDEADEA3C67785428#)(protected-at "20240308T204911"))) +Created: 20240308T204901 diff --git a/org.eclipse.jgit.gpg.bc.test/tst/org/eclipse/jgit/gpg/bc/internal/keys/SecretKeysTest.java b/org.eclipse.jgit.gpg.bc.test/tst/org/eclipse/jgit/gpg/bc/internal/keys/SecretKeysTest.java index 5e5e303319..fed06103b6 100644 --- a/org.eclipse.jgit.gpg.bc.test/tst/org/eclipse/jgit/gpg/bc/internal/keys/SecretKeysTest.java +++ b/org.eclipse.jgit.gpg.bc.test/tst/org/eclipse/jgit/gpg/bc/internal/keys/SecretKeysTest.java @@ -97,6 +97,7 @@ public class SecretKeysTest { new TestData("2FB05DBB70FC07CB84C13431F640CA6CEA1DBF8A", false, true), new TestData("66CCECEC2AB46A9735B10FEC54EDF9FD0F77BAF9", true, true), new TestData("F727FAB884DA3BD402B6E0F5472E108D21033124", true, true), + new TestData("62D43D7F117F7A5E4998ECB6617EE9942D069C14", true, true), new TestData("faked", false, true) }; } @@ -152,7 +153,7 @@ public class SecretKeysTest { assertNotNull(secretKey); } catch (PGPException e) { // Currently we may not be able to load OCB-encrypted keys. - assertTrue(e.getMessage().contains("OCB")); + assertTrue(e.toString(), e.getMessage().contains("OCB")); assertTrue(data.encrypted); assertFalse(ocbAvailable()); } diff --git a/org.eclipse.jgit.gpg.bc/META-INF/MANIFEST.MF b/org.eclipse.jgit.gpg.bc/META-INF/MANIFEST.MF index d27c9def82..514dc1f46d 100644 --- a/org.eclipse.jgit.gpg.bc/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.gpg.bc/META-INF/MANIFEST.MF @@ -3,13 +3,12 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.gpg.bc Bundle-SymbolicName: org.eclipse.jgit.gpg.bc;singleton:=true -Fragment-Host: org.eclipse.jgit;bundle-version="[6.9.1,6.10.0)" +Fragment-Host: org.eclipse.jgit;bundle-version="[6.10.1,6.11.0)" Bundle-Vendor: %Bundle-Vendor Bundle-Localization: OSGI-INF/l10n/gpg_bc -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-RequiredExecutionEnvironment: JavaSE-11 Import-Package: org.bouncycastle.asn1;version="[1.69.0,2.0.0)", - org.bouncycastle.asn1.cryptlib;version="[1.69.0,2.0.0)", org.bouncycastle.asn1.x9;version="[1.69.0,2.0.0)", org.bouncycastle.bcpg;version="[1.69.0,2.0.0)", org.bouncycastle.bcpg.sig;version="[1.69.0,2.0.0)", @@ -29,9 +28,9 @@ Import-Package: org.bouncycastle.asn1;version="[1.69.0,2.0.0)", org.bouncycastle.util;version="[1.69.0,2.0.0)", org.bouncycastle.util.encoders;version="[1.69.0,2.0.0)", org.bouncycastle.util.io;version="[1.69.0,2.0.0)", - org.eclipse.jgit.annotations;version="[6.9.1,6.10.0)", - org.eclipse.jgit.api.errors;version="[6.9.1,6.10.0)", + org.eclipse.jgit.annotations;version="[6.10.1,6.11.0)", + org.eclipse.jgit.api.errors;version="[6.10.1,6.11.0)", org.slf4j;version="[1.7.0,3.0.0)" -Export-Package: org.eclipse.jgit.gpg.bc;version="6.9.1", - org.eclipse.jgit.gpg.bc.internal;version="6.9.1";x-friends:="org.eclipse.jgit.gpg.bc.test", - org.eclipse.jgit.gpg.bc.internal.keys;version="6.9.1";x-friends:="org.eclipse.jgit.gpg.bc.test" +Export-Package: org.eclipse.jgit.gpg.bc;version="6.10.1", + org.eclipse.jgit.gpg.bc.internal;version="6.10.1";x-friends:="org.eclipse.jgit.gpg.bc.test", + org.eclipse.jgit.gpg.bc.internal.keys;version="6.10.1";x-friends:="org.eclipse.jgit.gpg.bc.test" diff --git a/org.eclipse.jgit.gpg.bc/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.gpg.bc/META-INF/SOURCE-MANIFEST.MF index 2e1149a1b5..609aa11eb2 100644 --- a/org.eclipse.jgit.gpg.bc/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.gpg.bc/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.gpg.bc - Sources Bundle-SymbolicName: org.eclipse.jgit.gpg.bc.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.gpg.bc;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.gpg.bc;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.gpg.bc/pom.xml b/org.eclipse.jgit.gpg.bc/pom.xml index 191a6cfdbb..3ff49eda6e 100644 --- a/org.eclipse.jgit.gpg.bc/pom.xml +++ b/org.eclipse.jgit.gpg.bc/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.gpg.bc</artifactId> diff --git a/org.eclipse.jgit.gpg.bc/resources/org/eclipse/jgit/gpg/bc/internal/BCText.properties b/org.eclipse.jgit.gpg.bc/resources/org/eclipse/jgit/gpg/bc/internal/BCText.properties index ab83298c15..77ca2cd0a4 100644 --- a/org.eclipse.jgit.gpg.bc/resources/org/eclipse/jgit/gpg/bc/internal/BCText.properties +++ b/org.eclipse.jgit.gpg.bc/resources/org/eclipse/jgit/gpg/bc/internal/BCText.properties @@ -29,6 +29,7 @@ signatureInconsistent=Inconsistent signature; key ID {0} does not match issuer f signatureKeyLookupError=Error occurred while looking for public key signatureNoKeyInfo=No way to determine a public key from the signature signatureNoPublicKey=No public key found to verify the signature +signatureNoSigningKey=No signing key found for key fingerprint {0} signatureParseError=Signature cannot be parsed signatureVerificationError=Signature verification failed unableToSignCommitNoSecretKey=Unable to sign commit. Signing key not available. diff --git a/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BCText.java b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BCText.java index 434998493f..705e195e44 100644 --- a/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BCText.java +++ b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BCText.java @@ -59,6 +59,7 @@ public final class BCText extends TranslationBundle { /***/ public String signatureKeyLookupError; /***/ public String signatureNoKeyInfo; /***/ public String signatureNoPublicKey; + /***/ public String signatureNoSigningKey; /***/ public String signatureParseError; /***/ public String signatureVerificationError; /***/ public String unableToSignCommitNoSecretKey; diff --git a/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgKeyLocator.java b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgKeyLocator.java index e9032a81fd..970e7df3c9 100644 --- a/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgKeyLocator.java +++ b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgKeyLocator.java @@ -27,10 +27,14 @@ import java.nio.file.Paths; import java.security.NoSuchAlgorithmException; import java.security.NoSuchProviderException; import java.text.MessageFormat; +import java.util.ArrayList; +import java.util.Collections; import java.util.Iterator; +import java.util.List; import java.util.Locale; import java.util.function.Consumer; import java.util.function.Function; +import java.util.stream.Collectors; import org.bouncycastle.gpg.keybox.BlobType; import org.bouncycastle.gpg.keybox.KeyBlob; @@ -268,9 +272,11 @@ public class BouncyCastleGpgKeyLocator { return keyId; } - static PGPPublicKey findPublicKey(String fingerprint, String keySpec) + static BouncyCastleGpgPublicKey findPublicKey(String fingerprint, + String keySpec) throws IOException, PGPException { - PGPPublicKey result = findPublicKeyInPubring(USER_PGP_PUBRING_FILE, + BouncyCastleGpgPublicKey result = findPublicKeyInPubring( + USER_PGP_PUBRING_FILE, fingerprint, keySpec); if (result == null && exists(USER_KEYBOX_PATH)) { try { @@ -330,7 +336,8 @@ public class BouncyCastleGpgKeyLocator { * @throws NoOpenPgpKeyException * if the file does not contain any OpenPGP key */ - private static PGPPublicKey findPublicKeyInKeyBox(Path keyboxFile, + private static BouncyCastleGpgPublicKey findPublicKeyInKeyBox( + Path keyboxFile, String keyId, String keySpec) throws IOException, NoSuchAlgorithmException, NoSuchProviderException, NoOpenPgpKeyException { @@ -343,11 +350,16 @@ public class BouncyCastleGpgKeyLocator { hasOpenPgpKey = true; PGPPublicKey key = findPublicKeyByKeyId(keyBlob, id); if (key != null) { - return key; + if (!isSigningKey(key)) { + return null; + } + return new BouncyCastleGpgPublicKey(key, true, + toStrings(keyBlob.getUserIds())); } key = findPublicKeyByUserId(keyBlob, keySpec); if (key != null) { - return key; + return new BouncyCastleGpgPublicKey(key, true, + toStrings(keyBlob.getUserIds())); } } } @@ -357,6 +369,14 @@ public class BouncyCastleGpgKeyLocator { return null; } + private static List<String> toStrings(List<UserID> userIds) { + if (userIds == null) { + return Collections.emptyList(); + } + return userIds.stream().map(UserID::getUserIDAsString) + .collect(Collectors.toList()); + } + /** * If there is a private key directory containing keys, use pubring.kbx or * pubring.gpg to find the public key; then try to find the secret key in @@ -387,7 +407,7 @@ public class BouncyCastleGpgKeyLocator { NoSuchAlgorithmException, NoSuchProviderException, PGPException, CanceledException, UnsupportedCredentialItem, URISyntaxException { BouncyCastleGpgKey key; - PGPPublicKey publicKey = null; + BouncyCastleGpgPublicKey publicKey = null; if (hasKeyFiles(USER_SECRET_KEY_DIR)) { // Use pubring.kbx or pubring.gpg to find the public key, then try // the key files in the directory. If the public key was found in @@ -397,14 +417,15 @@ public class BouncyCastleGpgKeyLocator { publicKey = findPublicKeyInKeyBox(USER_KEYBOX_PATH, null, signingKey); if (publicKey != null) { - key = findSecretKeyForKeyBoxPublicKey(publicKey, - USER_KEYBOX_PATH); + key = findSecretKeyForKeyBoxPublicKey( + publicKey.getPublicKey(), USER_KEYBOX_PATH); if (key != null) { return key; } throw new PGPException(MessageFormat.format( BCText.get().gpgNoSecretKeyForPublicKey, - Long.toHexString(publicKey.getKeyID()))); + Long.toHexString( + publicKey.getPublicKey().getKeyID()))); } throw new PGPException(MessageFormat.format( BCText.get().gpgNoPublicKeyFound, signingKey)); @@ -427,7 +448,8 @@ public class BouncyCastleGpgKeyLocator { // secring.gpg at all, even if it exists. Which means for us // we have to try both since we don't know which GPG version // the user has. - key = findSecretKeyForKeyBoxPublicKey(publicKey, + key = findSecretKeyForKeyBoxPublicKey( + publicKey.getPublicKey(), USER_PGP_PUBRING_FILE); if (key != null) { return key; @@ -452,7 +474,7 @@ public class BouncyCastleGpgKeyLocator { if (publicKey != null) { throw new PGPException(MessageFormat.format( BCText.get().gpgNoSecretKeyForPublicKey, - Long.toHexString(publicKey.getKeyID()))); + Long.toHexString(publicKey.getPublicKey().getKeyID()))); } else if (hasSecring) { // publicKey == null: user has _only_ pubring.gpg/secring.gpg. throw new PGPException(MessageFormat.format( @@ -614,40 +636,88 @@ public class BouncyCastleGpgKeyLocator { * @throws PGPException * on BouncyCastle errors */ - private static PGPPublicKey findPublicKeyInPubring(Path pubringFile, + private static BouncyCastleGpgPublicKey findPublicKeyInPubring( + Path pubringFile, String keyId, String keySpec) throws IOException, PGPException { try (InputStream in = newInputStream(pubringFile)) { PGPPublicKeyRingCollection pgpPub = new PGPPublicKeyRingCollection( new BufferedInputStream(in), new JcaKeyFingerprintCalculator()); - String id = keyId != null ? keyId : toFingerprint(keySpec).toLowerCase(Locale.ROOT); Iterator<PGPPublicKeyRing> keyrings = pgpPub.getKeyRings(); + BouncyCastleGpgPublicKey candidate = null; while (keyrings.hasNext()) { PGPPublicKeyRing keyRing = keyrings.next(); - Iterator<PGPPublicKey> keys = keyRing.getPublicKeys(); - while (keys.hasNext()) { - PGPPublicKey key = keys.next(); - // try key id - String fingerprint = Hex.toHexString(key.getFingerprint()) - .toLowerCase(Locale.ROOT); - if (fingerprint.endsWith(id)) { - return key; - } - // try user id - Iterator<String> userIDs = key.getUserIDs(); - while (userIDs.hasNext()) { - String userId = userIDs.next(); - if (containsSigningKey(userId, keySpec)) { - return key; - } + BouncyCastleGpgPublicKey newCandidate = findPublicKeyInPubring( + keyRing, id, keySpec); + if (newCandidate != null) { + if (newCandidate.isExactMatch()) { + return newCandidate; + } else if (candidate == null) { + candidate = newCandidate; } } } + return candidate; } catch (FileNotFoundException | NoSuchFileException e) { - // Ignore and return null + return null; + } + } + + private static BouncyCastleGpgPublicKey findPublicKeyInPubring( + PGPPublicKeyRing keyRing, String keyId, String keySpec) { + Iterator<PGPPublicKey> keys = keyRing.getPublicKeys(); + if (!keys.hasNext()) { + return null; + } + PGPPublicKey masterKey = keys.next(); + String fingerprint = Hex.toHexString(masterKey.getFingerprint()) + .toLowerCase(Locale.ROOT); + boolean masterFingerprintMatch = false; + boolean userIdMatch = false; + List<String> userIds = new ArrayList<>(); + masterKey.getUserIDs().forEachRemaining(userIds::add); + if (fingerprint.endsWith(keyId)) { + masterFingerprintMatch = true; + } else { + // Check the user IDs + for (String userId : userIds) { + if (containsSigningKey(userId, keySpec)) { + userIdMatch = true; + break; + } + } + } + if (masterFingerprintMatch) { + if (isSigningKey(masterKey)) { + return new BouncyCastleGpgPublicKey(masterKey, true, userIds); + } + } + // Check subkeys -- they have no user ids, so only check for a + // fingerprint match (unless the master key matched). + PGPPublicKey candidate = null; + while (keys.hasNext()) { + PGPPublicKey subKey = keys.next(); + if (!isSigningKey(subKey)) { + continue; + } + if (masterFingerprintMatch) { + candidate = subKey; + break; + } + fingerprint = Hex.toHexString(subKey.getFingerprint()) + .toLowerCase(Locale.ROOT); + if (fingerprint.endsWith(keyId)) { + return new BouncyCastleGpgPublicKey(subKey, true, userIds); + } + if (candidate == null) { + candidate = subKey; + } + } + if (candidate != null && (masterFingerprintMatch || userIdMatch)) { + return new BouncyCastleGpgPublicKey(candidate, false, userIds); } return null; } diff --git a/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgPublicKey.java b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgPublicKey.java new file mode 100644 index 0000000000..d736536fd7 --- /dev/null +++ b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgPublicKey.java @@ -0,0 +1,36 @@ +package org.eclipse.jgit.gpg.bc.internal; + +import java.util.List; + +import org.bouncycastle.openpgp.PGPPublicKey; + +/** + * Container for GPG public keys. + */ +class BouncyCastleGpgPublicKey { + + private final PGPPublicKey publicKey; + + private final boolean exactMatch; + + private final List<String> userIds; + + BouncyCastleGpgPublicKey(PGPPublicKey publicKey, boolean exactMatch, + List<String> userIds) { + this.publicKey = publicKey; + this.exactMatch = exactMatch; + this.userIds = userIds; + } + + PGPPublicKey getPublicKey() { + return publicKey; + } + + boolean isExactMatch() { + return exactMatch; + } + + List<String> getUserIds() { + return userIds; + } +} diff --git a/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgSignatureVerifier.java b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgSignatureVerifier.java index f4fed40973..3378bb3969 100644 --- a/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgSignatureVerifier.java +++ b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/BouncyCastleGpgSignatureVerifier.java @@ -16,7 +16,7 @@ import java.security.Security; import java.text.MessageFormat; import java.time.Instant; import java.util.Date; -import java.util.Iterator; +import java.util.List; import java.util.Locale; import org.bouncycastle.bcpg.sig.IssuerFingerprint; @@ -121,7 +121,7 @@ public class BouncyCastleGpgSignatureVerifier } else { throw new JGitInternalException(BCText.get().nonSignatureError); } - } catch (PGPException e) { + } catch (NumberFormatException | PGPException e) { throw new JGitInternalException(BCText.get().signatureParseError, e); } @@ -134,7 +134,7 @@ public class BouncyCastleGpgSignatureVerifier if (fingerprint != null && keyId != null && !fingerprint.endsWith(keyId)) { return new VerificationResult(signatureCreatedAt, signer, fingerprint, - null, false, false, TrustLevel.UNKNOWN, + signer, false, false, TrustLevel.UNKNOWN, MessageFormat.format(BCText.get().signatureInconsistent, keyId, fingerprint)); } @@ -144,18 +144,18 @@ public class BouncyCastleGpgSignatureVerifier // Try to find the public key String keySpec = '<' + signer + '>'; Object cached = null; - PGPPublicKey publicKey = null; + BouncyCastleGpgPublicKey publicKey = null; try { cached = byFingerprint.get(fingerprint); if (cached != null) { - if (cached instanceof PGPPublicKey) { - publicKey = (PGPPublicKey) cached; + if (cached instanceof BouncyCastleGpgPublicKey) { + publicKey = (BouncyCastleGpgPublicKey) cached; } } else if (!StringUtils.isEmptyOrNull(signer)) { cached = bySigner.get(signer); if (cached != null) { - if (cached instanceof PGPPublicKey) { - publicKey = (PGPPublicKey) cached; + if (cached instanceof BouncyCastleGpgPublicKey) { + publicKey = (BouncyCastleGpgPublicKey) cached; } } } @@ -176,9 +176,17 @@ public class BouncyCastleGpgSignatureVerifier } } return new VerificationResult(signatureCreatedAt, signer, - fingerprint, null, false, false, TrustLevel.UNKNOWN, + fingerprint, signer, false, false, TrustLevel.UNKNOWN, BCText.get().signatureNoPublicKey); } + if (fingerprint != null && !publicKey.isExactMatch()) { + // We did find _some_ signing key for the signer, but it doesn't + // match the given fingerprint. + return new VerificationResult(signatureCreatedAt, signer, + fingerprint, signer, false, false, TrustLevel.UNKNOWN, + MessageFormat.format(BCText.get().signatureNoSigningKey, + fingerprint)); + } if (cached == null) { byFingerprint.put(fingerprint, publicKey); byFingerprint.put(keyId, publicKey); @@ -187,27 +195,28 @@ public class BouncyCastleGpgSignatureVerifier } } String user = null; - Iterator<String> userIds = publicKey.getUserIDs(); - if (!StringUtils.isEmptyOrNull(signer)) { - while (userIds.hasNext()) { - String userId = userIds.next(); - if (BouncyCastleGpgKeyLocator.containsSigningKey(userId, - keySpec)) { - user = userId; - break; + List<String> userIds = publicKey.getUserIds(); + if (userIds != null && !userIds.isEmpty()) { + if (!StringUtils.isEmptyOrNull(signer)) { + for (String userId : publicKey.getUserIds()) { + if (BouncyCastleGpgKeyLocator.containsSigningKey(userId, + keySpec)) { + user = userId; + break; + } } } - } - if (user == null) { - userIds = publicKey.getUserIDs(); - if (userIds.hasNext()) { - user = userIds.next(); + if (user == null) { + user = userIds.get(0); } + } else if (signer != null) { + user = signer; } + PGPPublicKey pubKey = publicKey.getPublicKey(); boolean expired = false; - long validFor = publicKey.getValidSeconds(); + long validFor = pubKey.getValidSeconds(); if (validFor > 0 && signatureCreatedAt != null) { - Instant expiredAt = publicKey.getCreationTime().toInstant() + Instant expiredAt = pubKey.getCreationTime().toInstant() .plusSeconds(validFor); expired = expiredAt.isBefore(signatureCreatedAt.toInstant()); } @@ -215,14 +224,14 @@ public class BouncyCastleGpgSignatureVerifier // specific. We don't use the GPG trustdb but simply the trust packet // on the public key, if present. Even if present, it may or may not // be set. - byte[] trustData = publicKey.getTrustData(); + byte[] trustData = pubKey.getTrustData(); TrustLevel trust = parseGpgTrustPacket(trustData); boolean verified = false; try { signature.init( new JcaPGPContentVerifierBuilderProvider() .setProvider(BouncyCastleProvider.PROVIDER_NAME), - publicKey); + pubKey); signature.update(data); verified = signature.verify(); } catch (PGPException e) { diff --git a/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/keys/KeyGrip.java b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/keys/KeyGrip.java index 3eee18aef5..9b5d592fa8 100644 --- a/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/keys/KeyGrip.java +++ b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/keys/KeyGrip.java @@ -43,17 +43,6 @@ import org.eclipse.jgit.util.sha1.SHA1; */ public final class KeyGrip { - // Some OIDs apparently unknown to BouncyCastle. - - private static String OID_OPENPGP_ED25519 = "1.3.6.1.4.1.11591.15.1"; //$NON-NLS-1$ - - private static String OID_RFC8410_CURVE25519 = "1.3.101.110"; //$NON-NLS-1$ - - private static String OID_RFC8410_ED25519 = "1.3.101.112"; //$NON-NLS-1$ - - private static ASN1ObjectIdentifier CURVE25519 = ECNamedCurveTable - .getOID("curve25519"); //$NON-NLS-1$ - private KeyGrip() { // No instantiation } @@ -99,20 +88,15 @@ public final class KeyGrip { break; case PublicKeyAlgorithmTags.ECDH: case PublicKeyAlgorithmTags.ECDSA: - case PublicKeyAlgorithmTags.EDDSA: + case PublicKeyAlgorithmTags.EDDSA_LEGACY: + case PublicKeyAlgorithmTags.Ed25519: ECPublicBCPGKey ec = (ECPublicBCPGKey) publicKey .getPublicKeyPacket().getKey(); ASN1ObjectIdentifier curveOID = ec.getCurveOID(); // BC doesn't know these OIDs. - if (OID_OPENPGP_ED25519.equals(curveOID.getId()) - || OID_RFC8410_ED25519.equals(curveOID.getId())) { + if (ObjectIds.isEd25519(curveOID)) { return hashEd25519(grip, ec.getEncodedPoint()); - } else if (CURVE25519.equals(curveOID) - || OID_RFC8410_CURVE25519.equals(curveOID.getId())) { - // curvey25519 actually is the OpenPGP OID for Curve25519 and is - // known to BC, but the parameters are for the short Weierstrass - // form. See https://github.com/bcgit/bc-java/issues/399 . - // libgcrypt uses Montgomery form. + } else if (ObjectIds.isCurve25519(curveOID)) { return hashCurve25519(grip, ec.getEncodedPoint()); } X9ECParameters params = getX9Parameters(curveOID); @@ -141,7 +125,9 @@ public final class KeyGrip { hash(grip, b.toByteArray(), 'b', false); hash(grip, g, 'g', false); hash(grip, n.toByteArray(), 'n', false); - if (publicKey.getAlgorithm() == PublicKeyAlgorithmTags.EDDSA) { + int algorithm = publicKey.getAlgorithm(); + if (algorithm == PublicKeyAlgorithmTags.EDDSA_LEGACY + || algorithm == PublicKeyAlgorithmTags.Ed25519) { hashQ25519(grip, q); } else { hash(grip, q.toByteArray(), 'q', false); diff --git a/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/keys/ObjectIds.java b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/keys/ObjectIds.java new file mode 100644 index 0000000000..3d3098158a --- /dev/null +++ b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/keys/ObjectIds.java @@ -0,0 +1,109 @@ +/* + * Copyright (C) 2024, Thomas Wolf <twolf@apache.org> and others + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Distribution License v. 1.0 which is available at + * https://www.eclipse.org/org/documents/edl-v10.php. + * + * SPDX-License-Identifier: BSD-3-Clause + */ +package org.eclipse.jgit.gpg.bc.internal.keys; + +import org.bouncycastle.asn1.ASN1ObjectIdentifier; +import org.bouncycastle.asn1.x9.ECNamedCurveTable; + +/** + * Some OIDs apparently unknown to Bouncy Castle. + */ +public final class ObjectIds { + + /** + * Legacy OID for ed25519 used in OpenPGP. + */ + public static final ASN1ObjectIdentifier OID_OPENPGP_ED25519 = + new ASN1ObjectIdentifier("1.3.6.1.4.1.11591.15.1"); //$NON-NLS-1$ + + /** + * OID for ed25519 according to RFC 8410. + */ + public static final ASN1ObjectIdentifier OID_RFC8410_ED25519 = + new ASN1ObjectIdentifier("1.3.101.112"); //$NON-NLS-1$ + + /** + * Legacy OID for curve25519 used in OpenPGP. + */ + public static final ASN1ObjectIdentifier OID_OPENPGP_CURVE25519 = + ECNamedCurveTable.getOID("curve25519"); //$NON-NLS-1$ + // This is 1.3.6.1.4.1.3029.1.5.1 + + /** + * OID for curve25519 according to RFC 8410. + */ + public static final ASN1ObjectIdentifier OID_RFC8410_CURVE25519 = new ASN1ObjectIdentifier( + "1.3.101.110"); //$NON-NLS-1$ + + /** + * Determines whether the given {@code oid} denoted ed25519. + * + * @param oid + * to test + * @return {@code true} if it is ed25519, {@code false} otherwise + */ + public static boolean isEd25519(ASN1ObjectIdentifier oid) { + return OID_OPENPGP_ED25519.equals(oid) + || OID_RFC8410_ED25519.equals(oid); + } + + /** + * Determines whether the given {@code oid} denoted curve25519. + * + * @param oid + * to test + * @return {@code true} if it is curve25519, {@code false} otherwise + */ + public static boolean isCurve25519(ASN1ObjectIdentifier oid) { + return OID_RFC8410_CURVE25519.equals(oid) + || OID_OPENPGP_CURVE25519.equals(oid); + } + + /** + * Retrieves an OID by name. + * + * @param name + * to get the OID for + * @return the OID, or {@code null} if unknown. + */ + public static ASN1ObjectIdentifier getByName(String name) { + if (name != null) { + switch (name) { + case "Ed25519": //$NON-NLS-1$ + return OID_OPENPGP_ED25519; + case "Curve25519": //$NON-NLS-1$ + return OID_OPENPGP_CURVE25519; + default: + break; + } + } + return null; + } + + /** + * Checks whether two OIDs denote the same algorithm. + * + * @param oid1 + * First OID to test + * @param oid2 + * Second OID to test + * @return {@code true} if the two OIDs match, {@code false} otherwise + */ + public static boolean match(ASN1ObjectIdentifier oid1, + ASN1ObjectIdentifier oid2) { + if (isEd25519(oid1)) { + return isEd25519(oid2); + } + if (isCurve25519(oid1)) { + return isCurve25519(oid2); + } + return oid1 != null && oid1.equals(oid2); + } +} diff --git a/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/keys/SExprParser.java b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/keys/SExprParser.java index c93c2164c9..fd030ee032 100644 --- a/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/keys/SExprParser.java +++ b/org.eclipse.jgit.gpg.bc/src/org/eclipse/jgit/gpg/bc/internal/keys/SExprParser.java @@ -30,6 +30,7 @@ import java.io.OutputStream; import java.math.BigInteger; import java.util.Date; +import org.bouncycastle.asn1.ASN1ObjectIdentifier; import org.bouncycastle.asn1.x9.ECNamedCurveTable; import org.bouncycastle.bcpg.DSAPublicBCPGKey; import org.bouncycastle.bcpg.DSASecretBCPGKey; @@ -62,9 +63,12 @@ import org.bouncycastle.util.Strings; * modified by the JGit team to: * <ul> * <li>handle unencrypted DSA, EC, and ElGamal keys (upstream only handles - * unencrypted RSA), and</li> + * unencrypted RSA)</li> * <li>handle secret keys using AES/OCB as encryption (those don't have a - * hash).</li> + * hash)</li> + * <li>fix EC parsing to account for "flags" sub-list present for ed25519 and + * curve25519</li> + * <li>add support for ed25519 OIDs unknown to BouncyCastle</li> * </ul> */ @SuppressWarnings("nls") @@ -128,6 +132,15 @@ public class SExprParser { SXprUtils.skipOpenParenthesis(inputStream); type = SXprUtils.readString(inputStream, inputStream.read()); + // JGit: c.f. https://github.com/bcgit/bc-java/issues/1590. + // There may be a flags sub-list here for ed25519 or curve25519. + if (type.equals("flags")) { + SXprUtils.readString(inputStream, inputStream.read()); + SXprUtils.skipCloseParenthesis(inputStream); + SXprUtils.skipOpenParenthesis(inputStream); + type = SXprUtils.readString(inputStream, + inputStream.read()); + } if (type.equals("q")) { qVal = SXprUtils.readBytes(inputStream, inputStream.read()); } else { @@ -143,12 +156,19 @@ public class SExprParser { curveName = curveName.substring("NIST ".length()); } + // JGit: BC doesn't know Ed25519 curve name. + ASN1ObjectIdentifier curveOid = ECNamedCurveTable + .getOID(curveName); + if (curveOid == null) { + curveOid = ObjectIds.getByName(curveName); + } ECPublicBCPGKey basePubKey = new ECDSAPublicBCPGKey( - ECNamedCurveTable.getOID(curveName), + curveOid, new BigInteger(1, qVal)); ECPublicBCPGKey assocPubKey = (ECPublicBCPGKey) pubKey .getPublicKeyPacket().getKey(); - if (!basePubKey.getCurveOID().equals(assocPubKey.getCurveOID()) + if (!ObjectIds.match(basePubKey.getCurveOID(), + assocPubKey.getCurveOID()) || !basePubKey.getEncodedPoint() .equals(assocPubKey.getEncodedPoint())) { throw new PGPException( @@ -292,6 +312,15 @@ public class SExprParser { SXprUtils.skipOpenParenthesis(inputStream); type = SXprUtils.readString(inputStream, inputStream.read()); + // JGit: c.f. https://github.com/bcgit/bc-java/issues/1590. + // There may be a flags sub-list here for ed25519 or curve25519. + if (type.equals("flags")) { + SXprUtils.readString(inputStream, inputStream.read()); + SXprUtils.skipCloseParenthesis(inputStream); + SXprUtils.skipOpenParenthesis(inputStream); + type = SXprUtils.readString(inputStream, + inputStream.read()); + } if (type.equals("q")) { qVal = SXprUtils.readBytes(inputStream, inputStream.read()); } else { diff --git a/org.eclipse.jgit.http.apache/META-INF/MANIFEST.MF b/org.eclipse.jgit.http.apache/META-INF/MANIFEST.MF index 82e6a04501..87a048aaef 100644 --- a/org.eclipse.jgit.http.apache/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.http.apache/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.http.apache Bundle-SymbolicName: org.eclipse.jgit.http.apache -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-RequiredExecutionEnvironment: JavaSE-11 Bundle-Localization: OSGI-INF/l10n/plugin Bundle-Vendor: %Bundle-Vendor @@ -26,11 +26,11 @@ Import-Package: javax.net.ssl, org.apache.http.impl.conn;version="[4.4.0,5.0.0)", org.apache.http.params;version="[4.3.0,5.0.0)", org.apache.http.ssl;version="[4.3.0,5.0.0)", - org.eclipse.jgit.annotations;version="[6.9.1,6.10.0)", - org.eclipse.jgit.nls;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.http;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)" -Export-Package: org.eclipse.jgit.transport.http.apache;version="6.9.1"; + org.eclipse.jgit.annotations;version="[6.10.1,6.11.0)", + org.eclipse.jgit.nls;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.http;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)" +Export-Package: org.eclipse.jgit.transport.http.apache;version="6.10.1"; uses:="org.apache.http.client, org.eclipse.jgit.transport.http, org.apache.http.entity, diff --git a/org.eclipse.jgit.http.apache/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.http.apache/META-INF/SOURCE-MANIFEST.MF index db19ed10f2..040228c154 100644 --- a/org.eclipse.jgit.http.apache/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.http.apache/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.http.apache - Sources Bundle-SymbolicName: org.eclipse.jgit.http.apache.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.http.apache;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.http.apache;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.http.apache/pom.xml b/org.eclipse.jgit.http.apache/pom.xml index 0353fdf584..d3919bc164 100644 --- a/org.eclipse.jgit.http.apache/pom.xml +++ b/org.eclipse.jgit.http.apache/pom.xml @@ -15,7 +15,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.http.apache</artifactId> diff --git a/org.eclipse.jgit.http.apache/src/org/eclipse/jgit/transport/http/apache/HttpClientConnection.java b/org.eclipse.jgit.http.apache/src/org/eclipse/jgit/transport/http/apache/HttpClientConnection.java index 6d806dee37..0cb6fe10d0 100644 --- a/org.eclipse.jgit.http.apache/src/org/eclipse/jgit/transport/http/apache/HttpClientConnection.java +++ b/org.eclipse.jgit.http.apache/src/org/eclipse/jgit/transport/http/apache/HttpClientConnection.java @@ -25,10 +25,10 @@ import java.net.URL; import java.security.KeyManagementException; import java.security.NoSuchAlgorithmException; import java.security.SecureRandom; +import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; import java.util.HashMap; -import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.stream.Collectors; @@ -300,7 +300,7 @@ public class HttpClientConnection implements HttpConnection { for (Header hdr : resp.getAllHeaders()) { List<String> list = ret.get(hdr.getName()); if (list == null) { - list = new LinkedList<>(); + list = new ArrayList<>(); ret.put(hdr.getName(), list); } for (HeaderElement hdrElem : hdr.getElements()) { diff --git a/org.eclipse.jgit.http.server/META-INF/MANIFEST.MF b/org.eclipse.jgit.http.server/META-INF/MANIFEST.MF index fb8e105c7c..d3b4221d2d 100644 --- a/org.eclipse.jgit.http.server/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.http.server/META-INF/MANIFEST.MF @@ -3,13 +3,13 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.http.server Bundle-SymbolicName: org.eclipse.jgit.http.server -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Localization: OSGI-INF/l10n/plugin Bundle-Vendor: %Bundle-Vendor -Export-Package: org.eclipse.jgit.http.server;version="6.9.1", - org.eclipse.jgit.http.server.glue;version="6.9.1"; +Export-Package: org.eclipse.jgit.http.server;version="6.10.1", + org.eclipse.jgit.http.server.glue;version="6.10.1"; uses:="javax.servlet,javax.servlet.http", - org.eclipse.jgit.http.server.resolver;version="6.9.1"; + org.eclipse.jgit.http.server.resolver;version="6.10.1"; uses:="org.eclipse.jgit.transport.resolver, org.eclipse.jgit.lib, org.eclipse.jgit.transport, @@ -18,14 +18,14 @@ Bundle-ActivationPolicy: lazy Bundle-RequiredExecutionEnvironment: JavaSE-11 Import-Package: javax.servlet;version="[2.5.0,5.0.0)", javax.servlet.http;version="[2.5.0,5.0.0)", - org.eclipse.jgit.annotations;version="[6.9.1,6.10.0)", - org.eclipse.jgit.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.dfs;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.transport.parser;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.nls;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.resolver;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)" + org.eclipse.jgit.annotations;version="[6.10.1,6.11.0)", + org.eclipse.jgit.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.dfs;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.transport.parser;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.nls;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.resolver;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)" diff --git a/org.eclipse.jgit.http.server/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.http.server/META-INF/SOURCE-MANIFEST.MF index b765631480..498a3631ea 100644 --- a/org.eclipse.jgit.http.server/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.http.server/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.http.server - Sources Bundle-SymbolicName: org.eclipse.jgit.http.server.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.http.server;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.http.server;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.http.server/pom.xml b/org.eclipse.jgit.http.server/pom.xml index 363729245f..dc176f566e 100644 --- a/org.eclipse.jgit.http.server/pom.xml +++ b/org.eclipse.jgit.http.server/pom.xml @@ -19,7 +19,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.http.server</artifactId> diff --git a/org.eclipse.jgit.http.server/src/org/eclipse/jgit/http/server/GitFilter.java b/org.eclipse.jgit.http.server/src/org/eclipse/jgit/http/server/GitFilter.java index 2f3eee41d6..703c0be8d9 100644 --- a/org.eclipse.jgit.http.server/src/org/eclipse/jgit/http/server/GitFilter.java +++ b/org.eclipse.jgit.http.server/src/org/eclipse/jgit/http/server/GitFilter.java @@ -12,7 +12,7 @@ package org.eclipse.jgit.http.server; import java.io.File; import java.text.MessageFormat; -import java.util.LinkedList; +import java.util.ArrayList; import java.util.List; import javax.servlet.Filter; @@ -65,9 +65,9 @@ public class GitFilter extends MetaFilter { private ReceivePackErrorHandler receivePackErrorHandler; - private final List<Filter> uploadPackFilters = new LinkedList<>(); + private final List<Filter> uploadPackFilters = new ArrayList<>(); - private final List<Filter> receivePackFilters = new LinkedList<>(); + private final List<Filter> receivePackFilters = new ArrayList<>(); /** * New servlet that will load its base directory from {@code web.xml}. diff --git a/org.eclipse.jgit.http.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.http.test/META-INF/MANIFEST.MF index cc84aac3e9..4ade09a139 100644 --- a/org.eclipse.jgit.http.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.http.test/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.http.test Bundle-SymbolicName: org.eclipse.jgit.http.test -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -28,26 +28,26 @@ Import-Package: javax.servlet;version="[2.5.0,5.0.0)", org.eclipse.jetty.util.log;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.security;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.thread;version="[10.0.0,11.0.0)", - org.eclipse.jgit.api;version="[6.9.1,6.10.0)", - org.eclipse.jgit.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.http.server;version="[6.9.1,6.10.0)", - org.eclipse.jgit.http.server.glue;version="[6.9.1,6.10.0)", - org.eclipse.jgit.http.server.resolver;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.dfs;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.reftable;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit.http;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.nls;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.http;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.http.apache;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.resolver;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", + org.eclipse.jgit.api;version="[6.10.1,6.11.0)", + org.eclipse.jgit.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.http.server;version="[6.10.1,6.11.0)", + org.eclipse.jgit.http.server.glue;version="[6.10.1,6.11.0)", + org.eclipse.jgit.http.server.resolver;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.dfs;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.reftable;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit.http;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.nls;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.http;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.http.apache;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.resolver;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", org.junit;version="[4.13,5.0.0)", org.junit.rules;version="[4.13,5.0.0)", org.junit.runner;version="[4.13,5.0.0)", diff --git a/org.eclipse.jgit.http.test/pom.xml b/org.eclipse.jgit.http.test/pom.xml index eba5578be1..62b1a2125f 100644 --- a/org.eclipse.jgit.http.test/pom.xml +++ b/org.eclipse.jgit.http.test/pom.xml @@ -18,7 +18,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.http.test</artifactId> diff --git a/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/FileResolverTest.java b/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/FileResolverTest.java index 8d25c2e395..34c871ab06 100644 --- a/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/FileResolverTest.java +++ b/org.eclipse.jgit.http.test/tst/org/eclipse/jgit/http/test/FileResolverTest.java @@ -88,7 +88,7 @@ public class FileResolverTest extends LocalDiskRepositoryTestCase { try { resolver.open(null, name).close(); } catch (ServiceNotEnabledException e) { - fail("did not honor export-all flag"); + throw new AssertionError("did not honor export-all flag", e); } FileUtils.createNewFile(export); @@ -99,7 +99,7 @@ public class FileResolverTest extends LocalDiskRepositoryTestCase { try { resolver.open(null, name).close(); } catch (ServiceNotEnabledException e) { - fail("did not honor git-daemon-export-ok"); + throw new AssertionError("did not honor git-daemon-export-ok", e); } } diff --git a/org.eclipse.jgit.junit.http/META-INF/MANIFEST.MF b/org.eclipse.jgit.junit.http/META-INF/MANIFEST.MF index 533f170998..26fdf64132 100644 --- a/org.eclipse.jgit.junit.http/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.junit.http/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.junit.http Bundle-SymbolicName: org.eclipse.jgit.junit.http -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Localization: OSGI-INF/l10n/plugin Bundle-Vendor: %Bundle-Vendor Bundle-ActivationPolicy: lazy @@ -21,17 +21,17 @@ Import-Package: javax.servlet;version="[2.5.0,5.0.0)", org.eclipse.jetty.util.log;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.security;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.ssl;version="[10.0.0,11.0.0)", - org.eclipse.jgit.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.http.server;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.resolver;version="[6.9.1,6.10.0)", + org.eclipse.jgit.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.http.server;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.resolver;version="[6.10.1,6.11.0)", org.junit;version="[4.13,5.0.0)", org.slf4j.helpers;version="[1.7.0,3.0.0)" -Export-Package: org.eclipse.jgit.junit.http;version="6.9.1"; +Export-Package: org.eclipse.jgit.junit.http;version="6.10.1"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.junit, javax.servlet.http, diff --git a/org.eclipse.jgit.junit.http/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.junit.http/META-INF/SOURCE-MANIFEST.MF index 2da45670c1..be7b8d7d00 100644 --- a/org.eclipse.jgit.junit.http/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.junit.http/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.junit.http - Sources Bundle-SymbolicName: org.eclipse.jgit.junit.http.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.junit.http;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.junit.http;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.junit.http/pom.xml b/org.eclipse.jgit.junit.http/pom.xml index e6206e27df..87395f29e9 100644 --- a/org.eclipse.jgit.junit.http/pom.xml +++ b/org.eclipse.jgit.junit.http/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.junit.http</artifactId> diff --git a/org.eclipse.jgit.junit.ssh/META-INF/MANIFEST.MF b/org.eclipse.jgit.junit.ssh/META-INF/MANIFEST.MF index e7f8972144..e704f2cecf 100644 --- a/org.eclipse.jgit.junit.ssh/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.junit.ssh/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.junit.ssh Bundle-SymbolicName: org.eclipse.jgit.junit.ssh -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Localization: OSGI-INF/l10n/plugin Bundle-Vendor: %Bundle-Vendor Bundle-ActivationPolicy: lazy @@ -33,16 +33,16 @@ Import-Package: org.apache.sshd.common;version="[2.12.0,2.13.0)", org.apache.sshd.server.subsystem;version="[2.12.0,2.13.0)", org.apache.sshd.sftp;version="[2.12.0,2.13.0)", org.apache.sshd.sftp.server;version="[2.12.0,2.13.0)", - org.eclipse.jgit.annotations;version="[6.9.1,6.10.0)", - org.eclipse.jgit.api;version="[6.9.1,6.10.0)", - org.eclipse.jgit.api.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", + org.eclipse.jgit.annotations;version="[6.10.1,6.11.0)", + org.eclipse.jgit.api;version="[6.10.1,6.11.0)", + org.eclipse.jgit.api.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", org.junit;version="[4.13,5.0.0)", org.junit.experimental.theories;version="[4.13,5.0.0)", org.slf4j;version="[1.7.0,3.0.0)" -Export-Package: org.eclipse.jgit.junit.ssh;version="6.9.1" +Export-Package: org.eclipse.jgit.junit.ssh;version="6.10.1" diff --git a/org.eclipse.jgit.junit.ssh/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.junit.ssh/META-INF/SOURCE-MANIFEST.MF index 24e31eb856..fd28dfdacd 100644 --- a/org.eclipse.jgit.junit.ssh/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.junit.ssh/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.junit.ssh - Sources Bundle-SymbolicName: org.eclipse.jgit.junit.ssh.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.junit.ssh;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.junit.ssh;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.junit.ssh/pom.xml b/org.eclipse.jgit.junit.ssh/pom.xml index 7cf78c355b..d4c79b9a86 100644 --- a/org.eclipse.jgit.junit.ssh/pom.xml +++ b/org.eclipse.jgit.junit.ssh/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.junit.ssh</artifactId> diff --git a/org.eclipse.jgit.junit.ssh/src/org/eclipse/jgit/junit/ssh/SshTestGitServer.java b/org.eclipse.jgit.junit.ssh/src/org/eclipse/jgit/junit/ssh/SshTestGitServer.java index 1138be8a96..f5627e00c8 100644 --- a/org.eclipse.jgit.junit.ssh/src/org/eclipse/jgit/junit/ssh/SshTestGitServer.java +++ b/org.eclipse.jgit.junit.ssh/src/org/eclipse/jgit/junit/ssh/SshTestGitServer.java @@ -323,7 +323,7 @@ public class SshTestGitServer { server.setFileSystemFactory(new VirtualFileSystemFactory(repository .getDirectory().getParentFile().getAbsoluteFile().toPath())); return Collections - .singletonList((new SftpSubsystemFactory.Builder()).build()); + .singletonList(new SftpSubsystemFactory.Builder().build()); } /** diff --git a/org.eclipse.jgit.junit/META-INF/MANIFEST.MF b/org.eclipse.jgit.junit/META-INF/MANIFEST.MF index bd8746096f..f0176f05e5 100644 --- a/org.eclipse.jgit.junit/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.junit/META-INF/MANIFEST.MF @@ -3,36 +3,36 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.junit Bundle-SymbolicName: org.eclipse.jgit.junit -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Localization: OSGI-INF/l10n/plugin Bundle-Vendor: %Bundle-Vendor Bundle-ActivationPolicy: lazy Bundle-RequiredExecutionEnvironment: JavaSE-11 -Import-Package: org.eclipse.jgit.annotations;version="[6.9.1,6.10.0)", - org.eclipse.jgit.api;version="[6.9.1,6.10.0)", - org.eclipse.jgit.api.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.dircache;version="[6.9.1,6.10.0)", - org.eclipse.jgit.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.pack;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.util;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.merge;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="6.9.1", - org.eclipse.jgit.treewalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.treewalk.filter;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util.io;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util.time;version="[6.9.1,6.10.0)", +Import-Package: org.eclipse.jgit.annotations;version="[6.10.1,6.11.0)", + org.eclipse.jgit.api;version="[6.10.1,6.11.0)", + org.eclipse.jgit.api.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.dircache;version="[6.10.1,6.11.0)", + org.eclipse.jgit.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.pack;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.util;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.merge;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="6.10.1", + org.eclipse.jgit.treewalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.treewalk.filter;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util.io;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util.time;version="[6.10.1,6.11.0)", org.junit;version="[4.13,5.0.0)", org.junit.rules;version="[4.13,5.0.0)", org.junit.runner;version="[4.13,5.0.0)", org.junit.runners;version="[4.13,5.0.0)", org.junit.runners.model;version="[4.13,5.0.0)", org.slf4j;version="[1.7.0,3.0.0)" -Export-Package: org.eclipse.jgit.junit;version="6.9.1"; +Export-Package: org.eclipse.jgit.junit;version="6.10.1"; uses:="org.eclipse.jgit.dircache, org.eclipse.jgit.lib, org.eclipse.jgit.revwalk, @@ -45,4 +45,4 @@ Export-Package: org.eclipse.jgit.junit;version="6.9.1"; org.junit.runners.model, org.junit.runner, org.eclipse.jgit.util.time", - org.eclipse.jgit.junit.time;version="6.9.1";uses:="org.eclipse.jgit.util.time" + org.eclipse.jgit.junit.time;version="6.10.1";uses:="org.eclipse.jgit.util.time" diff --git a/org.eclipse.jgit.junit/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.junit/META-INF/SOURCE-MANIFEST.MF index 52fc544258..e9704a08f8 100644 --- a/org.eclipse.jgit.junit/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.junit/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.junit - Sources Bundle-SymbolicName: org.eclipse.jgit.junit.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.junit;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.junit;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.junit/pom.xml b/org.eclipse.jgit.junit/pom.xml index 1638238a86..12070f7353 100644 --- a/org.eclipse.jgit.junit/pom.xml +++ b/org.eclipse.jgit.junit/pom.xml @@ -19,7 +19,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.junit</artifactId> diff --git a/org.eclipse.jgit.lfs.server.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.lfs.server.test/META-INF/MANIFEST.MF index 266d9bb3e1..4240d6009d 100644 --- a/org.eclipse.jgit.lfs.server.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.lfs.server.test/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.lfs.server.test Bundle-SymbolicName: org.eclipse.jgit.lfs.server.test -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -26,24 +26,24 @@ Import-Package: javax.servlet;version="[3.1.0,5.0.0)", org.eclipse.jetty.util.log;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.security;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.thread;version="[10.0.0,11.0.0)", - org.eclipse.jgit.api;version="[6.9.1,6.10.0)", - org.eclipse.jgit.api.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit.http;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.server;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.server.fs;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.test;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.treewalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.treewalk.filter;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", + org.eclipse.jgit.api;version="[6.10.1,6.11.0)", + org.eclipse.jgit.api.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit.http;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.server;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.server.fs;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.test;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.treewalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.treewalk.filter;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", org.hamcrest.core;version="[1.1.0,3.0.0)", org.junit;version="[4.13,5.0.0)", org.junit.rules;version="[4.13,5.0.0)", diff --git a/org.eclipse.jgit.lfs.server.test/pom.xml b/org.eclipse.jgit.lfs.server.test/pom.xml index 53ee569769..8db851adae 100644 --- a/org.eclipse.jgit.lfs.server.test/pom.xml +++ b/org.eclipse.jgit.lfs.server.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.lfs.server.test</artifactId> diff --git a/org.eclipse.jgit.lfs.server/META-INF/MANIFEST.MF b/org.eclipse.jgit.lfs.server/META-INF/MANIFEST.MF index f3a5028458..827c39f108 100644 --- a/org.eclipse.jgit.lfs.server/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.lfs.server/META-INF/MANIFEST.MF @@ -3,19 +3,19 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.lfs.server Bundle-SymbolicName: org.eclipse.jgit.lfs.server -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Localization: OSGI-INF/l10n/plugin Bundle-Vendor: %Bundle-Vendor -Export-Package: org.eclipse.jgit.lfs.server;version="6.9.1"; +Export-Package: org.eclipse.jgit.lfs.server;version="6.10.1"; uses:="javax.servlet.http, org.eclipse.jgit.lfs.lib", - org.eclipse.jgit.lfs.server.fs;version="6.9.1"; + org.eclipse.jgit.lfs.server.fs;version="6.10.1"; uses:="javax.servlet, javax.servlet.http, org.eclipse.jgit.lfs.server, org.eclipse.jgit.lfs.lib", - org.eclipse.jgit.lfs.server.internal;version="6.9.1";x-internal:=true, - org.eclipse.jgit.lfs.server.s3;version="6.9.1"; + org.eclipse.jgit.lfs.server.internal;version="6.10.1";x-internal:=true, + org.eclipse.jgit.lfs.server.s3;version="6.10.1"; uses:="org.eclipse.jgit.lfs.server, org.eclipse.jgit.lfs.lib" Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -24,15 +24,15 @@ Import-Package: com.google.gson;version="[2.8.0,3.0.0)", javax.servlet.annotation;version="[3.1.0,5.0.0)", javax.servlet.http;version="[3.1.0,5.0.0)", org.apache.http;version="[4.3.0,5.0.0)", - org.eclipse.jgit.annotations;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.internal;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.nls;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.http;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.http.apache;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", + org.eclipse.jgit.annotations;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.internal;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.nls;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.http;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.http.apache;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", org.slf4j;version="[1.7.0,3.0.0)" diff --git a/org.eclipse.jgit.lfs.server/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.lfs.server/META-INF/SOURCE-MANIFEST.MF index 4a869dd85b..572e160b8a 100644 --- a/org.eclipse.jgit.lfs.server/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.lfs.server/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.lfs.server - Sources Bundle-SymbolicName: org.eclipse.jgit.lfs.server.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.lfs.server;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.lfs.server;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.lfs.server/pom.xml b/org.eclipse.jgit.lfs.server/pom.xml index b1eca71449..deb7b8fb1e 100644 --- a/org.eclipse.jgit.lfs.server/pom.xml +++ b/org.eclipse.jgit.lfs.server/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.lfs.server</artifactId> diff --git a/org.eclipse.jgit.lfs.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.lfs.test/META-INF/MANIFEST.MF index 4ea3ccbf78..45192f51dd 100644 --- a/org.eclipse.jgit.lfs.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.lfs.test/META-INF/MANIFEST.MF @@ -3,27 +3,27 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.lfs.test Bundle-SymbolicName: org.eclipse.jgit.lfs.test -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 -Import-Package: org.eclipse.jgit.api;version="[6.9.1,6.10.0)", - org.eclipse.jgit.attributes;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.dfs;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.internal;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.http;version="[6.9.1,6.10.0)", - org.eclipse.jgit.treewalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.treewalk.filter;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", +Import-Package: org.eclipse.jgit.api;version="[6.10.1,6.11.0)", + org.eclipse.jgit.attributes;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.dfs;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.internal;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.http;version="[6.10.1,6.11.0)", + org.eclipse.jgit.treewalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.treewalk.filter;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", org.hamcrest.core;version="[1.1.0,3.0.0)", org.junit;version="[4.13,5.0.0)", org.junit.runner;version="[4.13,5.0.0)", org.junit.runners;version="[4.13,5.0.0)" -Export-Package: org.eclipse.jgit.lfs.test;version="6.9.1";x-friends:="org.eclipse.jgit.lfs.server.test" +Export-Package: org.eclipse.jgit.lfs.test;version="6.10.1";x-friends:="org.eclipse.jgit.lfs.server.test" diff --git a/org.eclipse.jgit.lfs.test/pom.xml b/org.eclipse.jgit.lfs.test/pom.xml index 667335a517..1ad7c94e70 100644 --- a/org.eclipse.jgit.lfs.test/pom.xml +++ b/org.eclipse.jgit.lfs.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.lfs.test</artifactId> diff --git a/org.eclipse.jgit.lfs/META-INF/MANIFEST.MF b/org.eclipse.jgit.lfs/META-INF/MANIFEST.MF index 442a87ccd8..3e092099f0 100644 --- a/org.eclipse.jgit.lfs/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.lfs/META-INF/MANIFEST.MF @@ -3,32 +3,32 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.lfs Bundle-SymbolicName: org.eclipse.jgit.lfs -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Localization: OSGI-INF/l10n/plugin Bundle-Vendor: %Bundle-Vendor -Export-Package: org.eclipse.jgit.lfs;version="6.9.1", - org.eclipse.jgit.lfs.errors;version="6.9.1", - org.eclipse.jgit.lfs.internal;version="6.9.1";x-friends:="org.eclipse.jgit.lfs.test,org.eclipse.jgit.lfs.server.fs,org.eclipse.jgit.lfs.server", - org.eclipse.jgit.lfs.lib;version="6.9.1" +Export-Package: org.eclipse.jgit.lfs;version="6.10.1", + org.eclipse.jgit.lfs.errors;version="6.10.1", + org.eclipse.jgit.lfs.internal;version="6.10.1";x-friends:="org.eclipse.jgit.lfs.test,org.eclipse.jgit.lfs.server.fs,org.eclipse.jgit.lfs.server", + org.eclipse.jgit.lfs.lib;version="6.10.1" Bundle-RequiredExecutionEnvironment: JavaSE-11 Import-Package: com.google.gson;version="[2.8.2,3.0.0)", com.google.gson.stream;version="[2.8.2,3.0.0)", - org.eclipse.jgit.annotations;version="[6.9.1,6.10.0)";resolution:=optional, - org.eclipse.jgit.api.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.attributes;version="[6.9.1,6.10.0)", - org.eclipse.jgit.diff;version="[6.9.1,6.10.0)", - org.eclipse.jgit.dircache;version="[6.9.1,6.10.0)", - org.eclipse.jgit.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.hooks;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.nls;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.storage.pack;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.http;version="[6.9.1,6.10.0)", - org.eclipse.jgit.treewalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.treewalk.filter;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util.io;version="[6.9.1,6.10.0)" + org.eclipse.jgit.annotations;version="[6.10.1,6.11.0)";resolution:=optional, + org.eclipse.jgit.api.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.attributes;version="[6.10.1,6.11.0)", + org.eclipse.jgit.diff;version="[6.10.1,6.11.0)", + org.eclipse.jgit.dircache;version="[6.10.1,6.11.0)", + org.eclipse.jgit.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.hooks;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.nls;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.storage.pack;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.http;version="[6.10.1,6.11.0)", + org.eclipse.jgit.treewalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.treewalk.filter;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util.io;version="[6.10.1,6.11.0)" diff --git a/org.eclipse.jgit.lfs/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.lfs/META-INF/SOURCE-MANIFEST.MF index ad93a57c17..f865468324 100644 --- a/org.eclipse.jgit.lfs/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.lfs/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.lfs - Sources Bundle-SymbolicName: org.eclipse.jgit.lfs.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.lfs;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.lfs;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.lfs/pom.xml b/org.eclipse.jgit.lfs/pom.xml index 1dd81e0741..b3e00c57e4 100644 --- a/org.eclipse.jgit.lfs/pom.xml +++ b/org.eclipse.jgit.lfs/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.lfs</artifactId> diff --git a/org.eclipse.jgit.lfs/src/org/eclipse/jgit/lfs/internal/LfsConnectionFactory.java b/org.eclipse.jgit.lfs/src/org/eclipse/jgit/lfs/internal/LfsConnectionFactory.java index d7d8d63775..1a4e85ded6 100644 --- a/org.eclipse.jgit.lfs/src/org/eclipse/jgit/lfs/internal/LfsConnectionFactory.java +++ b/org.eclipse.jgit.lfs/src/org/eclipse/jgit/lfs/internal/LfsConnectionFactory.java @@ -9,11 +9,11 @@ */ package org.eclipse.jgit.lfs.internal; +import static org.eclipse.jgit.lib.Constants.DEFAULT_REMOTE_NAME; import static org.eclipse.jgit.util.HttpSupport.ENCODING_GZIP; import static org.eclipse.jgit.util.HttpSupport.HDR_ACCEPT; import static org.eclipse.jgit.util.HttpSupport.HDR_ACCEPT_ENCODING; import static org.eclipse.jgit.util.HttpSupport.HDR_CONTENT_TYPE; -import static org.eclipse.jgit.lib.Constants.DEFAULT_REMOTE_NAME; import java.io.IOException; import java.net.ProxySelector; @@ -22,7 +22,7 @@ import java.net.URL; import java.time.LocalDateTime; import java.time.ZoneOffset; import java.time.format.DateTimeFormatter; -import java.util.LinkedList; +import java.util.ArrayList; import java.util.Map; import java.util.TreeMap; @@ -266,7 +266,7 @@ public class LfsConnectionFactory { Protocol.Request req = new Protocol.Request(); req.operation = operation; if (resources != null) { - req.objects = new LinkedList<>(); + req.objects = new ArrayList<>(); for (LfsPointer res : resources) { Protocol.ObjectSpec o = new Protocol.ObjectSpec(); o.oid = res.getOid().getName(); diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/feature.xml index 53a6d971f2..78c7a810a0 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit" label="%featureName" - version="6.9.1.qualifier" + version="6.10.1.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/pom.xml index a8df8d3aab..36d74e9b2f 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/feature.xml index e12baced16..e1c76c8711 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.gpg.bc" label="%featureName" - version="6.9.1.qualifier" + version="6.10.1.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -23,7 +23,7 @@ </url> <requires> - <import plugin="org.eclipse.jgit" version="6.9.1" match="equivalent"/> + <import plugin="org.eclipse.jgit" version="6.10.1" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/pom.xml index 47b6cb22ba..7376b2025b 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.gpg.bc.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/feature.xml index fa9758c71e..8ddd5602ab 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.http.apache" label="%featureName" - version="6.9.1.qualifier" + version="6.10.1.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -23,7 +23,7 @@ </url> <requires> - <import plugin="org.eclipse.jgit" version="6.9.1" match="equivalent"/> + <import plugin="org.eclipse.jgit" version="6.10.1" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/pom.xml index 7edde81ff8..52861d64f9 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.http.apache.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/feature.xml index 58e0de9d86..51ef6c4457 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.junit" label="%featureName" - version="6.9.1.qualifier" + version="6.10.1.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -24,7 +24,7 @@ <requires> <import plugin="com.jcraft.jsch"/> - <import plugin="org.eclipse.jgit" version="6.9.1" match="equivalent"/> + <import plugin="org.eclipse.jgit" version="6.10.1" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/pom.xml index 46f365066a..c66ba20d0c 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.junit.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/feature.xml index 09d897517f..5a95f9ebb4 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.lfs" label="%featureName" - version="6.9.1.qualifier" + version="6.10.1.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -23,7 +23,7 @@ </url> <requires> - <import feature="org.eclipse.jgit" version="6.9.1" match="equivalent"/> + <import feature="org.eclipse.jgit" version="6.10.1" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/pom.xml index 4273207dcd..d1ed57f4d6 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.lfs.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/feature.xml index ad85f8e7f0..afdeb02c68 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.pgm" label="%featureName" - version="6.9.1.qualifier" + version="6.10.1.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -35,9 +35,9 @@ version="0.0.0"/> <requires> - <import feature="org.eclipse.jgit" version="6.9.1" match="equivalent"/> - <import feature="org.eclipse.jgit.lfs" version="6.9.1" match="equivalent"/> - <import feature="org.eclipse.jgit.ssh.apache" version="6.9.1" match="equivalent"/> + <import feature="org.eclipse.jgit" version="6.10.1" match="equivalent"/> + <import feature="org.eclipse.jgit.lfs" version="6.10.1" match="equivalent"/> + <import feature="org.eclipse.jgit.ssh.apache" version="6.10.1" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/pom.xml index 041fac1c12..1d3ca70413 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.pgm.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/category.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/category.xml index e0c790ad90..bf24cb8f2b 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/category.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/category.xml @@ -147,10 +147,13 @@ <bundle id="org.apache.commons.commons-compress.source"> <category name="JGit-dependency-bundles"/> </bundle> - <bundle id="org.apache.commons.logging"> + <bundle id="org.apache.commons.lang3"> + <category name="JGit-dependency-bundles"/> + </bundle> + <bundle id="org.apache.commons.lang3.source"> <category name="JGit-dependency-bundles"/> </bundle> - <bundle id="org.apache.commons.logging.source"> + <bundle id="org.apache.commons.logging"> <category name="JGit-dependency-bundles"/> </bundle> <bundle id="org.apache.httpcomponents.httpclient"> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/pom.xml index 58f47b0d72..5af966b465 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.repository/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.repository</artifactId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/feature.xml index c94d25e7c8..2a056b55ae 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.source" label="%featureName" - version="6.9.1.qualifier" + version="6.10.1.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -23,7 +23,7 @@ </url> <requires> - <import feature="org.eclipse.jgit" version="6.9.1" match="equivalent"/> + <import feature="org.eclipse.jgit" version="6.10.1" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/pom.xml index a962942767..487e519b2a 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.source.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> @@ -30,7 +30,7 @@ <dependency> <groupId>org.eclipse.jgit.feature</groupId> <artifactId>org.eclipse.jgit</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </dependency> </dependencies> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/feature.xml index b1e6e9d60a..6cb162b787 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.ssh.apache" label="%featureName" - version="6.9.1.qualifier" + version="6.10.1.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -23,7 +23,7 @@ </url> <requires> - <import feature="org.eclipse.jgit" version="6.9.1" match="equivalent"/> + <import feature="org.eclipse.jgit" version="6.10.1" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/pom.xml index 361a31eb38..876e9f5a90 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.apache.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/feature.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/feature.xml index 5856a21975..ed02ffccef 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/feature.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/feature.xml @@ -2,7 +2,7 @@ <feature id="org.eclipse.jgit.ssh.jsch" label="%featureName" - version="6.9.1.qualifier" + version="6.10.1.qualifier" provider-name="%providerName"> <description url="http://www.eclipse.org/jgit/"> @@ -23,7 +23,7 @@ </url> <requires> - <import plugin="org.eclipse.jgit" version="6.9.1" match="equivalent"/> + <import plugin="org.eclipse.jgit" version="6.10.1" match="equivalent"/> </requires> <plugin diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/pom.xml b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/pom.xml index d1ed898607..c20b918dc0 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/pom.xml +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.ssh.jsch.feature/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <groupId>org.eclipse.jgit.feature</groupId> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.17.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.17.target index cf278d8d41..357a5158f6 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.17.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.17.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.17" sequenceNumber="1708457973"> +<target name="jgit-4.17" sequenceNumber="1716824813"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/releases/2020-09/"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.18.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.18.target index c7fdb830dd..4164742e6d 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.18.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.18.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.18" sequenceNumber="1708457973"> +<target name="jgit-4.18" sequenceNumber="1716824813"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/releases/2020-12/"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.19.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.19.target index b3f4165412..c3f24679a9 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.19.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.19.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.19-staging" sequenceNumber="1708457973"> +<target name="jgit-4.19-staging" sequenceNumber="1716824813"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/releases/2021-03/"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.20.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.20.target index 55b6281408..7412a7d5ff 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.20.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.20.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.20" sequenceNumber="1708457973"> +<target name="jgit-4.20" sequenceNumber="1716824813"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/releases/2021-06/"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.21.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.21.target index 45136a7aaa..c4144d65cb 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.21.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.21.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.21" sequenceNumber="1708457973"> +<target name="jgit-4.21" sequenceNumber="1716824813"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/releases/2021-09/"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.22.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.22.target index 7fe3b68085..b3625fa0d8 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.22.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.22.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.22" sequenceNumber="1708457972"> +<target name="jgit-4.22" sequenceNumber="1716824812"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/releases/2021-12/"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.23.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.23.target index e0786fd4eb..6f1e2ede1c 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.23.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.23.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.23" sequenceNumber="1708457972"> +<target name="jgit-4.23" sequenceNumber="1716824812"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/releases/2022-03/"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.24.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.24.target index 4656b56676..db79a5abe9 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.24.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.24.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.24" sequenceNumber="1708457972"> +<target name="jgit-4.24" sequenceNumber="1716824812"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/releases/2022-06/"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.25.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.25.target index efa79b3246..3d164c0ed8 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.25.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.25.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.25" sequenceNumber="1708457972"> +<target name="jgit-4.25" sequenceNumber="1716824812"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/releases/2022-09/"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.26.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.26.target index a432bbbe12..63fe49222d 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.26.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.26.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.26" sequenceNumber="1708457970"> +<target name="jgit-4.26" sequenceNumber="1716824812"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/releases/2022-12/"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.27.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.27.target index 4b912382d9..ee8b3d7bdd 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.27.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.27.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.27" sequenceNumber="1708457970"> +<target name="jgit-4.27" sequenceNumber="1716824812"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/releases/2023-03/"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.28.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.28.target index 7dc8dd82fd..ee4845d006 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.28.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.28.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.28" sequenceNumber="1708457970"> +<target name="jgit-4.28" sequenceNumber="1716824812"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/releases/2023-06"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.29.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.29.target index d86ea2826d..5cb731e771 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.29.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.29.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.29" sequenceNumber="1708457970"> +<target name="jgit-4.29" sequenceNumber="1716824812"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/releases/2023-09"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.30.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.30.target index afd4d320bc..488373d3e2 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.30.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.30.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.30" sequenceNumber="1708457970"> +<target name="jgit-4.30" sequenceNumber="1716824811"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -33,246 +33,252 @@ <repository location="https://download.eclipse.org/staging/2023-12/"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.31.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.31.target index d95197a43e..5bbcd3ce97 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.31.target +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.31.target @@ -1,7 +1,7 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <?pde?> <!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> -<target name="jgit-4.31" sequenceNumber="1708457970"> +<target name="jgit-4.31" sequenceNumber="1716824812"> <locations> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> @@ -30,249 +30,255 @@ </location> <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> <unit id="org.eclipse.osgi" version="0.0.0"/> - <repository location="https://download.eclipse.org/staging/2024-03/"/> + <repository location="https://download.eclipse.org/releases/2024-03/"/> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> - <dependencies> - <dependency> - <groupId>org.tukaani</groupId> - <artifactId>xz</artifactId> - <version>1.9</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> - <dependencies> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-api</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.slf4j</groupId> - <artifactId>slf4j-simple</artifactId> - <version>1.7.36</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> - <dependencies> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-osgi</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.sshd</groupId> - <artifactId>sshd-sftp</artifactId> - <version>2.12.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> - <dependencies> - <dependency> - <groupId>org.mockito</groupId> - <artifactId>mockito-core</artifactId> - <version>5.10.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> - <dependencies> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.java.dev.jna</groupId> - <artifactId>jna-platform</artifactId> - <version>5.14.0</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> - <dependencies> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-http</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-io</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-security</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-server</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-servlet</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.eclipse.jetty</groupId> - <artifactId>jetty-util-ajax</artifactId> - <version>10.0.20</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>jakarta.servlet</groupId> - <artifactId>jakarta.servlet-api</artifactId> - <version>4.0.4</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> - <dependencies> - <dependency> - <groupId>com.googlecode.javaewah</groupId> - <artifactId>JavaEWAH</artifactId> - <version>1.2.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> - <dependencies> - <dependency> - <groupId>org.hamcrest</groupId> - <artifactId>hamcrest</artifactId> - <version>2.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> - <dependencies> - <dependency> - <groupId>com.google.code.gson</groupId> - <artifactId>gson</artifactId> - <version>2.10.1</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> - <dependencies> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>net.bytebuddy</groupId> - <artifactId>byte-buddy-agent</artifactId> - <version>1.14.12</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> - <dependencies> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpg-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcprov-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcpkix-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.bouncycastle</groupId> - <artifactId>bcutil-jdk18on</artifactId> - <version>1.77</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> - <dependencies> - <dependency> - <groupId>org.assertj</groupId> - <artifactId>assertj-core</artifactId> - <version>3.25.3</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> - <dependencies> - <dependency> - <groupId>args4j</groupId> - <artifactId>args4j</artifactId> - <version>2.33</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> </location> <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> - <dependencies> - <dependency> - <groupId>commons-codec</groupId> - <artifactId>commons-codec</artifactId> - <version>1.16.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>org.apache.commons</groupId> - <artifactId>commons-compress</artifactId> - <version>1.26.0</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-io</groupId> - <artifactId>commons-io</artifactId> - <version>2.15.1</version> - <type>jar</type> - </dependency> - <dependency> - <groupId>commons-logging</groupId> - <artifactId>commons-logging</artifactId> - <version>1.2</version> - <type>jar</type> - </dependency> - </dependencies> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> </location> </locations> </target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.31.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.31.tpd index 58491c85d5..8174709b7c 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.31.tpd +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.31.tpd @@ -3,6 +3,6 @@ target "jgit-4.31" with source configurePhase include "orbit/orbit-4.31.tpd" include "maven/dependencies.tpd" -location "https://download.eclipse.org/staging/2024-03/" { +location "https://download.eclipse.org/releases/2024-03/" { org.eclipse.osgi lazy } diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.32.target b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.32.target new file mode 100644 index 0000000000..b0bd4d3f2e --- /dev/null +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.32.target @@ -0,0 +1,284 @@ +<?xml version="1.0" encoding="UTF-8" standalone="no"?> +<?pde?> +<!-- generated with https://github.com/eclipse-cbi/targetplatform-dsl --> +<target name="jgit-4.32" sequenceNumber="1716824813"> + <locations> + <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> + <unit id="com.jcraft.jsch" version="0.1.55.v20230916-1400"/> + <unit id="com.jcraft.jsch.source" version="0.1.55.v20230916-1400"/> + <unit id="com.jcraft.jzlib" version="1.1.3.v20230916-1400"/> + <unit id="com.jcraft.jzlib.source" version="1.1.3.v20230916-1400"/> + <unit id="net.i2p.crypto.eddsa" version="0.3.0"/> + <unit id="net.i2p.crypto.eddsa.source" version="0.3.0"/> + <unit id="org.apache.ant" version="1.10.14.v20230922-1200"/> + <unit id="org.apache.ant.source" version="1.10.14.v20230922-1200"/> + <unit id="org.apache.httpcomponents.httpclient" version="4.5.14"/> + <unit id="org.apache.httpcomponents.httpclient.source" version="4.5.14"/> + <unit id="org.apache.httpcomponents.httpcore" version="4.4.16"/> + <unit id="org.apache.httpcomponents.httpcore.source" version="4.4.16"/> + <unit id="org.hamcrest.core" version="1.3.0.v20230809-1000"/> + <unit id="org.hamcrest.core.source" version="1.3.0.v20230809-1000"/> + <unit id="org.hamcrest.library" version="1.3.0.v20230809-1000"/> + <unit id="org.hamcrest.library.source" version="1.3.0.v20230809-1000"/> + <unit id="org.junit" version="4.13.2.v20230809-1000"/> + <unit id="org.junit.source" version="4.13.2.v20230809-1000"/> + <unit id="org.objenesis" version="3.4.0"/> + <unit id="org.objenesis.source" version="3.4.0"/> + <unit id="org.osgi.service.cm" version="1.6.1.202109301733"/> + <unit id="org.osgi.service.cm.source" version="1.6.1.202109301733"/> + <repository location="https://download.eclipse.org/tools/orbit/simrel/orbit-aggregation/2024-06"/> + </location> + <location includeMode="slicer" includeAllPlatforms="false" includeSource="true" includeConfigurePhase="true" type="InstallableUnit"> + <unit id="org.eclipse.osgi" version="0.0.0"/> + <repository location="https://download.eclipse.org/staging/2024-06/"/> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="xz"> + <dependencies> + <dependency> + <groupId>org.tukaani</groupId> + <artifactId>xz</artifactId> + <version>1.9</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="slf4j"> + <dependencies> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-api</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.slf4j</groupId> + <artifactId>slf4j-simple</artifactId> + <version>1.7.36</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="sshd"> + <dependencies> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-osgi</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.sshd</groupId> + <artifactId>sshd-sftp</artifactId> + <version>2.12.1</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="mockito"> + <dependencies> + <dependency> + <groupId>org.mockito</groupId> + <artifactId>mockito-core</artifactId> + <version>5.12.0</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jna"> + <dependencies> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.java.dev.jna</groupId> + <artifactId>jna-platform</artifactId> + <version>5.14.0</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="jetty"> + <dependencies> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-http</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-io</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-security</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-server</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-servlet</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.eclipse.jetty</groupId> + <artifactId>jetty-util-ajax</artifactId> + <version>10.0.21</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>jakarta.servlet</groupId> + <artifactId>jakarta.servlet-api</artifactId> + <version>4.0.4</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="javaewah"> + <dependencies> + <dependency> + <groupId>com.googlecode.javaewah</groupId> + <artifactId>JavaEWAH</artifactId> + <version>1.2.3</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="hamcrest"> + <dependencies> + <dependency> + <groupId>org.hamcrest</groupId> + <artifactId>hamcrest</artifactId> + <version>2.2</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="gson"> + <dependencies> + <dependency> + <groupId>com.google.code.gson</groupId> + <artifactId>gson</artifactId> + <version>2.11.0</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bytebuddy"> + <dependencies> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>net.bytebuddy</groupId> + <artifactId>byte-buddy-agent</artifactId> + <version>1.14.16</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="bouncycastle"> + <dependencies> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpg-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcprov-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcpkix-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.bouncycastle</groupId> + <artifactId>bcutil-jdk18on</artifactId> + <version>1.78.1</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="assertj"> + <dependencies> + <dependency> + <groupId>org.assertj</groupId> + <artifactId>assertj-core</artifactId> + <version>3.26.0</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="args4j"> + <dependencies> + <dependency> + <groupId>args4j</groupId> + <artifactId>args4j</artifactId> + <version>2.37</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + <location includeDependencyDepth="none" includeDependencyScopes="compile" includeSource="true" missingManifest="error" type="Maven" label="apache"> + <dependencies> + <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-compress</artifactId> + <version>1.26.2</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-lang3</artifactId> + <version>3.14.0</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-io</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + <type>jar</type> + </dependency> + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + <type>jar</type> + </dependency> + </dependencies> + </location> + </locations> +</target> diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.32.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.32.tpd new file mode 100644 index 0000000000..b8574c73b9 --- /dev/null +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/jgit-4.32.tpd @@ -0,0 +1,8 @@ +target "jgit-4.32" with source configurePhase + +include "orbit/orbit-4.32.tpd" +include "maven/dependencies.tpd" + +location "https://download.eclipse.org/staging/2024-06/" { + org.eclipse.osgi lazy +} diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/maven/dependencies.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/maven/dependencies.tpd index 8347389018..3d47632ffd 100644 --- a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/maven/dependencies.tpd +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/maven/dependencies.tpd @@ -10,22 +10,27 @@ maven apache dependency { groupId = "commons-codec" artifactId = "commons-codec" - version = "1.16.0" + version = "1.17.0" } dependency { groupId = "org.apache.commons" artifactId = "commons-compress" - version = "1.26.0" + version = "1.26.2" + } + dependency { + groupId = "org.apache.commons" + artifactId = "commons-lang3" + version = "3.14.0" } dependency { groupId = "commons-io" artifactId = "commons-io" - version = "2.15.1" + version = "2.16.1" } dependency { groupId = "commons-logging" artifactId = "commons-logging" - version = "1.2" + version = "1.3.2" } } @@ -38,7 +43,7 @@ maven args4j dependency { groupId = "args4j" artifactId = "args4j" - version = "2.33" + version = "2.37" } } @@ -51,7 +56,7 @@ maven assertj dependency { groupId = "org.assertj" artifactId = "assertj-core" - version = "3.25.3" + version = "3.26.0" } } @@ -64,22 +69,22 @@ maven bouncycastle dependency { groupId = "org.bouncycastle" artifactId = "bcpg-jdk18on" - version = "1.77" + version = "1.78.1" } dependency { groupId = "org.bouncycastle" artifactId = "bcprov-jdk18on" - version = "1.77" + version = "1.78.1" } dependency { groupId = "org.bouncycastle" artifactId = "bcpkix-jdk18on" - version = "1.77" + version = "1.78.1" } dependency { groupId = "org.bouncycastle" artifactId = "bcutil-jdk18on" - version = "1.77" + version = "1.78.1" } } @@ -92,12 +97,12 @@ maven bytebuddy dependency { groupId = "net.bytebuddy" artifactId = "byte-buddy" - version = "1.14.12" + version = "1.14.16" } dependency { groupId = "net.bytebuddy" artifactId = "byte-buddy-agent" - version = "1.14.12" + version = "1.14.16" } } @@ -110,7 +115,7 @@ maven gson dependency { groupId = "com.google.code.gson" artifactId = "gson" - version = "2.10.1" + version = "2.11.0" } } @@ -149,37 +154,37 @@ maven jetty dependency { groupId = "org.eclipse.jetty" artifactId = "jetty-http" - version = "10.0.20" + version = "10.0.21" } dependency { groupId = "org.eclipse.jetty" artifactId = "jetty-io" - version = "10.0.20" + version = "10.0.21" } dependency { groupId = "org.eclipse.jetty" artifactId = "jetty-security" - version = "10.0.20" + version = "10.0.21" } dependency { groupId = "org.eclipse.jetty" artifactId = "jetty-server" - version = "10.0.20" + version = "10.0.21" } dependency { groupId = "org.eclipse.jetty" artifactId = "jetty-servlet" - version = "10.0.20" + version = "10.0.21" } dependency { groupId = "org.eclipse.jetty" artifactId = "jetty-util" - version = "10.0.20" + version = "10.0.21" } dependency { groupId = "org.eclipse.jetty" artifactId = "jetty-util-ajax" - version = "10.0.20" + version = "10.0.21" } dependency { groupId = "jakarta.servlet" @@ -215,7 +220,7 @@ maven mockito dependency { groupId = "org.mockito" artifactId = "mockito-core" - version = "5.10.0" + version = "5.12.0" } } @@ -228,12 +233,12 @@ maven sshd dependency { groupId = "org.apache.sshd" artifactId = "sshd-osgi" - version = "2.12.0" + version = "2.12.1" } dependency { groupId = "org.apache.sshd" artifactId = "sshd-sftp" - version = "2.12.0" + version = "2.12.1" } } diff --git a/org.eclipse.jgit.packaging/org.eclipse.jgit.target/orbit/orbit-4.32.tpd b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/orbit/orbit-4.32.tpd new file mode 100644 index 0000000000..480e96e2e8 --- /dev/null +++ b/org.eclipse.jgit.packaging/org.eclipse.jgit.target/orbit/orbit-4.32.tpd @@ -0,0 +1,27 @@ +target "orbit-4.32" with source configurePhase +// see https://download.eclipse.org/tools/orbit/downloads/ + +location "https://download.eclipse.org/tools/orbit/simrel/orbit-aggregation/2024-06" { + com.jcraft.jsch [0.1.55.v20230916-1400,0.1.55.v20230916-1400] + com.jcraft.jsch.source [0.1.55.v20230916-1400,0.1.55.v20230916-1400] + com.jcraft.jzlib [1.1.3.v20230916-1400,1.1.3.v20230916-1400] + com.jcraft.jzlib.source [1.1.3.v20230916-1400,1.1.3.v20230916-1400] + net.i2p.crypto.eddsa [0.3.0,0.3.0] + net.i2p.crypto.eddsa.source [0.3.0,0.3.0] + org.apache.ant [1.10.14.v20230922-1200,1.10.14.v20230922-1200] + org.apache.ant.source [1.10.14.v20230922-1200,1.10.14.v20230922-1200] + org.apache.httpcomponents.httpclient [4.5.14,4.5.14] + org.apache.httpcomponents.httpclient.source [4.5.14,4.5.14] + org.apache.httpcomponents.httpcore [4.4.16,4.4.16] + org.apache.httpcomponents.httpcore.source [4.4.16,4.4.16] + org.hamcrest.core [1.3.0.v20230809-1000,1.3.0.v20230809-1000] + org.hamcrest.core.source [1.3.0.v20230809-1000,1.3.0.v20230809-1000] + org.hamcrest.library [1.3.0.v20230809-1000,1.3.0.v20230809-1000] + org.hamcrest.library.source [1.3.0.v20230809-1000,1.3.0.v20230809-1000] + org.junit [4.13.2.v20230809-1000,4.13.2.v20230809-1000] + org.junit.source [4.13.2.v20230809-1000,4.13.2.v20230809-1000] + org.objenesis [3.4,3.4] + org.objenesis.source [3.4,3.4] + org.osgi.service.cm [1.6.1.202109301733,1.6.1.202109301733] + org.osgi.service.cm.source [1.6.1.202109301733,1.6.1.202109301733] +} diff --git a/org.eclipse.jgit.packaging/pom.xml b/org.eclipse.jgit.packaging/pom.xml index c06d6e41da..a5dee45990 100644 --- a/org.eclipse.jgit.packaging/pom.xml +++ b/org.eclipse.jgit.packaging/pom.xml @@ -16,7 +16,7 @@ <groupId>org.eclipse.jgit</groupId> <artifactId>jgit.tycho.parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> <packaging>pom</packaging> <name>JGit Tycho Parent</name> @@ -184,7 +184,7 @@ <configuration> <rules> <requireMavenVersion> - <version>3.6.3</version> + <version>3.9.0</version> </requireMavenVersion> </rules> </configuration> @@ -204,7 +204,7 @@ <plugin> <groupId>org.cyclonedx</groupId> <artifactId>cyclonedx-maven-plugin</artifactId> - <version>2.7.11</version> + <version>2.8.0</version> <configuration> <projectType>library</projectType> <schemaVersion>1.4</schemaVersion> @@ -233,7 +233,7 @@ <plugin> <groupId>io.github.git-commit-id</groupId> <artifactId>git-commit-id-maven-plugin</artifactId> - <version>7.0.0</version> + <version>8.0.2</version> <executions> <execution> <id>get-the-git-infos</id> @@ -273,7 +273,7 @@ <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-jar-plugin</artifactId> - <version>3.3.0</version> + <version>3.4.1</version> <configuration> <archive> <manifestEntries> @@ -386,7 +386,7 @@ <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>build-helper-maven-plugin</artifactId> - <version>3.5.0</version> + <version>3.6.0</version> </plugin> <plugin> <artifactId>maven-clean-plugin</artifactId> @@ -395,22 +395,22 @@ <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-deploy-plugin</artifactId> - <version>3.1.1</version> + <version>3.1.2</version> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-install-plugin</artifactId> - <version>3.1.1</version> + <version>3.1.2</version> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-site-plugin</artifactId> - <version>4.0.0-M13</version> + <version>4.0.0-M14</version> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-artifact-plugin</artifactId> - <version>3.5.0</version> + <version>3.5.1</version> <configuration> <ignore>**/*cyclonedx.json</ignore> <reproducible>true</reproducible> diff --git a/org.eclipse.jgit.pgm.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.pgm.test/META-INF/MANIFEST.MF index 7232b276f3..e01d3b20a2 100644 --- a/org.eclipse.jgit.pgm.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.pgm.test/META-INF/MANIFEST.MF @@ -3,30 +3,30 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.pgm.test Bundle-SymbolicName: org.eclipse.jgit.pgm.test -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-ActivationPolicy: lazy Bundle-RequiredExecutionEnvironment: JavaSE-11 -Import-Package: org.eclipse.jgit.api;version="[6.9.1,6.10.0)", - org.eclipse.jgit.api.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.diff;version="[6.9.1,6.10.0)", - org.eclipse.jgit.dircache;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.diffmergetool;version="6.9.1", - org.eclipse.jgit.internal.storage.file;version="6.9.1", - org.eclipse.jgit.junit;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib.internal;version="[6.9.1,6.10.0)", - org.eclipse.jgit.merge;version="[6.9.1,6.10.0)", - org.eclipse.jgit.pgm;version="[6.9.1,6.10.0)", - org.eclipse.jgit.pgm.internal;version="[6.9.1,6.10.0)", - org.eclipse.jgit.pgm.opt;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.treewalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util.io;version="[6.9.1,6.10.0)", +Import-Package: org.eclipse.jgit.api;version="[6.10.1,6.11.0)", + org.eclipse.jgit.api.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.diff;version="[6.10.1,6.11.0)", + org.eclipse.jgit.dircache;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.diffmergetool;version="6.10.1", + org.eclipse.jgit.internal.storage.file;version="6.10.1", + org.eclipse.jgit.junit;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib.internal;version="[6.10.1,6.11.0)", + org.eclipse.jgit.merge;version="[6.10.1,6.11.0)", + org.eclipse.jgit.pgm;version="[6.10.1,6.11.0)", + org.eclipse.jgit.pgm.internal;version="[6.10.1,6.11.0)", + org.eclipse.jgit.pgm.opt;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.treewalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util.io;version="[6.10.1,6.11.0)", org.hamcrest.core;bundle-version="[1.1.0,3.0.0)", org.junit;version="[4.13,5.0.0)", org.junit.rules;version="[4.13,5.0.0)", diff --git a/org.eclipse.jgit.pgm.test/pom.xml b/org.eclipse.jgit.pgm.test/pom.xml index ae02cdc668..a358b99e59 100644 --- a/org.eclipse.jgit.pgm.test/pom.xml +++ b/org.eclipse.jgit.pgm.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.pgm.test</artifactId> diff --git a/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/CloneTest.java b/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/CloneTest.java index cbb5bbb9cc..a1fb9fb589 100644 --- a/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/CloneTest.java +++ b/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/CloneTest.java @@ -183,7 +183,7 @@ public class CloneTest extends CLIRepositoryTestCase { File gitDir = db.getDirectory(); String sourcePath = gitDir.getAbsolutePath(); - String targetPath = (new File(sourcePath)).getParentFile() + String targetPath = new File(sourcePath).getParentFile() .getParentFile().getAbsolutePath() + File.separator + "target.git"; String cmd = "git clone --bare " + shellQuote(sourcePath) + " " @@ -207,7 +207,7 @@ public class CloneTest extends CLIRepositoryTestCase { File gitDir = db.getDirectory(); String sourcePath = gitDir.getAbsolutePath(); - String targetPath = (new File(sourcePath)).getParentFile() + String targetPath = new File(sourcePath).getParentFile() .getParentFile().getAbsolutePath() + File.separator + "target.git"; String cmd = "git clone --mirror " + shellQuote(sourcePath) + " " diff --git a/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/ConfigTest.java b/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/ConfigTest.java index 005215f443..0af310c497 100644 --- a/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/ConfigTest.java +++ b/org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/ConfigTest.java @@ -45,10 +45,9 @@ public class ConfigTest extends CLIRepositoryTestCase { Map<String, String> options = parseOptions(output); assertEquals(!isWindows, Boolean.valueOf(options.get("core.filemode"))); - assertTrue((Boolean.valueOf(options.get("core.logallrefupdates")))); + assertTrue(Boolean.valueOf(options.get("core.logallrefupdates"))); if (isMac) { - assertTrue( - (Boolean.valueOf(options.get("core.precomposeunicode")))); + assertTrue(Boolean.valueOf(options.get("core.precomposeunicode"))); } assertEquals(Integer.valueOf(0), Integer.valueOf(options.get("core.repositoryformatversion"))); diff --git a/org.eclipse.jgit.pgm/META-INF/MANIFEST.MF b/org.eclipse.jgit.pgm/META-INF/MANIFEST.MF index 825911c838..c6215ca38d 100644 --- a/org.eclipse.jgit.pgm/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.pgm/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.pgm Bundle-SymbolicName: org.eclipse.jgit.pgm -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: OSGI-INF/l10n/plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -14,49 +14,49 @@ Import-Package: javax.servlet;version="[3.1.0,5.0.0)", org.eclipse.jetty.servlet;version="[10.0.0,11.0.0)", org.eclipse.jetty.util;version="[10.0.0,11.0.0)", org.eclipse.jetty.util.component;version="[10.0.0,11.0.0)", - org.eclipse.jgit.api;version="[6.9.1,6.10.0)", - org.eclipse.jgit.api.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.archive;version="[6.9.1,6.10.0)", - org.eclipse.jgit.awtui;version="[6.9.1,6.10.0)", - org.eclipse.jgit.blame;version="[6.9.1,6.10.0)", - org.eclipse.jgit.diff;version="[6.9.1,6.10.0)", - org.eclipse.jgit.dircache;version="[6.9.1,6.10.0)", - org.eclipse.jgit.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.gitrepo;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.diffmergetool;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.io;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.pack;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.reftable;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.server;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.server.fs;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs.server.s3;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.merge;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib.internal;version="[6.9.1,6.10.0)", - org.eclipse.jgit.nls;version="[6.9.1,6.10.0)", - org.eclipse.jgit.notes;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revplot;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk.filter;version="[6.9.1,6.10.0)", - org.eclipse.jgit.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.storage.pack;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.http.apache;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.resolver;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.ssh.jsch;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.sshd;version="[6.9.1,6.10.0)", - org.eclipse.jgit.treewalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.treewalk.filter;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util.io;version="[6.9.1,6.10.0)", + org.eclipse.jgit.api;version="[6.10.1,6.11.0)", + org.eclipse.jgit.api.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.archive;version="[6.10.1,6.11.0)", + org.eclipse.jgit.awtui;version="[6.10.1,6.11.0)", + org.eclipse.jgit.blame;version="[6.10.1,6.11.0)", + org.eclipse.jgit.diff;version="[6.10.1,6.11.0)", + org.eclipse.jgit.dircache;version="[6.10.1,6.11.0)", + org.eclipse.jgit.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.gitrepo;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.diffmergetool;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.io;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.pack;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.reftable;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.server;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.server.fs;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs.server.s3;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.merge;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib.internal;version="[6.10.1,6.11.0)", + org.eclipse.jgit.nls;version="[6.10.1,6.11.0)", + org.eclipse.jgit.notes;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revplot;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk.filter;version="[6.10.1,6.11.0)", + org.eclipse.jgit.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.storage.pack;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.http.apache;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.resolver;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.ssh.jsch;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.sshd;version="[6.10.1,6.11.0)", + org.eclipse.jgit.treewalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.treewalk.filter;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util.io;version="[6.10.1,6.11.0)", org.kohsuke.args4j;version="[2.33.0,3.0.0)", org.kohsuke.args4j.spi;version="[2.33.0,3.0.0)" -Export-Package: org.eclipse.jgit.console;version="6.9.1"; +Export-Package: org.eclipse.jgit.console;version="6.10.1"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.util", - org.eclipse.jgit.pgm;version="6.9.1"; + org.eclipse.jgit.pgm;version="6.10.1"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.util.io, org.eclipse.jgit.awtui, @@ -68,14 +68,14 @@ Export-Package: org.eclipse.jgit.console;version="6.9.1"; org.eclipse.jgit.treewalk, org.eclipse.jgit.api, javax.swing", - org.eclipse.jgit.pgm.debug;version="6.9.1"; + org.eclipse.jgit.pgm.debug;version="6.10.1"; uses:="org.eclipse.jgit.util.io, org.eclipse.jgit.pgm, org.eclipse.jetty.servlet", - org.eclipse.jgit.pgm.internal;version="6.9.1"; + org.eclipse.jgit.pgm.internal;version="6.10.1"; x-friends:="org.eclipse.jgit.pgm.test, org.eclipse.jgit.test", - org.eclipse.jgit.pgm.opt;version="6.9.1"; + org.eclipse.jgit.pgm.opt;version="6.10.1"; uses:="org.kohsuke.args4j, org.eclipse.jgit.lib, org.eclipse.jgit.revwalk, diff --git a/org.eclipse.jgit.pgm/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.pgm/META-INF/SOURCE-MANIFEST.MF index cb5e8148da..5236cf5709 100644 --- a/org.eclipse.jgit.pgm/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.pgm/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.pgm - Sources Bundle-SymbolicName: org.eclipse.jgit.pgm.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.pgm;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.pgm;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.pgm/pom.xml b/org.eclipse.jgit.pgm/pom.xml index 488b481565..89d803ed4f 100644 --- a/org.eclipse.jgit.pgm/pom.xml +++ b/org.eclipse.jgit.pgm/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.pgm</artifactId> diff --git a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/CommandCatalog.java b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/CommandCatalog.java index 210e17277f..2a9f7acdb9 100644 --- a/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/CommandCatalog.java +++ b/org.eclipse.jgit.pgm/src/org/eclipse/jgit/pgm/CommandCatalog.java @@ -19,10 +19,10 @@ import java.net.URL; import java.util.ArrayList; import java.util.Arrays; import java.util.Collection; +import java.util.Collections; import java.util.Enumeration; import java.util.HashMap; import java.util.Map; -import java.util.Vector; /** * List of all commands known by jgit's command line tools. @@ -104,7 +104,7 @@ public class CommandCatalog { final String pfx = "META-INF/services/"; //$NON-NLS-1$ return ldr.getResources(pfx + TextBuiltin.class.getName()); } catch (IOException err) { - return new Vector<URL>().elements(); + return Collections.emptyEnumeration(); } } diff --git a/org.eclipse.jgit.ssh.apache.agent/META-INF/MANIFEST.MF b/org.eclipse.jgit.ssh.apache.agent/META-INF/MANIFEST.MF index 5011a8e764..5090d71efa 100644 --- a/org.eclipse.jgit.ssh.apache.agent/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ssh.apache.agent/META-INF/MANIFEST.MF @@ -2,16 +2,16 @@ Manifest-Version: 1.0 Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Bundle-SymbolicName: org.eclipse.jgit.ssh.apache.agent;singleton:=true -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Localization: OSGI-INF/l10n/agent Bundle-Vendor: %Bundle-Vendor -Fragment-Host: org.eclipse.jgit.ssh.apache;bundle-version="[6.9.1,6.10.0)" +Fragment-Host: org.eclipse.jgit.ssh.apache;bundle-version="[6.10.1,6.11.0)" Bundle-ActivationPolicy: lazy Automatic-Module-Name: org.eclipse.jgit.ssh.apache.agent Bundle-RequiredExecutionEnvironment: JavaSE-11 -Import-Package: org.eclipse.jgit.transport.sshd;version="[6.9.1,6.10.0)", - org.eclipse.jgit.nls;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)" +Import-Package: org.eclipse.jgit.transport.sshd;version="[6.10.1,6.11.0)", + org.eclipse.jgit.nls;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)" Require-Bundle: com.sun.jna;bundle-version="[5.8.0,6.0.0)", com.sun.jna.platform;bundle-version="[5.8.0,6.0.0)" -Export-Package: org.eclipse.jgit.internal.transport.sshd.agent.connector;version="6.9.1";x-internal:=true +Export-Package: org.eclipse.jgit.internal.transport.sshd.agent.connector;version="6.10.1";x-internal:=true diff --git a/org.eclipse.jgit.ssh.apache.agent/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.ssh.apache.agent/META-INF/SOURCE-MANIFEST.MF index e841539fc9..1a0ea15a63 100644 --- a/org.eclipse.jgit.ssh.apache.agent/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.ssh.apache.agent/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.ssh.apache.agent - Sources Bundle-SymbolicName: org.eclipse.jgit.ssh.apache.agent.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.ssh.apache.agent;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.ssh.apache.agent;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.ssh.apache.agent/pom.xml b/org.eclipse.jgit.ssh.apache.agent/pom.xml index 7da173a099..1893c8feee 100644 --- a/org.eclipse.jgit.ssh.apache.agent/pom.xml +++ b/org.eclipse.jgit.ssh.apache.agent/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ssh.apache.agent</artifactId> diff --git a/org.eclipse.jgit.ssh.apache.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.ssh.apache.test/META-INF/MANIFEST.MF index 7c5b2d7788..64c40628b1 100644 --- a/org.eclipse.jgit.ssh.apache.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ssh.apache.test/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.ssh.apache.test Bundle-SymbolicName: org.eclipse.jgit.ssh.apache.test -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -22,16 +22,16 @@ Import-Package: org.apache.sshd.client.config.hosts;version="[2.12.0,2.13.0)", org.apache.sshd.core;version="[2.12.0,2.13.0)", org.apache.sshd.server;version="[2.12.0,2.13.0)", org.apache.sshd.server.forward;version="[2.12.0,2.13.0)", - org.eclipse.jgit.api;version="[6.9.1,6.10.0)", - org.eclipse.jgit.api.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.transport.sshd.proxy;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit.ssh;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.sshd;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.sshd.agent;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", + org.eclipse.jgit.api;version="[6.10.1,6.11.0)", + org.eclipse.jgit.api.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.transport.sshd.proxy;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit.ssh;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.sshd;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.sshd.agent;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", org.junit;version="[4.13,5.0.0)", org.junit.experimental.theories;version="[4.13,5.0.0)", org.junit.runner;version="[4.13,5.0.0)" diff --git a/org.eclipse.jgit.ssh.apache.test/pom.xml b/org.eclipse.jgit.ssh.apache.test/pom.xml index a8598a9ca4..f4fa30e9f1 100644 --- a/org.eclipse.jgit.ssh.apache.test/pom.xml +++ b/org.eclipse.jgit.ssh.apache.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ssh.apache.test</artifactId> diff --git a/org.eclipse.jgit.ssh.apache.test/tst/org/eclipse/jgit/transport/sshd/ApacheSshTest.java b/org.eclipse.jgit.ssh.apache.test/tst/org/eclipse/jgit/transport/sshd/ApacheSshTest.java index a8fcca7b8e..873945780f 100644 --- a/org.eclipse.jgit.ssh.apache.test/tst/org/eclipse/jgit/transport/sshd/ApacheSshTest.java +++ b/org.eclipse.jgit.ssh.apache.test/tst/org/eclipse/jgit/transport/sshd/ApacheSshTest.java @@ -861,4 +861,37 @@ public class ApacheSshTest extends SshTestBase { verifyAuthLog(e.getMessage(), "log in"); } + @Test + public void testCipherModificationSingle() throws Exception { + cloneWith( + "ssh://" + TEST_USER + "@localhost:" + testPort + + "/doesntmatter", + defaultCloneDir, null, + "IdentityFile " + privateKey1.getAbsolutePath(), + "Ciphers aes192-ctr"); + } + + @Test + public void testCipherModificationAdd() throws Exception { + cloneWith( + "ssh://" + TEST_USER + "@localhost:" + testPort + + "/doesntmatter", + defaultCloneDir, null, + "IdentityFile " + privateKey1.getAbsolutePath(), + "Ciphers +3des-cbc"); + } + + @Test + public void testCipherModificationUnknown() throws Exception { + TransportException e = assertThrows(TransportException.class, + () -> cloneWith( + "ssh://" + TEST_USER + "@localhost:" + testPort + + "/doesntmatter", + defaultCloneDir, null, + "IdentityFile " + privateKey1.getAbsolutePath(), + // The server is not configured to use this deprecated + // algorithm + "Ciphers 3des-cbc")); + assertTrue(e.getLocalizedMessage().contains("3des-cbc")); + } } diff --git a/org.eclipse.jgit.ssh.apache/META-INF/MANIFEST.MF b/org.eclipse.jgit.ssh.apache/META-INF/MANIFEST.MF index ac9d96499b..404129d0f3 100644 --- a/org.eclipse.jgit.ssh.apache/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ssh.apache/META-INF/MANIFEST.MF @@ -6,9 +6,9 @@ Bundle-SymbolicName: org.eclipse.jgit.ssh.apache Bundle-Vendor: %Bundle-Vendor Bundle-Localization: OSGI-INF/l10n/plugin Bundle-ActivationPolicy: lazy -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-RequiredExecutionEnvironment: JavaSE-11 -Export-Package: org.eclipse.jgit.internal.transport.sshd;version="6.9.1";x-internal:=true; +Export-Package: org.eclipse.jgit.internal.transport.sshd;version="6.10.1";x-internal:=true; uses:="org.apache.sshd.client, org.apache.sshd.client.auth, org.apache.sshd.client.auth.keyboard, @@ -23,18 +23,18 @@ Export-Package: org.eclipse.jgit.internal.transport.sshd;version="6.9.1";x-inter org.apache.sshd.common.signature, org.apache.sshd.common.util.buffer, org.eclipse.jgit.transport", - org.eclipse.jgit.internal.transport.sshd.agent;version="6.9.1";x-internal:=true, - org.eclipse.jgit.internal.transport.sshd.auth;version="6.9.1";x-internal:=true, - org.eclipse.jgit.internal.transport.sshd.pkcs11;version="6.9.1";x-internal:=true, - org.eclipse.jgit.internal.transport.sshd.proxy;version="6.9.1";x-friends:="org.eclipse.jgit.ssh.apache.test", - org.eclipse.jgit.transport.sshd;version="6.9.1"; + org.eclipse.jgit.internal.transport.sshd.agent;version="6.10.1";x-internal:=true, + org.eclipse.jgit.internal.transport.sshd.auth;version="6.10.1";x-internal:=true, + org.eclipse.jgit.internal.transport.sshd.pkcs11;version="6.10.1";x-internal:=true, + org.eclipse.jgit.internal.transport.sshd.proxy;version="6.10.1";x-friends:="org.eclipse.jgit.ssh.apache.test", + org.eclipse.jgit.transport.sshd;version="6.10.1"; uses:="org.eclipse.jgit.transport, org.apache.sshd.client.config.hosts, org.apache.sshd.common.keyprovider, org.eclipse.jgit.util, org.apache.sshd.client.session, org.apache.sshd.client.keyverifier", - org.eclipse.jgit.transport.sshd.agent;version="6.9.1", + org.eclipse.jgit.transport.sshd.agent;version="6.10.1", sun.security.x509 Import-Package: net.i2p.crypto.eddsa;version="[0.3.0,0.4.0)", org.apache.sshd.agent;version="[2.12.0,2.13.0)", @@ -53,6 +53,7 @@ Import-Package: net.i2p.crypto.eddsa;version="[0.3.0,0.4.0)", org.apache.sshd.common;version="[2.12.0,2.13.0)", org.apache.sshd.common.auth;version="[2.12.0,2.13.0)", org.apache.sshd.common.channel;version="[2.12.0,2.13.0)", + org.apache.sshd.common.cipher;version="[2.12.0,2.13.0)", org.apache.sshd.common.compression;version="[2.12.0,2.13.0)", org.apache.sshd.common.config.keys;version="[2.12.0,2.13.0)", org.apache.sshd.common.config.keys.loader;version="[2.12.0,2.13.0)", @@ -88,12 +89,12 @@ Import-Package: net.i2p.crypto.eddsa;version="[0.3.0,0.4.0)", org.apache.sshd.sftp;version="[2.12.0,2.13.0)", org.apache.sshd.sftp.client;version="[2.12.0,2.13.0)", org.apache.sshd.sftp.common;version="[2.12.0,2.13.0)", - org.eclipse.jgit.annotations;version="[6.9.1,6.10.0)", - org.eclipse.jgit.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.fnmatch;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.transport.ssh;version="[6.9.1,6.10.0)", - org.eclipse.jgit.nls;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", + org.eclipse.jgit.annotations;version="[6.10.1,6.11.0)", + org.eclipse.jgit.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.fnmatch;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.transport.ssh;version="[6.10.1,6.11.0)", + org.eclipse.jgit.nls;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", org.slf4j;version="[1.7.0,3.0.0)" diff --git a/org.eclipse.jgit.ssh.apache/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.ssh.apache/META-INF/SOURCE-MANIFEST.MF index 5e7a06c8ab..29482ec3c1 100644 --- a/org.eclipse.jgit.ssh.apache/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.ssh.apache/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.ssh.apache - Sources Bundle-SymbolicName: org.eclipse.jgit.ssh.apache.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.ssh.apache;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.ssh.apache;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.ssh.apache/pom.xml b/org.eclipse.jgit.ssh.apache/pom.xml index 68b2360449..d73ab40086 100644 --- a/org.eclipse.jgit.ssh.apache/pom.xml +++ b/org.eclipse.jgit.ssh.apache/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ssh.apache</artifactId> diff --git a/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/JGitClientSession.java b/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/JGitClientSession.java index c19a04d7e5..32d6facbc3 100644 --- a/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/JGitClientSession.java +++ b/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/JGitClientSession.java @@ -20,6 +20,7 @@ import java.security.PublicKey; import java.util.ArrayList; import java.util.Collection; import java.util.Collections; +import java.util.EnumSet; import java.util.HashSet; import java.util.Iterator; import java.util.LinkedHashSet; @@ -28,6 +29,7 @@ import java.util.Map; import java.util.Objects; import java.util.Set; import java.util.function.Supplier; +import java.util.stream.Collectors; import org.apache.sshd.client.ClientBuilder; import org.apache.sshd.client.ClientFactoryManager; @@ -36,8 +38,12 @@ import org.apache.sshd.client.keyverifier.ServerKeyVerifier; import org.apache.sshd.client.session.ClientSessionImpl; import org.apache.sshd.common.AttributeRepository; import org.apache.sshd.common.FactoryManager; +import org.apache.sshd.common.NamedFactory; import org.apache.sshd.common.NamedResource; import org.apache.sshd.common.PropertyResolver; +import org.apache.sshd.common.cipher.BuiltinCiphers; +import org.apache.sshd.common.cipher.Cipher; +import org.apache.sshd.common.cipher.CipherFactory; import org.apache.sshd.common.config.keys.KeyUtils; import org.apache.sshd.common.io.IoSession; import org.apache.sshd.common.io.IoWriteFuture; @@ -86,12 +92,21 @@ public class JGitClientSession extends ClientSessionImpl { */ private static final int DEFAULT_MAX_IDENTIFICATION_SIZE = 64 * 1024; - private static final AttributeKey<Boolean> INITIAL_KEX_DONE = new AttributeKey<>(); + /** + * Cipher implementations that we never ever want to use, even if Apache + * MINA SSHD has implementations for them. + */ + private static final Set<? extends CipherFactory> FORBIDDEN_CIPHERS = EnumSet + .of(BuiltinCiphers.none); private HostConfigEntry hostConfig; private CredentialsProvider credentialsProvider; + private boolean isInitialKex = true; + + private List<NamedFactory<Cipher>> ciphers; + private volatile StatefulProxyConnector proxyHandler; /** @@ -349,8 +364,7 @@ public class JGitClientSession extends ClientSessionImpl { protected String resolveSessionKexProposal(String hostKeyTypes) throws IOException { String kexMethods = String.join(",", determineKexProposal()); //$NON-NLS-1$ - Boolean isRekey = getAttribute(INITIAL_KEX_DONE); - if (isRekey == null || !isRekey.booleanValue()) { + if (isInitialKex) { // First time KexExtensionHandler extHandler = getKexExtensionHandler(); if (extHandler != null && extHandler.isKexExtensionsAvailable(this, @@ -361,7 +375,7 @@ public class JGitClientSession extends ClientSessionImpl { kexMethods += ',' + KexExtensions.CLIENT_KEX_EXTENSION; } } - setAttribute(INITIAL_KEX_DONE, Boolean.TRUE); + isInitialKex = false; } if (log.isDebugEnabled()) { log.debug(SshConstants.KEX_ALGORITHMS + ' ' + kexMethods); @@ -369,6 +383,46 @@ public class JGitClientSession extends ClientSessionImpl { return kexMethods; } + @Override + public List<NamedFactory<Cipher>> getCipherFactories() { + if (ciphers == null) { + List<NamedFactory<Cipher>> defaultCiphers = super.getCipherFactories(); + HostConfigEntry config = resolveAttribute( + JGitSshClient.HOST_CONFIG_ENTRY); + String algorithms = config.getProperty(SshConstants.CIPHERS); + if (!StringUtils.isEmptyOrNull(algorithms)) { + List<String> defaultCipherNames = defaultCiphers + .stream().map(NamedFactory::getName) + .collect(Collectors.toCollection(ArrayList::new)); + Set<String> allKnownCiphers = new HashSet<>(); + BuiltinCiphers.VALUES.stream() + .filter(c -> !FORBIDDEN_CIPHERS.contains(c)) + .filter(CipherFactory::isSupported) + .forEach(c -> allKnownCiphers.add(c.getName())); + BuiltinCiphers.getRegisteredExtensions().stream() + .filter(CipherFactory::isSupported) + .forEach(c -> allKnownCiphers.add(c.getName())); + List<String> sessionCipherNames = modifyAlgorithmList( + defaultCipherNames, allKnownCiphers, algorithms, + SshConstants.CIPHERS); + if (sessionCipherNames.isEmpty()) { + log.warn(format(SshdText.get().configNoKnownAlgorithms, + SshConstants.CIPHERS, algorithms)); + ciphers = defaultCiphers; + } else { + List<NamedFactory<Cipher>> sessionCiphers = new ArrayList<>( + sessionCipherNames.size()); + sessionCipherNames.forEach(name -> sessionCiphers + .add(BuiltinCiphers.resolveFactory(name))); + ciphers = sessionCiphers; + } + } else { + ciphers = defaultCiphers; + } + } + return ciphers; + } + /** * Modifies a given algorithm list according to a list from the ssh config, * including add ('+'), remove ('-') and reordering ('^') operators. diff --git a/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/JGitPublicKeyAuthentication.java b/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/JGitPublicKeyAuthentication.java index b0b1028daa..6aace4753a 100644 --- a/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/JGitPublicKeyAuthentication.java +++ b/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/JGitPublicKeyAuthentication.java @@ -17,6 +17,7 @@ import static org.eclipse.jgit.transport.SshConstants.PUBKEY_ACCEPTED_ALGORITHMS import java.io.File; import java.io.IOException; +import java.io.StreamCorruptedException; import java.net.URISyntaxException; import java.nio.file.Files; import java.nio.file.InvalidPathException; @@ -355,20 +356,20 @@ public class JGitPublicKeyAuthentication extends UserAuthPublicKey { // only warn about non-existing files in case the key file is // not derived if (!isDerived) { - log.warn("{}", //$NON-NLS-1$ + log.warn(LOG_FORMAT, format(SshdText.get().cannotReadPublicKey, keyFile)); } - } catch (InvalidPathException | IOException e) { - log.warn("{}", //$NON-NLS-1$ - format(SshdText.get().cannotReadPublicKey, keyFile), e); - } catch (GeneralSecurityException e) { + } catch (GeneralSecurityException | StreamCorruptedException e) { // ignore in case this is not a derived key path, as in most // cases this specifies a private key if (isDerived) { - log.warn("{}", //$NON-NLS-1$ + log.warn(LOG_FORMAT, format(SshdText.get().cannotReadPublicKey, keyFile), e); } + } catch (InvalidPathException | IOException e) { + log.warn(LOG_FORMAT, + format(SshdText.get().cannotReadPublicKey, keyFile), e); } return null; } diff --git a/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/KnownHostEntryReader.java b/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/KnownHostEntryReader.java index a00e5d96ac..96829b7365 100644 --- a/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/KnownHostEntryReader.java +++ b/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/KnownHostEntryReader.java @@ -18,9 +18,9 @@ import java.io.BufferedReader; import java.io.IOException; import java.nio.file.Files; import java.nio.file.Path; +import java.util.ArrayList; import java.util.Arrays; import java.util.Collection; -import java.util.LinkedList; import java.util.List; import java.util.stream.Collectors; @@ -65,7 +65,7 @@ public class KnownHostEntryReader { */ public static List<KnownHostEntry> readFromFile(Path path) throws IOException { - List<KnownHostEntry> result = new LinkedList<>(); + List<KnownHostEntry> result = new ArrayList<>(); try (BufferedReader r = Files.newBufferedReader(path, UTF_8)) { r.lines().forEachOrdered(l -> { if (l == null) { diff --git a/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/OpenSshServerKeyDatabase.java b/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/OpenSshServerKeyDatabase.java index 65ba5be0c5..2b4f7e50ff 100644 --- a/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/OpenSshServerKeyDatabase.java +++ b/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/internal/transport/sshd/OpenSshServerKeyDatabase.java @@ -31,7 +31,6 @@ import java.util.ArrayList; import java.util.Arrays; import java.util.Collection; import java.util.Collections; -import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.Random; @@ -587,7 +586,7 @@ public class OpenSshServerKeyDatabase if (rawEntries == null || rawEntries.isEmpty()) { return Collections.emptyList(); } - List<HostEntryPair> newEntries = new LinkedList<>(); + List<HostEntryPair> newEntries = new ArrayList<>(); for (KnownHostEntry entry : rawEntries) { AuthorizedKeyEntry keyPart = entry.getKeyEntry(); if (keyPart == null) { diff --git a/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/transport/sshd/SshdSession.java b/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/transport/sshd/SshdSession.java index b94ccc6d4f..96316ba1aa 100644 --- a/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/transport/sshd/SshdSession.java +++ b/org.eclipse.jgit.ssh.apache/src/org/eclipse/jgit/transport/sshd/SshdSession.java @@ -23,7 +23,6 @@ import java.util.ArrayList; import java.util.Collection; import java.util.Collections; import java.util.EnumSet; -import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.concurrent.CopyOnWriteArrayList; @@ -263,7 +262,7 @@ public class SshdSession implements RemoteSession2 { private List<URIish> parseProxyJump(String proxyJump) throws URISyntaxException { String[] hops = proxyJump.split(","); //$NON-NLS-1$ - List<URIish> result = new LinkedList<>(); + List<URIish> result = new ArrayList<>(); for (String hop : hops) { // There shouldn't be any whitespace, but let's be lenient hop = hop.trim(); diff --git a/org.eclipse.jgit.ssh.jsch.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.ssh.jsch.test/META-INF/MANIFEST.MF index 1af338b73e..50168d8158 100644 --- a/org.eclipse.jgit.ssh.jsch.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ssh.jsch.test/META-INF/MANIFEST.MF @@ -3,19 +3,19 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.ssh.jsch.test Bundle-SymbolicName: org.eclipse.jgit.ssh.jsch.test -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-Localization: plugin Bundle-RequiredExecutionEnvironment: JavaSE-11 Require-Bundle: org.hamcrest.core;bundle-version="[1.3.0,2.0.0)" Import-Package: com.jcraft.jsch;version="[0.1.54,0.2.0)", - org.eclipse.jgit.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit.ssh;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.ssh.jsch;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", + org.eclipse.jgit.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit.ssh;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.ssh.jsch;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", org.junit;version="[4.13,5.0.0)", org.junit.experimental.theories;version="[4.13,5.0.0)", org.junit.runner;version="[4.13,5.0.0)" diff --git a/org.eclipse.jgit.ssh.jsch.test/pom.xml b/org.eclipse.jgit.ssh.jsch.test/pom.xml index d70dc1216e..c5344917a0 100644 --- a/org.eclipse.jgit.ssh.jsch.test/pom.xml +++ b/org.eclipse.jgit.ssh.jsch.test/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ssh.jsch.test</artifactId> diff --git a/org.eclipse.jgit.ssh.jsch/META-INF/MANIFEST.MF b/org.eclipse.jgit.ssh.jsch/META-INF/MANIFEST.MF index 36e2de2117..88b2e13f76 100644 --- a/org.eclipse.jgit.ssh.jsch/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ssh.jsch/META-INF/MANIFEST.MF @@ -3,19 +3,19 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.ssh.jsch Bundle-SymbolicName: org.eclipse.jgit.ssh.jsch;singleton:=true -Fragment-Host: org.eclipse.jgit;bundle-version="[6.9.1,6.10.0)" +Fragment-Host: org.eclipse.jgit;bundle-version="[6.10.1,6.11.0)" Bundle-Vendor: %Bundle-Vendor Bundle-Localization: OSGI-INF/l10n/jsch Bundle-ActivationPolicy: lazy -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-RequiredExecutionEnvironment: JavaSE-11 -Export-Package: org.eclipse.jgit.transport.ssh.jsch;version="6.9.1" +Export-Package: org.eclipse.jgit.transport.ssh.jsch;version="6.10.1" Import-Package: com.jcraft.jsch;version="[0.1.37,0.2.0)", - org.eclipse.jgit.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.transport.ssh;version="[6.9.1,6.10.0)", - org.eclipse.jgit.nls;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util.io;version="[6.9.1,6.10.0)", + org.eclipse.jgit.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.transport.ssh;version="[6.10.1,6.11.0)", + org.eclipse.jgit.nls;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util.io;version="[6.10.1,6.11.0)", org.slf4j;version="[1.7.0,3.0.0)" diff --git a/org.eclipse.jgit.ssh.jsch/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.ssh.jsch/META-INF/SOURCE-MANIFEST.MF index 50747f6e21..408739ba05 100644 --- a/org.eclipse.jgit.ssh.jsch/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.ssh.jsch/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.ssh.jsch - Sources Bundle-SymbolicName: org.eclipse.jgit.ssh.jsch.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.ssh.jsch;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.ssh.jsch;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.ssh.jsch/pom.xml b/org.eclipse.jgit.ssh.jsch/pom.xml index bd0ff6084f..994ff12618 100644 --- a/org.eclipse.jgit.ssh.jsch/pom.xml +++ b/org.eclipse.jgit.ssh.jsch/pom.xml @@ -17,7 +17,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ssh.jsch</artifactId> diff --git a/org.eclipse.jgit.test/META-INF/MANIFEST.MF b/org.eclipse.jgit.test/META-INF/MANIFEST.MF index fb6255eed9..4f09990058 100644 --- a/org.eclipse.jgit.test/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.test/META-INF/MANIFEST.MF @@ -3,7 +3,7 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.test Bundle-SymbolicName: org.eclipse.jgit.test -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Localization: plugin Bundle-Vendor: %Bundle-Vendor Bundle-RequiredExecutionEnvironment: JavaSE-11 @@ -21,64 +21,64 @@ Import-Package: com.googlecode.javaewah;version="[1.1.6,2.0.0)", org.apache.commons.io;version="[2.15.0,3.0.0)", org.apache.commons.io.output;version="[2.15.0,3.0.0)", org.assertj.core.api;version="[3.14.0,4.0.0)", - org.eclipse.jgit.annotations;version="[6.9.1,6.10.0)", - org.eclipse.jgit.api;version="[6.9.1,6.10.0)", - org.eclipse.jgit.api.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.archive;version="[6.9.1,6.10.0)", - org.eclipse.jgit.attributes;version="[6.9.1,6.10.0)", - org.eclipse.jgit.awtui;version="[6.9.1,6.10.0)", - org.eclipse.jgit.blame;version="[6.9.1,6.10.0)", - org.eclipse.jgit.diff;version="[6.9.1,6.10.0)", - org.eclipse.jgit.dircache;version="[6.9.1,6.10.0)", - org.eclipse.jgit.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.events;version="[6.9.1,6.10.0)", - org.eclipse.jgit.fnmatch;version="[6.9.1,6.10.0)", - org.eclipse.jgit.gitrepo;version="[6.9.1,6.10.0)", - org.eclipse.jgit.hooks;version="[6.9.1,6.10.0)", - org.eclipse.jgit.ignore;version="[6.9.1,6.10.0)", - org.eclipse.jgit.ignore.internal;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.diff;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.diffmergetool;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.fsck;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.commitgraph;version="6.9.1", - org.eclipse.jgit.internal.storage.dfs;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.io;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.memory;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.pack;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.storage.reftable;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.transport.connectivity;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.transport.http;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.transport.parser;version="[6.9.1,6.10.0)", - org.eclipse.jgit.internal.transport.ssh;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit;version="[6.9.1,6.10.0)", - org.eclipse.jgit.junit.time;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lfs;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib.internal;version="[6.9.1,6.10.0)", - org.eclipse.jgit.logging;version="[6.9.1,6.10.0)", - org.eclipse.jgit.merge;version="[6.9.1,6.10.0)", - org.eclipse.jgit.nls;version="[6.9.1,6.10.0)", - org.eclipse.jgit.notes;version="[6.9.1,6.10.0)", - org.eclipse.jgit.patch;version="[6.9.1,6.10.0)", - org.eclipse.jgit.pgm;version="[6.9.1,6.10.0)", - org.eclipse.jgit.pgm.internal;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revplot;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk.filter;version="[6.9.1,6.10.0)", - org.eclipse.jgit.storage.file;version="[6.9.1,6.10.0)", - org.eclipse.jgit.storage.pack;version="[6.9.1,6.10.0)", - org.eclipse.jgit.submodule;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.http;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport.resolver;version="[6.9.1,6.10.0)", - org.eclipse.jgit.treewalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.treewalk.filter;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util.io;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util.sha1;version="[6.9.1,6.10.0)", + org.eclipse.jgit.annotations;version="[6.10.1,6.11.0)", + org.eclipse.jgit.api;version="[6.10.1,6.11.0)", + org.eclipse.jgit.api.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.archive;version="[6.10.1,6.11.0)", + org.eclipse.jgit.attributes;version="[6.10.1,6.11.0)", + org.eclipse.jgit.awtui;version="[6.10.1,6.11.0)", + org.eclipse.jgit.blame;version="[6.10.1,6.11.0)", + org.eclipse.jgit.diff;version="[6.10.1,6.11.0)", + org.eclipse.jgit.dircache;version="[6.10.1,6.11.0)", + org.eclipse.jgit.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.events;version="[6.10.1,6.11.0)", + org.eclipse.jgit.fnmatch;version="[6.10.1,6.11.0)", + org.eclipse.jgit.gitrepo;version="[6.10.1,6.11.0)", + org.eclipse.jgit.hooks;version="[6.10.1,6.11.0)", + org.eclipse.jgit.ignore;version="[6.10.1,6.11.0)", + org.eclipse.jgit.ignore.internal;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.diff;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.diffmergetool;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.fsck;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.commitgraph;version="6.10.1", + org.eclipse.jgit.internal.storage.dfs;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.io;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.memory;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.pack;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.storage.reftable;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.transport.connectivity;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.transport.http;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.transport.parser;version="[6.10.1,6.11.0)", + org.eclipse.jgit.internal.transport.ssh;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit;version="[6.10.1,6.11.0)", + org.eclipse.jgit.junit.time;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lfs;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib.internal;version="[6.10.1,6.11.0)", + org.eclipse.jgit.logging;version="[6.10.1,6.11.0)", + org.eclipse.jgit.merge;version="[6.10.1,6.11.0)", + org.eclipse.jgit.nls;version="[6.10.1,6.11.0)", + org.eclipse.jgit.notes;version="[6.10.1,6.11.0)", + org.eclipse.jgit.patch;version="[6.10.1,6.11.0)", + org.eclipse.jgit.pgm;version="[6.10.1,6.11.0)", + org.eclipse.jgit.pgm.internal;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revplot;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk.filter;version="[6.10.1,6.11.0)", + org.eclipse.jgit.storage.file;version="[6.10.1,6.11.0)", + org.eclipse.jgit.storage.pack;version="[6.10.1,6.11.0)", + org.eclipse.jgit.submodule;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.http;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport.resolver;version="[6.10.1,6.11.0)", + org.eclipse.jgit.treewalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.treewalk.filter;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util.io;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util.sha1;version="[6.10.1,6.11.0)", org.junit;version="[4.13,5.0.0)", org.junit.experimental.theories;version="[4.13,5.0.0)", org.junit.function;version="[4.13.0,5.0.0)", diff --git a/org.eclipse.jgit.test/pom.xml b/org.eclipse.jgit.test/pom.xml index fd40586661..b0ea83cd56 100644 --- a/org.eclipse.jgit.test/pom.xml +++ b/org.eclipse.jgit.test/pom.xml @@ -19,7 +19,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.test</artifactId> diff --git a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/ConflictOutOfBounds.patch b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/ConflictOutOfBounds.patch new file mode 100644 index 0000000000..6e7448b95c --- /dev/null +++ b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/ConflictOutOfBounds.patch @@ -0,0 +1,10 @@ +diff --git a/ConflictOutOfBounds b/ConflictOutOfBounds +index 0000000..de98044 +--- a/ConflictOutOfBounds ++++ b/ConflictOutOfBounds +@@ -25,4 +25,4 @@ + line3 +-lineA ++lineB + line5 + line6 diff --git a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/ConflictOutOfBounds_PostImage b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/ConflictOutOfBounds_PostImage new file mode 100644 index 0000000000..4e5d5b2d88 --- /dev/null +++ b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/ConflictOutOfBounds_PostImage @@ -0,0 +1,15 @@ +line1 +line2 +line3 +line4 +line5 +line6 +line7 +line8 +<<<<<<< HEAD +======= +line3 +lineB +line5 +line6 +>>>>>>> PATCH diff --git a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/ConflictOutOfBounds_PreImage b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/ConflictOutOfBounds_PreImage new file mode 100644 index 0000000000..f62562a216 --- /dev/null +++ b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/ConflictOutOfBounds_PreImage @@ -0,0 +1,8 @@ +line1 +line2 +line3 +line4 +line5 +line6 +line7 +line8 diff --git a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/allowconflict.patch b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/allowconflict.patch new file mode 100644 index 0000000000..a99e636382 --- /dev/null +++ b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/allowconflict.patch @@ -0,0 +1,10 @@ +diff --git a/allowconflict b/allowconflict +index 0000000..de98044 +--- a/allowconflict ++++ b/allowconflict +@@ -3,4 +3,4 @@ + line3 +-lineA ++lineB + line5 + line6 diff --git a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/allowconflict_PostImage b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/allowconflict_PostImage new file mode 100644 index 0000000000..a963b40dfe --- /dev/null +++ b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/allowconflict_PostImage @@ -0,0 +1,15 @@ +line1 +line2 +<<<<<<< HEAD +line3 +line4 +line5 +line6 +======= +line3 +lineB +line5 +line6 +>>>>>>> PATCH +line7 +line8 diff --git a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/allowconflict_PreImage b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/allowconflict_PreImage new file mode 100644 index 0000000000..f62562a216 --- /dev/null +++ b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/allowconflict_PreImage @@ -0,0 +1,8 @@ +line1 +line2 +line3 +line4 +line5 +line6 +line7 +line8 diff --git a/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/allowconflict_file_deleted.patch b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/allowconflict_file_deleted.patch new file mode 100644 index 0000000000..c9655a5e6b --- /dev/null +++ b/org.eclipse.jgit.test/tst-rsrc/org/eclipse/jgit/diff/allowconflict_file_deleted.patch @@ -0,0 +1,10 @@ +diff --git a/allowconflict_file_deleted b/allowconflict_file_deleted +index 0000000..de98044 +--- a/allowconflict_file_deleted ++++ b/allowconflict_file_deleted +@@ -3,4 +3,4 @@ + line3 +-lineA ++lineB + line5 + line6 diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/AddCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/AddCommandTest.java index db2d5d1404..1c2e995bbb 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/AddCommandTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/AddCommandTest.java @@ -13,6 +13,8 @@ package org.eclipse.jgit.api; import static java.nio.charset.StandardCharsets.UTF_8; import static org.eclipse.jgit.util.FileUtils.RECURSIVE; import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNotEquals; +import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertTrue; import static org.junit.Assert.fail; import static org.junit.Assume.assumeTrue; @@ -607,14 +609,14 @@ public class AddCommandTest extends RepositoryTestCase { try (Git git = new Git(db)) { DirCache dc = git.add().addFilepattern("a.txt").call(); - dc.getEntry(0).getObjectId(); + ObjectId oid = dc.getEntry(0).getObjectId(); try (PrintWriter writer = new PrintWriter(file, UTF_8.name())) { writer.print("other content"); } dc = git.add().addFilepattern("a.txt").call(); - + assertNotEquals(oid, dc.getEntry(0).getObjectId()); assertEquals( "[a.txt, mode:100644, content:other content]", indexState(CONTENT)); @@ -632,7 +634,7 @@ public class AddCommandTest extends RepositoryTestCase { try (Git git = new Git(db)) { DirCache dc = git.add().addFilepattern("a.txt").call(); - dc.getEntry(0).getObjectId(); + ObjectId oid = dc.getEntry(0).getObjectId(); git.commit().setMessage("commit a.txt").call(); @@ -641,7 +643,7 @@ public class AddCommandTest extends RepositoryTestCase { } dc = git.add().addFilepattern("a.txt").call(); - + assertNotEquals(oid, dc.getEntry(0).getObjectId()); assertEquals( "[a.txt, mode:100644, content:other content]", indexState(CONTENT)); @@ -659,12 +661,12 @@ public class AddCommandTest extends RepositoryTestCase { try (Git git = new Git(db)) { DirCache dc = git.add().addFilepattern("a.txt").call(); - dc.getEntry(0).getObjectId(); + ObjectId oid = dc.getEntry(0).getObjectId(); FileUtils.delete(file); // is supposed to do nothing dc = git.add().addFilepattern("a.txt").call(); - + assertEquals(oid, dc.getEntry(0).getObjectId()); assertEquals( "[a.txt, mode:100644, content:content]", indexState(CONTENT)); @@ -684,12 +686,12 @@ public class AddCommandTest extends RepositoryTestCase { git.commit().setMessage("commit a.txt").call(); - dc.getEntry(0).getObjectId(); + ObjectId oid = dc.getEntry(0).getObjectId(); FileUtils.delete(file); // is supposed to do nothing dc = git.add().addFilepattern("a.txt").call(); - + assertEquals(oid, dc.getEntry(0).getObjectId()); assertEquals( "[a.txt, mode:100644, content:content]", indexState(CONTENT)); @@ -878,7 +880,7 @@ public class AddCommandTest extends RepositoryTestCase { } } // Help null pointer analysis. - assert lastFile != null; + assertNotNull(lastFile); // Wait a bit. If entries are "racily clean", we'll recompute // hashes from the disk files, and then the second add is also slow. // We want to test the normal case. @@ -1259,7 +1261,7 @@ public class AddCommandTest extends RepositoryTestCase { "[git-link-dir, mode:160000]", indexState(0)); Set<String> untrackedFiles = git.status().call().getUntracked(); - assert (untrackedFiles.isEmpty()); + assertTrue(untrackedFiles.isEmpty()); } } @@ -1274,7 +1276,8 @@ public class AddCommandTest extends RepositoryTestCase { ConfigConstants.CONFIG_KEY_DIRNOGITLINKS, true); config.save(); - assert (db.getConfig().get(WorkingTreeOptions.KEY).isDirNoGitLinks()); + assertTrue( + db.getConfig().get(WorkingTreeOptions.KEY).isDirNoGitLinks()); try (Git git = new Git(db)) { git.add().addFilepattern("nested-repo").call(); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/CommitAndLogCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/CommitAndLogCommandTest.java index b7abba4209..57e5d4958f 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/CommitAndLogCommandTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/CommitAndLogCommandTest.java @@ -284,11 +284,10 @@ public class CommitAndLogCommandTest extends RepositoryTestCase { // template) chars = commit.getFullMessage().getBytes(UTF_8); int lineStart = 0; - int lineEnd = 0; for (int i = 0; i < 4; i++) { lineStart = RawParseUtils.nextLF(chars, lineStart); } - lineEnd = RawParseUtils.nextLF(chars, lineStart); + int lineEnd = RawParseUtils.nextLF(chars, lineStart); String line = RawParseUtils.decode(chars, lineStart, lineEnd); @@ -303,13 +302,12 @@ public class CommitAndLogCommandTest extends RepositoryTestCase { // we should find the untouched template chars = commit.getFullMessage().getBytes(UTF_8); lineStart = 0; - lineEnd = 0; for (int i = 0; i < 4; i++) { lineStart = RawParseUtils.nextLF(chars, lineStart); } lineEnd = RawParseUtils.nextLF(chars, lineStart); - line = RawParseUtils.decode(chars, lineStart, lineEnd); + RawParseUtils.decode(chars, lineStart, lineEnd); assertTrue(commit.getFullMessage() .contains("Change-Id: I" + ObjectId.zeroId().getName())); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/PathCheckoutCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/PathCheckoutCommandTest.java index f52b715d39..cf952d2b77 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/PathCheckoutCommandTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/PathCheckoutCommandTest.java @@ -172,9 +172,9 @@ public class PathCheckoutCommandTest extends RepositoryTestCase { @Test public void testUpdateWorkingDirectoryFromIndex() throws Exception { CheckoutCommand co = git.checkout(); - File written = writeTrashFile(FILE1, "3a"); + writeTrashFile(FILE1, "3a"); git.add().addFilepattern(FILE1).call(); - written = writeTrashFile(FILE1, ""); + File written = writeTrashFile(FILE1, ""); assertEquals("", read(written)); co.addPath(FILE1).call(); assertEquals("3a", read(written)); @@ -185,9 +185,9 @@ public class PathCheckoutCommandTest extends RepositoryTestCase { public void testUpdateWorkingDirectoryFromHeadWithIndexChange() throws Exception { CheckoutCommand co = git.checkout(); - File written = writeTrashFile(FILE1, "3a"); + writeTrashFile(FILE1, "3a"); git.add().addFilepattern(FILE1).call(); - written = writeTrashFile(FILE1, ""); + File written = writeTrashFile(FILE1, ""); assertEquals("", read(written)); co.addPath(FILE1).setStartPoint("HEAD").call(); assertEquals("3", read(written)); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RebaseCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RebaseCommandTest.java index 987c98e232..02e3a2e06f 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RebaseCommandTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/RebaseCommandTest.java @@ -2650,7 +2650,9 @@ public class RebaseCommandTest extends RepositoryTestCase { assertEquals("1111111", firstLine.getCommit().name()); assertEquals("pick", firstLine.getAction().toToken()); } catch (Exception e) { - fail("Valid parsable RebaseTodoLine that has been commented out should allow to change the action, but failed"); + throw new AssertionError( + "Valid parsable RebaseTodoLine that has been commented out should allow to change the action, but failed", + e); } assertEquals("2222222", steps.get(1).getCommit().name()); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StashDropCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StashDropCommandTest.java index f9af968a7e..c81731d746 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StashDropCommandTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/api/StashDropCommandTest.java @@ -69,8 +69,7 @@ public class StashDropCommandTest extends RepositoryTestCase { RevCommit stashed = git.stashCreate().call(); assertNotNull(stashed); stashRef = git.getRepository().exactRef(Constants.R_STASH); - assertEquals(stashed, - git.getRepository().exactRef(Constants.R_STASH).getObjectId()); + assertEquals(stashed, stashRef.getObjectId()); try { assertNull(git.stashDrop().setStashRef(100).call()); fail("Exception not thrown"); @@ -88,8 +87,7 @@ public class StashDropCommandTest extends RepositoryTestCase { RevCommit stashed = git.stashCreate().call(); assertNotNull(stashed); stashRef = git.getRepository().exactRef(Constants.R_STASH); - assertEquals(stashed, - git.getRepository().exactRef(Constants.R_STASH).getObjectId()); + assertEquals(stashed, stashRef.getObjectId()); assertNull(git.stashDrop().call()); stashRef = git.getRepository().exactRef(Constants.R_STASH); assertNull(stashRef); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/attributes/CGitAttributesTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/attributes/CGitAttributesTest.java index 5638c1f7d9..562a515721 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/attributes/CGitAttributesTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/attributes/CGitAttributesTest.java @@ -104,10 +104,9 @@ public class CGitAttributesTest extends RepositoryTestCase { UTF_8))) { r.lines().forEach(line -> { // Parse the line and add to result map - int start = 0; int i = line.indexOf(':'); String path = line.substring(0, i).trim(); - start = i + 1; + int start = i + 1; i = line.indexOf(':', start); String key = line.substring(start, i).trim(); String value = line.substring(i + 1).trim(); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/attributes/TreeWalkAttributeTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/attributes/TreeWalkAttributeTest.java index 73abd2d37e..698fdb31a8 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/attributes/TreeWalkAttributeTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/attributes/TreeWalkAttributeTest.java @@ -791,7 +791,7 @@ public class TreeWalkAttributeTest extends RepositoryTestCase { for (Attribute a : attributes) { ret.add(a); } - return (ret); + return ret; } private File writeAttributesFile(String name, String... rules) diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/attributes/merge/MergeGitAttributeTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/attributes/merge/MergeGitAttributeTest.java index 795029188d..009ca8a152 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/attributes/merge/MergeGitAttributeTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/attributes/merge/MergeGitAttributeTest.java @@ -10,7 +10,6 @@ package org.eclipse.jgit.attributes.merge; import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertNotNull; import static org.junit.Assert.assertNull; import static org.junit.Assert.assertTrue; @@ -20,6 +19,7 @@ import java.io.File; import java.io.FileInputStream; import java.io.IOException; import java.io.InputStream; +import java.io.UncheckedIOException; import java.nio.file.Files; import java.util.function.Consumer; @@ -42,7 +42,6 @@ import org.eclipse.jgit.revwalk.RevCommit; import org.eclipse.jgit.treewalk.FileTreeIterator; import org.eclipse.jgit.treewalk.TreeWalk; import org.eclipse.jgit.treewalk.filter.PathFilter; -import org.junit.Ignore; import org.junit.Test; public class MergeGitAttributeTest extends RepositoryTestCase { @@ -99,19 +98,19 @@ public class MergeGitAttributeTest extends RepositoryTestCase { try { writeTrashFile("main.cat", "A\n" + "B\n" + "C\n" + "D\n"); } catch (IOException e) { - e.printStackTrace(); + throw new UncheckedIOException(e); } }, g -> { try { writeTrashFile("main.cat", "A\n" + "B\n" + "C\n" + "F\n"); } catch (IOException e) { - e.printStackTrace(); + throw new UncheckedIOException(e); } }, g -> { try { writeTrashFile("main.cat", "A\n" + "E\n" + "C\n" + "D\n"); } catch (IOException e) { - e.printStackTrace(); + throw new UncheckedIOException(e); } })) { checkoutBranch(REFS_HEADS_LEFT); @@ -141,19 +140,19 @@ public class MergeGitAttributeTest extends RepositoryTestCase { writeTrashFile(".gitattributes", "*.cat -merge"); writeTrashFile("main.cat", "A\n" + "B\n" + "C\n" + "D\n"); } catch (IOException e) { - e.printStackTrace(); + throw new UncheckedIOException(e); } }, g -> { try { writeTrashFile("main.cat", "A\n" + "B\n" + "C\n" + "F\n"); } catch (IOException e) { - e.printStackTrace(); + throw new UncheckedIOException(e); } }, g -> { try { writeTrashFile("main.cat", "A\n" + "E\n" + "C\n" + "D\n"); } catch (IOException e) { - e.printStackTrace(); + throw new UncheckedIOException(e); } })) { // Check that the merge attribute is unset @@ -186,19 +185,19 @@ public class MergeGitAttributeTest extends RepositoryTestCase { writeTrashFile(".gitattributes", "*.txt -merge"); writeTrashFile("main.cat", "A\n" + "B\n" + "C\n" + "D\n"); } catch (IOException e) { - e.printStackTrace(); + throw new UncheckedIOException(e); } }, g -> { try { writeTrashFile("main.cat", "A\n" + "B\n" + "C\n" + "F\n"); } catch (IOException e) { - e.printStackTrace(); + throw new UncheckedIOException(e); } }, g -> { try { writeTrashFile("main.cat", "A\n" + "E\n" + "C\n" + "D\n"); } catch (IOException e) { - e.printStackTrace(); + throw new UncheckedIOException(e); } })) { // Check that the merge attribute is unset @@ -230,19 +229,19 @@ public class MergeGitAttributeTest extends RepositoryTestCase { writeTrashFile(".gitattributes", "*.cat merge=binary"); writeTrashFile("main.cat", "A\n" + "B\n" + "C\n" + "D\n"); } catch (IOException e) { - e.printStackTrace(); + throw new UncheckedIOException(e); } }, g -> { try { writeTrashFile("main.cat", "A\n" + "B\n" + "C\n" + "F\n"); } catch (IOException e) { - e.printStackTrace(); + throw new UncheckedIOException(e); } }, g -> { try { writeTrashFile("main.cat", "A\n" + "E\n" + "C\n" + "D\n"); } catch (IOException e) { - e.printStackTrace(); + throw new UncheckedIOException(e); } })) { // Check that the merge attribute is set to binary @@ -268,12 +267,7 @@ public class MergeGitAttributeTest extends RepositoryTestCase { } } - /* - * This test is commented because JGit add conflict markers in binary files. - * cf. https://www.eclipse.org/forums/index.php/t/1086511/ - */ @Test - @Ignore public void mergeBinaryFile_NoAttr_Conflict() throws IllegalStateException, IOException, NoHeadException, ConcurrentRefUpdateException, CheckoutConflictException, InvalidMergeHeadsException, @@ -433,7 +427,7 @@ public class MergeGitAttributeTest extends RepositoryTestCase { try (FileInputStream mergeResultFile = new FileInputStream( db.getWorkTree().toPath().resolve(ENABLED_CHECKED_GIF) .toFile())) { - assertFalse(contentEquals( + assertTrue(contentEquals( getClass().getResourceAsStream(ENABLED_CHECKED_GIF), mergeResultFile)); } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/dircache/DirCacheBuilderTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/dircache/DirCacheBuilderTest.java index 703d68b37c..61801106af 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/dircache/DirCacheBuilderTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/dircache/DirCacheBuilderTest.java @@ -218,7 +218,7 @@ public class DirCacheBuilderTest extends RepositoryTestCase { try { b.commit(); } catch (ReceivedEventMarkerException e) { - fail("unexpected IndexChangedEvent"); + throw new AssertionError("unexpected IndexChangedEvent", e); } } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/gitrepo/BareSuperprojectWriterTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/gitrepo/BareSuperprojectWriterTest.java index c3b93879b2..5065b57840 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/gitrepo/BareSuperprojectWriterTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/gitrepo/BareSuperprojectWriterTest.java @@ -12,6 +12,7 @@ package org.eclipse.jgit.gitrepo; import static org.hamcrest.MatcherAssert.assertThat; import static org.hamcrest.Matchers.containsInAnyOrder; import static org.hamcrest.Matchers.is; +import static org.hamcrest.Matchers.nullValue; import static org.mockito.Mockito.mock; import static org.mockito.Mockito.when; @@ -22,6 +23,7 @@ import java.util.List; import org.eclipse.jgit.gitrepo.BareSuperprojectWriter.BareWriterConfig; import org.eclipse.jgit.gitrepo.RepoCommand.RemoteReader; import org.eclipse.jgit.junit.RepositoryTestCase; +import org.eclipse.jgit.lib.Config; import org.eclipse.jgit.lib.ObjectId; import org.eclipse.jgit.lib.ObjectReader; import org.eclipse.jgit.lib.Repository; @@ -68,6 +70,49 @@ public class BareSuperprojectWriterTest extends RepositoryTestCase { } @Test + public void write_setGitModulesContents_pinned() throws Exception { + try (Repository bareRepo = createBareRepository()) { + RepoProject pinWithUpstream = new RepoProject("pinWithUpstream", + "path/x", "cbc0fae7e1911d27e1de37d364698dba4411c78b", + "remote", ""); + pinWithUpstream.setUrl("http://example.com/a"); + pinWithUpstream.setUpstream("branchX"); + + RepoProject pinWithoutUpstream = new RepoProject( + "pinWithoutUpstream", "path/y", + "cbc0fae7e1911d27e1de37d364698dba4411c78b", "remote", ""); + pinWithoutUpstream.setUrl("http://example.com/b"); + + RemoteReader mockRemoteReader = mock(RemoteReader.class); + + BareSuperprojectWriter w = new BareSuperprojectWriter(bareRepo, + null, "refs/heads/master", author, mockRemoteReader, + BareWriterConfig.getDefault(), List.of()); + + RevCommit commit = w + .write(Arrays.asList(pinWithUpstream, pinWithoutUpstream)); + + String contents = readContents(bareRepo, commit, ".gitmodules"); + Config cfg = new Config(); + cfg.fromText(contents); + + assertThat(cfg.getString("submodule", "pinWithUpstream", "path"), + is("path/x")); + assertThat(cfg.getString("submodule", "pinWithUpstream", "url"), + is("http://example.com/a")); + assertThat(cfg.getString("submodule", "pinWithUpstream", "ref"), + is("branchX")); + + assertThat(cfg.getString("submodule", "pinWithoutUpstream", "path"), + is("path/y")); + assertThat(cfg.getString("submodule", "pinWithoutUpstream", "url"), + is("http://example.com/b")); + assertThat(cfg.getString("submodule", "pinWithoutUpstream", "ref"), + nullValue()); + } + } + + @Test public void write_setExtraContents() throws Exception { try (Repository bareRepo = createBareRepository()) { RepoProject repoProject = new RepoProject("subprojectX", "path/to", diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/gitrepo/ManifestParserTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/gitrepo/ManifestParserTest.java index 20958a812c..fca27d32aa 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/gitrepo/ManifestParserTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/gitrepo/ManifestParserTest.java @@ -11,6 +11,7 @@ package org.eclipse.jgit.gitrepo; import static java.nio.charset.StandardCharsets.UTF_8; import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNull; import static org.junit.Assert.assertTrue; import static org.junit.Assert.fail; @@ -18,7 +19,9 @@ import java.io.ByteArrayInputStream; import java.io.IOException; import java.net.URI; import java.util.HashSet; +import java.util.Map; import java.util.Set; +import java.util.function.Function; import java.util.stream.Collectors; import java.util.stream.Stream; @@ -138,6 +141,72 @@ public class ManifestParserTest { .collect(Collectors.toSet())); } + @Test + public void testPinProjectWithUpstream() throws Exception { + StringBuilder xmlContent = new StringBuilder(); + xmlContent.append("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n") + .append("<manifest>") + .append("<remote name=\"remote1\" fetch=\".\" />") + .append("<default revision=\"master\" remote=\"remote1\" />") + .append("<project path=\"foo\" name=\"pin-with-upstream\"") + .append(" revision=\"9b2fe85c0279f4d5ac69f07ddcd48566c3555405\"") + .append(" upstream=\"branchX\"/>") + .append("<project path=\"bar\" name=\"pin-without-upstream\"") + .append(" revision=\"76ce6d91a2e07fdfcbfc8df6970c9e98a98e36a0\" />") + .append("</manifest>"); + + ManifestParser parser = new ManifestParser(null, null, "master", + "https://git.google.com/", null, null); + parser.read(new ByteArrayInputStream( + xmlContent.toString().getBytes(UTF_8))); + + Map<String, RepoProject> repos = parser.getProjects().stream().collect( + Collectors.toMap(RepoProject::getName, Function.identity())); + assertEquals(2, repos.size()); + + RepoProject foo = repos.get("pin-with-upstream"); + assertEquals("pin-with-upstream", foo.getName()); + assertEquals("9b2fe85c0279f4d5ac69f07ddcd48566c3555405", + foo.getRevision()); + assertEquals("branchX", foo.getUpstream()); + + RepoProject bar = repos.get("pin-without-upstream"); + assertEquals("pin-without-upstream", bar.getName()); + assertEquals("76ce6d91a2e07fdfcbfc8df6970c9e98a98e36a0", + bar.getRevision()); + assertNull(bar.getUpstream()); + } + + @Test + public void testWithDestBranch() throws Exception { + StringBuilder xmlContent = new StringBuilder(); + xmlContent.append("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n") + .append("<manifest>") + .append("<remote name=\"remote1\" fetch=\".\" />") + .append("<default revision=\"master\" remote=\"remote1\" />") + .append("<project path=\"foo\" name=\"foo\"") + .append(" dest-branch=\"branchX\"/>") + .append("<project path=\"bar\" name=\"bar\"/>") + .append("</manifest>"); + + ManifestParser parser = new ManifestParser(null, null, "master", + "https://git.google.com/", null, null); + parser.read(new ByteArrayInputStream( + xmlContent.toString().getBytes(UTF_8))); + + Map<String, RepoProject> repos = parser.getProjects().stream().collect( + Collectors.toMap(RepoProject::getName, Function.identity())); + assertEquals(2, repos.size()); + + RepoProject foo = repos.get("foo"); + assertEquals("foo", foo.getName()); + assertEquals("branchX", foo.getDestBranch()); + + RepoProject bar = repos.get("bar"); + assertEquals("bar", bar.getName()); + assertNull(bar.getDestBranch()); + } + void testNormalize(String in, String want) { URI got = ManifestParser.normalizeEmptyPath(URI.create(in)); if (!got.toString().equals(want)) { diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/gitrepo/RepoCommandTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/gitrepo/RepoCommandTest.java index ca6f2e1053..3162e7910b 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/gitrepo/RepoCommandTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/gitrepo/RepoCommandTest.java @@ -1171,6 +1171,94 @@ public class RepoCommandTest extends RepositoryTestCase { } } + @Test + public void testRecordRemoteBranch_pinned() throws Exception { + Repository remoteDb = createBareRepository(); + Repository tempDb = createWorkRepository(); + + StringBuilder xmlContent = new StringBuilder(); + xmlContent.append("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n") + .append("<manifest>") + .append("<remote name=\"remote1\" fetch=\".\" />") + .append("<default revision=\"master\" remote=\"remote1\" />") + .append("<project path=\"pin-noupstream\"") + .append(" name=\"pin-noupstream\"") + .append(" revision=\"76ce6d91a2e07fdfcbfc8df6970c9e98a98e36a0\" />") + .append("<project path=\"pin-upstream\"") + .append(" name=\"pin-upstream\"") + .append(" upstream=\"branchX\"") + .append(" revision=\"76ce6d91a2e07fdfcbfc8df6970c9e98a98e36a0\" />") + .append("</manifest>"); + JGitTestUtil.writeTrashFile(tempDb, "manifest.xml", + xmlContent.toString()); + + RepoCommand command = new RepoCommand(remoteDb); + command.setPath( + tempDb.getWorkTree().getAbsolutePath() + "/manifest.xml") + .setURI(rootUri).setRecordRemoteBranch(true).call(); + // Clone it + File directory = createTempDirectory("testBareRepo"); + try (Repository localDb = Git.cloneRepository().setDirectory(directory) + .setURI(remoteDb.getDirectory().toURI().toString()).call() + .getRepository();) { + // The .gitmodules file should exist + File gitmodules = new File(localDb.getWorkTree(), ".gitmodules"); + assertTrue("The .gitmodules file should exist", + gitmodules.exists()); + FileBasedConfig c = new FileBasedConfig(gitmodules, FS.DETECTED); + c.load(); + assertEquals("Pinned submodule with upstream records the ref", + "branchX", c.getString("submodule", "pin-upstream", "ref")); + assertNull("Pinned submodule without upstream don't have ref", + c.getString("submodule", "pin-noupstream", "ref")); + } + } + + @Test + public void testRecordRemoteBranch_pinned_nameConflict() throws Exception { + Repository remoteDb = createBareRepository(); + Repository tempDb = createWorkRepository(); + + StringBuilder xmlContent = new StringBuilder(); + xmlContent.append("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n") + .append("<manifest>") + .append("<remote name=\"remote1\" fetch=\".\" />") + .append("<default revision=\"master\" remote=\"remote1\" />") + .append("<project path=\"pin-upstream\"") + .append(" name=\"pin-upstream\"") + .append(" upstream=\"branchX\"") + .append(" revision=\"76ce6d91a2e07fdfcbfc8df6970c9e98a98e36a0\" />") + .append("<project path=\"pin-upstream-name-conflict\"") + .append(" name=\"pin-upstream\"") + .append(" upstream=\"branchX\"") + .append(" revision=\"76ce6d91a2e07fdfcbfc8df6970c9e98a98e36a0\" />") + .append("</manifest>"); + JGitTestUtil.writeTrashFile(tempDb, "manifest.xml", + xmlContent.toString()); + + RepoCommand command = new RepoCommand(remoteDb); + command.setPath( + tempDb.getWorkTree().getAbsolutePath() + "/manifest.xml") + .setURI(rootUri).setRecordRemoteBranch(true).call(); + // Clone it + File directory = createTempDirectory("testBareRepo"); + try (Repository localDb = Git.cloneRepository().setDirectory(directory) + .setURI(remoteDb.getDirectory().toURI().toString()).call() + .getRepository();) { + // The .gitmodules file should exist + File gitmodules = new File(localDb.getWorkTree(), ".gitmodules"); + assertTrue("The .gitmodules file should exist", + gitmodules.exists()); + FileBasedConfig c = new FileBasedConfig(gitmodules, FS.DETECTED); + c.load(); + assertEquals("Upstream is preserved in name conflict", "branchX", + c.getString("submodule", "pin-upstream/pin-upstream", + "ref")); + assertEquals("Upstream is preserved in name conflict (other side)", + "branchX", c.getString("submodule", + "pin-upstream/pin-upstream-name-conflict", "ref")); + } + } @Test public void testRecordSubmoduleLabels() throws Exception { diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/dfs/DfsGarbageCollectorTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/dfs/DfsGarbageCollectorTest.java index 05360dc052..e193de9764 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/dfs/DfsGarbageCollectorTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/dfs/DfsGarbageCollectorTest.java @@ -18,10 +18,11 @@ import java.io.IOException; import java.util.Arrays; import java.util.Collections; import java.util.concurrent.TimeUnit; - import org.eclipse.jgit.internal.storage.commitgraph.CommitGraph; import org.eclipse.jgit.internal.storage.commitgraph.CommitGraphWriter; import org.eclipse.jgit.internal.storage.dfs.DfsObjDatabase.PackSource; +import org.eclipse.jgit.internal.storage.file.PackBitmapIndex; +import org.eclipse.jgit.internal.storage.pack.PackExt; import org.eclipse.jgit.internal.storage.reftable.RefCursor; import org.eclipse.jgit.internal.storage.reftable.ReftableConfig; import org.eclipse.jgit.internal.storage.reftable.ReftableReader; @@ -30,6 +31,8 @@ import org.eclipse.jgit.junit.MockSystemReader; import org.eclipse.jgit.junit.TestRepository; import org.eclipse.jgit.lib.AnyObjectId; import org.eclipse.jgit.lib.BatchRefUpdate; +import org.eclipse.jgit.lib.Config; +import org.eclipse.jgit.lib.ConfigConstants; import org.eclipse.jgit.lib.NullProgressMonitor; import org.eclipse.jgit.lib.ObjectId; import org.eclipse.jgit.lib.ObjectIdRef; @@ -1121,6 +1124,40 @@ public class DfsGarbageCollectorTest { } @Test + public void testReadChangedPathConfigAsFalse() throws Exception { + String head = "refs/heads/head1"; + git.branch(head).commit().message("0").noParents().create(); + gcWithCommitGraphAndBloomFilter(); + + Config repoConfig = odb.getRepository().getConfig(); + repoConfig.setBoolean(ConfigConstants.CONFIG_COMMIT_GRAPH_SECTION, null, + ConfigConstants.CONFIG_KEY_READ_CHANGED_PATHS, false); + + DfsPackFile gcPack = odb.getPacks()[0]; + try (DfsReader reader = odb.newReader()) { + CommitGraph cg = gcPack.getCommitGraph(reader); + assertNull(cg.getChangedPathFilter(0)); + } + } + + @Test + public void testReadChangedPathConfigAsTrue() throws Exception { + String head = "refs/heads/head1"; + git.branch(head).commit().message("0").noParents().create(); + gcWithCommitGraphAndBloomFilter(); + + Config repoConfig = odb.getRepository().getConfig(); + repoConfig.setBoolean(ConfigConstants.CONFIG_COMMIT_GRAPH_SECTION, null, + ConfigConstants.CONFIG_KEY_READ_CHANGED_PATHS, true); + + DfsPackFile gcPack = odb.getPacks()[0]; + try (DfsReader reader = odb.newReader()) { + CommitGraph cg = gcPack.getCommitGraph(reader); + assertNotNull(cg.getChangedPathFilter(0)); + } + } + + @Test public void objectSizeIdx_reachableBlob_bigEnough_indexed() throws Exception { String master = "refs/heads/master"; RevCommit root = git.branch(master).commit().message("root").noParents() @@ -1178,6 +1215,71 @@ public class DfsGarbageCollectorTest { assertFalse(gcRestPack.hasObjectSizeIndex(reader)); } + @Test + public void bitmapIndexWrittenDuringGc() throws Exception { + int numBranches = 2; + int commitsPerBranch = 50; + + RevCommit commit0 = commit().message("0").create(); + git.update("branch0", commit0); + RevCommit branch1 = commitChain(commit0, commitsPerBranch); + git.update("branch1", branch1); + RevCommit branch2 = commitChain(commit0, commitsPerBranch); + git.update("branch2", branch2); + + int contiguousCommitCount = 5; + int recentCommitSpan = 2; + int recentCommitCount = 10; + int distantCommitSpan = 5; + + PackConfig packConfig = new PackConfig(); + packConfig.setBitmapContiguousCommitCount(contiguousCommitCount); + packConfig.setBitmapRecentCommitSpan(recentCommitSpan); + packConfig.setBitmapRecentCommitCount(recentCommitCount); + packConfig.setBitmapDistantCommitSpan(distantCommitSpan); + + DfsGarbageCollector gc = new DfsGarbageCollector(repo); + gc.setPackConfig(packConfig); + run(gc); + + DfsPackFile pack = odb.getPacks()[0]; + PackBitmapIndex bitmapIndex = pack.getBitmapIndex(odb.newReader()); + assertTrue("pack file has bitmap index extension", + pack.getPackDescription().hasFileExt(PackExt.BITMAP_INDEX)); + + int recentCommitsPerBranch = (recentCommitCount - contiguousCommitCount + - 1) / recentCommitSpan; + assertEquals("expected recent commits", 2, recentCommitsPerBranch); + + int distantCommitsPerBranch = (commitsPerBranch - 1 - recentCommitCount) + / distantCommitSpan; + assertEquals("expected distant commits", 7, distantCommitsPerBranch); + + int branchBitmapsCount = contiguousCommitCount + + numBranches + * (recentCommitsPerBranch + + distantCommitsPerBranch); + assertEquals("expected bitmaps count", 23, branchBitmapsCount); + assertEquals("bitmap index has expected number of bitmaps", + branchBitmapsCount, + bitmapIndex.getBitmapCount()); + + // The count is just a function of whether any bitmaps happen to + // compress efficiently against the others in the index. We expect for + // this test that this there will be at least one like this, but the + // actual count is situation-specific + assertTrue("bitmap index has xor-compressed bitmaps", + bitmapIndex.getXorBitmapCount() > 0); + } + + private RevCommit commitChain(RevCommit parent, int length) + throws Exception { + for (int i = 0; i < length; i++) { + parent = commit().message("" + i).parent(parent).create(); + } + return parent; + } + private static DfsPackFile findFirstBySource(DfsPackFile[] packs, PackSource source) { return Arrays.stream(packs) .filter(p -> p.getPackDescription().getPackSource() == source) diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/dfs/DfsPackFileTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/dfs/DfsPackFileTest.java index 44694acc8d..d21e51f276 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/dfs/DfsPackFileTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/dfs/DfsPackFileTest.java @@ -10,7 +10,9 @@ package org.eclipse.jgit.internal.storage.dfs; +import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_COMMIT_GRAPH_SECTION; import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_MIN_BYTES_OBJ_SIZE_INDEX; +import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_KEY_READ_CHANGED_PATHS; import static org.eclipse.jgit.lib.ConfigConstants.CONFIG_PACK_SECTION; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; @@ -24,6 +26,7 @@ import java.util.HashMap; import java.util.Map; import java.util.zip.Deflater; +import org.eclipse.jgit.internal.storage.commitgraph.CommitGraph; import org.eclipse.jgit.internal.storage.dfs.DfsObjDatabase.PackSource; import org.eclipse.jgit.internal.storage.dfs.DfsReader.PackLoadListener; import org.eclipse.jgit.internal.storage.file.PackBitmapIndex; @@ -31,6 +34,7 @@ import org.eclipse.jgit.internal.storage.pack.PackExt; import org.eclipse.jgit.internal.storage.pack.PackOutputStream; import org.eclipse.jgit.internal.storage.pack.PackWriter; import org.eclipse.jgit.junit.JGitTestUtil; +import org.eclipse.jgit.junit.TestRepository; import org.eclipse.jgit.junit.TestRng; import org.eclipse.jgit.lib.BatchRefUpdate; import org.eclipse.jgit.lib.Constants; @@ -263,6 +267,27 @@ public class DfsPackFileTest { assertEquals(2, tal.blockLoadCount); } + @Test + public void testExistenceOfBloomFilterAlongWithCommitGraph() + throws Exception { + try (TestRepository<InMemoryRepository> repository = new TestRepository<>( + db)) { + repository.branch("/refs/heads/main").commit().add("blob1", "blob1") + .create(); + } + setReadChangedPaths(true); + DfsGarbageCollector gc = new DfsGarbageCollector(db); + gc.setWriteCommitGraph(true).setWriteBloomFilter(true) + .pack(NullProgressMonitor.INSTANCE); + + DfsReader reader = db.getObjectDatabase().newReader(); + CommitGraph cg = db.getObjectDatabase().getPacks()[0] + .getCommitGraph(reader); + assertNotNull(cg); + assertEquals(1, cg.getCommitCnt()); + assertNotNull(cg.getChangedPathFilter(0)); + } + private ObjectId setupPack(int bs, int ps) throws IOException { DfsBlockCacheConfig cfg = new DfsBlockCacheConfig().setBlockSize(bs) .setBlockLimit(bs * 100).setStreamRatio(bypassCache ? 0F : 1F); @@ -298,4 +323,9 @@ public class DfsPackFileTest { db.getConfig().setInt(CONFIG_PACK_SECTION, null, CONFIG_KEY_MIN_BYTES_OBJ_SIZE_INDEX, threshold); } + + private void setReadChangedPaths(boolean enable) { + db.getConfig().setBoolean(CONFIG_COMMIT_GRAPH_SECTION, null, + CONFIG_KEY_READ_CHANGED_PATHS, enable); + } } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/dfs/DfsPackParserTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/dfs/DfsPackParserTest.java index 845d5fcca1..130af27773 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/dfs/DfsPackParserTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/dfs/DfsPackParserTest.java @@ -46,10 +46,10 @@ public class DfsPackParserTest { .fromString("2e65efe2a145dda7ee51d1741299f848e5bf752e"); pack.header(2); - pack.write((Constants.OBJ_BLOB) << 4 | 1); + pack.write(Constants.OBJ_BLOB << 4 | 1); pack.deflate(new byte[] { 'a' }); - pack.write((Constants.OBJ_REF_DELTA) << 4 | 4); + pack.write(Constants.OBJ_REF_DELTA << 4 | 4); pack.copyRaw(blobA); pack.deflate(new byte[] { 0x1, 0x1, 0x1, 'b' }); pack.digest(); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/GcConcurrentTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/GcConcurrentTest.java index 96a064989b..8c1b4f7b65 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/GcConcurrentTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/GcConcurrentTest.java @@ -10,7 +10,6 @@ package org.eclipse.jgit.internal.storage.file; -import static java.lang.Integer.valueOf; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertNotEquals; import static org.junit.Assert.assertNotNull; @@ -73,7 +72,7 @@ public class GcConcurrentTest extends GcTestCase { try { gc.setProgressMonitor(this); gc.repack(); - return valueOf(0); + return Integer.valueOf(0); } catch (IOException e) { // leave the syncPoint in broken state so any awaiting // threads and any threads that call await in the future get @@ -84,7 +83,7 @@ public class GcConcurrentTest extends GcTestCase { } catch (InterruptedException ignored) { // } - return valueOf(1); + return Integer.valueOf(1); } } } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/GcKeepFilesTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/GcKeepFilesTest.java index 9a2935f136..e1b6778c0e 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/GcKeepFilesTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/GcKeepFilesTest.java @@ -162,7 +162,7 @@ public class GcKeepFilesTest extends GcTestCase { private void testKeptObjectsAreIncluded() throws Exception { BranchBuilder bb = tr.branch("refs/heads/master"); ObjectId commitObjectInLockedPack = bb.commit().create().toObjectId(); - gc.gc(); + gc.gc().get(); stats = gc.getStatistics(); assertEquals(COMMIT_AND_TREE_OBJECTS, stats.numberOfPackedObjects); assertEquals(1, stats.numberOfPackFiles); @@ -170,7 +170,7 @@ public class GcKeepFilesTest extends GcTestCase { .createNewFile()); bb.commit().create(); - gc.gc(); + gc.gc().get(); stats = gc.getStatistics(); assertEquals(2 * COMMIT_AND_TREE_OBJECTS + 1, stats.numberOfPackedObjects); @@ -194,7 +194,7 @@ public class GcKeepFilesTest extends GcTestCase { private void testKeptObjectsAreNotIncluded() throws Exception { BranchBuilder bb = tr.branch("refs/heads/master"); ObjectId commitObjectInLockedPack = bb.commit().create().toObjectId(); - gc.gc(); + gc.gc().get(); stats = gc.getStatistics(); assertEquals(COMMIT_AND_TREE_OBJECTS, stats.numberOfPackedObjects); assertEquals(1, stats.numberOfPackFiles); @@ -202,7 +202,7 @@ public class GcKeepFilesTest extends GcTestCase { .createNewFile()); bb.commit().create(); - gc.gc(); + gc.gc().get(); stats = gc.getStatistics(); assertEquals(COMMIT_AND_TREE_OBJECTS + 1, stats.numberOfPackedObjects); assertEquals(2, stats.numberOfPackFiles); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/LockFileTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/LockFileTest.java index 7eab1dcb09..953d624bfe 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/LockFileTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/LockFileTest.java @@ -209,7 +209,8 @@ public class LockFileTest extends RepositoryTestCase { lock.unlock(); lock.unlock(); } catch (Throwable e) { - fail("unlock should be noop if not locked at all."); + throw new AssertionError( + "unlock should be noop if not locked at all.", e); } } } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefUpdateTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefUpdateTest.java index 28d5ca726a..cb977bd601 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefUpdateTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/file/RefUpdateTest.java @@ -513,7 +513,6 @@ public class RefUpdateTest extends SampleDataRepositoryTestCase { @Test public void testRefsCacheAfterUpdate() throws Exception { // Do not use the default repo for this case. - List<Ref> allRefs = db.getRefDatabase().getRefs(); ObjectId oldValue = db.resolve("HEAD"); ObjectId newValue = db.resolve("HEAD^"); // first make HEAD refer to loose ref @@ -529,7 +528,7 @@ public class RefUpdateTest extends SampleDataRepositoryTestCase { update = updateRef.update(); assertEquals(Result.FAST_FORWARD, update); - allRefs = db.getRefDatabase().getRefs(); + List<Ref> allRefs = db.getRefDatabase().getRefs(); Ref master = getRef(allRefs, "refs/heads/master").get(); Ref head = getRef(allRefs, "HEAD").get(); assertEquals("refs/heads/master", master.getName()); @@ -550,7 +549,6 @@ public class RefUpdateTest extends SampleDataRepositoryTestCase { @Test public void testRefsCacheAfterUpdateLooseOnly() throws Exception { // Do not use the default repo for this case. - List<Ref> allRefs = db.getRefDatabase().getRefs(); ObjectId oldValue = db.resolve("HEAD"); writeSymref(Constants.HEAD, "refs/heads/newref"); RefUpdate updateRef = db.updateRef(Constants.HEAD); @@ -559,7 +557,7 @@ public class RefUpdateTest extends SampleDataRepositoryTestCase { Result update = updateRef.update(); assertEquals(Result.NEW, update); - allRefs = db.getRefDatabase().getRefs(); + List<Ref> allRefs = db.getRefDatabase().getRefs(); Ref head = getRef(allRefs, "HEAD").get(); Ref newref = getRef(allRefs, "refs/heads/newref").get(); assertEquals("refs/heads/newref", newref.getName()); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/pack/GcCommitSelectionTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/pack/GcCommitSelectionTest.java index 0c09ad1510..ecf9a15b03 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/pack/GcCommitSelectionTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/internal/storage/pack/GcCommitSelectionTest.java @@ -110,7 +110,7 @@ public class GcCommitSelectionTest extends GcTestCase { tr.branch(mainBranch).update(commit1); gc.setExpireAgeMillis(0); - gc.gc(); + gc.gc().get(); // Create only 2 bitmaps, for commit0 and commit1, excluding commit2 assertEquals(2, gc.getStatistics().numberOfBitmaps); @@ -227,7 +227,7 @@ public class GcCommitSelectionTest extends GcTestCase { PackConfig packConfig = new PackConfig(); packConfig.setBitmapExcludedRefsPrefixes(new String[] { "refs/heads/other" }); gc.setPackConfig(packConfig); - gc.gc(); + gc.gc().get(); assertEquals(1, gc.getStatistics().numberOfBitmaps); } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/ConfigTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/ConfigTest.java index 0c0257df90..31940a16f7 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/ConfigTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/ConfigTest.java @@ -42,7 +42,6 @@ import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; import java.util.Iterator; -import java.util.LinkedList; import java.util.List; import java.util.Set; import java.util.concurrent.TimeUnit; @@ -124,16 +123,16 @@ public class ConfigTest { @Test public void test005_PutGetStringList() { Config c = new Config(); - final LinkedList<String> values = new LinkedList<>(); + List<String> values = new ArrayList<>(); values.add("value1"); values.add("value2"); c.setStringList("my", null, "somename", values); - final Object[] expArr = values.toArray(); - final String[] actArr = c.getStringList("my", null, "somename"); + Object[] expArr = values.toArray(); + String[] actArr = c.getStringList("my", null, "somename"); assertArrayEquals(expArr, actArr); - final String expText = "[my]\n\tsomename = value1\n\tsomename = value2\n"; + String expText = "[my]\n\tsomename = value1\n\tsomename = value2\n"; assertEquals(expText, c.toText()); } @@ -1568,7 +1567,6 @@ public class ConfigTest { @Test public void testCommitTemplateEncoding() throws ConfigInvalidException, IOException { - Config config = new Config(null); File workTree = tmp.newFolder("dummy-worktree"); Repository repo = FileRepositoryBuilder .create(new File(workTree, ".git")); @@ -1577,7 +1575,7 @@ public class ConfigTest { String templateContent = "content of the template"; JGitTestUtil.write(tempFile, templateContent); String expectedTemplatePath = tempFile.getPath(); - config = parse("[i18n]\n\tcommitEncoding = utf-8\n" + Config config = parse("[i18n]\n\tcommitEncoding = utf-8\n" + "[commit]\n\ttemplate = " + Config.escapeValue(expectedTemplatePath) + "\n"); assertEquals(templateContent, @@ -1591,7 +1589,6 @@ public class ConfigTest { @Test(expected = ConfigInvalidException.class) public void testCommitTemplateWithInvalidEncoding() throws ConfigInvalidException, IOException { - Config config = new Config(null); File workTree = tmp.newFolder("dummy-worktree"); File tempFile = tmp.newFile("testCommitTemplate-"); Repository repo = FileRepositoryBuilder @@ -1599,7 +1596,7 @@ public class ConfigTest { repo.create(); String templateContent = "content of the template"; JGitTestUtil.write(tempFile, templateContent); - config = parse("[i18n]\n\tcommitEncoding = invalidEcoding\n" + Config config = parse("[i18n]\n\tcommitEncoding = invalidEcoding\n" + "[commit]\n\ttemplate = " + Config.escapeValue(tempFile.getPath()) + "\n"); config.get(CommitConfig.KEY).getCommitTemplateContent(repo); @@ -1608,7 +1605,6 @@ public class ConfigTest { @Test(expected = FileNotFoundException.class) public void testCommitTemplateWithInvalidPath() throws ConfigInvalidException, IOException { - Config config = new Config(null); File workTree = tmp.newFolder("dummy-worktree"); File tempFile = tmp.newFile("testCommitTemplate-"); Repository repo = FileRepositoryBuilder @@ -1618,7 +1614,8 @@ public class ConfigTest { JGitTestUtil.write(tempFile, templateContent); // commit message encoding String expectedTemplatePath = "~/nonExistingTemplate"; - config = parse("[commit]\n\ttemplate = " + expectedTemplatePath + "\n"); + Config config = parse( + "[commit]\n\ttemplate = " + expectedTemplatePath + "\n"); String templatePath = config.get(CommitConfig.KEY) .getCommitTemplatePath(); assertEquals(expectedTemplatePath, templatePath); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/ObjectCheckerTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/ObjectCheckerTest.java index 5c44c9c44d..3ec4b6a073 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/ObjectCheckerTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/ObjectCheckerTest.java @@ -11,7 +11,6 @@ package org.eclipse.jgit.lib; -import static java.lang.Integer.valueOf; import static java.nio.charset.StandardCharsets.UTF_8; import static org.eclipse.jgit.junit.JGitTestUtil.concat; import static org.eclipse.jgit.lib.Constants.OBJECT_ID_LENGTH; @@ -92,7 +91,7 @@ public class ObjectCheckerTest { public void testInvalidType() { String msg = MessageFormat.format( JGitText.get().corruptObjectInvalidType2, - valueOf(OBJ_BAD)); + Integer.valueOf(OBJ_BAD)); assertCorrupt(msg, OBJ_BAD, new byte[0]); } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/RacyGitTests.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/RacyGitTests.java index b1d80c5c30..f25e5d10ff 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/RacyGitTests.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/RacyGitTests.java @@ -30,6 +30,22 @@ import org.junit.Test; public class RacyGitTests extends RepositoryTestCase { + /** + * This test is inherently flaky in nature since using clocks in a computer + * to determine file modifications in a filesystem from Java is difficult + * and depends on many factors and we can't test all combinations + * + * If this test fails on your computer, don't worry but let us know if you + * are willing to provide details which may help to further improve handling + * of the racy git problem in JGit. + * + * Despite not being completely reproducible this test is still useful to + * detect regressions when running this test repeatedly on the same + * OS/filesystem/Java version (which we do on the CI used to build JGit). + * + * @see "https://git-scm.com/docs/racy-git" + * @see "https://www.youtube.com/watch?v=m44cAozuLNI" + */ @Test public void testRacyGitDetection() throws Exception { // Reset to force creation of index file diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/ThreadSafeProgressMonitorTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/ThreadSafeProgressMonitorTest.java index e21ff580bd..a5a6ce5d76 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/ThreadSafeProgressMonitorTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/lib/ThreadSafeProgressMonitorTest.java @@ -125,7 +125,7 @@ public class ThreadSafeProgressMonitorTest { try { assertTrue("latch released", cdl.await(1000, TimeUnit.MILLISECONDS)); } catch (InterruptedException ie) { - fail("Did not expect to be interrupted"); + throw new AssertionError("Did not expect to be interrupted", ie); } } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/MergeAlgorithmTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/MergeAlgorithmTest.java index 680a2d5d72..7a8a93e977 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/MergeAlgorithmTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/MergeAlgorithmTest.java @@ -162,6 +162,19 @@ public class MergeAlgorithmTest { merge("abz}z}z123q", "Abz}z123Q", "abz}z123q", true)); } + @Test + public void testInsertionAfterDeletion() throws IOException { + assertEquals(t("a<=bc>d"), merge("abd", "ad", "abcd", false)); + assertEquals(t("a<|b=bc>d"), + merge("abd", "ad", "abcd", true)); + } + + @Test + public void testInsertionBeforeDeletion() throws IOException { + assertEquals(t("a<=cb>d"), merge("abd", "ad", "acbd", false)); + assertEquals(t("a<|b=cb>d"), merge("abd", "ad", "acbd", true)); + } + /** * Test a conflicting region at the very start of the text. * diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/MergerTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/MergerTest.java index 022e8cd55e..3a036acaca 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/MergerTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/merge/MergerTest.java @@ -22,9 +22,12 @@ import java.io.ByteArrayOutputStream; import java.io.File; import java.io.FileInputStream; import java.io.IOException; +import java.nio.file.Files; import java.time.Instant; import java.util.Arrays; +import java.util.HashSet; import java.util.Map; +import java.util.Set; import org.eclipse.jgit.api.Git; import org.eclipse.jgit.api.MergeResult; @@ -51,6 +54,7 @@ import org.eclipse.jgit.lib.ObjectInserter; import org.eclipse.jgit.lib.ObjectLoader; import org.eclipse.jgit.lib.ObjectReader; import org.eclipse.jgit.lib.ObjectStream; +import org.eclipse.jgit.lib.Repository; import org.eclipse.jgit.lib.StoredConfig; import org.eclipse.jgit.merge.ResolveMerger.MergeFailureReason; import org.eclipse.jgit.revwalk.RevCommit; @@ -1442,6 +1446,8 @@ public class MergerTest extends RepositoryTestCase { git.checkout().setName("master").call(); mergeResult = git.merge().include(commitX).setStrategy(strategy) .call(); + assertEquals(MergeResult.MergeStatus.MERGED, + mergeResult.getMergeStatus()); // Now, merge commit A and B (i.e. "master" and "second-branch"). // None of them have the file "a", so there is no conflict, BUT while @@ -1735,25 +1741,25 @@ public class MergerTest extends RepositoryTestCase { git.add().addFilepattern("c").call(); RevCommit commitI = git.commit().setMessage("Initial commit").call(); - File a = writeTrashFile("a", "content in Ancestor"); + writeTrashFile("a", "content in Ancestor"); git.add().addFilepattern("a").call(); RevCommit commitA1 = git.commit().setMessage("Ancestor 1").call(); - a = writeTrashFile("a", "content in Child 1 (commited on master)"); + writeTrashFile("a", "content in Child 1 (commited on master)"); git.add().addFilepattern("a").call(); // commit C1M git.commit().setMessage("Child 1 on master").call(); git.checkout().setCreateBranch(true).setStartPoint(commitI).setName("branch-to-merge").call(); // "a" becomes executable in A2 - a = writeTrashFile("a", "content in Ancestor"); + File a = writeTrashFile("a", "content in Ancestor"); a.setExecutable(true); git.add().addFilepattern("a").call(); RevCommit commitA2 = git.commit().setMessage("Ancestor 2").call(); // second branch git.checkout().setCreateBranch(true).setStartPoint(commitA1).setName("second-branch").call(); - a = writeTrashFile("a", "content in Child 2 (commited on second-branch)"); + writeTrashFile("a", "content in Child 2 (commited on second-branch)"); git.add().addFilepattern("a").call(); // commit C2S git.commit().setMessage("Child 2 on second-branch").call(); @@ -1789,6 +1795,188 @@ public class MergerTest extends RepositoryTestCase { } + /** + * File is binary in ours, theirs and base with different content in each of + * them. Content of the file should not change after the merge conflict as + * no conflict markers are added to the binary files + */ + @Theory + public void oursBinaryTheirsBinaryBaseBinary(MergeStrategy strategy) + throws Exception { + Git git = Git.wrap(db); + String binaryFile = "file"; + + writeTrashFile(binaryFile, "\u0000\u0001"); + git.add().addFilepattern(binaryFile).call(); + RevCommit parent = git.commit().setMessage("BASE COMMIT").call(); + String fileHashInBase = getFileHashInWorkTree(git, binaryFile); + + writeTrashFile(binaryFile, "\u0001\u0002"); + git.add().addFilepattern(binaryFile).call(); + RevCommit child1 = git.commit().setMessage("THEIRS COMMIT").call(); + String fileHashInChild1 = getFileHashInWorkTree(git, binaryFile); + + git.checkout().setCreateBranch(true).setStartPoint(parent) + .setName("side").call(); + + writeTrashFile(binaryFile, "\u0002\u0000"); + git.add().addFilepattern(binaryFile).call(); + git.commit().setMessage("OURS COMMIT").call(); + String fileHashInChild2 = getFileHashInWorkTree(git, binaryFile); + + MergeResult mergeResult = git.merge().setStrategy(strategy) + .include(child1).call(); + + // check if the merge caused a conflict + assertTrue(mergeResult.getConflicts() != null + && !mergeResult.getConflicts().isEmpty()); + String fileHashInChild2AfterMerge = getFileHashInWorkTree(git, + binaryFile); + + // check if the file content changed during a conflicting merge + assertEquals(fileHashInChild2AfterMerge, fileHashInChild2); + + Set<String> hashesInIndexFile = new HashSet<>(); + DirCache indexContent = git.getRepository().readDirCache(); + for (int i = 0; i < indexContent.getEntryCount(); ++i) { + DirCacheEntry indexEntry = indexContent.getEntry(i); + if (binaryFile.equals(indexEntry.getPathString())) { + hashesInIndexFile.add(indexEntry.getObjectId().name()); + } + } + + // check if all the three stages are added to index file + assertTrue(hashesInIndexFile.contains(fileHashInBase)); + assertTrue(hashesInIndexFile.contains(fileHashInChild1)); + assertTrue(hashesInIndexFile.contains(fileHashInChild2)); + } + + /** + * File is text in ours and theirs with different content but binary in + * base. Even in this case, file will be treated as a binary and no conflict + * markers are added to it + */ + @Theory + public void oursAndTheirsDifferentTextBaseBinary(MergeStrategy strategy) + throws Exception { + Git git = Git.wrap(db); + String binaryFile = "file"; + + writeTrashFile(binaryFile, "\u0000\u0001"); + git.add().addFilepattern(binaryFile).call(); + RevCommit parent = git.commit().setMessage("BASE COMMIT").call(); + String fileHashInBase = getFileHashInWorkTree(git, binaryFile); + + writeTrashFile(binaryFile, "TEXT1"); + git.add().addFilepattern(binaryFile).call(); + RevCommit child1 = git.commit().setMessage("THEIRS COMMIT").call(); + String fileHashInChild1 = getFileHashInWorkTree(git, binaryFile); + + git.checkout().setCreateBranch(true).setStartPoint(parent) + .setName("side").call(); + + writeTrashFile(binaryFile, "TEXT2"); + git.add().addFilepattern(binaryFile).call(); + git.commit().setMessage("OURS COMMIT").call(); + String fileHashInChild2 = getFileHashInWorkTree(git, binaryFile); + + MergeResult mergeResult = git.merge().setStrategy(strategy) + .include(child1).call(); + + assertTrue(mergeResult.getConflicts() != null + && !mergeResult.getConflicts().isEmpty()); + String fileHashInChild2AfterMerge = getFileHashInWorkTree(git, + binaryFile); + + assertEquals(fileHashInChild2AfterMerge, fileHashInChild2); + + Set<String> hashesInIndexFile = new HashSet<>(); + DirCache indexContent = git.getRepository().readDirCache(); + for (int i = 0; i < indexContent.getEntryCount(); ++i) { + DirCacheEntry indexEntry = indexContent.getEntry(i); + if (binaryFile.equals(indexEntry.getPathString())) { + hashesInIndexFile.add(indexEntry.getObjectId().name()); + } + } + + assertTrue(hashesInIndexFile.contains(fileHashInBase)); + assertTrue(hashesInIndexFile.contains(fileHashInChild1)); + assertTrue(hashesInIndexFile.contains(fileHashInChild2)); + } + + /** + * Tests the scenario where a file is expected to be treated as binary + * according to Git attributes + */ + @Theory + public void fileInBinaryInAttribute(MergeStrategy strategy) + throws Exception { + Git git = Git.wrap(db); + String binaryFile = "file.bin"; + + writeTrashFile(".gitattributes", binaryFile + " binary"); + git.add().addFilepattern(".gitattributes").call(); + git.commit().setMessage("ADDING GITATTRIBUTES").call(); + + writeTrashFile(binaryFile, "\u0000\u0001"); + git.add().addFilepattern(binaryFile).call(); + RevCommit parent = git.commit().setMessage("BASE COMMIT").call(); + String fileHashInBase = getFileHashInWorkTree(git, binaryFile); + + writeTrashFile(binaryFile, "\u0001\u0002"); + git.add().addFilepattern(binaryFile).call(); + RevCommit child1 = git.commit().setMessage("THEIRS COMMIT").call(); + String fileHashInChild1 = getFileHashInWorkTree(git, binaryFile); + + git.checkout().setCreateBranch(true).setStartPoint(parent) + .setName("side").call(); + + writeTrashFile(binaryFile, "\u0002\u0000"); + git.add().addFilepattern(binaryFile).call(); + git.commit().setMessage("OURS COMMIT").call(); + String fileHashInChild2 = getFileHashInWorkTree(git, binaryFile); + + MergeResult mergeResult = git.merge().setStrategy(strategy) + .include(child1).call(); + + // check if the merge caused a conflict + assertTrue(mergeResult.getConflicts() != null + && !mergeResult.getConflicts().isEmpty()); + String fileHashInChild2AfterMerge = getFileHashInWorkTree(git, + binaryFile); + + // check if the file content changed during a conflicting merge + assertEquals(fileHashInChild2AfterMerge, fileHashInChild2); + + Set<String> hashesInIndexFile = new HashSet<>(); + DirCache indexContent = git.getRepository().readDirCache(); + for (int i = 0; i < indexContent.getEntryCount(); ++i) { + DirCacheEntry indexEntry = indexContent.getEntry(i); + if (binaryFile.equals(indexEntry.getPathString())) { + hashesInIndexFile.add(indexEntry.getObjectId().name()); + } + } + + // check if all the three stages are added to index file + assertTrue(hashesInIndexFile.contains(fileHashInBase)); + assertTrue(hashesInIndexFile.contains(fileHashInChild1)); + assertTrue(hashesInIndexFile.contains(fileHashInChild2)); + } + + private String getFileHashInWorkTree(Git git, String filePath) + throws IOException { + Repository repository = git.getRepository(); + ObjectInserter objectInserter = repository.newObjectInserter(); + + File conflictingFile = new File(repository.getWorkTree(), filePath); + byte[] fileContent = Files.readAllBytes(conflictingFile.toPath()); + ObjectId blobId = objectInserter.insert(Constants.OBJ_BLOB, + fileContent); + objectInserter.flush(); + + return blobId.name(); + } + private void writeSubmodule(String path, ObjectId commit) throws IOException, ConfigInvalidException { addSubmoduleToIndex(path, commit); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/patch/PatchApplierTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/patch/PatchApplierTest.java index 2aac15bbb6..5507f8572d 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/patch/PatchApplierTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/patch/PatchApplierTest.java @@ -48,8 +48,7 @@ import org.junit.runner.RunWith; import org.junit.runners.Suite; @RunWith(Suite.class) -@Suite.SuiteClasses({ - PatchApplierTest.WithWorktree. class, // +@Suite.SuiteClasses({ PatchApplierTest.WithWorktree.class, // PatchApplierTest.InCore.class, // }) public class PatchApplierTest { @@ -128,6 +127,20 @@ public class PatchApplierTest { } } + protected Result applyPatchAllowConflicts() throws IOException { + InputStream patchStream = getTestResource(name + ".patch"); + Patch patch = new Patch(); + patch.parse(patchStream); + if (inCore) { + try (ObjectInserter oi = db.newObjectInserter()) { + return new PatchApplier(db, baseTip, oi).allowConflicts() + .applyPatch(patch); + } + } + return new PatchApplier(db).allowConflicts() + .applyPatch(patch); + } + protected static InputStream getTestResource(String patchFile) { return PatchApplierTest.class.getClassLoader() .getResourceAsStream("org/eclipse/jgit/diff/" + patchFile); @@ -169,6 +182,13 @@ public class PatchApplierTest { verifyContent(result, aName, exists); } + void verifyChange(Result result, String aName, boolean exists, + int numConflicts) throws Exception { + assertEquals(numConflicts, result.getErrors().size()); + assertEquals(1, result.getPaths().size()); + verifyContent(result, aName, exists); + } + protected byte[] readBlob(ObjectId treeish, String path) throws Exception { try (TestRepository<?> tr = new TestRepository<>(db); @@ -346,6 +366,44 @@ public class PatchApplierTest { } @Test + public void testConflictMarkers() throws Exception { + init("allowconflict", true, true); + + Result result = applyPatchAllowConflicts(); + + assertEquals(result.getErrors().size(), 1); + PatchApplier.Result.Error error = result.getErrors().get(0); + assertEquals("cannot apply hunk", error.msg); + assertEquals("allowconflict", error.oldFileName); + assertTrue(error.isGitConflict()); + verifyChange(result, "allowconflict", true, 1); + } + + @Test + public void testConflictMarkersOutOfBounds() throws Exception { + init("ConflictOutOfBounds", true, true); + + Result result = applyPatchAllowConflicts(); + + assertEquals(result.getErrors().size(), 1); + PatchApplier.Result.Error error = result.getErrors().get(0); + assertEquals("cannot apply hunk", error.msg); + assertEquals("ConflictOutOfBounds", error.oldFileName); + assertTrue(error.isGitConflict()); + verifyChange(result, "ConflictOutOfBounds", true, 1); + } + + @Test + public void testConflictMarkersFileDeleted() throws Exception { + init("allowconflict_file_deleted", false, false); + + Result result = applyPatchAllowConflicts(); + + assertEquals(1, result.getErrors().size()); + assertEquals(0, result.getPaths().size()); + } + + @Test public void testShiftUp() throws Exception { init("ShiftUp"); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/patch/PatchCcErrorTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/patch/PatchCcErrorTest.java index 71bda46ee5..8335c07b1f 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/patch/PatchCcErrorTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/patch/PatchCcErrorTest.java @@ -10,7 +10,6 @@ package org.eclipse.jgit.patch; -import static java.lang.Integer.valueOf; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertSame; import static org.junit.Assert.assertTrue; @@ -35,7 +34,7 @@ public class PatchCcErrorTest { assertSame(FormatError.Severity.ERROR, e.getSeverity()); assertEquals(MessageFormat.format( JGitText.get().truncatedHunkLinesMissingForAncestor, - valueOf(1), valueOf(1)), e.getMessage()); + Integer.valueOf(1), Integer.valueOf(1)), e.getMessage()); assertEquals(346, e.getOffset()); assertTrue(e.getLineText().startsWith( "@@@ -55,12 -163,13 +163,15 @@@ public ")); @@ -45,7 +44,7 @@ public class PatchCcErrorTest { assertSame(FormatError.Severity.ERROR, e.getSeverity()); assertEquals(MessageFormat.format( JGitText.get().truncatedHunkLinesMissingForAncestor, - valueOf(2), valueOf(2)), e.getMessage()); + Integer.valueOf(2), Integer.valueOf(2)), e.getMessage()); assertEquals(346, e.getOffset()); assertTrue(e.getLineText().startsWith( "@@@ -55,12 -163,13 +163,15 @@@ public ")); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/revplot/AbstractPlotRendererTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/revplot/AbstractPlotRendererTest.java index 49f832a1aa..e4bd8506e3 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/revplot/AbstractPlotRendererTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/revplot/AbstractPlotRendererTest.java @@ -11,7 +11,7 @@ package org.eclipse.jgit.revplot; import static org.junit.Assert.assertEquals; -import java.util.LinkedList; +import java.util.ArrayList; import java.util.List; import org.eclipse.jgit.api.Git; @@ -70,7 +70,7 @@ public class AbstractPlotRendererTest extends RepositoryTestCase { private static class TestPlotRenderer extends AbstractPlotRenderer<PlotLane, Object> { - List<Integer> indentations = new LinkedList<>(); + List<Integer> indentations = new ArrayList<>(); @Override protected int drawLabel(int x, int y, Ref ref) { diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/RevCommitParseTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/RevCommitParseTest.java index 82af34ded2..6872289a8b 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/RevCommitParseTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/RevCommitParseTest.java @@ -153,9 +153,9 @@ public class RevCommitParseTest extends RepositoryTestCase { c.parseCanonical(rw, b.toString().getBytes(UTF_8)); } assertEquals( - new PersonIdent("", "a_u_thor@example.com", 1218123387000l, 7), + new PersonIdent("", "a_u_thor@example.com", 1218123387000L, 7), c.getAuthorIdent()); - assertEquals(new PersonIdent("", "", 1218123390000l, -5), + assertEquals(new PersonIdent("", "", 1218123390000L, -5), c.getCommitterIdent()); } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/RevWalkCommitGraphTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/RevWalkCommitGraphTest.java index 8215a795b2..c2f8f10631 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/RevWalkCommitGraphTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/RevWalkCommitGraphTest.java @@ -38,6 +38,7 @@ import org.eclipse.jgit.revwalk.filter.RevFilter; import org.eclipse.jgit.storage.file.FileBasedConfig; import org.eclipse.jgit.treewalk.filter.AndTreeFilter; import org.eclipse.jgit.treewalk.filter.PathFilter; +import org.eclipse.jgit.treewalk.filter.PathFilterGroup; import org.eclipse.jgit.treewalk.filter.TreeFilter; import org.junit.Test; @@ -197,6 +198,35 @@ public class RevWalkCommitGraphTest extends RevWalkTestCase { } @Test + public void testChangedPathFilterWithMultiPaths() throws Exception { + RevCommit c1 = commitFile("file1", "1", "master"); + RevCommit c2 = commitFile("file1", "2", "master"); + RevCommit c3 = commitFile("file2", "3", "master"); + RevCommit c4 = commitFile("file3", "4", "master"); + + enableAndWriteCommitGraph(); + + TreeRevFilter trf = new TreeRevFilter(rw, + PathFilterGroup.createFromStrings(List.of("file1", "file2"))); + rw.markStart(rw.lookupCommit(c4)); + rw.setRevFilter(trf); + assertEquals(c3, rw.next()); + assertEquals(c2, rw.next()); + assertEquals(c1, rw.next()); + assertNull(rw.next()); + + // c2 and c3 has either file1 or file2, c1 did not use ChangedPathFilter + // since it has no parent + assertEquals(2, trf.getChangedPathFilterTruePositive()); + + // No false positives + assertEquals(0, trf.getChangedPathFilterFalsePositive()); + + // c4 does not match either file1 or file2 + assertEquals(1, trf.getChangedPathFilterNegative()); + } + + @Test public void testChangedPathFilterWithFollowFilter() throws Exception { RevCommit c0 = commit(tree()); RevCommit c1 = commit(tree(file("file", blob("contents"))), c0); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/TreeRevFilterTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/TreeRevFilterTest.java index 298facfd15..ddbb19cb8f 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/TreeRevFilterTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/revwalk/TreeRevFilterTest.java @@ -20,17 +20,33 @@ import org.eclipse.jgit.treewalk.filter.TreeFilter; import org.junit.Test; public class TreeRevFilterTest extends RevWalkTestCase { - private RevFilter treeRevFilter() { - return new TreeRevFilter(rw, TreeFilter.ANY_DIFF); - } + @Test + public void testStringOfPearls_FilePath1_treeRevFilter() + throws Exception { + RevCommit a = commit(tree(file("d/f", blob("a")))); + RevCommit b = commit(tree(file("d/f", blob("a"))), a); + RevCommit c = commit(tree(file("d/f", blob("b"))), b); + rw.setRevFilter(new TreeRevFilter(rw, TreeFilter.ANY_DIFF)); + markStart(c); + + assertCommit(c, rw.next()); + assertEquals(1, c.getParentCount()); + assertCommit(b, c.getParent(0)); + + assertCommit(a, rw.next()); // b was skipped + assertEquals(0, a.getParentCount()); + assertNull(rw.next()); + } @Test - public void testStringOfPearls_FilePath1() + public void testStringOfPearls_FilePath1_noRewriteParents() throws Exception { RevCommit a = commit(tree(file("d/f", blob("a")))); RevCommit b = commit(tree(file("d/f", blob("a"))), a); RevCommit c = commit(tree(file("d/f", blob("b"))), b); - rw.setRevFilter(treeRevFilter()); + + rw.setRewriteParents(false); + rw.setTreeFilter(TreeFilter.ANY_DIFF); markStart(c); assertCommit(c, rw.next()); @@ -43,12 +59,74 @@ public class TreeRevFilterTest extends RevWalkTestCase { } @Test + public void testStringOfPearls_FilePath1_RewriteParents() + throws Exception { + RevCommit a = commit(tree(file("d/f", blob("a")))); + RevCommit b = commit(tree(file("d/f", blob("a"))), a); + RevCommit c = commit(tree(file("d/f", blob("b"))), b); + + rw.setRevFilter(new TreeRevFilter(rw, TreeFilter.ANY_DIFF)); + rw.setTreeFilter(TreeFilter.ANY_DIFF); + markStart(c); + + assertCommit(c, rw.next()); + assertEquals(1, c.getParentCount()); + assertCommit(a, c.getParent(0)); + + assertCommit(a, rw.next()); // b was skipped + assertEquals(0, a.getParentCount()); + assertNull(rw.next()); + } + + @Test public void testStringOfPearls_FilePath2() throws Exception { RevCommit a = commit(tree(file("d/f", blob("a")))); RevCommit b = commit(tree(file("d/f", blob("a"))), a); RevCommit c = commit(tree(file("d/f", blob("b"))), b); RevCommit d = commit(tree(file("d/f", blob("b"))), c); - rw.setRevFilter(treeRevFilter()); + rw.setRevFilter(new TreeRevFilter(rw, TreeFilter.ANY_DIFF)); + markStart(d); + + // d was skipped + assertCommit(c, rw.next()); + assertEquals(1, c.getParentCount()); + assertCommit(b, c.getParent(0)); + + // b was skipped + assertCommit(a, rw.next()); + assertEquals(0, a.getParentCount()); + assertNull(rw.next()); + } + + @Test + public void testStringOfPearls_FilePath2_RewriteParents() throws Exception { + RevCommit a = commit(tree(file("d/f", blob("a")))); + RevCommit b = commit(tree(file("d/f", blob("a"))), a); + RevCommit c = commit(tree(file("d/f", blob("b"))), b); + RevCommit d = commit(tree(file("d/f", blob("b"))), c); + rw.setTreeFilter(TreeFilter.ANY_DIFF); + markStart(d); + + // d was skipped + assertCommit(c, rw.next()); + assertEquals(1, c.getParentCount()); + assertCommit(a, c.getParent(0)); + + // b was skipped + assertCommit(a, rw.next()); + assertEquals(0, a.getParentCount()); + assertNull(rw.next()); + } + + @Test + public void testStringOfPearls_FilePath2_RewriteParents_False() throws Exception { + RevCommit a = commit(tree(file("d/f", blob("a")))); + RevCommit b = commit(tree(file("d/f", blob("a"))), a); + RevCommit c = commit(tree(file("d/f", blob("b"))), b); + RevCommit d = commit(tree(file("d/f", blob("b"))), c); + rw.setRewriteParents(false); + rw.setRevFilter(new TreeRevFilter(rw, TreeFilter.ANY_DIFF)); + rw.setTreeFilter(TreeFilter.ANY_DIFF); markStart(d); // d was skipped @@ -68,7 +146,7 @@ public class TreeRevFilterTest extends RevWalkTestCase { RevCommit b = commit(tree(file("d/f", blob("a"))), a); RevCommit c = commit(tree(file("d/f", blob("b"))), b); RevCommit d = commit(tree(file("d/f", blob("b"))), c); - rw.setRevFilter(treeRevFilter()); + rw.setRevFilter(new TreeRevFilter(rw, TreeFilter.ANY_DIFF)); markStart(d); // d was skipped @@ -93,7 +171,9 @@ public class TreeRevFilterTest extends RevWalkTestCase { RevCommit g = commit(tree(file("d/f", blob("b"))), f); RevCommit h = commit(tree(file("d/f", blob("b"))), g); RevCommit i = commit(tree(file("d/f", blob("c"))), h); - rw.setRevFilter(treeRevFilter()); + + // Doesn't rewrite parents since no TreeFilter is set + rw.setRevFilter(new TreeRevFilter(rw, TreeFilter.ANY_DIFF)); markStart(i); assertCommit(i, rw.next()); @@ -112,8 +192,39 @@ public class TreeRevFilterTest extends RevWalkTestCase { } @Test + public void testStringOfPearls_FilePath3_RewriteParents() throws Exception { + RevCommit a = commit(tree(file("d/f", blob("a")))); + RevCommit b = commit(tree(file("d/f", blob("a"))), a); + RevCommit c = commit(tree(file("d/f", blob("b"))), b); + RevCommit d = commit(tree(file("d/f", blob("b"))), c); + RevCommit e = commit(tree(file("d/f", blob("b"))), d); + RevCommit f = commit(tree(file("d/f", blob("b"))), e); + RevCommit g = commit(tree(file("d/f", blob("b"))), f); + RevCommit h = commit(tree(file("d/f", blob("b"))), g); + RevCommit i = commit(tree(file("d/f", blob("c"))), h); + + rw.setRevFilter(new TreeRevFilter(rw, TreeFilter.ANY_DIFF)); + rw.setTreeFilter(TreeFilter.ANY_DIFF); + markStart(i); + + assertCommit(i, rw.next()); + assertEquals(1, i.getParentCount()); + assertCommit(c, i.getParent(0)); + + // h..d was skipped + assertCommit(c, rw.next()); + assertEquals(1, c.getParentCount()); + assertCommit(a, c.getParent(0)); + + // b was skipped + assertCommit(a, rw.next()); + assertEquals(0, a.getParentCount()); + assertNull(rw.next()); + } + + @Test public void testPathFilterOrOtherFilter() throws Exception { - RevFilter pathFilter = treeRevFilter(); + RevFilter pathFilter = new TreeRevFilter(rw, TreeFilter.ANY_DIFF); RevFilter skipFilter = SkipRevFilter.create(1); RevFilter orFilter = OrRevFilter.create(skipFilter, pathFilter); @@ -125,6 +236,9 @@ public class TreeRevFilterTest extends RevWalkTestCase { rw.setRevFilter(pathFilter); markStart(c); assertCommit(c, rw.next()); + assertEquals(1, c.getParentCount()); + assertCommit(b, c.getParent(0)); + assertCommit(a, rw.next()); // Skip filter matches b, a. diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/AtomicPushTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/AtomicPushTest.java index c47e591445..0ba8926a7f 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/AtomicPushTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/AtomicPushTest.java @@ -25,10 +25,6 @@ import org.eclipse.jgit.internal.storage.dfs.InMemoryRepository; import org.eclipse.jgit.junit.TestRepository; import org.eclipse.jgit.lib.NullProgressMonitor; import org.eclipse.jgit.lib.ObjectId; -import org.eclipse.jgit.lib.Repository; -import org.eclipse.jgit.transport.resolver.ReceivePackFactory; -import org.eclipse.jgit.transport.resolver.ServiceNotAuthorizedException; -import org.eclipse.jgit.transport.resolver.ServiceNotEnabledException; import org.junit.After; import org.junit.Before; import org.junit.Test; @@ -46,16 +42,8 @@ public class AtomicPushTest { public void setUp() throws Exception { server = newRepo("server"); client = newRepo("client"); - testProtocol = new TestProtocol<>( - null, - new ReceivePackFactory<Object>() { - @Override - public ReceivePack create(Object req, Repository db) - throws ServiceNotEnabledException, - ServiceNotAuthorizedException { - return new ReceivePack(db); - } - }); + testProtocol = new TestProtocol<>(null, + (req, db) -> new ReceivePack(db)); uri = testProtocol.register(ctx, server); try (TestRepository<?> clientRepo = new TestRepository<>(client)) { diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/PackParserTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/PackParserTest.java index 2fd82e7bdb..6148df99f3 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/PackParserTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/PackParserTest.java @@ -191,7 +191,7 @@ public class PackParserTest extends RepositoryTestCase { InMemoryPack pack = new InMemoryPack(); pack.header(1); - pack.write((Constants.OBJ_REF_DELTA) << 4 | 4); + pack.write(Constants.OBJ_REF_DELTA << 4 | 4); pack.copyRaw(a); pack.deflate(new byte[] { 0x1, 0x1, 0x1, 'b' }); pack.digest(); @@ -211,7 +211,7 @@ public class PackParserTest extends RepositoryTestCase { InMemoryPack pack = new InMemoryPack(); pack.header(1); - pack.write((Constants.OBJ_BLOB) << 4 | 0x80 | 1); + pack.write(Constants.OBJ_BLOB << 4 | 0x80 | 1); pack.write(1); pack.deflate(data); pack.digest(); @@ -231,9 +231,9 @@ public class PackParserTest extends RepositoryTestCase { InMemoryPack pack = new InMemoryPack(); pack.header(2); - pack.write((Constants.OBJ_BLOB) << 4 | 10); // offset 12 + pack.write(Constants.OBJ_BLOB << 4 | 10); // offset 12 pack.deflate(data); - pack.write((Constants.OBJ_OFS_DELTA) << 4 | 4); // offset 31 + pack.write(Constants.OBJ_OFS_DELTA << 4 | 4); // offset 31 pack.write(19); pack.deflate(new byte[] { 0xA, 0xB, 0x1, 'b' }); pack.digest(); @@ -270,7 +270,7 @@ public class PackParserTest extends RepositoryTestCase { InMemoryPack pack = new InMemoryPack(); pack.header(1); - pack.write((Constants.OBJ_REF_DELTA) << 4 | 4); + pack.write(Constants.OBJ_REF_DELTA << 4 | 4); pack.copyRaw(a); pack.deflate(new byte[] { 0x1, 0x1, 0x1, 'b' }); pack.digest(); @@ -300,7 +300,7 @@ public class PackParserTest extends RepositoryTestCase { InMemoryPack pack = new InMemoryPack(); pack.header(1); - pack.write((Constants.OBJ_BLOB) << 4 | 10); + pack.write(Constants.OBJ_BLOB << 4 | 10); pack.deflate(data); pack.digest(); @@ -333,7 +333,7 @@ public class PackParserTest extends RepositoryTestCase { InMemoryPack pack = new InMemoryPack(); pack.header(1); - pack.write((Constants.OBJ_REF_DELTA) << 4 | 14); + pack.write(Constants.OBJ_REF_DELTA << 4 | 14); pack.copyRaw(a); pack.deflate(new byte[] { 1, 11, 11, 'a', '0', '1', '2', '3', '4', '5', '6', '7', '8', '9' }); @@ -366,7 +366,7 @@ public class PackParserTest extends RepositoryTestCase { InMemoryPack pack = new InMemoryPack(); pack.header(1); - pack.write((Constants.OBJ_REF_DELTA) << 4 | 4); + pack.write(Constants.OBJ_REF_DELTA << 4 | 4); pack.copyRaw(a); pack.deflate(new byte[] { 10, 11, 1, 'a' }); pack.digest(); @@ -398,7 +398,7 @@ public class PackParserTest extends RepositoryTestCase { InMemoryPack pack = new InMemoryPack(); pack.header(1); - pack.write((Constants.OBJ_REF_DELTA) << 4 | 4); + pack.write(Constants.OBJ_REF_DELTA << 4 | 4); pack.copyRaw(a); pack.deflate(new byte[] { 0x1, 0x1, 0x1, 'b' }); pack.digest(); @@ -439,7 +439,7 @@ public class PackParserTest extends RepositoryTestCase { InMemoryPack pack = new InMemoryPack(); pack.header(1); - pack.write((Constants.OBJ_REF_DELTA) << 4 | 4); + pack.write(Constants.OBJ_REF_DELTA << 4 | 4); pack.copyRaw(a); pack.deflate(new byte[] { 0x1, 0x1, 0x1, 'b' }); pack.digest(); @@ -470,7 +470,7 @@ public class PackParserTest extends RepositoryTestCase { pack.header(objects); for (int i = 0; i < objects; i++) { - pack.write((Constants.OBJ_BLOB) << 4 | 10); + pack.write(Constants.OBJ_BLOB << 4 | 10); pack.deflate(data); } pack.digest(); @@ -508,7 +508,7 @@ public class PackParserTest extends RepositoryTestCase { for (int i = 0; i < offset; i++) sb.append(i); offset = sb.toString().length(); - int lenByte = (Constants.OBJ_BLOB) << 4 | (offset & 0x0F); + int lenByte = Constants.OBJ_BLOB << 4 | (offset & 0x0F); offset >>= 4; if (offset > 0) lenByte |= 1 << 7; @@ -525,7 +525,7 @@ public class PackParserTest extends RepositoryTestCase { for (int i = 0; i < objects; i++) { // The last pack header written falls across the 8192 byte boundary // between [8189:8210] - pack.write((Constants.OBJ_REF_DELTA) << 4 | 4); + pack.write(Constants.OBJ_REF_DELTA << 4 | 4); pack.copyRaw(b); pack.deflate(new byte[] { 0x1, 0x1, 0x1, 'b' }); } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/PushCertificateIdentTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/PushCertificateIdentTest.java index f5658abceb..cee023d5a9 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/PushCertificateIdentTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/PushCertificateIdentTest.java @@ -73,7 +73,7 @@ public class PushCertificateIdentTest { @Test public void fuzzyCasesMatchPersonIdent() throws Exception { // See RawParseUtils_ParsePersonIdentTest#testParsePersonIdent_fuzzyCases() - Date when = new Date(1234567890000l); + Date when = new Date(1234567890000L); TimeZone tz = TimeZone.getTimeZone("GMT-7"); assertMatchesPersonIdent( @@ -89,7 +89,7 @@ public class PushCertificateIdentTest { @Test public void incompleteCasesMatchPersonIdent() throws Exception { // See RawParseUtils_ParsePersonIdentTest#testParsePersonIdent_incompleteCases() - Date when = new Date(1234567890000l); + Date when = new Date(1234567890000L); TimeZone tz = TimeZone.getTimeZone("GMT-7"); assertMatchesPersonIdent( diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/ReceivePackAdvertiseRefsHookTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/ReceivePackAdvertiseRefsHookTest.java index a91bc95c8d..7dac27f612 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/ReceivePackAdvertiseRefsHookTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/ReceivePackAdvertiseRefsHookTest.java @@ -187,10 +187,10 @@ public class ReceivePackAdvertiseRefsHookTest extends LocalDiskRepositoryTestCas TemporaryBuffer.Heap pack = new TemporaryBuffer.Heap(1024); packHeader(pack, 2); - pack.write((Constants.OBJ_BLOB) << 4 | 1); + pack.write(Constants.OBJ_BLOB << 4 | 1); deflate(pack, new byte[] { 'a' }); - pack.write((Constants.OBJ_REF_DELTA) << 4 | 4); + pack.write(Constants.OBJ_REF_DELTA << 4 | 4); a.copyRawTo(pack); deflate(pack, new byte[] { 0x1, 0x1, 0x1, 'b' }); @@ -296,7 +296,7 @@ public class ReceivePackAdvertiseRefsHookTest extends LocalDiskRepositoryTestCas packHeader(pack, 3); copy(pack, src.open(N)); copy(pack, src.open(s.parseBody(N).getTree())); - pack.write((Constants.OBJ_REF_DELTA) << 4 | 4); + pack.write(Constants.OBJ_REF_DELTA << 4 | 4); b.copyRawTo(pack); deflate(pack, delta); digest(pack); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/SideBandOutputStreamTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/SideBandOutputStreamTest.java index 3516ed01fc..444e958ae8 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/SideBandOutputStreamTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/SideBandOutputStreamTest.java @@ -10,7 +10,6 @@ package org.eclipse.jgit.transport; -import static java.lang.Integer.valueOf; import static java.nio.charset.StandardCharsets.UTF_8; import static org.eclipse.jgit.transport.SideBandOutputStream.CH_DATA; import static org.eclipse.jgit.transport.SideBandOutputStream.CH_ERROR; @@ -224,7 +223,8 @@ public class SideBandOutputStreamTest { } catch (IllegalArgumentException e) { assertEquals(MessageFormat.format( JGitText.get().packetSizeMustBeAtMost, - valueOf(Integer.MAX_VALUE), valueOf(65520)), e.getMessage()); + Integer.valueOf(Integer.MAX_VALUE), Integer.valueOf(65520)), + e.getMessage()); } } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackHandleDeletedPackFileTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackHandleDeletedPackFileTest.java index 417ce61df2..272c5ea5b5 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackHandleDeletedPackFileTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackHandleDeletedPackFileTest.java @@ -9,10 +9,9 @@ */ package org.eclipse.jgit.transport; -import static org.junit.Assert.fail; import static org.eclipse.jgit.lib.Constants.HEAD; -import static org.junit.Assert.assertTrue; import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertTrue; import java.util.Arrays; import java.util.Collection; @@ -91,7 +90,7 @@ public class UploadPackHandleDeletedPackFileTest private void doRemovePackFileDuringUploadPack(PackExt packExt) throws Exception { Object ctx = new Object(); - TestProtocol testProtocol = new TestProtocol<>( + TestProtocol<Object> testProtocol = new TestProtocol<>( (Object req, Repository db) -> { UploadPack up = new UploadPack(db); up.setRequestPolicy(RequestPolicy.REACHABLE_COMMIT); @@ -103,11 +102,12 @@ public class UploadPackHandleDeletedPackFileTest try { addNewCommit(); - new GC(remote.getRepository()).gc(); + new GC(remote.getRepository()).gc().get(); pack.getPackFile().create(packExt).delete(); } catch (Exception e) { - fail("GC or pack file removal failed"); + throw new AssertionError( + "GC or pack file removal failed", e); } return up; @@ -136,7 +136,7 @@ public class UploadPackHandleDeletedPackFileTest .create(); remote.update("master", commit0); - new GC(remote.getRepository()).gc(); // create pack files + new GC(remote.getRepository()).gc().get(); // create pack files head = remote.commit().message("1").parent(commit0) .add("test1.txt", remote.blob("1")) diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackReachabilityTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackReachabilityTest.java index 2711762640..a5507c8f81 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackReachabilityTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackReachabilityTest.java @@ -27,9 +27,6 @@ import org.eclipse.jgit.lib.Repository; import org.eclipse.jgit.revwalk.RevBlob; import org.eclipse.jgit.revwalk.RevCommit; import org.eclipse.jgit.transport.UploadPack.RequestPolicy; -import org.eclipse.jgit.transport.resolver.ServiceNotAuthorizedException; -import org.eclipse.jgit.transport.resolver.ServiceNotEnabledException; -import org.eclipse.jgit.transport.resolver.UploadPackFactory; import org.junit.After; import org.junit.Before; import org.junit.Test; @@ -264,15 +261,10 @@ public class UploadPackReachabilityTest { } private static TestProtocol<Object> generateReachableCommitUploadPackProtocol() { - return new TestProtocol<>(new UploadPackFactory<Object>() { - @Override - public UploadPack create(Object req, Repository db) - throws ServiceNotEnabledException, - ServiceNotAuthorizedException { - UploadPack up = new UploadPack(db); - up.setRequestPolicy(RequestPolicy.REACHABLE_COMMIT); - return up; - } + return new TestProtocol<>((req, db) -> { + UploadPack up = new UploadPack(db); + up.setRequestPolicy(RequestPolicy.REACHABLE_COMMIT); + return up; }, null); } } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackTest.java index 026492f7b6..def73acadd 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/UploadPackTest.java @@ -1800,14 +1800,15 @@ public class UploadPackTest { RevBlob blobHighDepth = remote.blob("hi"); RevTree subtree = remote.tree(remote.file("1", blobHighDepth)); - RevTree rootTree = (new TreeBuilder() { + + RevTree rootTree = new TreeBuilder() { @Override void addElements(DirCacheBuilder dcBuilder) throws Exception { dcBuilder.add(remote.file("1", blobLowDepth)); dcBuilder.addTree(new byte[] {'2'}, DirCacheEntry.STAGE_0, remote.getRevWalk().getObjectReader(), subtree); } - }).build(); + }.build(); RevCommit commit = remote.commit(rootTree); DeepTreePreparator() throws Exception {} @@ -1904,21 +1905,23 @@ public class UploadPackTest { class RepeatedSubtreePreparator { RevBlob foo = remote.blob("foo"); RevTree subtree3 = remote.tree(remote.file("foo", foo)); - RevTree subtree2 = (new TreeBuilder() { + RevTree subtree2 = new TreeBuilder() { @Override void addElements(DirCacheBuilder dcBuilder) throws Exception { dcBuilder.addTree(new byte[] {'b'}, DirCacheEntry.STAGE_0, remote.getRevWalk().getObjectReader(), subtree3); } - }).build(); - RevTree subtree1 = (new TreeBuilder() { + }.build(); + + RevTree subtree1 = new TreeBuilder() { @Override void addElements(DirCacheBuilder dcBuilder) throws Exception { dcBuilder.addTree(new byte[] {'x'}, DirCacheEntry.STAGE_0, remote.getRevWalk().getObjectReader(), subtree2); } - }).build(); - RevTree rootTree = (new TreeBuilder() { + }.build(); + + RevTree rootTree = new TreeBuilder() { @Override void addElements(DirCacheBuilder dcBuilder) throws Exception { dcBuilder.addTree(new byte[] {'a'}, DirCacheEntry.STAGE_0, @@ -1926,7 +1929,7 @@ public class UploadPackTest { dcBuilder.addTree(new byte[] {'x'}, DirCacheEntry.STAGE_0, remote.getRevWalk().getObjectReader(), subtree2); } - }).build(); + }.build(); RevCommit commit = remote.commit(rootTree); RepeatedSubtreePreparator() throws Exception {} @@ -1970,22 +1973,22 @@ public class UploadPackTest { RevTree subtree1 = remote.tree(remote.file("foo", foo)); /** b/foo */ - RevTree subtree2 = (new TreeBuilder() { + RevTree subtree2 = new TreeBuilder() { @Override void addElements(DirCacheBuilder dcBuilder) throws Exception { dcBuilder.addTree(new byte[] {'b'}, DirCacheEntry.STAGE_0, remote.getRevWalk().getObjectReader(), subtree1); } - }).build(); + }.build(); /** x/b/foo */ - RevTree subtree3 = (new TreeBuilder() { + RevTree subtree3 = new TreeBuilder() { @Override void addElements(DirCacheBuilder dcBuilder) throws Exception { dcBuilder.addTree(new byte[] {'x'}, DirCacheEntry.STAGE_0, remote.getRevWalk().getObjectReader(), subtree2); } - }).build(); + }.build(); RevBlob baz = remote.blob("baz"); @@ -1993,33 +1996,33 @@ public class UploadPackTest { RevTree subtree4 = remote.tree(remote.file("baz", baz)); /** c/baz */ - RevTree subtree5 = (new TreeBuilder() { + RevTree subtree5 = new TreeBuilder() { @Override void addElements(DirCacheBuilder dcBuilder) throws Exception { dcBuilder.addTree(new byte[] {'c'}, DirCacheEntry.STAGE_0, remote.getRevWalk().getObjectReader(), subtree4); } - }).build(); + }.build(); /** u/c/baz */ - RevTree subtree6 = (new TreeBuilder() { + RevTree subtree6 = new TreeBuilder() { @Override void addElements(DirCacheBuilder dcBuilder) throws Exception { dcBuilder.addTree(new byte[] {'u'}, DirCacheEntry.STAGE_0, remote.getRevWalk().getObjectReader(), subtree5); } - }).build(); + }.build(); /** v/c/baz */ - RevTree subtree7 = (new TreeBuilder() { + RevTree subtree7 = new TreeBuilder() { @Override void addElements(DirCacheBuilder dcBuilder) throws Exception { dcBuilder.addTree(new byte[] {'v'}, DirCacheEntry.STAGE_0, remote.getRevWalk().getObjectReader(), subtree5); } - }).build(); + }.build(); - RevTree rootTree = (new TreeBuilder() { + RevTree rootTree = new TreeBuilder() { @Override void addElements(DirCacheBuilder dcBuilder) throws Exception { dcBuilder.addTree(new byte[] {'a'}, DirCacheEntry.STAGE_0, @@ -2031,7 +2034,7 @@ public class UploadPackTest { dcBuilder.addTree(new byte[] {'z'}, DirCacheEntry.STAGE_0, remote.getRevWalk().getObjectReader(), subtree7); } - }).build(); + }.build(); RevCommit commit = remote.commit(rootTree); RepeatedSubtreeAtSameLevelPreparator() throws Exception {} diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/http/JDKHttpConnectionTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/http/JDKHttpConnectionTest.java index 37f9514494..f71781dcf3 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/http/JDKHttpConnectionTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/transport/http/JDKHttpConnectionTest.java @@ -16,9 +16,9 @@ import static org.mockito.Mockito.mock; import static org.mockito.Mockito.when; import java.net.HttpURLConnection; +import java.util.ArrayList; import java.util.Collections; import java.util.HashMap; -import java.util.LinkedList; import java.util.List; import java.util.Map; @@ -74,7 +74,7 @@ public class JDKHttpConnectionTest { } private void assertValues(String key, String... values) { - List<String> l = new LinkedList<>(); + List<String> l = new ArrayList<>(); List<String> hf = c.getHeaderFields(key); if (hf != null) { l.addAll(hf); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/treewalk/filter/PathFilterGroupTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/treewalk/filter/PathFilterGroupTest.java index 32bd40312f..1bb4939c85 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/treewalk/filter/PathFilterGroupTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/treewalk/filter/PathFilterGroupTest.java @@ -11,6 +11,7 @@ package org.eclipse.jgit.treewalk.filter; import static org.junit.Assert.assertArrayEquals; +import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; import static org.junit.Assert.assertTrue; import static org.junit.Assert.fail; @@ -21,7 +22,9 @@ import java.util.Arrays; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.Optional; import java.util.Set; +import java.util.stream.Collectors; import org.eclipse.jgit.dircache.DirCache; import org.eclipse.jgit.dircache.DirCacheEditor; @@ -30,6 +33,7 @@ import org.eclipse.jgit.dircache.DirCacheIterator; import org.eclipse.jgit.errors.IncorrectObjectTypeException; import org.eclipse.jgit.errors.MissingObjectException; import org.eclipse.jgit.errors.StopWalkException; +import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.FileMode; import org.eclipse.jgit.lib.ObjectReader; import org.eclipse.jgit.lib.Sets; @@ -143,6 +147,29 @@ public class PathFilterGroupTest { } @Test + public void testGetPathsBestEffort() { + String[] paths = { "path1", "path2", "path3" }; + Set<byte[]> expected = Arrays.stream(paths).map(Constants::encode) + .collect(Collectors.toSet()); + TreeFilter pathFilterGroup = PathFilterGroup.createFromStrings(paths); + Optional<Set<byte[]>> bestEffortPaths = pathFilterGroup + .getPathsBestEffort(); + assertTrue(bestEffortPaths.isPresent()); + Set<byte[]> actual = bestEffortPaths.get(); + assertEquals(expected.size(), actual.size()); + for (byte[] actualPath : actual) { + boolean findMatch = false; + for (byte[] expectedPath : expected) { + if (Arrays.equals(actualPath, expectedPath)) { + findMatch = true; + break; + } + } + assertTrue(findMatch); + } + } + + @Test public void testStopWalk() throws MissingObjectException, IncorrectObjectTypeException, IOException { // Obvious diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/BlockListTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/BlockListTest.java index a270ca8861..b8b9cbe558 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/BlockListTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/BlockListTest.java @@ -296,6 +296,7 @@ public class BlockListTest { public void testAddRejectsBadIndexes() { BlockList<Integer> list = new BlockList<>(4); list.add(Integer.valueOf(41)); + assertEquals(Integer.valueOf(41), list.get(0)); try { list.add(-1, Integer.valueOf(42)); @@ -316,6 +317,7 @@ public class BlockListTest { public void testRemoveRejectsBadIndexes() { BlockList<Integer> list = new BlockList<>(4); list.add(Integer.valueOf(41)); + assertEquals(Integer.valueOf(41), list.get(0)); try { list.remove(-1); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/FileUtilsTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/FileUtilsTest.java index 2b1fb2ef04..5106540227 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/FileUtilsTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/FileUtilsTest.java @@ -74,7 +74,9 @@ public class FileUtilsTest { try { FileUtils.delete(f, FileUtils.SKIP_MISSING); } catch (IOException e) { - fail("deletion of non-existing file must not fail with option SKIP_MISSING"); + throw new AssertionError( + "deletion of non-existing file must not fail with option SKIP_MISSING", + e); } } @@ -108,7 +110,9 @@ public class FileUtilsTest { try { FileUtils.delete(d, FileUtils.RECURSIVE | FileUtils.SKIP_MISSING); } catch (IOException e) { - fail("recursive deletion of non-existing directory must not fail with option SKIP_MISSING"); + throw new AssertionError( + "recursive deletion of non-existing directory must not fail with option SKIP_MISSING", + e); } } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/GitDateFormatterTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/GitDateFormatterTest.java index 0bd7e0bd61..7ef386f6ee 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/GitDateFormatterTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/GitDateFormatterTest.java @@ -90,7 +90,8 @@ public class GitDateFormatterTest { public void LOCALE() { String date = new GitDateFormatter(Format.LOCALE).formatDate(ident); assertTrue("Sep 20, 2011 7:09:25 PM -0400".equals(date) - || "Sep 20, 2011, 7:09:25 PM -0400".equals(date)); // JDK-8206961 + || "Sep 20, 2011, 7:09:25 PM -0400".equals(date) // JDK-8206961 + || "Sep 20, 2011, 7:09:25\u202FPM -0400".equals(date)); // JDK-8304925 } @Test @@ -98,6 +99,7 @@ public class GitDateFormatterTest { String date = new GitDateFormatter(Format.LOCALELOCAL) .formatDate(ident); assertTrue("Sep 20, 2011 7:39:25 PM".equals(date) - || "Sep 20, 2011, 7:39:25 PM".equals(date)); // JDK-8206961 + || "Sep 20, 2011, 7:39:25 PM".equals(date) // JDK-8206961 + || "Sep 20, 2011, 7:39:25\u202FPM".equals(date)); // JDK-8304925 } } diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/HookTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/HookTest.java index 1231aefee0..b7490f0b1f 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/HookTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/HookTest.java @@ -157,7 +157,7 @@ public class HookTest extends RepositoryTestCase { git.commit().setMessage("commit") .setHookOutputStream(new PrintStream(out)).call(); } catch (AbortedByHookException e) { - fail("unexpected hook failure"); + throw new AssertionError("unexpected hook failure", e); } assertEquals("unexpected hook output", "test pre-commit\ntest commit-msg .git/COMMIT_EDITMSG\ntest post-commit\n", diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/HttpSupportTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/HttpSupportTest.java index cbe4eb2eb0..a3a5697ef4 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/HttpSupportTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/HttpSupportTest.java @@ -47,18 +47,6 @@ public class HttpSupportTest { } @Test - public void testMalformedUri() throws Exception { - // Valid URL, but backslash is not allowed in a URI in the userinfo part - // per RFC 3986: https://tools.ietf.org/html/rfc3986#section-3.2.1 . - // Test that conversion to URI to call the ProxySelector does not throw - // an exception. - Proxy proxy = HttpSupport.proxyFor(new TestProxySelector(), new URL( - "http://infor\\c.jones@somehost/somewhere/someproject.git")); - assertNotNull(proxy); - assertEquals(Proxy.Type.HTTP, proxy.type()); - } - - @Test public void testCorrectUri() throws Exception { // Backslash escaped as %5C is correct. Proxy proxy = HttpSupport.proxyFor(new TestProxySelector(), new URL( diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/RawParseUtils_ParsePersonIdentTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/RawParseUtils_ParsePersonIdentTest.java index ee3ce8d98c..355bbbab16 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/RawParseUtils_ParsePersonIdentTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/RawParseUtils_ParsePersonIdentTest.java @@ -22,7 +22,7 @@ public class RawParseUtils_ParsePersonIdentTest { @Test public void testParsePersonIdent_legalCases() { - final Date when = new Date(1234567890000l); + final Date when = new Date(1234567890000L); final TimeZone tz = TimeZone.getTimeZone("GMT-7"); assertPersonIdent("Me <me@example.com> 1234567890 -0700", @@ -50,7 +50,7 @@ public class RawParseUtils_ParsePersonIdentTest { @Test public void testParsePersonIdent_fuzzyCases() { - final Date when = new Date(1234567890000l); + final Date when = new Date(1234567890000L); final TimeZone tz = TimeZone.getTimeZone("GMT-7"); assertPersonIdent( @@ -64,7 +64,7 @@ public class RawParseUtils_ParsePersonIdentTest { @Test public void testParsePersonIdent_incompleteCases() { - final Date when = new Date(1234567890000l); + final Date when = new Date(1234567890000L); final TimeZone tz = TimeZone.getTimeZone("GMT-7"); assertPersonIdent("Me <> 1234567890 -0700", new PersonIdent("Me", "", diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/RefMapTest.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/RefMapTest.java index 627417d462..a8077fdb0c 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/RefMapTest.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/RefMapTest.java @@ -268,6 +268,7 @@ public class RefMapTest { assertFalse(itr.hasNext()); } + @SuppressWarnings("ModifiedButNotUsed") @Test public void testPut_KeyMustMatchName_NoPrefix() { final Ref refA = newRef("refs/heads/A", ID_ONE); @@ -280,6 +281,7 @@ public class RefMapTest { } } + @SuppressWarnings("ModifiedButNotUsed") @Test public void testPut_KeyMustMatchName_WithPrefix() { final Ref refA = newRef("refs/heads/A", ID_ONE); diff --git a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/http/HttpCookiesMatcher.java b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/http/HttpCookiesMatcher.java index 5a2bd976c7..c1c72804da 100644 --- a/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/http/HttpCookiesMatcher.java +++ b/org.eclipse.jgit.test/tst/org/eclipse/jgit/util/http/HttpCookiesMatcher.java @@ -10,7 +10,7 @@ package org.eclipse.jgit.util.http; import java.net.HttpCookie; -import java.util.LinkedList; +import java.util.ArrayList; import java.util.List; import org.hamcrest.Description; @@ -26,7 +26,7 @@ public final class HttpCookiesMatcher { public static Matcher<Iterable<? extends HttpCookie>> containsInOrder( Iterable<HttpCookie> expectedCookies, int allowedMaxAgeDelta) { - final List<Matcher<? super HttpCookie>> cookieMatchers = new LinkedList<>(); + final List<Matcher<? super HttpCookie>> cookieMatchers = new ArrayList<>(); for (HttpCookie cookie : expectedCookies) { cookieMatchers .add(new HttpCookieMatcher(cookie, allowedMaxAgeDelta)); @@ -92,7 +92,7 @@ public final class HttpCookiesMatcher { } @SuppressWarnings("boxing") - protected static void describeCookie(Description description, + private static void describeCookie(Description description, HttpCookie cookie) { description.appendText("HttpCookie["); description.appendText("name: ").appendValue(cookie.getName()) diff --git a/org.eclipse.jgit.ui/META-INF/MANIFEST.MF b/org.eclipse.jgit.ui/META-INF/MANIFEST.MF index 00e7f537e8..7cf8277394 100644 --- a/org.eclipse.jgit.ui/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit.ui/META-INF/MANIFEST.MF @@ -4,14 +4,14 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit.ui Bundle-SymbolicName: org.eclipse.jgit.ui -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Vendor: %Bundle-Vendor Bundle-RequiredExecutionEnvironment: JavaSE-11 -Export-Package: org.eclipse.jgit.awtui;version="6.9.1" -Import-Package: org.eclipse.jgit.errors;version="[6.9.1,6.10.0)", - org.eclipse.jgit.lib;version="[6.9.1,6.10.0)", - org.eclipse.jgit.nls;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revplot;version="[6.9.1,6.10.0)", - org.eclipse.jgit.revwalk;version="[6.9.1,6.10.0)", - org.eclipse.jgit.transport;version="[6.9.1,6.10.0)", - org.eclipse.jgit.util;version="[6.9.1,6.10.0)" +Export-Package: org.eclipse.jgit.awtui;version="6.10.1" +Import-Package: org.eclipse.jgit.errors;version="[6.10.1,6.11.0)", + org.eclipse.jgit.lib;version="[6.10.1,6.11.0)", + org.eclipse.jgit.nls;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revplot;version="[6.10.1,6.11.0)", + org.eclipse.jgit.revwalk;version="[6.10.1,6.11.0)", + org.eclipse.jgit.transport;version="[6.10.1,6.11.0)", + org.eclipse.jgit.util;version="[6.10.1,6.11.0)" diff --git a/org.eclipse.jgit.ui/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit.ui/META-INF/SOURCE-MANIFEST.MF index 8462fb0f9f..22586a6f65 100644 --- a/org.eclipse.jgit.ui/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit.ui/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit.ui - Sources Bundle-SymbolicName: org.eclipse.jgit.ui.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit.ui;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit.ui;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit.ui/pom.xml b/org.eclipse.jgit.ui/pom.xml index 9f7cfadc24..02381d7dbc 100644 --- a/org.eclipse.jgit.ui/pom.xml +++ b/org.eclipse.jgit.ui/pom.xml @@ -19,7 +19,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit.ui</artifactId> diff --git a/org.eclipse.jgit.ui/src/org/eclipse/jgit/awtui/SwingCommitList.java b/org.eclipse.jgit.ui/src/org/eclipse/jgit/awtui/SwingCommitList.java index 47acc11e7d..901452617d 100644 --- a/org.eclipse.jgit.ui/src/org/eclipse/jgit/awtui/SwingCommitList.java +++ b/org.eclipse.jgit.ui/src/org/eclipse/jgit/awtui/SwingCommitList.java @@ -11,16 +11,17 @@ package org.eclipse.jgit.awtui; import java.awt.Color; -import java.util.LinkedList; +import java.util.ArrayDeque; +import java.util.Deque; import org.eclipse.jgit.revplot.PlotCommitList; import org.eclipse.jgit.revplot.PlotLane; class SwingCommitList extends PlotCommitList<SwingCommitList.SwingLane> { - final LinkedList<Color> colors; + final Deque<Color> colors; SwingCommitList() { - colors = new LinkedList<>(); + colors = new ArrayDeque<>(); repackColors(); } diff --git a/org.eclipse.jgit/.settings/.api_filters b/org.eclipse.jgit/.settings/.api_filters index dda62f22a3..50a04d20f0 100644 --- a/org.eclipse.jgit/.settings/.api_filters +++ b/org.eclipse.jgit/.settings/.api_filters @@ -1,18 +1,18 @@ <?xml version="1.0" encoding="UTF-8" standalone="no"?> <component id="org.eclipse.jgit" version="2"> - <resource path="src/org/eclipse/jgit/lib/GpgSignatureVerifier.java" type="org.eclipse.jgit.lib.GpgSignatureVerifier"> - <filter id="404000815"> + <resource path="src/org/eclipse/jgit/gitrepo/RepoProject.java" type="org.eclipse.jgit.gitrepo.RepoProject"> + <filter id="1141899266"> <message_arguments> - <message_argument value="org.eclipse.jgit.lib.GpgSignatureVerifier"/> - <message_argument value="verify(GpgConfig, byte[], byte[])"/> + <message_argument value="7.0"/> + <message_argument value="6.10"/> + <message_argument value="getDestBranch()"/> </message_arguments> </filter> - </resource> - <resource path="src/org/eclipse/jgit/storage/pack/PackConfig.java" type="org.eclipse.jgit.storage.pack.PackConfig"> - <filter id="336658481"> + <filter id="1141899266"> <message_arguments> - <message_argument value="org.eclipse.jgit.storage.pack.PackConfig"/> - <message_argument value="DEFAULT_BITMAP_EXCESSIVE_BRANCH_TIP_COUNT"/> + <message_argument value="7.0"/> + <message_argument value="6.10"/> + <message_argument value="setDestBranch(String)"/> </message_arguments> </filter> </resource> diff --git a/org.eclipse.jgit/META-INF/MANIFEST.MF b/org.eclipse.jgit/META-INF/MANIFEST.MF index b2b01fdc27..e9042772d2 100644 --- a/org.eclipse.jgit/META-INF/MANIFEST.MF +++ b/org.eclipse.jgit/META-INF/MANIFEST.MF @@ -3,12 +3,14 @@ Bundle-ManifestVersion: 2 Bundle-Name: %Bundle-Name Automatic-Module-Name: org.eclipse.jgit Bundle-SymbolicName: org.eclipse.jgit -Bundle-Version: 6.9.1.qualifier +Bundle-Version: 6.10.1.qualifier Bundle-Localization: OSGI-INF/l10n/plugin Bundle-Vendor: %Bundle-Vendor +Bundle-ActivationPolicy: lazy +Service-Component: OSGI-INF/org.eclipse.jgit.internal.util.CleanupService.xml Eclipse-ExtensibleAPI: true -Export-Package: org.eclipse.jgit.annotations;version="6.9.1", - org.eclipse.jgit.api;version="6.9.1"; +Export-Package: org.eclipse.jgit.annotations;version="6.10.1", + org.eclipse.jgit.api;version="6.10.1"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.notes, org.eclipse.jgit.dircache, @@ -23,18 +25,18 @@ Export-Package: org.eclipse.jgit.annotations;version="6.9.1", org.eclipse.jgit.revwalk.filter, org.eclipse.jgit.blame, org.eclipse.jgit.merge", - org.eclipse.jgit.api.errors;version="6.9.1"; + org.eclipse.jgit.api.errors;version="6.10.1"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.errors", - org.eclipse.jgit.attributes;version="6.9.1"; + org.eclipse.jgit.attributes;version="6.10.1"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.treewalk", - org.eclipse.jgit.blame;version="6.9.1"; + org.eclipse.jgit.blame;version="6.10.1"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.revwalk, org.eclipse.jgit.treewalk.filter, org.eclipse.jgit.diff", - org.eclipse.jgit.diff;version="6.9.1"; + org.eclipse.jgit.diff;version="6.10.1"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.attributes, org.eclipse.jgit.revwalk, @@ -42,53 +44,53 @@ Export-Package: org.eclipse.jgit.annotations;version="6.9.1", org.eclipse.jgit.treewalk.filter, org.eclipse.jgit.treewalk, org.eclipse.jgit.util", - org.eclipse.jgit.dircache;version="6.9.1"; + org.eclipse.jgit.dircache;version="6.10.1"; uses:="org.eclipse.jgit.events, org.eclipse.jgit.lib, org.eclipse.jgit.attributes, org.eclipse.jgit.treewalk, org.eclipse.jgit.util", - org.eclipse.jgit.errors;version="6.9.1"; + org.eclipse.jgit.errors;version="6.10.1"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.dircache, org.eclipse.jgit.lib, org.eclipse.jgit.internal.storage.pack", - org.eclipse.jgit.events;version="6.9.1"; + org.eclipse.jgit.events;version="6.10.1"; uses:="org.eclipse.jgit.lib", - org.eclipse.jgit.fnmatch;version="6.9.1", - org.eclipse.jgit.gitrepo;version="6.9.1"; + org.eclipse.jgit.fnmatch;version="6.10.1", + org.eclipse.jgit.gitrepo;version="6.10.1"; uses:="org.xml.sax.helpers, org.eclipse.jgit.api, org.eclipse.jgit.lib, org.eclipse.jgit.revwalk, org.xml.sax", - org.eclipse.jgit.gitrepo.internal;version="6.9.1";x-internal:=true, - org.eclipse.jgit.hooks;version="6.9.1";uses:="org.eclipse.jgit.lib", - org.eclipse.jgit.ignore;version="6.9.1", - org.eclipse.jgit.ignore.internal;version="6.9.1"; + org.eclipse.jgit.gitrepo.internal;version="6.10.1";x-internal:=true, + org.eclipse.jgit.hooks;version="6.10.1";uses:="org.eclipse.jgit.lib", + org.eclipse.jgit.ignore;version="6.10.1", + org.eclipse.jgit.ignore.internal;version="6.10.1"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal;version="6.9.1"; + org.eclipse.jgit.internal;version="6.10.1"; x-friends:="org.eclipse.jgit.test, org.eclipse.jgit.http.test", - org.eclipse.jgit.internal.diff;version="6.9.1"; + org.eclipse.jgit.internal.diff;version="6.10.1"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.diffmergetool;version="6.9.1"; + org.eclipse.jgit.internal.diffmergetool;version="6.10.1"; x-friends:="org.eclipse.jgit.test, org.eclipse.jgit.pgm.test, org.eclipse.jgit.pgm, org.eclipse.egit.ui", - org.eclipse.jgit.internal.fsck;version="6.9.1"; + org.eclipse.jgit.internal.fsck;version="6.10.1"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.revwalk;version="6.9.1"; + org.eclipse.jgit.internal.revwalk;version="6.10.1"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.storage.commitgraph;version="6.9.1"; + org.eclipse.jgit.internal.storage.commitgraph;version="6.10.1"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.storage.dfs;version="6.9.1"; + org.eclipse.jgit.internal.storage.dfs;version="6.10.1"; x-friends:="org.eclipse.jgit.test, org.eclipse.jgit.http.server, org.eclipse.jgit.http.test, org.eclipse.jgit.lfs.test", - org.eclipse.jgit.internal.storage.file;version="6.9.1"; + org.eclipse.jgit.internal.storage.file;version="6.10.1"; x-friends:="org.eclipse.jgit.test, org.eclipse.jgit.junit, org.eclipse.jgit.junit.http, @@ -97,36 +99,36 @@ Export-Package: org.eclipse.jgit.annotations;version="6.9.1", org.eclipse.jgit.pgm, org.eclipse.jgit.pgm.test, org.eclipse.jgit.ssh.apache", - org.eclipse.jgit.internal.storage.io;version="6.9.1"; + org.eclipse.jgit.internal.storage.io;version="6.10.1"; x-friends:="org.eclipse.jgit.junit, org.eclipse.jgit.test, org.eclipse.jgit.pgm", - org.eclipse.jgit.internal.storage.memory;version="6.9.1"; + org.eclipse.jgit.internal.storage.memory;version="6.10.1"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.storage.pack;version="6.9.1"; + org.eclipse.jgit.internal.storage.pack;version="6.10.1"; x-friends:="org.eclipse.jgit.junit, org.eclipse.jgit.test, org.eclipse.jgit.pgm", - org.eclipse.jgit.internal.storage.reftable;version="6.9.1"; + org.eclipse.jgit.internal.storage.reftable;version="6.10.1"; x-friends:="org.eclipse.jgit.http.test, org.eclipse.jgit.junit, org.eclipse.jgit.test, org.eclipse.jgit.pgm", - org.eclipse.jgit.internal.submodule;version="6.9.1";x-internal:=true, - org.eclipse.jgit.internal.transport.connectivity;version="6.9.1"; + org.eclipse.jgit.internal.submodule;version="6.10.1";x-internal:=true, + org.eclipse.jgit.internal.transport.connectivity;version="6.10.1"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.transport.http;version="6.9.1"; + org.eclipse.jgit.internal.transport.http;version="6.10.1"; x-friends:="org.eclipse.jgit.test", - org.eclipse.jgit.internal.transport.parser;version="6.9.1"; + org.eclipse.jgit.internal.transport.parser;version="6.10.1"; x-friends:="org.eclipse.jgit.http.server, org.eclipse.jgit.test", - org.eclipse.jgit.internal.transport.ssh;version="6.9.1"; + org.eclipse.jgit.internal.transport.ssh;version="6.10.1"; x-friends:="org.eclipse.jgit.ssh.apache, org.eclipse.jgit.ssh.jsch, org.eclipse.jgit.test", - org.eclipse.jgit.internal.util;version="6.9.1"; + org.eclipse.jgit.internal.util;version="6.10.1"; x-friends:=" org.eclipse.jgit.junit", - org.eclipse.jgit.lib;version="6.9.1"; + org.eclipse.jgit.lib;version="6.10.1"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.util.sha1, org.eclipse.jgit.dircache, @@ -140,12 +142,12 @@ Export-Package: org.eclipse.jgit.annotations;version="6.9.1", org.eclipse.jgit.util, org.eclipse.jgit.submodule, org.eclipse.jgit.util.time", - org.eclipse.jgit.lib.internal;version="6.9.1"; + org.eclipse.jgit.lib.internal;version="6.10.1"; x-friends:="org.eclipse.jgit.test, org.eclipse.jgit.pgm, org.eclipse.egit.ui", - org.eclipse.jgit.logging;version="6.9.1", - org.eclipse.jgit.merge;version="6.9.1"; + org.eclipse.jgit.logging;version="6.10.1", + org.eclipse.jgit.merge;version="6.10.1"; uses:="org.eclipse.jgit.dircache, org.eclipse.jgit.lib, org.eclipse.jgit.revwalk, @@ -154,40 +156,40 @@ Export-Package: org.eclipse.jgit.annotations;version="6.9.1", org.eclipse.jgit.util, org.eclipse.jgit.api, org.eclipse.jgit.attributes", - org.eclipse.jgit.nls;version="6.9.1", - org.eclipse.jgit.notes;version="6.9.1"; + org.eclipse.jgit.nls;version="6.10.1", + org.eclipse.jgit.notes;version="6.10.1"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.revwalk, org.eclipse.jgit.treewalk, org.eclipse.jgit.merge", - org.eclipse.jgit.patch;version="6.9.1"; + org.eclipse.jgit.patch;version="6.10.1"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.diff", - org.eclipse.jgit.revplot;version="6.9.1"; + org.eclipse.jgit.revplot;version="6.10.1"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.revwalk", - org.eclipse.jgit.revwalk;version="6.9.1"; + org.eclipse.jgit.revwalk;version="6.10.1"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.diff, org.eclipse.jgit.treewalk.filter, org.eclipse.jgit.revwalk.filter, org.eclipse.jgit.treewalk", - org.eclipse.jgit.revwalk.filter;version="6.9.1"; + org.eclipse.jgit.revwalk.filter;version="6.10.1"; uses:="org.eclipse.jgit.revwalk, org.eclipse.jgit.lib, org.eclipse.jgit.util", - org.eclipse.jgit.storage.file;version="6.9.1"; + org.eclipse.jgit.storage.file;version="6.10.1"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.util", - org.eclipse.jgit.storage.pack;version="6.9.1"; + org.eclipse.jgit.storage.pack;version="6.10.1"; uses:="org.eclipse.jgit.lib", - org.eclipse.jgit.submodule;version="6.9.1"; + org.eclipse.jgit.submodule;version="6.10.1"; uses:="org.eclipse.jgit.lib, org.eclipse.jgit.diff, org.eclipse.jgit.treewalk.filter, org.eclipse.jgit.treewalk, org.eclipse.jgit.util", - org.eclipse.jgit.transport;version="6.9.1"; + org.eclipse.jgit.transport;version="6.10.1"; uses:="javax.crypto, org.eclipse.jgit.util.io, org.eclipse.jgit.lib, @@ -200,21 +202,21 @@ Export-Package: org.eclipse.jgit.annotations;version="6.9.1", org.eclipse.jgit.transport.resolver, org.eclipse.jgit.storage.pack, org.eclipse.jgit.errors", - org.eclipse.jgit.transport.http;version="6.9.1"; + org.eclipse.jgit.transport.http;version="6.10.1"; uses:="javax.net.ssl", - org.eclipse.jgit.transport.resolver;version="6.9.1"; + org.eclipse.jgit.transport.resolver;version="6.10.1"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.lib", - org.eclipse.jgit.treewalk;version="6.9.1"; + org.eclipse.jgit.treewalk;version="6.10.1"; uses:="org.eclipse.jgit.dircache, org.eclipse.jgit.lib, org.eclipse.jgit.attributes, org.eclipse.jgit.revwalk, org.eclipse.jgit.treewalk.filter, org.eclipse.jgit.util", - org.eclipse.jgit.treewalk.filter;version="6.9.1"; + org.eclipse.jgit.treewalk.filter;version="6.10.1"; uses:="org.eclipse.jgit.treewalk", - org.eclipse.jgit.util;version="6.9.1"; + org.eclipse.jgit.util;version="6.10.1"; uses:="org.eclipse.jgit.transport, org.eclipse.jgit.hooks, org.eclipse.jgit.revwalk, @@ -227,18 +229,18 @@ Export-Package: org.eclipse.jgit.annotations;version="6.9.1", org.eclipse.jgit.treewalk, javax.net.ssl, org.eclipse.jgit.util.time", - org.eclipse.jgit.util.io;version="6.9.1"; + org.eclipse.jgit.util.io;version="6.10.1"; uses:="org.eclipse.jgit.attributes, org.eclipse.jgit.lib, org.eclipse.jgit.treewalk", - org.eclipse.jgit.util.sha1;version="6.9.1", - org.eclipse.jgit.util.time;version="6.9.1" + org.eclipse.jgit.util.sha1;version="6.10.1", + org.eclipse.jgit.util.time;version="6.10.1" Bundle-RequiredExecutionEnvironment: JavaSE-11 Import-Package: com.googlecode.javaewah;version="[1.1.6,2.0.0)", javax.crypto, javax.management, javax.net.ssl, - org.apache.commons.codec.digest;version="1.15.0", + org.apache.commons.codec.digest;version="[1.15.0,2.0.0)", org.slf4j;version="[1.7.0,3.0.0)", org.xml.sax, org.xml.sax.helpers diff --git a/org.eclipse.jgit/META-INF/SOURCE-MANIFEST.MF b/org.eclipse.jgit/META-INF/SOURCE-MANIFEST.MF index 70e1e493df..054264b6a7 100644 --- a/org.eclipse.jgit/META-INF/SOURCE-MANIFEST.MF +++ b/org.eclipse.jgit/META-INF/SOURCE-MANIFEST.MF @@ -3,5 +3,5 @@ Bundle-ManifestVersion: 2 Bundle-Name: org.eclipse.jgit - Sources Bundle-SymbolicName: org.eclipse.jgit.source Bundle-Vendor: Eclipse.org - JGit -Bundle-Version: 6.9.1.qualifier -Eclipse-SourceBundle: org.eclipse.jgit;version="6.9.1.qualifier";roots="." +Bundle-Version: 6.10.1.qualifier +Eclipse-SourceBundle: org.eclipse.jgit;version="6.10.1.qualifier";roots="." diff --git a/org.eclipse.jgit/OSGI-INF/org.eclipse.jgit.internal.util.CleanupService.xml b/org.eclipse.jgit/OSGI-INF/org.eclipse.jgit.internal.util.CleanupService.xml new file mode 100644 index 0000000000..8d97374c66 --- /dev/null +++ b/org.eclipse.jgit/OSGI-INF/org.eclipse.jgit.internal.util.CleanupService.xml @@ -0,0 +1,4 @@ +<?xml version="1.0" encoding="UTF-8"?> +<scr:component xmlns:scr="http://www.osgi.org/xmlns/scr/v1.1.0" activate="start" deactivate="shutDown" name="org.eclipse.jgit.internal.util.CleanupService"> + <implementation class="org.eclipse.jgit.internal.util.CleanupService"/> +</scr:component>
\ No newline at end of file diff --git a/org.eclipse.jgit/pom.xml b/org.eclipse.jgit/pom.xml index 49a60923c2..67232cbc97 100644 --- a/org.eclipse.jgit/pom.xml +++ b/org.eclipse.jgit/pom.xml @@ -20,7 +20,7 @@ <parent> <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> </parent> <artifactId>org.eclipse.jgit</artifactId> @@ -49,7 +49,6 @@ <dependency> <groupId>commons-codec</groupId> <artifactId>commons-codec</artifactId> - <version>1.16.0</version> </dependency> </dependencies> diff --git a/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties b/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties index bbfd0b0d3a..19c90086aa 100644 --- a/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties +++ b/org.eclipse.jgit/resources/org/eclipse/jgit/internal/JGitText.properties @@ -716,6 +716,7 @@ shortReadOfBlock=Short read of block. shortReadOfOptionalDIRCExtensionExpectedAnotherBytes=Short read of optional DIRC extension {0}; expected another {1} bytes within the section. shortSkipOfBlock=Short skip of block. shutdownCleanup=Cleanup {} during JVM shutdown +shutdownCleanupFailed=Cleanup during JVM shutdown failed shutdownCleanupListenerFailed=Cleanup of {0} during JVM shutdown failed signatureVerificationError=Signature verification failed signatureVerificationUnavailable=No signature verifier registered diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/CheckoutCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/CheckoutCommand.java index a03ea01864..c133219d4d 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/CheckoutCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/CheckoutCommand.java @@ -17,7 +17,6 @@ import java.text.MessageFormat; import java.util.ArrayList; import java.util.EnumSet; import java.util.HashSet; -import java.util.LinkedList; import java.util.List; import java.util.Set; @@ -164,7 +163,7 @@ public class CheckoutCommand extends GitCommand<Ref> { */ protected CheckoutCommand(Repository repo) { super(repo); - this.paths = new LinkedList<>(); + this.paths = new ArrayList<>(); } @Override diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/CherryPickCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/CherryPickCommand.java index a1c64788bd..a353d1a135 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/CherryPickCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/CherryPickCommand.java @@ -14,7 +14,7 @@ import static org.eclipse.jgit.lib.Constants.OBJECT_ID_ABBREV_STRING_LENGTH; import java.io.IOException; import java.text.MessageFormat; -import java.util.LinkedList; +import java.util.ArrayList; import java.util.List; import java.util.Map; @@ -63,7 +63,7 @@ import org.eclipse.jgit.treewalk.FileTreeIterator; public class CherryPickCommand extends GitCommand<CherryPickResult> { private String reflogPrefix = "cherry-pick:"; //$NON-NLS-1$ - private List<Ref> commits = new LinkedList<>(); + private List<Ref> commits = new ArrayList<>(); private String ourCommitName = null; @@ -102,7 +102,7 @@ public class CherryPickCommand extends GitCommand<CherryPickResult> { UnmergedPathsException, ConcurrentRefUpdateException, WrongRepositoryStateException, NoHeadException { RevCommit newHead = null; - List<Ref> cherryPickedRefs = new LinkedList<>(); + List<Ref> cherryPickedRefs = new ArrayList<>(); checkCallable(); try (RevWalk revWalk = new RevWalk(repo)) { diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/CommitCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/CommitCommand.java index 483b9602da..a1a2cc09d2 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/CommitCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/CommitCommand.java @@ -16,7 +16,6 @@ import java.text.MessageFormat; import java.util.ArrayList; import java.util.Collections; import java.util.HashMap; -import java.util.LinkedList; import java.util.List; import org.eclipse.jgit.annotations.NonNull; @@ -109,7 +108,7 @@ public class CommitCommand extends GitCommand<RevCommit> { * parents this commit should have. The current HEAD will be in this list * and also all commits mentioned in .git/MERGE_HEAD */ - private List<ObjectId> parents = new LinkedList<>(); + private List<ObjectId> parents = new ArrayList<>(); private String reflogComment; diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/MergeCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/MergeCommand.java index ed4a5342b3..7064f5a57a 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/MergeCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/MergeCommand.java @@ -13,9 +13,9 @@ package org.eclipse.jgit.api; import java.io.IOException; import java.text.MessageFormat; +import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; -import java.util.LinkedList; import java.util.List; import java.util.Locale; import java.util.Map; @@ -75,7 +75,7 @@ public class MergeCommand extends GitCommand<MergeResult> { private ContentMergeStrategy contentStrategy; - private List<Ref> commits = new LinkedList<>(); + private List<Ref> commits = new ArrayList<>(); private Boolean squash; diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/RebaseCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/RebaseCommand.java index 757aff89c3..858bd961cd 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/RebaseCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/RebaseCommand.java @@ -23,7 +23,6 @@ import java.util.Collection; import java.util.Collections; import java.util.HashMap; import java.util.Iterator; -import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.regex.Matcher; @@ -1120,8 +1119,8 @@ public class RebaseCommand extends GitCommand<RebaseResult> { private void popSteps(int numSteps) throws IOException { if (numSteps == 0) return; - List<RebaseTodoLine> todoLines = new LinkedList<>(); - List<RebaseTodoLine> poppedLines = new LinkedList<>(); + List<RebaseTodoLine> todoLines = new ArrayList<>(); + List<RebaseTodoLine> poppedLines = new ArrayList<>(); for (RebaseTodoLine line : repo.readRebaseTodo( rebaseState.getPath(GIT_REBASE_TODO), true)) { diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/ResetCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/ResetCommand.java index 225c9996cf..47145a0563 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/ResetCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/ResetCommand.java @@ -11,8 +11,8 @@ package org.eclipse.jgit.api; import java.io.IOException; import java.text.MessageFormat; +import java.util.ArrayList; import java.util.Collection; -import java.util.LinkedList; import org.eclipse.jgit.api.errors.CheckoutConflictException; import org.eclipse.jgit.api.errors.GitAPIException; @@ -90,7 +90,7 @@ public class ResetCommand extends GitCommand<Ref> { private ResetType mode; - private Collection<String> filepaths = new LinkedList<>(); + private Collection<String> filepaths = new ArrayList<>(); private boolean isReflogDisabled; diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/RevertCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/RevertCommand.java index 5231d4a327..855c3b1cf3 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/RevertCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/RevertCommand.java @@ -13,7 +13,7 @@ import static org.eclipse.jgit.lib.Constants.OBJECT_ID_ABBREV_STRING_LENGTH; import java.io.IOException; import java.text.MessageFormat; -import java.util.LinkedList; +import java.util.ArrayList; import java.util.List; import java.util.Map; @@ -58,13 +58,13 @@ import org.eclipse.jgit.treewalk.FileTreeIterator; * >Git documentation about revert</a> */ public class RevertCommand extends GitCommand<RevCommit> { - private List<Ref> commits = new LinkedList<>(); + private List<Ref> commits = new ArrayList<>(); private String ourCommitName = null; private boolean insertChangeId; - private List<Ref> revertedRefs = new LinkedList<>(); + private List<Ref> revertedRefs = new ArrayList<>(); private MergeResult failingResult; diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/RmCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/RmCommand.java index 656f36a81a..7459e7298f 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/RmCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/RmCommand.java @@ -13,7 +13,6 @@ import java.io.File; import java.io.IOException; import java.util.ArrayList; import java.util.Collection; -import java.util.LinkedList; import java.util.List; import org.eclipse.jgit.api.errors.GitAPIException; @@ -71,7 +70,7 @@ public class RmCommand extends GitCommand<DirCache> { */ public RmCommand(Repository repo) { super(repo); - filepatterns = new LinkedList<>(); + filepatterns = new ArrayList<>(); } /** diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/StatusCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/StatusCommand.java index eab389460a..cdd078ea25 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/StatusCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/StatusCommand.java @@ -10,7 +10,7 @@ package org.eclipse.jgit.api; import java.io.IOException; -import java.util.LinkedList; +import java.util.ArrayList; import java.util.List; import org.eclipse.jgit.api.errors.GitAPIException; @@ -83,7 +83,7 @@ public class StatusCommand extends GitCommand<Status> { */ public StatusCommand addPath(String path) { if (paths == null) - paths = new LinkedList<>(); + paths = new ArrayList<>(); paths.add(path); return this; } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/errors/CheckoutConflictException.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/errors/CheckoutConflictException.java index 0224b3dbb3..5538711192 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/errors/CheckoutConflictException.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/errors/CheckoutConflictException.java @@ -37,7 +37,7 @@ */ package org.eclipse.jgit.api.errors; -import java.util.LinkedList; +import java.util.ArrayList; import java.util.List; /** @@ -99,7 +99,7 @@ public class CheckoutConflictException extends GitAPIException { */ CheckoutConflictException addConflictingPath(String conflictingPath) { if (conflictingPaths == null) - conflictingPaths = new LinkedList<>(); + conflictingPaths = new ArrayList<>(); conflictingPaths.add(conflictingPath); return this; } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/BareSuperprojectWriter.java b/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/BareSuperprojectWriter.java index 3ce97a4ff7..d191e23399 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/BareSuperprojectWriter.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/BareSuperprojectWriter.java @@ -156,6 +156,9 @@ class BareSuperprojectWriter { ObjectId objectId; if (ObjectId.isId(proj.getRevision())) { objectId = ObjectId.fromString(proj.getRevision()); + if (config.recordRemoteBranch && proj.getUpstream() != null) { + cfg.setString("submodule", name, "ref", proj.getUpstream()); + } } else { objectId = callback.sha1(url, proj.getRevision()); if (objectId == null && !config.ignoreRemoteFailures) { diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/ManifestParser.java b/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/ManifestParser.java index 957b3869f2..b033177e05 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/ManifestParser.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/ManifestParser.java @@ -176,6 +176,10 @@ public class ManifestParser extends DefaultHandler { attributes.getValue("groups")); currentProject .setRecommendShallow(attributes.getValue("clone-depth")); + currentProject + .setUpstream(attributes.getValue("upstream")); + currentProject + .setDestBranch(attributes.getValue("dest-branch")); break; case "remote": String alias = attributes.getValue("alias"); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/RepoCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/RepoCommand.java index 95c1c8b22e..9979664ceb 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/RepoCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/RepoCommand.java @@ -255,7 +255,7 @@ public class RepoCommand extends GitCommand<RevCommit> { @SuppressWarnings("serial") static class ManifestErrorException extends GitAPIException { ManifestErrorException(Throwable cause) { - super(RepoText.get().invalidManifest, cause); + super(RepoText.get().invalidManifest + " " + cause.getMessage(), cause); } } @@ -615,6 +615,7 @@ public class RepoCommand extends GitCommand<RevCommit> { p.setUrl(proj.getUrl()); p.addCopyFiles(proj.getCopyFiles()); p.addLinkFiles(proj.getLinkFiles()); + p.setUpstream(proj.getUpstream()); ret.add(p); } } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/RepoProject.java b/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/RepoProject.java index 8deb7386a6..b7a9ac5b73 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/RepoProject.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/gitrepo/RepoProject.java @@ -38,6 +38,8 @@ public class RepoProject implements Comparable<RepoProject> { private final Set<String> groups; private final List<CopyFile> copyfiles; private final List<LinkFile> linkfiles; + private String upstream; + private String destBranch; private String recommendShallow; private String url; private String defaultRevision; @@ -389,6 +391,56 @@ public class RepoProject implements Comparable<RepoProject> { this.linkfiles.clear(); } + /** + * Return the upstream attribute of the project + * + * @return the upstream value if present, null otherwise. + * + * @since 6.10 + */ + public String getUpstream() { + return this.upstream; + } + + /** + * Return the dest-branch attribute of the project + * + * @return the dest-branch value if present, null otherwise. + * + * @since 7.0 + */ + public String getDestBranch() { + return this.destBranch; + } + + /** + * Set the upstream attribute of the project + * + * Name of the git ref in which a sha1 can be found, when the revision is a + * sha1. + * + * @param upstream value of the attribute in the manifest + * + * @since 6.10 + */ + public void setUpstream(String upstream) { + this.upstream = upstream; + } + + /** + * Set the dest-branch attribute of the project + * + * Name of a Git branch. + * + * @param destBranch + * value of the attribute in the manifest + * + * @since 7.0 + */ + public void setDestBranch(String destBranch) { + this.destBranch = destBranch; + } + private String getPathWithSlash() { if (path.endsWith("/")) { //$NON-NLS-1$ return path; diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java index ef464e3172..700b54a7a6 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/JGitText.java @@ -745,6 +745,7 @@ public class JGitText extends TranslationBundle { /***/ public String shortReadOfOptionalDIRCExtensionExpectedAnotherBytes; /***/ public String shortSkipOfBlock; /***/ public String shutdownCleanup; + /***/ public String shutdownCleanupFailed; /***/ public String shutdownCleanupListenerFailed; /***/ public String signatureVerificationError; /***/ public String signatureVerificationUnavailable; diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/diffmergetool/CommandExecutor.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/diffmergetool/CommandExecutor.java index 25b7b8e5ba..c64a844af1 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/diffmergetool/CommandExecutor.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/diffmergetool/CommandExecutor.java @@ -165,6 +165,9 @@ public class CommandExecutor { if (fs instanceof FS_POSIX) { commandArray = new String[1]; commandArray[0] = commandFile.getCanonicalPath(); + } else if (fs instanceof FS_Win32_Cygwin) { + commandArray = new String[1]; + commandArray[0] = commandFile.getCanonicalPath().replace("\\", "/"); //$NON-NLS-1$ //$NON-NLS-2$ } else if (fs instanceof FS_Win32) { if (useMsys2) { commandArray = new String[3]; @@ -176,9 +179,6 @@ public class CommandExecutor { commandArray = new String[1]; commandArray[0] = commandFile.getCanonicalPath(); } - } else if (fs instanceof FS_Win32_Cygwin) { - commandArray = new String[1]; - commandArray[0] = commandFile.getCanonicalPath().replace("\\", "/"); //$NON-NLS-1$ //$NON-NLS-2$ } else { throw new ToolException( "JGit: file system not supported: " + fs.toString()); //$NON-NLS-1$ diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/commitgraph/CommitGraphLoader.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/commitgraph/CommitGraphLoader.java index 867d522e08..7e9220dc0d 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/commitgraph/CommitGraphLoader.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/commitgraph/CommitGraphLoader.java @@ -98,6 +98,46 @@ public class CommitGraphLoader { */ public static CommitGraph read(InputStream fd) throws CommitGraphFormatException, IOException { + + boolean readChangedPathFilters; + try { + readChangedPathFilters = SystemReader.getInstance().getJGitConfig() + .getBoolean(ConfigConstants.CONFIG_COMMIT_GRAPH_SECTION, + ConfigConstants.CONFIG_KEY_READ_CHANGED_PATHS, + false); + } catch (ConfigInvalidException e) { + // Use the default value if, for some reason, the config couldn't be + // read. + readChangedPathFilters = false; + } + + return read(fd, readChangedPathFilters); + } + + /** + * Read an existing commit-graph file from a buffered stream. + * <p> + * The format of the file will be automatically detected and a proper access + * implementation for that format will be constructed and returned to the + * caller. The file may or may not be held open by the returned instance. + * + * @param fd + * stream to read the commit-graph file from. The stream must be + * buffered as some small IOs are performed against the stream. + * The caller is responsible for closing the stream. + * + * @param readChangedPathFilters + * enable reading bloom filter chunks. + * + * @return a copy of the commit-graph file in memory + * @throws CommitGraphFormatException + * the commit-graph file's format is different from we expected. + * @throws java.io.IOException + * the stream cannot be read. + */ + public static CommitGraph read(InputStream fd, + boolean readChangedPathFilters) + throws CommitGraphFormatException, IOException { byte[] hdr = new byte[8]; IO.readFully(fd, hdr, 0, hdr.length); @@ -142,17 +182,6 @@ public class CommitGraphLoader { chunks.add(new ChunkSegment(id, offset)); } - boolean readChangedPathFilters; - try { - readChangedPathFilters = SystemReader.getInstance() - .getJGitConfig() - .getBoolean(ConfigConstants.CONFIG_COMMIT_GRAPH_SECTION, - ConfigConstants.CONFIG_KEY_READ_CHANGED_PATHS, false); - } catch (ConfigInvalidException e) { - // Use the default value if, for some reason, the config couldn't be read. - readChangedPathFilters = false; - } - CommitGraphBuilder builder = CommitGraphBuilder.builder(); for (int i = 0; i < numberOfChunks; i++) { long chunkOffset = chunks.get(i).offset; diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/commitgraph/CommitGraphWriter.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/commitgraph/CommitGraphWriter.java index 1f1c35ac19..0d9815eceb 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/commitgraph/CommitGraphWriter.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/commitgraph/CommitGraphWriter.java @@ -31,12 +31,12 @@ import java.io.IOException; import java.io.InterruptedIOException; import java.io.OutputStream; import java.nio.ByteBuffer; +import java.util.ArrayDeque; import java.util.ArrayList; import java.util.Collections; import java.util.HashSet; import java.util.List; import java.util.Optional; -import java.util.Stack; import org.eclipse.jgit.annotations.NonNull; import org.eclipse.jgit.annotations.Nullable; @@ -336,10 +336,10 @@ public class CommitGraphWriter { continue; } - Stack<RevCommit> commitStack = new Stack<>(); + ArrayDeque<RevCommit> commitStack = new ArrayDeque<>(); commitStack.push(cmit); - while (!commitStack.empty()) { + while (!commitStack.isEmpty()) { int maxGeneration = 0; boolean allParentComputed = true; RevCommit current = commitStack.peek(); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/ClockBlockCacheTable.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/ClockBlockCacheTable.java new file mode 100644 index 0000000000..d0907bcc8d --- /dev/null +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/ClockBlockCacheTable.java @@ -0,0 +1,563 @@ +/* + * Copyright (c) 2024, Google LLC and others + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Distribution License v. 1.0 which is available at + * http://www.eclipse.org/org/documents/edl-v10.php. + * + * SPDX-License-Identifier: BSD-3-Clause + */ + +package org.eclipse.jgit.internal.storage.dfs; + +import java.io.IOException; +import java.time.Duration; +import java.util.Map; +import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.atomic.AtomicReferenceArray; +import java.util.concurrent.locks.ReentrantLock; +import java.util.function.Consumer; +import java.util.stream.LongStream; + +import org.eclipse.jgit.internal.JGitText; +import org.eclipse.jgit.internal.storage.dfs.DfsBlockCache.ReadableChannelSupplier; +import org.eclipse.jgit.internal.storage.dfs.DfsBlockCache.Ref; +import org.eclipse.jgit.internal.storage.dfs.DfsBlockCache.RefLoader; +import org.eclipse.jgit.internal.storage.pack.PackExt; + +/** + * Default implementation of the {@link DfsBlockCacheTable}. + * <p> + * This cache implements a clock replacement algorithm, giving each block at + * least one chance to have been accessed during a sweep of the cache to save + * itself from eviction. The number of swipe chances is configurable per pack + * extension. + * <p> + * Entities created by the cache are held under hard references, preventing the + * Java VM from clearing anything. Blocks are discarded by the replacement + * algorithm when adding a new block would cause the cache to exceed its + * configured maximum size. + * <p> + * Whenever a cache miss occurs, loading is invoked by exactly one thread for + * the given <code>(DfsStreamKey,position)</code> key tuple. This is ensured by + * an array of locks, with the tuple hashed to a lock instance. + * <p> + * The internal hash table does not expand at runtime, instead it is fixed in + * size at cache creation time. The internal lock table used to gate load + * invocations is also fixed in size. + */ +final class ClockBlockCacheTable implements DfsBlockCacheTable { + /** Number of entries in {@link #table}. */ + private final int tableSize; + + /** Maximum number of bytes the cache should hold. */ + private final long maxBytes; + + /** + * Used to reserve space for blocks. + * <p> + * The value for blockSize must be a power of 2. + */ + private final int blockSize; + + private final Hash hash; + + /** Hash bucket directory; entries are chained below. */ + private final AtomicReferenceArray<HashEntry> table; + + /** + * Locks to prevent concurrent loads for same (PackFile,position) block. The + * number of locks is {@link DfsBlockCacheConfig#getConcurrencyLevel()} to + * cap the overall concurrent block loads. + */ + private final ReentrantLock[] loadLocks; + + /** + * A separate pool of locks per pack extension to prevent concurrent loads + * for same index or bitmap from PackFile. + */ + private final ReentrantLock[][] refLocks; + + /** Protects the clock and its related data. */ + private final ReentrantLock clockLock; + + /** Current position of the clock. */ + private Ref clockHand; + + private final DfsBlockCacheStats dfsBlockCacheStats; + + /** + * A consumer of object reference lock wait time milliseconds. May be used + * to build a metric. + */ + private final Consumer<Long> refLockWaitTime; + + /** Consumer of loading and eviction events of indexes. */ + private final DfsBlockCacheConfig.IndexEventConsumer indexEventConsumer; + + /** Stores timestamps of the last eviction of indexes. */ + private final Map<EvictKey, Long> indexEvictionMap = new ConcurrentHashMap<>(); + + ClockBlockCacheTable(DfsBlockCacheConfig cfg) { + this.tableSize = tableSize(cfg); + if (tableSize < 1) { + throw new IllegalArgumentException( + JGitText.get().tSizeMustBeGreaterOrEqual1); + } + int concurrencyLevel = cfg.getConcurrencyLevel(); + this.maxBytes = cfg.getBlockLimit(); + this.blockSize = cfg.getBlockSize(); + int blockSizeShift = Integer.numberOfTrailingZeros(blockSize); + this.hash = new Hash(blockSizeShift); + table = new AtomicReferenceArray<>(tableSize); + + loadLocks = new ReentrantLock[concurrencyLevel]; + for (int i = 0; i < loadLocks.length; i++) { + loadLocks[i] = new ReentrantLock(/* fair= */ true); + } + refLocks = new ReentrantLock[PackExt.values().length][concurrencyLevel]; + for (int i = 0; i < PackExt.values().length; i++) { + for (int j = 0; j < concurrencyLevel; ++j) { + refLocks[i][j] = new ReentrantLock(/* fair= */ true); + } + } + + clockLock = new ReentrantLock(/* fair= */ true); + String none = ""; //$NON-NLS-1$ + clockHand = new Ref<>( + DfsStreamKey.of(new DfsRepositoryDescription(none), none, null), + -1, 0, null); + clockHand.next = clockHand; + + this.dfsBlockCacheStats = new DfsBlockCacheStats(); + this.refLockWaitTime = cfg.getRefLockWaitTimeConsumer(); + this.indexEventConsumer = cfg.getIndexEventConsumer(); + } + + @Override + public DfsBlockCacheStats getDfsBlockCacheStats() { + return dfsBlockCacheStats; + } + + @Override + public boolean hasBlock0(DfsStreamKey key) { + HashEntry e1 = table.get(slot(key, 0)); + DfsBlock v = scan(e1, key, 0); + return v != null && v.contains(key, 0); + } + + @Override + public DfsBlock getOrLoad(BlockBasedFile file, long position, DfsReader ctx, + ReadableChannelSupplier fileChannel) throws IOException { + final long requestedPosition = position; + position = file.alignToBlock(position); + + DfsStreamKey key = file.key; + int slot = slot(key, position); + HashEntry e1 = table.get(slot); + DfsBlock v = scan(e1, key, position); + if (v != null && v.contains(key, requestedPosition)) { + ctx.stats.blockCacheHit++; + dfsBlockCacheStats.incrementHit(key); + return v; + } + + reserveSpace(blockSize, key); + ReentrantLock regionLock = lockFor(key, position); + regionLock.lock(); + try { + HashEntry e2 = table.get(slot); + if (e2 != e1) { + v = scan(e2, key, position); + if (v != null) { + ctx.stats.blockCacheHit++; + dfsBlockCacheStats.incrementHit(key); + creditSpace(blockSize, key); + return v; + } + } + + dfsBlockCacheStats.incrementMiss(key); + boolean credit = true; + try { + v = file.readOneBlock(position, ctx, fileChannel.get()); + credit = false; + } finally { + if (credit) { + creditSpace(blockSize, key); + } + } + if (position != v.start) { + // The file discovered its blockSize and adjusted. + position = v.start; + slot = slot(key, position); + e2 = table.get(slot); + } + + Ref<DfsBlock> ref = new Ref<>(key, position, v.size(), v); + ref.markHotter(); + for (;;) { + HashEntry n = new HashEntry(HashEntry.clean(e2), ref); + if (table.compareAndSet(slot, e2, n)) { + break; + } + e2 = table.get(slot); + } + addToClock(ref, blockSize - v.size()); + } finally { + regionLock.unlock(); + } + + // If the block size changed from the default, it is possible the + // block + // that was loaded is the wrong block for the requested position. + if (v.contains(file.key, requestedPosition)) { + return v; + } + return getOrLoad(file, requestedPosition, ctx, fileChannel); + } + + @Override + public <T> Ref<T> getOrLoadRef(DfsStreamKey key, long position, + RefLoader<T> loader) throws IOException { + long start = System.nanoTime(); + int slot = slot(key, position); + HashEntry e1 = table.get(slot); + Ref<T> ref = scanRef(e1, key, position); + if (ref != null) { + dfsBlockCacheStats.incrementHit(key); + reportIndexRequested(ref, true /* cacheHit= */, start); + return ref; + } + + ReentrantLock regionLock = lockForRef(key); + long lockStart = System.currentTimeMillis(); + regionLock.lock(); + try { + HashEntry e2 = table.get(slot); + if (e2 != e1) { + ref = scanRef(e2, key, position); + if (ref != null) { + dfsBlockCacheStats.incrementHit(key); + reportIndexRequested(ref, true /* cacheHit= */, start); + return ref; + } + } + + if (refLockWaitTime != null) { + refLockWaitTime.accept( + Long.valueOf(System.currentTimeMillis() - lockStart)); + } + dfsBlockCacheStats.incrementMiss(key); + ref = loader.load(); + ref.markHotter(); + // Reserve after loading to get the size of the object + reserveSpace(ref.size, key); + for (;;) { + HashEntry n = new HashEntry(HashEntry.clean(e2), ref); + if (table.compareAndSet(slot, e2, n)) { + break; + } + e2 = table.get(slot); + } + addToClock(ref, 0); + } finally { + regionLock.unlock(); + } + reportIndexRequested(ref, /* cacheHit= */ false, start); + return ref; + } + + @Override + public void put(DfsBlock v) { + put(v.stream, v.start, v.size(), v); + } + + @Override + public <T> Ref<T> put(DfsStreamKey key, long pos, long size, T v) { + int slot = slot(key, pos); + HashEntry e1 = table.get(slot); + Ref<T> ref = scanRef(e1, key, pos); + if (ref != null) { + return ref; + } + + reserveSpace(size, key); + ReentrantLock regionLock = lockFor(key, pos); + regionLock.lock(); + try { + HashEntry e2 = table.get(slot); + if (e2 != e1) { + ref = scanRef(e2, key, pos); + if (ref != null) { + creditSpace(size, key); + return ref; + } + } + + ref = new Ref<>(key, pos, size, v); + ref.markHotter(); + for (;;) { + HashEntry n = new HashEntry(HashEntry.clean(e2), ref); + if (table.compareAndSet(slot, e2, n)) { + break; + } + e2 = table.get(slot); + } + addToClock(ref, 0); + } finally { + regionLock.unlock(); + } + return ref; + } + + @Override + public <T> Ref<T> putRef(DfsStreamKey key, long size, T v) { + return put(key, 0, size, v); + } + + @Override + public boolean contains(DfsStreamKey key, long position) { + return scan(table.get(slot(key, position)), key, position) != null; + } + + @SuppressWarnings("unchecked") + @Override + public <T> T get(DfsStreamKey key, long position) { + T val = (T) scan(table.get(slot(key, position)), key, position); + if (val == null) { + dfsBlockCacheStats.incrementMiss(key); + } else { + dfsBlockCacheStats.incrementHit(key); + } + return val; + } + + private int slot(DfsStreamKey key, long position) { + return (hash.hash(key.hash, position) >>> 1) % tableSize; + } + + @SuppressWarnings("unchecked") + private void reserveSpace(long reserve, DfsStreamKey key) { + clockLock.lock(); + try { + long live = LongStream.of(dfsBlockCacheStats.getCurrentSize()).sum() + + reserve; + if (maxBytes < live) { + Ref prev = clockHand; + Ref hand = clockHand.next; + do { + if (hand.isHot()) { + // Value was recently touched. Cache is still hot so + // give it another chance, but cool it down a bit. + hand.markColder(); + prev = hand; + hand = hand.next; + continue; + } else if (prev == hand) { + break; + } + + // No recent access since last scan, kill + // value and remove from clock. + Ref dead = hand; + hand = hand.next; + prev.next = hand; + dead.next = null; + dead.value = null; + live -= dead.size; + dfsBlockCacheStats.addToLiveBytes(dead.key, -dead.size); + dfsBlockCacheStats.incrementEvict(dead.key); + reportIndexEvicted(dead); + } while (maxBytes < live); + clockHand = prev; + } + dfsBlockCacheStats.addToLiveBytes(key, reserve); + } finally { + clockLock.unlock(); + } + } + + private void creditSpace(long credit, DfsStreamKey key) { + clockLock.lock(); + try { + dfsBlockCacheStats.addToLiveBytes(key, -credit); + } finally { + clockLock.unlock(); + } + } + + @SuppressWarnings("unchecked") + private void addToClock(Ref ref, long credit) { + clockLock.lock(); + try { + if (credit != 0) { + dfsBlockCacheStats.addToLiveBytes(ref.key, -credit); + } + Ref ptr = clockHand; + ref.next = ptr.next; + ptr.next = ref; + clockHand = ref; + } finally { + clockLock.unlock(); + } + } + + private <T> T scan(HashEntry n, DfsStreamKey key, long position) { + Ref<T> r = scanRef(n, key, position); + return r != null ? r.get() : null; + } + + @SuppressWarnings("unchecked") + private <T> Ref<T> scanRef(HashEntry n, DfsStreamKey key, long position) { + for (; n != null; n = n.next) { + Ref<T> r = n.ref; + if (r.position == position && r.key.equals(key)) { + return r.get() != null ? r : null; + } + } + return null; + } + + private ReentrantLock lockFor(DfsStreamKey key, long position) { + return loadLocks[(hash.hash(key.hash, position) >>> 1) + % loadLocks.length]; + } + + private ReentrantLock lockForRef(DfsStreamKey key) { + int slot = (key.hash >>> 1) % refLocks[key.packExtPos].length; + return refLocks[key.packExtPos][slot]; + } + + private void reportIndexRequested(Ref<?> ref, boolean cacheHit, + long start) { + if (indexEventConsumer == null || !isIndexExtPos(ref.key.packExtPos)) { + return; + } + EvictKey evictKey = createEvictKey(ref); + Long prevEvictedTime = indexEvictionMap.get(evictKey); + long now = System.nanoTime(); + long sinceLastEvictionNanos = prevEvictedTime == null ? 0L + : now - prevEvictedTime.longValue(); + indexEventConsumer.acceptRequestedEvent(ref.key.packExtPos, cacheHit, + (now - start) / 1000L /* micros */, ref.size, + Duration.ofNanos(sinceLastEvictionNanos)); + } + + private void reportIndexEvicted(Ref<?> dead) { + if (indexEventConsumer == null + || !indexEventConsumer.shouldReportEvictedEvent() + || !isIndexExtPos(dead.key.packExtPos)) { + return; + } + EvictKey evictKey = createEvictKey(dead); + Long prevEvictedTime = indexEvictionMap.get(evictKey); + long now = System.nanoTime(); + long sinceLastEvictionNanos = prevEvictedTime == null ? 0L + : now - prevEvictedTime.longValue(); + indexEvictionMap.put(evictKey, Long.valueOf(now)); + indexEventConsumer.acceptEvictedEvent(dead.key.packExtPos, dead.size, + dead.getTotalHitCount(), + Duration.ofNanos(sinceLastEvictionNanos)); + } + + private static final class HashEntry { + /** Next entry in the hash table's chain list. */ + final HashEntry next; + + /** The referenced object. */ + final Ref ref; + + HashEntry(HashEntry n, Ref r) { + next = n; + ref = r; + } + + private static HashEntry clean(HashEntry top) { + while (top != null && top.ref.next == null) { + top = top.next; + } + if (top == null) { + return null; + } + HashEntry n = clean(top.next); + return n == top.next ? top : new HashEntry(n, top.ref); + } + } + + private EvictKey createEvictKey(Ref<?> ref) { + return new EvictKey(hash, ref); + } + + private static boolean isIndexExtPos(int packExtPos) { + return packExtPos == PackExt.INDEX.getPosition() + || packExtPos == PackExt.REVERSE_INDEX.getPosition() + || packExtPos == PackExt.BITMAP_INDEX.getPosition(); + } + + private static int tableSize(DfsBlockCacheConfig cfg) { + final int wsz = cfg.getBlockSize(); + final long limit = cfg.getBlockLimit(); + if (wsz <= 0) { + throw new IllegalArgumentException( + JGitText.get().invalidWindowSize); + } + if (limit < wsz) { + throw new IllegalArgumentException( + JGitText.get().windowSizeMustBeLesserThanLimit); + } + return (int) Math.min(5 * (limit / wsz) / 2, Integer.MAX_VALUE); + } + + private static final class Hash { + /** + * As {@link #blockSize} is a power of 2, bits to shift for a / + * blockSize. + */ + private final int blockSizeShift; + + Hash(int blockSizeShift) { + this.blockSizeShift = blockSizeShift; + } + + int hash(int packHash, long off) { + return packHash + (int) (off >>> blockSizeShift); + } + } + + private static final class EvictKey { + /** + * Provides the hash function to be used for this key's hashCode method. + */ + private final Hash hash; + + private final int keyHash; + + private final int packExtPos; + + private final long position; + + EvictKey(Hash hash, Ref<?> ref) { + this.hash = hash; + keyHash = ref.key.hash; + packExtPos = ref.key.packExtPos; + position = ref.position; + } + + @Override + public boolean equals(Object object) { + if (object instanceof EvictKey) { + EvictKey other = (EvictKey) object; + return keyHash == other.keyHash + && packExtPos == other.packExtPos + && position == other.position; + } + return false; + } + + @Override + public int hashCode() { + return hash.hash(keyHash, position); + } + } +} diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsBlockCache.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsBlockCache.java index f7c460c1a8..56719cf0f4 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsBlockCache.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsBlockCache.java @@ -12,18 +12,9 @@ package org.eclipse.jgit.internal.storage.dfs; import java.io.IOException; -import java.time.Duration; -import java.util.Map; -import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.atomic.AtomicInteger; -import java.util.concurrent.atomic.AtomicLong; -import java.util.concurrent.atomic.AtomicReference; -import java.util.concurrent.atomic.AtomicReferenceArray; -import java.util.concurrent.locks.ReentrantLock; -import java.util.function.Consumer; import java.util.stream.LongStream; -import org.eclipse.jgit.internal.JGitText; import org.eclipse.jgit.internal.storage.pack.PackExt; /** @@ -36,31 +27,14 @@ import org.eclipse.jgit.internal.storage.pack.PackExt; * reads of only tiny slices of a file, the DfsBlockCache tries to smooth out * these tiny reads into larger block-sized IO operations. * <p> - * Whenever a cache miss occurs, loading is invoked by exactly one thread for - * the given <code>(DfsStreamKey,position)</code> key tuple. This is ensured by - * an array of locks, with the tuple hashed to a lock instance. - * <p> * Its too expensive during object access to be accurate with a least recently * used (LRU) algorithm. Strictly ordering every read is a lot of overhead that - * typically doesn't yield a corresponding benefit to the application. This - * cache implements a clock replacement algorithm, giving each block at least - * one chance to have been accessed during a sweep of the cache to save itself - * from eviction. The number of swipe chances is configurable per pack - * extension. - * <p> - * Entities created by the cache are held under hard references, preventing the - * Java VM from clearing anything. Blocks are discarded by the replacement - * algorithm when adding a new block would cause the cache to exceed its - * configured maximum size. + * typically doesn't yield a corresponding benefit to the application. * <p> * The key tuple is passed through to methods as a pair of parameters rather * than as a single Object, thus reducing the transient memory allocations of * callers. It is more efficient to avoid the allocation, as we can't be 100% * sure that a JIT would be able to stack-allocate a key tuple. - * <p> - * The internal hash table does not expand at runtime, instead it is fixed in - * size at cache creation time. The internal lock table used to gate load - * invocations is also fixed in size. */ public final class DfsBlockCache { private static volatile DfsBlockCache cache; @@ -94,24 +68,7 @@ public final class DfsBlockCache { return cache; } - /** Number of entries in {@link #table}. */ - private final int tableSize; - - /** Hash bucket directory; entries are chained below. */ - private final AtomicReferenceArray<HashEntry> table; - - /** - * Locks to prevent concurrent loads for same (PackFile,position) block. The - * number of locks is {@link DfsBlockCacheConfig#getConcurrencyLevel()} to - * cap the overall concurrent block loads. - */ - private final ReentrantLock[] loadLocks; - - /** - * A separate pool of locks per pack extension to prevent concurrent loads - * for same index or bitmap from PackFile. - */ - private final ReentrantLock[][] refLocks; + private final DfsBlockCacheTable dfsBlockCacheTable; /** Maximum number of bytes the cache should hold. */ private final long maxBytes; @@ -131,89 +88,16 @@ public final class DfsBlockCache { */ private final int blockSize; - /** As {@link #blockSize} is a power of 2, bits to shift for a / blockSize. */ - private final int blockSizeShift; - - /** - * Number of times a block was found in the cache, per pack file extension. - */ - private final AtomicReference<AtomicLong[]> statHit; - - /** - * Number of times a block was not found, and had to be loaded, per pack - * file extension. - */ - private final AtomicReference<AtomicLong[]> statMiss; - - /** - * Number of blocks evicted due to cache being full, per pack file - * extension. - */ - private final AtomicReference<AtomicLong[]> statEvict; - - /** - * Number of bytes currently loaded in the cache, per pack file extension. - */ - private final AtomicReference<AtomicLong[]> liveBytes; - - /** Protects the clock and its related data. */ - private final ReentrantLock clockLock; - - /** - * A consumer of object reference lock wait time milliseconds. May be used to build a metric. - */ - private final Consumer<Long> refLockWaitTime; - - /** Current position of the clock. */ - private Ref clockHand; - /** Limits of cache hot count per pack file extension. */ private final int[] cacheHotLimits = new int[PackExt.values().length]; - /** Consumer of loading and eviction events of indexes. */ - private final DfsBlockCacheConfig.IndexEventConsumer indexEventConsumer; - - /** Stores timestamps of the last eviction of indexes. */ - private final Map<EvictKey, Long> indexEvictionMap = new ConcurrentHashMap<>(); - - @SuppressWarnings("unchecked") private DfsBlockCache(DfsBlockCacheConfig cfg) { - tableSize = tableSize(cfg); - if (tableSize < 1) { - throw new IllegalArgumentException(JGitText.get().tSizeMustBeGreaterOrEqual1); - } - - table = new AtomicReferenceArray<>(tableSize); - int concurrencyLevel = cfg.getConcurrencyLevel(); - loadLocks = new ReentrantLock[concurrencyLevel]; - for (int i = 0; i < loadLocks.length; i++) { - loadLocks[i] = new ReentrantLock(true /* fair */); - } - refLocks = new ReentrantLock[PackExt.values().length][concurrencyLevel]; - for (int i = 0; i < PackExt.values().length; i++) { - for (int j = 0; j < concurrencyLevel; ++j) { - refLocks[i][j] = new ReentrantLock(true /* fair */); - } - } - maxBytes = cfg.getBlockLimit(); - maxStreamThroughCache = (long) (maxBytes * cfg.getStreamRatio()); blockSize = cfg.getBlockSize(); - blockSizeShift = Integer.numberOfTrailingZeros(blockSize); - - clockLock = new ReentrantLock(true /* fair */); - String none = ""; //$NON-NLS-1$ - clockHand = new Ref<>( - DfsStreamKey.of(new DfsRepositoryDescription(none), none, null), - -1, 0, null); - clockHand.next = clockHand; - - statHit = new AtomicReference<>(newCounters()); - statMiss = new AtomicReference<>(newCounters()); - statEvict = new AtomicReference<>(newCounters()); - liveBytes = new AtomicReference<>(newCounters()); + double streamRatio = cfg.getStreamRatio(); + maxStreamThroughCache = (long) (maxBytes * streamRatio); - refLockWaitTime = cfg.getRefLockWaitTimeConsumer(); + dfsBlockCacheTable = new ClockBlockCacheTable(cfg); for (int i = 0; i < PackExt.values().length; ++i) { Integer limit = cfg.getCacheHotMap().get(PackExt.values()[i]); @@ -223,7 +107,6 @@ public final class DfsBlockCache { cacheHotLimits[i] = DfsBlockCacheConfig.DEFAULT_CACHE_HOT_MAX; } } - indexEventConsumer = cfg.getIndexEventConsumer(); } boolean shouldCopyThroughCache(long length) { @@ -236,7 +119,7 @@ public final class DfsBlockCache { * @return total number of bytes in the cache, per pack file extension. */ public long[] getCurrentSize() { - return getStatVals(liveBytes); + return dfsBlockCacheTable.getDfsBlockCacheStats().getCurrentSize(); } /** @@ -255,7 +138,7 @@ public final class DfsBlockCache { * extension. */ public long[] getHitCount() { - return getStatVals(statHit); + return dfsBlockCacheTable.getDfsBlockCacheStats().getHitCount(); } /** @@ -266,7 +149,7 @@ public final class DfsBlockCache { * extension. */ public long[] getMissCount() { - return getStatVals(statMiss); + return dfsBlockCacheTable.getDfsBlockCacheStats().getMissCount(); } /** @@ -275,16 +158,8 @@ public final class DfsBlockCache { * @return total number of requests (hit + miss), per pack file extension. */ public long[] getTotalRequestCount() { - AtomicLong[] hit = statHit.get(); - AtomicLong[] miss = statMiss.get(); - long[] cnt = new long[Math.max(hit.length, miss.length)]; - for (int i = 0; i < hit.length; i++) { - cnt[i] += hit[i].get(); - } - for (int i = 0; i < miss.length; i++) { - cnt[i] += miss[i].get(); - } - return cnt; + return dfsBlockCacheTable.getDfsBlockCacheStats() + .getTotalRequestCount(); } /** @@ -293,22 +168,7 @@ public final class DfsBlockCache { * @return hit ratios */ public long[] getHitRatio() { - AtomicLong[] hit = statHit.get(); - AtomicLong[] miss = statMiss.get(); - long[] ratio = new long[Math.max(hit.length, miss.length)]; - for (int i = 0; i < ratio.length; i++) { - if (i >= hit.length) { - ratio[i] = 0; - } else if (i >= miss.length) { - ratio[i] = 100; - } else { - long hitVal = hit[i].get(); - long missVal = miss[i].get(); - long total = hitVal + missVal; - ratio[i] = total == 0 ? 0 : hitVal * 100 / total; - } - } - return ratio; + return dfsBlockCacheTable.getDfsBlockCacheStats().getHitRatio(); } /** @@ -319,7 +179,7 @@ public final class DfsBlockCache { * file extension. */ public long[] getEvictions() { - return getStatVals(statEvict); + return dfsBlockCacheTable.getDfsBlockCacheStats().getEvictions(); } /** @@ -334,31 +194,13 @@ public final class DfsBlockCache { * @return true if block 0 (the first block) is in the cache. */ public boolean hasBlock0(DfsStreamKey key) { - HashEntry e1 = table.get(slot(key, 0)); - DfsBlock v = scan(e1, key, 0); - return v != null && v.contains(key, 0); - } - - private int hash(int packHash, long off) { - return packHash + (int) (off >>> blockSizeShift); + return dfsBlockCacheTable.hasBlock0(key); } int getBlockSize() { return blockSize; } - private static int tableSize(DfsBlockCacheConfig cfg) { - final int wsz = cfg.getBlockSize(); - final long limit = cfg.getBlockLimit(); - if (wsz <= 0) { - throw new IllegalArgumentException(JGitText.get().invalidWindowSize); - } - if (limit < wsz) { - throw new IllegalArgumentException(JGitText.get().windowSizeMustBeLesserThanLimit); - } - return (int) Math.min(5 * (limit / wsz) / 2, Integer.MAX_VALUE); - } - /** * Look up a cached object, creating and loading it if it doesn't exist. * @@ -376,139 +218,11 @@ public final class DfsBlockCache { */ DfsBlock getOrLoad(BlockBasedFile file, long position, DfsReader ctx, ReadableChannelSupplier fileChannel) throws IOException { - final long requestedPosition = position; - position = file.alignToBlock(position); - - DfsStreamKey key = file.key; - int slot = slot(key, position); - HashEntry e1 = table.get(slot); - DfsBlock v = scan(e1, key, position); - if (v != null && v.contains(key, requestedPosition)) { - ctx.stats.blockCacheHit++; - getStat(statHit, key).incrementAndGet(); - return v; - } - - reserveSpace(blockSize, key); - ReentrantLock regionLock = lockFor(key, position); - regionLock.lock(); - try { - HashEntry e2 = table.get(slot); - if (e2 != e1) { - v = scan(e2, key, position); - if (v != null) { - ctx.stats.blockCacheHit++; - getStat(statHit, key).incrementAndGet(); - creditSpace(blockSize, key); - return v; - } - } - - getStat(statMiss, key).incrementAndGet(); - boolean credit = true; - try { - v = file.readOneBlock(position, ctx, fileChannel.get()); - credit = false; - } finally { - if (credit) { - creditSpace(blockSize, key); - } - } - if (position != v.start) { - // The file discovered its blockSize and adjusted. - position = v.start; - slot = slot(key, position); - e2 = table.get(slot); - } - - Ref<DfsBlock> ref = new Ref<>(key, position, v.size(), v); - ref.markHotter(); - for (;;) { - HashEntry n = new HashEntry(clean(e2), ref); - if (table.compareAndSet(slot, e2, n)) { - break; - } - e2 = table.get(slot); - } - addToClock(ref, blockSize - v.size()); - } finally { - regionLock.unlock(); - } - - // If the block size changed from the default, it is possible the block - // that was loaded is the wrong block for the requested position. - if (v.contains(file.key, requestedPosition)) { - return v; - } - return getOrLoad(file, requestedPosition, ctx, fileChannel); - } - - @SuppressWarnings("unchecked") - private void reserveSpace(long reserve, DfsStreamKey key) { - clockLock.lock(); - try { - long live = LongStream.of(getCurrentSize()).sum() + reserve; - if (maxBytes < live) { - Ref prev = clockHand; - Ref hand = clockHand.next; - do { - if (hand.isHot()) { - // Value was recently touched. Cache is still hot so - // give it another chance, but cool it down a bit. - hand.markColder(); - prev = hand; - hand = hand.next; - continue; - } else if (prev == hand) - break; - - // No recent access since last scan, kill - // value and remove from clock. - Ref dead = hand; - hand = hand.next; - prev.next = hand; - dead.next = null; - dead.value = null; - live -= dead.size; - getStat(liveBytes, dead.key).addAndGet(-dead.size); - getStat(statEvict, dead.key).incrementAndGet(); - reportIndexEvicted(dead); - } while (maxBytes < live); - clockHand = prev; - } - getStat(liveBytes, key).addAndGet(reserve); - } finally { - clockLock.unlock(); - } - } - - private void creditSpace(long credit, DfsStreamKey key) { - clockLock.lock(); - try { - getStat(liveBytes, key).addAndGet(-credit); - } finally { - clockLock.unlock(); - } - } - - @SuppressWarnings("unchecked") - private void addToClock(Ref ref, long credit) { - clockLock.lock(); - try { - if (credit != 0) { - getStat(liveBytes, ref.key).addAndGet(-credit); - } - Ref ptr = clockHand; - ref.next = ptr.next; - ptr.next = ref; - clockHand = ref; - } finally { - clockLock.unlock(); - } + return dfsBlockCacheTable.getOrLoad(file, position, ctx, fileChannel); } void put(DfsBlock v) { - put(v.stream, v.start, v.size(), v); + dfsBlockCacheTable.put(v); } /** @@ -524,252 +238,41 @@ public final class DfsBlockCache { * @throws IOException * the reference was not in the cache and could not be loaded. */ - <T> Ref<T> getOrLoadRef( - DfsStreamKey key, long position, RefLoader<T> loader) - throws IOException { - long start = System.nanoTime(); - int slot = slot(key, position); - HashEntry e1 = table.get(slot); - Ref<T> ref = scanRef(e1, key, position); - if (ref != null) { - getStat(statHit, key).incrementAndGet(); - reportIndexRequested(ref, true /* cacheHit */, start); - return ref; - } - - ReentrantLock regionLock = lockForRef(key); - long lockStart = System.currentTimeMillis(); - regionLock.lock(); - try { - HashEntry e2 = table.get(slot); - if (e2 != e1) { - ref = scanRef(e2, key, position); - if (ref != null) { - getStat(statHit, key).incrementAndGet(); - reportIndexRequested(ref, true /* cacheHit */, - start); - return ref; - } - } - - if (refLockWaitTime != null) { - refLockWaitTime.accept( - Long.valueOf(System.currentTimeMillis() - lockStart)); - } - getStat(statMiss, key).incrementAndGet(); - ref = loader.load(); - ref.markHotter(); - // Reserve after loading to get the size of the object - reserveSpace(ref.size, key); - for (;;) { - HashEntry n = new HashEntry(clean(e2), ref); - if (table.compareAndSet(slot, e2, n)) { - break; - } - e2 = table.get(slot); - } - addToClock(ref, 0); - } finally { - regionLock.unlock(); - } - reportIndexRequested(ref, false /* cacheHit */, start); - return ref; + <T> Ref<T> getOrLoadRef(DfsStreamKey key, long position, + RefLoader<T> loader) throws IOException { + return dfsBlockCacheTable.getOrLoadRef(key, position, loader); } <T> Ref<T> putRef(DfsStreamKey key, long size, T v) { - return put(key, 0, size, v); + return dfsBlockCacheTable.putRef(key, size, v); } <T> Ref<T> put(DfsStreamKey key, long pos, long size, T v) { - int slot = slot(key, pos); - HashEntry e1 = table.get(slot); - Ref<T> ref = scanRef(e1, key, pos); - if (ref != null) { - return ref; - } - - reserveSpace(size, key); - ReentrantLock regionLock = lockFor(key, pos); - regionLock.lock(); - try { - HashEntry e2 = table.get(slot); - if (e2 != e1) { - ref = scanRef(e2, key, pos); - if (ref != null) { - creditSpace(size, key); - return ref; - } - } - - ref = new Ref<>(key, pos, size, v); - ref.markHotter(); - for (;;) { - HashEntry n = new HashEntry(clean(e2), ref); - if (table.compareAndSet(slot, e2, n)) { - break; - } - e2 = table.get(slot); - } - addToClock(ref, 0); - } finally { - regionLock.unlock(); - } - return ref; + return dfsBlockCacheTable.put(key, pos, size, v); } boolean contains(DfsStreamKey key, long position) { - return scan(table.get(slot(key, position)), key, position) != null; + return dfsBlockCacheTable.contains(key, position); } - @SuppressWarnings("unchecked") <T> T get(DfsStreamKey key, long position) { - T val = (T) scan(table.get(slot(key, position)), key, position); - if (val == null) { - getStat(statMiss, key).incrementAndGet(); - } else { - getStat(statHit, key).incrementAndGet(); - } - return val; - } - - private <T> T scan(HashEntry n, DfsStreamKey key, long position) { - Ref<T> r = scanRef(n, key, position); - return r != null ? r.get() : null; - } - - @SuppressWarnings("unchecked") - private <T> Ref<T> scanRef(HashEntry n, DfsStreamKey key, long position) { - for (; n != null; n = n.next) { - Ref<T> r = n.ref; - if (r.position == position && r.key.equals(key)) { - return r.get() != null ? r : null; - } - } - return null; - } - - private int slot(DfsStreamKey key, long position) { - return (hash(key.hash, position) >>> 1) % tableSize; - } - - private ReentrantLock lockFor(DfsStreamKey key, long position) { - return loadLocks[(hash(key.hash, position) >>> 1) % loadLocks.length]; - } - - private ReentrantLock lockForRef(DfsStreamKey key) { - int slot = (key.hash >>> 1) % refLocks[key.packExtPos].length; - return refLocks[key.packExtPos][slot]; - } - - private static AtomicLong[] newCounters() { - AtomicLong[] ret = new AtomicLong[PackExt.values().length]; - for (int i = 0; i < ret.length; i++) { - ret[i] = new AtomicLong(); - } - return ret; - } - - private static AtomicLong getStat(AtomicReference<AtomicLong[]> stats, - DfsStreamKey key) { - int pos = key.packExtPos; - while (true) { - AtomicLong[] vals = stats.get(); - if (pos < vals.length) { - return vals[pos]; - } - AtomicLong[] expect = vals; - vals = new AtomicLong[Math.max(pos + 1, PackExt.values().length)]; - System.arraycopy(expect, 0, vals, 0, expect.length); - for (int i = expect.length; i < vals.length; i++) { - vals[i] = new AtomicLong(); - } - if (stats.compareAndSet(expect, vals)) { - return vals[pos]; - } - } - } - - private static long[] getStatVals(AtomicReference<AtomicLong[]> stat) { - AtomicLong[] stats = stat.get(); - long[] cnt = new long[stats.length]; - for (int i = 0; i < stats.length; i++) { - cnt[i] = stats[i].get(); - } - return cnt; - } - - private static HashEntry clean(HashEntry top) { - while (top != null && top.ref.next == null) { - top = top.next; - } - if (top == null) { - return null; - } - HashEntry n = clean(top.next); - return n == top.next ? top : new HashEntry(n, top.ref); - } - - private void reportIndexRequested(Ref<?> ref, boolean cacheHit, - long start) { - if (indexEventConsumer == null - || !isIndexExtPos(ref.key.packExtPos)) { - return; - } - EvictKey evictKey = new EvictKey(ref); - Long prevEvictedTime = indexEvictionMap.get(evictKey); - long now = System.nanoTime(); - long sinceLastEvictionNanos = prevEvictedTime == null ? 0L - : now - prevEvictedTime.longValue(); - indexEventConsumer.acceptRequestedEvent(ref.key.packExtPos, cacheHit, - (now - start) / 1000L /* micros */, ref.size, - Duration.ofNanos(sinceLastEvictionNanos)); - } - - private void reportIndexEvicted(Ref<?> dead) { - if (indexEventConsumer == null - || !indexEventConsumer.shouldReportEvictedEvent() - || !isIndexExtPos(dead.key.packExtPos)) { - return; - } - EvictKey evictKey = new EvictKey(dead); - Long prevEvictedTime = indexEvictionMap.get(evictKey); - long now = System.nanoTime(); - long sinceLastEvictionNanos = prevEvictedTime == null ? 0L - : now - prevEvictedTime.longValue(); - indexEvictionMap.put(evictKey, Long.valueOf(now)); - indexEventConsumer.acceptEvictedEvent(dead.key.packExtPos, dead.size, - dead.totalHitCount.get(), - Duration.ofNanos(sinceLastEvictionNanos)); - } - - private static boolean isIndexExtPos(int packExtPos) { - return packExtPos == PackExt.INDEX.getPosition() - || packExtPos == PackExt.REVERSE_INDEX.getPosition() - || packExtPos == PackExt.BITMAP_INDEX.getPosition(); - } - - private static final class HashEntry { - /** Next entry in the hash table's chain list. */ - final HashEntry next; - - /** The referenced object. */ - final Ref ref; - - HashEntry(HashEntry n, Ref r) { - next = n; - ref = r; - } + return dfsBlockCacheTable.get(key, position); } static final class Ref<T> { final DfsStreamKey key; + final long position; + final long size; + volatile T value; + Ref next; private volatile int hotCount; - private AtomicInteger totalHitCount = new AtomicInteger(); + + private final AtomicInteger totalHitCount = new AtomicInteger(); Ref(DfsStreamKey key, long position, long size, T v) { this.key = key; @@ -804,33 +307,9 @@ public final class DfsBlockCache { boolean isHot() { return hotCount > 0; } - } - - private static final class EvictKey { - private final int keyHash; - private final int packExtPos; - private final long position; - - EvictKey(Ref<?> ref) { - keyHash = ref.key.hash; - packExtPos = ref.key.packExtPos; - position = ref.position; - } - - @Override - public boolean equals(Object object) { - if (object instanceof EvictKey) { - EvictKey other = (EvictKey) object; - return keyHash == other.keyHash - && packExtPos == other.packExtPos - && position == other.position; - } - return false; - } - @Override - public int hashCode() { - return DfsBlockCache.getInstance().hash(keyHash, position); + int getTotalHitCount() { + return totalHitCount.get(); } } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsBlockCacheTable.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsBlockCacheTable.java new file mode 100644 index 0000000000..701d1fdce3 --- /dev/null +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsBlockCacheTable.java @@ -0,0 +1,340 @@ +/* + * Copyright (c) 2024, Google LLC and others + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Distribution License v. 1.0 which is available at + * http://www.eclipse.org/org/documents/edl-v10.php. + * + * SPDX-License-Identifier: BSD-3-Clause + */ + +package org.eclipse.jgit.internal.storage.dfs; + +import java.io.IOException; +import java.util.concurrent.atomic.AtomicLong; +import java.util.concurrent.atomic.AtomicReference; + +import org.eclipse.jgit.internal.storage.pack.PackExt; + +/** + * Block cache table. + */ +public interface DfsBlockCacheTable { + /** + * Quickly check if the cache contains block 0 of the given stream. + * <p> + * This can be useful for sophisticated pre-read algorithms to quickly + * determine if a file is likely already in cache, especially small + * reftables which may be smaller than a typical DFS block size. + * + * @param key + * the file to check. + * @return true if block 0 (the first block) is in the cache. + */ + boolean hasBlock0(DfsStreamKey key); + + /** + * Look up a cached object, creating and loading it if it doesn't exist. + * + * @param file + * the pack that "contains" the cached object. + * @param position + * offset within <code>pack</code> of the object. + * @param dfsReader + * current thread's reader. + * @param fileChannel + * supplier for channel to read {@code pack}. + * @return the object reference. + * @throws IOException + * the reference was not in the cache and could not be loaded. + */ + DfsBlock getOrLoad(BlockBasedFile file, long position, DfsReader dfsReader, + DfsBlockCache.ReadableChannelSupplier fileChannel) + throws IOException; + + /** + * Look up a cached object, creating and loading it if it doesn't exist. + * + * @param key + * the stream key of the pack. + * @param position + * the position in the key. The default should be 0. + * @param loader + * the function to load the reference. + * @return the object reference. + * @throws IOException + * the reference was not in the cache and could not be loaded. + */ + <T> DfsBlockCache.Ref<T> getOrLoadRef(DfsStreamKey key, long position, + DfsBlockCache.RefLoader<T> loader) throws IOException; + + /** + * Put a block in the block cache. + * + * @param v + * the block to put in the cache. + */ + void put(DfsBlock v); + + /** + * Put a block in the block cache. + * + * @param key + * the stream key of the pack. + * @param pos + * the position in the key. + * @param size + * the size of the object. + * @param v + * the object to put in the block cache. + * @return the object reference. + */ + <T> DfsBlockCache.Ref<T> put(DfsStreamKey key, long pos, long size, T v); + + /** + * Put an object in the block cache. + * + * @param key + * the stream key of the pack. + * @param size + * the size of the object. + * @param v + * the object to put in the block cache. + * @return the object reference. + */ + <T> DfsBlockCache.Ref<T> putRef(DfsStreamKey key, long size, T v); + + /** + * Check if the block cache contains an object identified by (key, + * position). + * + * @param key + * the stream key of the pack. + * @param position + * the position in the key. + * @return if the block cache contains the object identified by (key, + * position). + */ + boolean contains(DfsStreamKey key, long position); + + /** + * Get the object identified by (key, position) from the block cache. + * + * @param key + * the stream key of the pack. + * @param position + * the position in the key. + * @return the object identified by (key, position). + */ + <T> T get(DfsStreamKey key, long position); + + /** + * Get the DfsBlockCacheStats object for this block cache table's + * statistics. + * + * @return the DfsBlockCacheStats tracking this block cache table's + * statistics. + */ + DfsBlockCacheStats getDfsBlockCacheStats(); + + /** + * Keeps track of stats for a Block Cache table. + */ + class DfsBlockCacheStats { + /** + * Number of times a block was found in the cache, per pack file + * extension. + */ + private final AtomicReference<AtomicLong[]> statHit; + + /** + * Number of times a block was not found, and had to be loaded, per pack + * file extension. + */ + private final AtomicReference<AtomicLong[]> statMiss; + + /** + * Number of blocks evicted due to cache being full, per pack file + * extension. + */ + private final AtomicReference<AtomicLong[]> statEvict; + + /** + * Number of bytes currently loaded in the cache, per pack file + * extension. + */ + private final AtomicReference<AtomicLong[]> liveBytes; + + DfsBlockCacheStats() { + statHit = new AtomicReference<>(newCounters()); + statMiss = new AtomicReference<>(newCounters()); + statEvict = new AtomicReference<>(newCounters()); + liveBytes = new AtomicReference<>(newCounters()); + } + + /** + * Increment the {@code statHit} count. + * + * @param key + * key identifying which liveBytes entry to update. + */ + void incrementHit(DfsStreamKey key) { + getStat(statHit, key).incrementAndGet(); + } + + /** + * Increment the {@code statMiss} count. + * + * @param key + * key identifying which liveBytes entry to update. + */ + void incrementMiss(DfsStreamKey key) { + getStat(statMiss, key).incrementAndGet(); + } + + /** + * Increment the {@code statEvict} count. + * + * @param key + * key identifying which liveBytes entry to update. + */ + void incrementEvict(DfsStreamKey key) { + getStat(statEvict, key).incrementAndGet(); + } + + /** + * Add {@code size} to the {@code liveBytes} count. + * + * @param key + * key identifying which liveBytes entry to update. + * @param size + * amount to increment the count by. + */ + void addToLiveBytes(DfsStreamKey key, long size) { + getStat(liveBytes, key).addAndGet(size); + } + + /** + * Get total number of bytes in the cache, per pack file extension. + * + * @return total number of bytes in the cache, per pack file extension. + */ + long[] getCurrentSize() { + return getStatVals(liveBytes); + } + + /** + * Get number of requests for items in the cache, per pack file + * extension. + * + * @return the number of requests for items in the cache, per pack file + * extension. + */ + long[] getHitCount() { + return getStatVals(statHit); + } + + /** + * Get number of requests for items not in the cache, per pack file + * extension. + * + * @return the number of requests for items not in the cache, per pack + * file extension. + */ + long[] getMissCount() { + return getStatVals(statMiss); + } + + /** + * Get total number of requests (hit + miss), per pack file extension. + * + * @return total number of requests (hit + miss), per pack file + * extension. + */ + long[] getTotalRequestCount() { + AtomicLong[] hit = statHit.get(); + AtomicLong[] miss = statMiss.get(); + long[] cnt = new long[Math.max(hit.length, miss.length)]; + for (int i = 0; i < hit.length; i++) { + cnt[i] += hit[i].get(); + } + for (int i = 0; i < miss.length; i++) { + cnt[i] += miss[i].get(); + } + return cnt; + } + + /** + * Get hit ratios. + * + * @return hit ratios. + */ + long[] getHitRatio() { + AtomicLong[] hit = statHit.get(); + AtomicLong[] miss = statMiss.get(); + long[] ratio = new long[Math.max(hit.length, miss.length)]; + for (int i = 0; i < ratio.length; i++) { + if (i >= hit.length) { + ratio[i] = 0; + } else if (i >= miss.length) { + ratio[i] = 100; + } else { + long hitVal = hit[i].get(); + long missVal = miss[i].get(); + long total = hitVal + missVal; + ratio[i] = total == 0 ? 0 : hitVal * 100 / total; + } + } + return ratio; + } + + /** + * Get number of evictions performed due to cache being full, per pack + * file extension. + * + * @return the number of evictions performed due to cache being full, + * per pack file extension. + */ + long[] getEvictions() { + return getStatVals(statEvict); + } + + private static AtomicLong[] newCounters() { + AtomicLong[] ret = new AtomicLong[PackExt.values().length]; + for (int i = 0; i < ret.length; i++) { + ret[i] = new AtomicLong(); + } + return ret; + } + + private static long[] getStatVals(AtomicReference<AtomicLong[]> stat) { + AtomicLong[] stats = stat.get(); + long[] cnt = new long[stats.length]; + for (int i = 0; i < stats.length; i++) { + cnt[i] = stats[i].get(); + } + return cnt; + } + + private static AtomicLong getStat(AtomicReference<AtomicLong[]> stats, + DfsStreamKey key) { + int pos = key.packExtPos; + while (true) { + AtomicLong[] vals = stats.get(); + if (pos < vals.length) { + return vals[pos]; + } + AtomicLong[] expect = vals; + vals = new AtomicLong[Math.max(pos + 1, + PackExt.values().length)]; + System.arraycopy(expect, 0, vals, 0, expect.length); + for (int i = expect.length; i < vals.length; i++) { + vals[i] = new AtomicLong(); + } + if (stats.compareAndSet(expect, vals)) { + return vals[pos]; + } + } + } + } +}
\ No newline at end of file diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsGarbageCollector.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsGarbageCollector.java index 62b55d4734..a177669788 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsGarbageCollector.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsGarbageCollector.java @@ -17,7 +17,6 @@ import static org.eclipse.jgit.internal.storage.dfs.DfsObjDatabase.PackSource.IN import static org.eclipse.jgit.internal.storage.dfs.DfsObjDatabase.PackSource.RECEIVE; import static org.eclipse.jgit.internal.storage.dfs.DfsObjDatabase.PackSource.UNREACHABLE_GARBAGE; import static org.eclipse.jgit.internal.storage.dfs.DfsPackCompactor.configureReftable; -import static org.eclipse.jgit.internal.storage.pack.PackExt.BITMAP_INDEX; import static org.eclipse.jgit.internal.storage.pack.PackExt.COMMIT_GRAPH; import static org.eclipse.jgit.internal.storage.pack.PackExt.INDEX; import static org.eclipse.jgit.internal.storage.pack.PackExt.OBJECT_SIZE_INDEX; @@ -709,13 +708,7 @@ public class DfsGarbageCollector { } if (pw.prepareBitmapIndex(pm)) { - try (DfsOutputStream out = objdb.writeFile(pack, BITMAP_INDEX)) { - CountingOutputStream cnt = new CountingOutputStream(out); - pw.writeBitmapIndex(cnt); - pack.addFileExt(BITMAP_INDEX); - pack.setFileSize(BITMAP_INDEX, cnt.getCount()); - pack.setBlockSize(BITMAP_INDEX, out.blockSize()); - } + pw.writeBitmapIndex(objdb.getPackBitmapIndexWriter(pack)); } PackStatistics stats = pw.getStatistics(); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsObjDatabase.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsObjDatabase.java index 9f6eb10256..616563ffdd 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsObjDatabase.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsObjDatabase.java @@ -11,6 +11,7 @@ package org.eclipse.jgit.internal.storage.dfs; import static java.util.stream.Collectors.joining; +import static org.eclipse.jgit.internal.storage.pack.PackExt.BITMAP_INDEX; import java.io.FileNotFoundException; import java.io.IOException; @@ -26,11 +27,14 @@ import java.util.Map; import java.util.Set; import java.util.concurrent.atomic.AtomicReference; +import org.eclipse.jgit.internal.storage.file.PackBitmapIndexWriterV1; +import org.eclipse.jgit.internal.storage.pack.PackBitmapIndexWriter; import org.eclipse.jgit.internal.storage.pack.PackExt; import org.eclipse.jgit.lib.AnyObjectId; import org.eclipse.jgit.lib.ObjectDatabase; import org.eclipse.jgit.lib.ObjectInserter; import org.eclipse.jgit.lib.ObjectReader; +import org.eclipse.jgit.util.io.CountingOutputStream; /** * Manages objects stored in @@ -743,4 +747,28 @@ public abstract class DfsObjDatabase extends ObjectDatabase { dirty = true; } } + + /** + * Returns a writer to store the bitmap index in this object database. + * + * @param pack + * Pack file to which the bitmaps are associated. + * @return a writer to store bitmaps associated with the pack + * @throws IOException + * when some I/O problem occurs while creating or writing to + * output stream + */ + public PackBitmapIndexWriter getPackBitmapIndexWriter( + DfsPackDescription pack) throws IOException { + return (bitmaps, packDataChecksum) -> { + try (DfsOutputStream out = writeFile(pack, BITMAP_INDEX)) { + CountingOutputStream cnt = new CountingOutputStream(out); + PackBitmapIndexWriterV1 iw = new PackBitmapIndexWriterV1(cnt); + iw.write(bitmaps, packDataChecksum); + pack.addFileExt(BITMAP_INDEX); + pack.setFileSize(BITMAP_INDEX, cnt.getCount()); + pack.setBlockSize(BITMAP_INDEX, out.blockSize()); + } + }; + } } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackFile.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackFile.java index 42b1d235bf..5cc2a57aba 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackFile.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsPackFile.java @@ -52,10 +52,12 @@ import org.eclipse.jgit.internal.storage.pack.PackOutputStream; import org.eclipse.jgit.internal.storage.pack.StoredObjectRepresentation; import org.eclipse.jgit.lib.AbbreviatedObjectId; import org.eclipse.jgit.lib.AnyObjectId; +import org.eclipse.jgit.lib.ConfigConstants; import org.eclipse.jgit.lib.Constants; import org.eclipse.jgit.lib.ObjectId; import org.eclipse.jgit.lib.ObjectLoader; import org.eclipse.jgit.lib.Repository; +import org.eclipse.jgit.lib.StoredConfig; import org.eclipse.jgit.util.LongList; /** @@ -68,7 +70,10 @@ public final class DfsPackFile extends BlockBasedFile { private static final long REF_POSITION = 0; - private static final PackBitmapIndexLoader DEFAULT_BITMAP_LOADER = new StreamPackBitmapIndexLoader(); + /** + * Loader for the default file-based {@link PackBitmapIndex} implementation. + */ + public static final PackBitmapIndexLoader DEFAULT_BITMAP_LOADER = new StreamPackBitmapIndexLoader(); /** Index mapping {@link ObjectId} to position within the pack stream. */ private volatile PackIndex index; @@ -113,7 +118,18 @@ public final class DfsPackFile extends BlockBasedFile { this(cache, desc, DEFAULT_BITMAP_LOADER); } - DfsPackFile(DfsBlockCache cache, DfsPackDescription desc, PackBitmapIndexLoader bitmapLoader) { + /** + * Create an instance of DfsPackFile with a custom bitmap loader + * + * @param cache + * cache that owns the pack data + * @param desc + * description of the pack within the DFS + * @param bitmapLoader + * loader to get the bitmaps of this pack (if any) + */ + public DfsPackFile(DfsBlockCache cache, DfsPackDescription desc, + PackBitmapIndexLoader bitmapLoader) { super(cache, desc, PACK); int bs = desc.getBlockSize(PACK); @@ -1283,11 +1299,16 @@ public final class DfsPackFile extends BlockBasedFile { DfsStreamKey cgkey) throws IOException { ctx.stats.readCommitGraph++; long start = System.nanoTime(); + StoredConfig repoConfig = ctx.db.getRepository().getConfig(); + boolean readChangedPathFilters = repoConfig.getBoolean( + ConfigConstants.CONFIG_COMMIT_GRAPH_SECTION, + ConfigConstants.CONFIG_KEY_READ_CHANGED_PATHS, false); try (ReadableChannel rc = ctx.db.openFile(desc, COMMIT_GRAPH)) { long size; CommitGraph cg; try { - cg = CommitGraphLoader.read(alignTo8kBlocks(rc)); + cg = CommitGraphLoader.read(alignTo8kBlocks(rc), + readChangedPathFilters); } finally { size = rc.position(); ctx.stats.readCommitGraphBytes += size; @@ -1364,12 +1385,22 @@ public final class DfsPackFile extends BlockBasedFile { * The bytes can be 0, if the implementation doesn't do any initial * loading. */ - class LoadResult { - final PackBitmapIndex bitmapIndex; - - final long bytesRead; - - LoadResult(PackBitmapIndex packBitmapIndex, long bytesRead) { + public class LoadResult { + /** The loaded {@link PackBitmapIndex}. */ + public final PackBitmapIndex bitmapIndex; + + /** The bytes read upon initial load (may be 0). */ + public final long bytesRead; + + /** + * Constructs the LoadResult. + * + * @param packBitmapIndex + * the loaded index. + * @param bytesRead + * the bytes read upon loading. + */ + public LoadResult(PackBitmapIndex packBitmapIndex, long bytesRead) { this.bitmapIndex = packBitmapIndex; this.bytesRead = bytesRead; } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsReader.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsReader.java index a342796cbe..9cfcbaa5f7 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsReader.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/dfs/DfsReader.java @@ -21,7 +21,6 @@ import java.util.Collections; import java.util.Comparator; import java.util.HashSet; import java.util.Iterator; -import java.util.LinkedList; import java.util.List; import java.util.Optional; import java.util.Set; @@ -308,7 +307,7 @@ public class DfsReader extends ObjectReader implements ObjectReuseAsIs { private <T extends ObjectId> Iterable<FoundObject<T>> findAll( Iterable<T> objectIds) throws IOException { - Collection<T> pending = new LinkedList<>(); + HashSet<T> pending = new HashSet<>(); for (T id : objectIds) { pending.add(id); } @@ -328,22 +327,21 @@ public class DfsReader extends ObjectReader implements ObjectReuseAsIs { } private <T extends ObjectId> void findAllImpl(PackList packList, - Collection<T> pending, List<FoundObject<T>> r) { + HashSet<T> pending, List<FoundObject<T>> r) { DfsPackFile[] packs = packList.packs; if (packs.length == 0) { return; } int lastIdx = 0; DfsPackFile lastPack = packs[lastIdx]; - - OBJECT_SCAN: for (Iterator<T> it = pending.iterator(); it.hasNext();) { - T t = it.next(); + HashSet<T> toRemove = new HashSet<>(); + OBJECT_SCAN: for (T t : pending) { if (!skipGarbagePack(lastPack)) { try { long p = lastPack.findOffset(this, t); if (0 < p) { r.add(new FoundObject<>(t, lastIdx, lastPack, p)); - it.remove(); + toRemove.add(t); continue; } } catch (IOException e) { @@ -361,7 +359,7 @@ public class DfsReader extends ObjectReader implements ObjectReuseAsIs { long p = pack.findOffset(this, t); if (0 < p) { r.add(new FoundObject<>(t, i, pack, p)); - it.remove(); + toRemove.add(t); lastIdx = i; lastPack = pack; continue OBJECT_SCAN; @@ -371,6 +369,7 @@ public class DfsReader extends ObjectReader implements ObjectReuseAsIs { } } } + pending.removeAll(toRemove); last = lastPack; } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/BasePackBitmapIndex.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/BasePackBitmapIndex.java index c2b3926309..5f979b0daa 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/BasePackBitmapIndex.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/BasePackBitmapIndex.java @@ -18,7 +18,7 @@ import com.googlecode.javaewah.EWAHCompressedBitmap; /** * Base implementation of the PackBitmapIndex. */ -abstract class BasePackBitmapIndex extends PackBitmapIndex { +abstract class BasePackBitmapIndex implements PackBitmapIndex { private final ObjectIdOwnerMap<StoredBitmap> bitmaps; BasePackBitmapIndex(ObjectIdOwnerMap<StoredBitmap> bitmaps) { diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/GC.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/GC.java index fc058abcca..cf26f8d284 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/GC.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/GC.java @@ -49,7 +49,6 @@ import java.util.Date; import java.util.HashMap; import java.util.HashSet; import java.util.Iterator; -import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.Objects; @@ -866,7 +865,7 @@ public class GC { } } - List<ObjectIdSet> excluded = new LinkedList<>(); + List<ObjectIdSet> excluded = new ArrayList<>(); for (Pack p : repo.getObjectDatabase().getPacks()) { checkCancelled(); if (!shouldPackKeptObjects() && p.shouldBeKept()) { @@ -1399,7 +1398,7 @@ public class GC { FileChannel idxChannel = fos.getChannel(); OutputStream idxStream = Channels .newOutputStream(idxChannel)) { - pw.writeBitmapIndex(idxStream); + pw.writeBitmapIndex(new PackBitmapIndexWriterV1(idxStream)); idxChannel.force(true); } } @@ -1897,7 +1896,7 @@ public class GC { } private String getProcDesc() { - StringBuffer s = new StringBuffer(Long.toString(getPID())); + StringBuilder s = new StringBuilder(Long.toString(getPID())); s.append(' '); s.append(getHostName()); return s.toString(); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/Pack.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/Pack.java index 212dbb20aa..be457644d9 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/Pack.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/Pack.java @@ -187,18 +187,18 @@ public class Pack implements Iterable<PackIndex.MutableEntry> { } if (packChecksum == null) { - packChecksum = idx.packChecksum; + packChecksum = idx.getChecksum(); fileSnapshot.setChecksum( ObjectId.fromRaw(packChecksum)); } else if (!Arrays.equals(packChecksum, - idx.packChecksum)) { + idx.getChecksum())) { throw new PackMismatchException(MessageFormat .format(JGitText.get().packChecksumMismatch, packFile.getPath(), PackExt.PACK.getExtension(), Hex.toHexString(packChecksum), PackExt.INDEX.getExtension(), - Hex.toHexString(idx.packChecksum))); + Hex.toHexString(idx.getChecksum()))); } loadedIdx = optionally(idx); return idx; @@ -791,7 +791,7 @@ public class Pack implements Iterable<PackIndex.MutableEntry> { MessageFormat.format(JGitText.get().packChecksumMismatch, getPackFile(), PackExt.PACK.getExtension(), Hex.toHexString(buf), PackExt.INDEX.getExtension(), - Hex.toHexString(idx.packChecksum))); + Hex.toHexString(idx.getChecksum()))); } } @@ -1154,7 +1154,7 @@ public class Pack implements Iterable<PackIndex.MutableEntry> { PackBitmapIndex idx = PackBitmapIndex.open(bitmapIdxFile, idx(), getReverseIdx()); // At this point, idx() will have set packChecksum. - if (Arrays.equals(packChecksum, idx.packChecksum)) { + if (Arrays.equals(packChecksum, idx.getPackChecksum())) { bitmapIdx = optionally(idx); return idx; } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndex.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndex.java index def4f3dc11..cbda8fc77c 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndex.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndex.java @@ -35,7 +35,7 @@ import com.googlecode.javaewah.EWAHCompressedBitmap; * {@link #findPosition(AnyObjectId)} can be used to build other bitmaps that a * compatible with the encoded bitmaps available from the index. */ -public abstract class PackBitmapIndex { +public interface PackBitmapIndex { /** Flag bit denoting the bitmap should be reused during index creation. */ public static final int FLAG_REUSE = 1; @@ -132,8 +132,14 @@ public abstract class PackBitmapIndex { reverseIndexSupplier, loadParallelRevIndex); } - /** Footer checksum applied on the bottom of the pack file. */ - byte[] packChecksum; + /** + * Footer checksum applied on the bottom of the pack file. + * + * @return checksum as a byte array + */ + default byte[] getPackChecksum() { + return null; + } /** * Finds the position in the bitmap of the object. @@ -148,7 +154,9 @@ public abstract class PackBitmapIndex { * Get the object at the bitmap position. * * @param position - * the id for which the object will be found. + * the offset in the bitmap which corresponds to an object of + * interest. This position is the same as the order of the object + * in the {@link PackFile}. * @return the ObjectId. * @throws java.lang.IllegalArgumentException * when the item is not found. diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexBuilder.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexBuilder.java index a47f2dfcc8..08d2b7178f 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexBuilder.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexBuilder.java @@ -11,9 +11,9 @@ package org.eclipse.jgit.internal.storage.file; import java.text.MessageFormat; +import java.util.ArrayDeque; import java.util.ArrayList; import java.util.Collections; -import java.util.LinkedList; import java.util.List; import org.eclipse.jgit.internal.JGitText; @@ -41,8 +41,7 @@ public class PackBitmapIndexBuilder extends BasePackBitmapIndex { private final EWAHCompressedBitmap tags; private final BlockList<PositionEntry> byOffset; - private final LinkedList<StoredBitmap> - bitmapsToWriteXorBuffer = new LinkedList<>(); + private final ArrayDeque<StoredBitmap> bitmapsToWriteXorBuffer = new ArrayDeque<>(); private List<StoredEntry> bitmapsToWrite = new ArrayList<>(); @@ -106,7 +105,7 @@ public class PackBitmapIndexBuilder extends BasePackBitmapIndex { .signum(a.getOffset() - b.getOffset())); for (int i = 0; i < entries.size(); i++) { PositionEntry e = positionEntries.get(entries.get(i)); - e.offsetPosition = i; + e.ridxPosition = i; byOffset.add(e); } } @@ -191,8 +190,8 @@ public class PackBitmapIndexBuilder extends BasePackBitmapIndex { throw new IllegalStateException(); } bestBitmap.trim(); - StoredEntry result = new StoredEntry(entry.namePosition, bestBitmap, - bestXorOffset, bitmapToWrite.getFlags()); + StoredEntry result = new StoredEntry(entry, entry.idxPosition, + bestBitmap, bestXorOffset, bitmapToWrite.getFlags()); return result; } @@ -235,7 +234,7 @@ public class PackBitmapIndexBuilder extends BasePackBitmapIndex { PositionEntry entry = positionEntries.get(objectId); if (entry == null) return -1; - return entry.offsetPosition; + return entry.ridxPosition; } @Override @@ -323,20 +322,44 @@ public class PackBitmapIndexBuilder extends BasePackBitmapIndex { generateStoredEntry(bitmapsToWriteXorBuffer.pollFirst())); } - Collections.reverse(bitmapsToWrite); - return bitmapsToWrite; + List<StoredEntry> bitmapsToReturn = new ArrayList<>(bitmapsToWrite); + Collections.reverse(bitmapsToReturn); + return bitmapsToReturn; } /** Data object for the on disk representation of a bitmap entry. */ public static final class StoredEntry { - private final long objectId; + private final ObjectId objectId; + + private final long idxPosition; + private final EWAHCompressedBitmap bitmap; + private final int xorOffset; + private final int flags; - StoredEntry(long objectId, EWAHCompressedBitmap bitmap, - int xorOffset, int flags) { + /** + * Create a StoredEntry + * + * @param objectId + * objectId of the object associated with the bitmap + * @param idxPosition + * position of this object into the pack index (i.e. sorted + * by sha1) + * @param bitmap + * bitmap associated with this object + * @param xorOffset + * offset of the bitmap against which this bitmap is + * xor-compressed. If 0, then this bitmap is not + * xor-compressed against any other bitmap + * @param flags + * flags for this bitmap + */ + public StoredEntry(ObjectId objectId, long idxPosition, + EWAHCompressedBitmap bitmap, int xorOffset, int flags) { this.objectId = objectId; + this.idxPosition = idxPosition; this.bitmap = bitmap; this.xorOffset = xorOffset; this.flags = flags; @@ -370,23 +393,29 @@ public class PackBitmapIndexBuilder extends BasePackBitmapIndex { } /** - * Get the ObjectId - * - * @return the ObjectId + * @return the position of the object with this bitmap in the primary + * index (i.e. ordered by sha1) + */ + public long getIdxPosition() { + return idxPosition; + } + + /** + * @return the objectId of the object associated with this bitmap */ - public long getObjectId() { + public ObjectId getObjectId() { return objectId; } } private static final class PositionEntry extends ObjectIdOwnerMap.Entry { - final int namePosition; + final int idxPosition; - int offsetPosition; + int ridxPosition; - PositionEntry(AnyObjectId objectId, int namePosition) { + PositionEntry(AnyObjectId objectId, int idxPosition) { super(objectId); - this.namePosition = namePosition; + this.idxPosition = idxPosition; } } } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexRemapper.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexRemapper.java index bb7cfd0464..ffbc0737ac 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexRemapper.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexRemapper.java @@ -28,8 +28,8 @@ import com.googlecode.javaewah.IntIterator; * implementations this implementation is not thread safe, as it is intended to * be used with a PackBitmapIndexBuilder, which is also not thread safe. */ -public class PackBitmapIndexRemapper extends PackBitmapIndex - implements Iterable<PackBitmapIndexRemapper.Entry> { +public class PackBitmapIndexRemapper + implements PackBitmapIndex, Iterable<PackBitmapIndexRemapper.Entry> { private final BasePackBitmapIndex oldPackIndex; final PackBitmapIndex newPackIndex; diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexV1.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexV1.java index f2f24b39cb..19608c1ce5 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexV1.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexV1.java @@ -46,6 +46,8 @@ class PackBitmapIndexV1 extends BasePackBitmapIndex { private static final int MAX_XOR_OFFSET = 126; + private byte[] packChecksum; + private static final ExecutorService executor = Executors .newCachedThreadPool(new ThreadFactory() { private final ThreadFactory baseFactory = Executors @@ -269,6 +271,11 @@ class PackBitmapIndexV1 extends BasePackBitmapIndex { return getPackIndex().hashCode(); } + @Override + public byte[] getPackChecksum() { + return this.packChecksum; + } + PackIndex getPackIndex() { return packIndex; } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexWriterV1.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexWriterV1.java index a5c8423dfd..38d7c90894 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexWriterV1.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackBitmapIndexWriterV1.java @@ -19,6 +19,7 @@ import java.text.MessageFormat; import org.eclipse.jgit.internal.JGitText; import org.eclipse.jgit.internal.storage.file.PackBitmapIndexBuilder.StoredEntry; +import org.eclipse.jgit.internal.storage.pack.PackBitmapIndexWriter; import org.eclipse.jgit.lib.Constants; import com.googlecode.javaewah.EWAHCompressedBitmap; @@ -28,7 +29,7 @@ import com.googlecode.javaewah.EWAHCompressedBitmap; * * @see PackBitmapIndexV1 */ -public class PackBitmapIndexWriterV1 { +public class PackBitmapIndexWriterV1 implements PackBitmapIndexWriter { private final DigestOutputStream out; private final DataOutput dataOutput; @@ -60,6 +61,7 @@ public class PackBitmapIndexWriterV1 { * an error occurred while writing to the output stream, or this * index format cannot store the object data supplied. */ + @Override public void write(PackBitmapIndexBuilder bitmaps, byte[] packDataChecksum) throws IOException { if (bitmaps == null || packDataChecksum.length != 20) @@ -113,7 +115,7 @@ public class PackBitmapIndexWriterV1 { private void writeBitmapEntry(StoredEntry entry) throws IOException { // Write object, XOR offset, and bitmap - dataOutput.writeInt((int) entry.getObjectId()); + dataOutput.writeInt((int) entry.getIdxPosition()); out.write(entry.getXorOffset()); out.write(entry.getFlags()); writeBitmap(entry.getBitmap()); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackIndex.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackIndex.java index c42d1c8866..c0540d5a4c 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackIndex.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackIndex.java @@ -42,8 +42,8 @@ import org.eclipse.jgit.util.io.SilentFileInputStream; * by ObjectId. * </p> */ -public abstract class PackIndex - implements Iterable<PackIndex.MutableEntry>, ObjectIdSet { +public interface PackIndex + extends Iterable<PackIndex.MutableEntry>, ObjectIdSet { /** * Open an existing pack <code>.idx</code> file for reading. * <p> @@ -61,7 +61,7 @@ public abstract class PackIndex * the file exists but could not be read due to security errors, * unrecognized data version, or unexpected data corruption. */ - public static PackIndex open(File idxFile) throws IOException { + static PackIndex open(File idxFile) throws IOException { try (SilentFileInputStream fd = new SilentFileInputStream( idxFile)) { return read(fd); @@ -92,7 +92,7 @@ public abstract class PackIndex * @throws org.eclipse.jgit.errors.CorruptObjectException * the stream does not contain a valid pack index. */ - public static PackIndex read(InputStream fd) throws IOException, + static PackIndex read(InputStream fd) throws IOException, CorruptObjectException { final byte[] hdr = new byte[8]; IO.readFully(fd, hdr, 0, hdr.length); @@ -116,9 +116,6 @@ public abstract class PackIndex return true; } - /** Footer checksum applied on the bottom of the pack file. */ - protected byte[] packChecksum; - /** * Determine if an object is contained within the pack file. * @@ -126,12 +123,12 @@ public abstract class PackIndex * the object to look for. Must not be null. * @return true if the object is listed in this index; false otherwise. */ - public boolean hasObject(AnyObjectId id) { + default boolean hasObject(AnyObjectId id) { return findOffset(id) != -1; } @Override - public boolean contains(AnyObjectId id) { + default boolean contains(AnyObjectId id) { return findOffset(id) != -1; } @@ -147,7 +144,7 @@ public abstract class PackIndex * </p> */ @Override - public abstract Iterator<MutableEntry> iterator(); + Iterator<MutableEntry> iterator(); /** * Obtain the total number of objects described by this index. @@ -155,7 +152,7 @@ public abstract class PackIndex * @return number of objects in this index, and likewise in the associated * pack that this index was generated from. */ - public abstract long getObjectCount(); + long getObjectCount(); /** * Obtain the total number of objects needing 64 bit offsets. @@ -163,7 +160,7 @@ public abstract class PackIndex * @return number of objects in this index using a 64 bit offset; that is an * object positioned after the 2 GB position within the file. */ - public abstract long getOffset64Count(); + long getOffset64Count(); /** * Get ObjectId for the n-th object entry returned by {@link #iterator()}. @@ -185,7 +182,7 @@ public abstract class PackIndex * is 0, the second is 1, etc. * @return the ObjectId for the corresponding entry. */ - public abstract ObjectId getObjectId(long nthPosition); + ObjectId getObjectId(long nthPosition); /** * Get ObjectId for the n-th object entry returned by {@link #iterator()}. @@ -209,7 +206,7 @@ public abstract class PackIndex * negative, but still valid. * @return the ObjectId for the corresponding entry. */ - public final ObjectId getObjectId(int nthPosition) { + default ObjectId getObjectId(int nthPosition) { if (nthPosition >= 0) return getObjectId((long) nthPosition); final int u31 = nthPosition >>> 1; @@ -228,7 +225,7 @@ public abstract class PackIndex * etc. Positions past 2**31-1 are negative, but still valid. * @return the offset in a pack for the corresponding entry. */ - abstract long getOffset(long nthPosition); + long getOffset(long nthPosition); /** * Locate the file offset position for the requested object. @@ -239,7 +236,7 @@ public abstract class PackIndex * object does not exist in this index and is thus not stored in the * associated pack. */ - public abstract long findOffset(AnyObjectId objId); + long findOffset(AnyObjectId objId); /** * Locate the position of this id in the list of object-ids in the index @@ -250,7 +247,7 @@ public abstract class PackIndex * of ids stored in this index; -1 if the object does not exist in * this index and is thus not stored in the associated pack. */ - public abstract int findPosition(AnyObjectId objId); + int findPosition(AnyObjectId objId); /** * Retrieve stored CRC32 checksum of the requested object raw-data @@ -264,7 +261,7 @@ public abstract class PackIndex * @throws java.lang.UnsupportedOperationException * when this index doesn't support CRC32 checksum */ - public abstract long findCRC32(AnyObjectId objId) + long findCRC32(AnyObjectId objId) throws MissingObjectException, UnsupportedOperationException; /** @@ -272,7 +269,7 @@ public abstract class PackIndex * * @return true if CRC32 is stored, false otherwise */ - public abstract boolean hasCRC32Support(); + boolean hasCRC32Support(); /** * Find objects matching the prefix abbreviation. @@ -288,7 +285,7 @@ public abstract class PackIndex * @throws java.io.IOException * the index cannot be read. */ - public abstract void resolve(Set<ObjectId> matches, AbbreviatedObjectId id, + void resolve(Set<ObjectId> matches, AbbreviatedObjectId id, int matchLimit) throws IOException; /** @@ -297,16 +294,14 @@ public abstract class PackIndex * @return the checksum of the pack; caller must not modify it * @since 5.5 */ - public byte[] getChecksum() { - return packChecksum; - } + byte[] getChecksum(); /** * Represent mutable entry of pack index consisting of object id and offset * in pack (both mutable). * */ - public static class MutableEntry { + class MutableEntry { final MutableObjectId idBuffer = new MutableObjectId(); long offset; @@ -358,16 +353,25 @@ public abstract class PackIndex } } + /** + * Base implementation of the iterator over index entries. + */ abstract class EntriesIterator implements Iterator<MutableEntry> { protected final MutableEntry entry = initEntry(); + private final long objectCount; + + protected EntriesIterator(long objectCount) { + this.objectCount = objectCount; + } + protected long returnedNumber = 0; protected abstract MutableEntry initEntry(); @Override public boolean hasNext() { - return returnedNumber < getObjectCount(); + return returnedNumber < objectCount; } /** diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackIndexV1.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackIndexV1.java index 4563c9039c..d7c83785d8 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackIndexV1.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackIndexV1.java @@ -29,13 +29,16 @@ import org.eclipse.jgit.lib.ObjectId; import org.eclipse.jgit.util.IO; import org.eclipse.jgit.util.NB; -class PackIndexV1 extends PackIndex { +class PackIndexV1 implements PackIndex { private static final int IDX_HDR_LEN = 256 * 4; private static final int RECORD_SIZE = 4 + Constants.OBJECT_ID_LENGTH; private final long[] idxHeader; + /** Footer checksum applied on the bottom of the pack file. */ + protected byte[] packChecksum; + byte[][] idxdata; private long objectCnt; @@ -118,7 +121,7 @@ class PackIndexV1 extends PackIndex { } @Override - long getOffset(long nthPosition) { + public long getOffset(long nthPosition) { final int levelOne = findLevelOne(nthPosition); final int levelTwo = getLevelTwo(nthPosition, levelOne); final int p = (4 + Constants.OBJECT_ID_LENGTH) * levelTwo; @@ -200,7 +203,7 @@ class PackIndexV1 extends PackIndex { @Override public Iterator<MutableEntry> iterator() { - return new IndexV1Iterator(); + return new IndexV1Iterator(objectCnt); } @Override @@ -238,11 +241,20 @@ class PackIndexV1 extends PackIndex { return (RECORD_SIZE * mid) + 4; } + @Override + public byte[] getChecksum() { + return packChecksum; + } + private class IndexV1Iterator extends EntriesIterator { int levelOne; int levelTwo; + IndexV1Iterator(long objectCount) { + super(objectCount); + } + @Override protected MutableEntry initEntry() { return new MutableEntry() { diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackIndexV2.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackIndexV2.java index 751b62dc40..caf8b71180 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackIndexV2.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/PackIndexV2.java @@ -28,7 +28,7 @@ import org.eclipse.jgit.util.IO; import org.eclipse.jgit.util.NB; /** Support for the pack index v2 format. */ -class PackIndexV2 extends PackIndex { +class PackIndexV2 implements PackIndex { private static final long IS_O64 = 1L << 31; private static final int FANOUT = 256; @@ -37,6 +37,9 @@ class PackIndexV2 extends PackIndex { private static final byte[] NO_BYTES = {}; + /** Footer checksum applied on the bottom of the pack file. */ + protected byte[] packChecksum; + private long objectCnt; private final long[] fanoutTable; @@ -221,7 +224,7 @@ class PackIndexV2 extends PackIndex { @Override public Iterator<MutableEntry> iterator() { - return new EntriesIteratorV2(); + return new EntriesIteratorV2(objectCnt); } @Override @@ -281,11 +284,20 @@ class PackIndexV2 extends PackIndex { return -1; } + @Override + public byte[] getChecksum() { + return packChecksum; + } + private class EntriesIteratorV2 extends EntriesIterator { int levelOne; int levelTwo; + EntriesIteratorV2(long objectCount){ + super(objectCount); + } + @Override protected MutableEntry initEntry() { return new MutableEntry() { diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/RefDirectory.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/RefDirectory.java index 169dce1cc0..8e57bf9f2f 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/RefDirectory.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/RefDirectory.java @@ -41,11 +41,11 @@ import java.nio.file.Paths; import java.security.DigestInputStream; import java.security.MessageDigest; import java.text.MessageFormat; +import java.util.ArrayList; import java.util.Arrays; import java.util.Collection; import java.util.Collections; import java.util.HashMap; -import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.concurrent.atomic.AtomicInteger; @@ -64,8 +64,8 @@ import org.eclipse.jgit.events.RefsChangedEvent; import org.eclipse.jgit.internal.JGitText; import org.eclipse.jgit.lib.ConfigConstants; import org.eclipse.jgit.lib.Constants; -import org.eclipse.jgit.lib.CoreConfig.TrustPackedRefsStat; import org.eclipse.jgit.lib.CoreConfig.TrustLooseRefStat; +import org.eclipse.jgit.lib.CoreConfig.TrustPackedRefsStat; import org.eclipse.jgit.lib.ObjectId; import org.eclipse.jgit.lib.ObjectIdRef; import org.eclipse.jgit.lib.Ref; @@ -413,7 +413,7 @@ public class RefDirectory extends RefDatabase { @Override public List<Ref> getAdditionalRefs() throws IOException { - List<Ref> ret = new LinkedList<>(); + List<Ref> ret = new ArrayList<>(); for (String name : additionalRefsNames) { Ref r = exactRef(name); if (r != null) diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/SnapshottingRefDirectory.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/SnapshottingRefDirectory.java index 46607f60d9..1dc5776e06 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/SnapshottingRefDirectory.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/file/SnapshottingRefDirectory.java @@ -16,15 +16,21 @@ import org.eclipse.jgit.lib.Ref; import org.eclipse.jgit.lib.RefUpdate; import org.eclipse.jgit.revwalk.RevWalk; +import java.io.File; import java.io.IOException; +import java.io.InputStream; +import java.nio.file.Files; +import java.nio.file.Path; import java.util.List; +import java.util.Set; +import java.util.concurrent.ConcurrentHashMap; /** * Snapshotting write-through cache of a {@link RefDirectory}. * <p> * This is intended to be short-term write-through snapshot based cache used in - * a request scope to avoid re-reading packed-refs on each read. A future - * improvement could also snapshot loose refs. + * a request scope to avoid re-reading packed-refs on each read and to avoid + * refreshing paths to a loose ref that has already been refreshed. * <p> * Only use this class when concurrent writes from other requests (not using the * same instance of SnapshottingRefDirectory) generally need not be visible to @@ -34,6 +40,7 @@ import java.util.List; */ class SnapshottingRefDirectory extends RefDirectory { final RefDirectory refDb; + private final Set<File> refreshedLooseRefDirs = ConcurrentHashMap.newKeySet(); private volatile boolean isValid; @@ -67,6 +74,22 @@ class SnapshottingRefDirectory extends RefDirectory { } @Override + void refreshPathToLooseRef(Path refPath) { + for (int i = 1; i < refPath.getNameCount(); i++) { + File dir = fileFor(refPath.subpath(0, i).toString()); + if (!refreshedLooseRefDirs.contains(dir)) { + try (InputStream stream = Files.newInputStream(dir.toPath())) { + // open the dir to refresh attributes (on some NFS clients) + } catch (IOException e) { + break; // loose ref may not exist + } finally { + refreshedLooseRefDirs.add(dir); + } + } + } + } + + @Override void delete(RefDirectoryUpdate update) throws IOException { refreshSnapshot(); super.delete(update); @@ -107,6 +130,7 @@ class SnapshottingRefDirectory extends RefDirectory { } synchronized void invalidateSnapshot() { + refreshedLooseRefDirs.clear(); isValid = false; } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/memory/TernarySearchTree.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/memory/TernarySearchTree.java index acc1c830d5..72434dbffe 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/memory/TernarySearchTree.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/memory/TernarySearchTree.java @@ -9,9 +9,9 @@ */ package org.eclipse.jgit.internal.storage.memory; +import java.util.ArrayDeque; import java.util.ArrayList; import java.util.HashMap; -import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.Map.Entry; @@ -340,7 +340,7 @@ public final class TernarySearchTree<Value> { * @return all keys */ public Iterable<String> getKeys() { - Queue<String> queue = new LinkedList<>(); + Queue<String> queue = new ArrayDeque<>(); lock.readLock().lock(); try { findKeysWithPrefix(root, new StringBuilder(), queue); @@ -358,7 +358,7 @@ public final class TernarySearchTree<Value> { * @return keys starting with given prefix */ public Iterable<String> getKeysWithPrefix(String prefix) { - Queue<String> keys = new LinkedList<>(); + Queue<String> keys = new ArrayDeque<>(); if (prefix == null) { return keys; } @@ -486,7 +486,7 @@ public final class TernarySearchTree<Value> { * @return keys matching given pattern. */ public Iterable<String> getKeysMatching(String pattern) { - Queue<String> keys = new LinkedList<>(); + Queue<String> keys = new ArrayDeque<>(); lock.readLock().lock(); try { findKeysWithPrefix(root, new StringBuilder(), 0, pattern, keys); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/DeltaTask.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/DeltaTask.java index 9a3f4b07ee..03d6f16733 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/DeltaTask.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/DeltaTask.java @@ -11,10 +11,10 @@ package org.eclipse.jgit.internal.storage.pack; import java.io.IOException; +import java.util.ArrayDeque; import java.util.ArrayList; import java.util.Collections; import java.util.Iterator; -import java.util.LinkedList; import java.util.List; import java.util.concurrent.Callable; @@ -232,14 +232,15 @@ final class DeltaTask implements Callable<Object> { } private final Block block; - final LinkedList<Slice> slices; + + final ArrayDeque<Slice> slices; private ObjectReader or; private DeltaWindow dw; DeltaTask(Block b) { this.block = b; - this.slices = new LinkedList<>(); + this.slices = new ArrayDeque<>(); } void add(Slice s) { diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/PackBitmapIndexWriter.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/PackBitmapIndexWriter.java new file mode 100644 index 0000000000..9cf8c7f2b5 --- /dev/null +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/PackBitmapIndexWriter.java @@ -0,0 +1,33 @@ +/* + * Copyright (C) 2024, Google Inc. + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Distribution License v. 1.0 which is available at + * https://www.eclipse.org/org/documents/edl-v10.php. + * + * SPDX-License-Identifier: BSD-3-Clause + */ + +package org.eclipse.jgit.internal.storage.pack; + +import java.io.IOException; + +import org.eclipse.jgit.internal.storage.file.PackBitmapIndexBuilder; + +/** + * Represents a function that accepts a collection of bitmaps and write them + * into storage. + */ +@FunctionalInterface +public interface PackBitmapIndexWriter { + /** + * @param bitmaps + * list of bitmaps to be written to a bitmap index + * @param packChecksum + * checksum of the pack that the bitmap index refers to + * @throws IOException + * thrown in case of IO errors while writing the bitmap index + */ + public void write(PackBitmapIndexBuilder bitmaps, byte[] packChecksum) + throws IOException; +}
\ No newline at end of file diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/PackWriter.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/PackWriter.java index 9e95231253..4350f97915 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/PackWriter.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/storage/pack/PackWriter.java @@ -58,11 +58,10 @@ import org.eclipse.jgit.errors.MissingObjectException; import org.eclipse.jgit.errors.SearchForReuseTimeout; import org.eclipse.jgit.errors.StoredObjectRepresentationNotAvailableException; import org.eclipse.jgit.internal.JGitText; -import org.eclipse.jgit.internal.storage.file.PackBitmapIndexBuilder; -import org.eclipse.jgit.internal.storage.file.PackBitmapIndexWriterV1; import org.eclipse.jgit.internal.storage.file.PackIndexWriter; import org.eclipse.jgit.internal.storage.file.PackObjectSizeIndexWriter; import org.eclipse.jgit.internal.storage.file.PackReverseIndexWriter; +import org.eclipse.jgit.internal.storage.file.PackBitmapIndexBuilder; import org.eclipse.jgit.lib.AnyObjectId; import org.eclipse.jgit.lib.AsyncObjectSizeQueue; import org.eclipse.jgit.lib.BatchingProgressMonitor; @@ -121,7 +120,7 @@ import org.eclipse.jgit.util.TemporaryBuffer; * pack is being stored as a file the matching index can be written out after * writing the pack by {@link #writeIndex(OutputStream)}. An optional bitmap * index can be made by calling {@link #prepareBitmapIndex(ProgressMonitor)} - * followed by {@link #writeBitmapIndex(OutputStream)}. + * followed by {@link #writeBitmapIndex(PackBitmapIndexWriter)}. * </p> * <p> * Class provide set of configurable options and @@ -1130,7 +1129,7 @@ public class PackWriter implements AutoCloseable { * Called after * {@link #writePack(ProgressMonitor, ProgressMonitor, OutputStream)} that * populates the list of objects to pack and before - * {@link #writeBitmapIndex(OutputStream)} that destroys it. + * {@link #writeBitmapIndex(PackBitmapIndexWriter)} that destroys it. * <p> * Writing this index is only required for local pack storage. Packs sent on * the network do not need to create an object size index. @@ -1204,20 +1203,18 @@ public class PackWriter implements AutoCloseable { * <p> * Called after {@link #prepareBitmapIndex(ProgressMonitor)}. * - * @param bitmapIndexStream - * output for the bitmap index data. Caller is responsible for - * closing this stream. + * @param bitmapIndexWriter + * a writer to store the bitmap index in this object database * @throws java.io.IOException - * the index data could not be written to the supplied stream. + * the index data could not be written using the supplied writer */ - public void writeBitmapIndex(OutputStream bitmapIndexStream) + public void writeBitmapIndex(PackBitmapIndexWriter bitmapIndexWriter) throws IOException { if (writeBitmaps == null) throw new IOException(JGitText.get().bitmapsMustBePrepared); long writeStart = System.currentTimeMillis(); - final PackBitmapIndexWriterV1 iw = new PackBitmapIndexWriterV1(bitmapIndexStream); - iw.write(writeBitmaps, packcsum); + bitmapIndexWriter.write(writeBitmaps, packcsum); stats.timeWriting += System.currentTimeMillis() - writeStart; } @@ -2468,7 +2465,8 @@ public class PackWriter implements AutoCloseable { * <p> * To reduce memory internal state is cleared during this method, rendering * the PackWriter instance useless for anything further than a call to write - * out the new bitmaps with {@link #writeBitmapIndex(OutputStream)}. + * out the new bitmaps with + * {@link #writeBitmapIndex(PackBitmapIndexWriter)}. * * @param pm * progress monitor to report bitmap building work. diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/transport/ssh/OpenSshConfigFile.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/transport/ssh/OpenSshConfigFile.java index 29a2922136..3e75a9dde3 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/transport/ssh/OpenSshConfigFile.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/transport/ssh/OpenSshConfigFile.java @@ -22,7 +22,6 @@ import java.util.ArrayList; import java.util.Collections; import java.util.HashMap; import java.util.Iterator; -import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.Set; @@ -100,7 +99,7 @@ public class OpenSshConfigFile implements SshConfigStore { * fully resolved entries created from that. */ private static class State { - List<HostEntry> entries = new LinkedList<>(); + List<HostEntry> entries = new ArrayList<>(); // Previous lookups, keyed by user@hostname:port Map<String, HostEntry> hosts = new HashMap<>(); @@ -218,7 +217,7 @@ public class OpenSshConfigFile implements SshConfigStore { private List<HostEntry> parse(BufferedReader reader) throws IOException { - final List<HostEntry> entries = new LinkedList<>(); + final List<HostEntry> entries = new ArrayList<>(); // The man page doesn't say so, but the openssh parser (readconf.c) // starts out in active mode and thus always applies any lines that diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/util/CleanupService.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/util/CleanupService.java new file mode 100644 index 0000000000..29ed7564d3 --- /dev/null +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/util/CleanupService.java @@ -0,0 +1,121 @@ +/* + * Copyright (C) 2024, Thomas Wolf <twolf@apache.org> and others + * + * This program and the accompanying materials are made available under the + * terms of the Eclipse Distribution License v. 1.0 which is available at + * https://www.eclipse.org/org/documents/edl-v10.php. + * + * SPDX-License-Identifier: BSD-3-Clause + */ +package org.eclipse.jgit.internal.util; + +import org.eclipse.jgit.internal.JGitText; +import org.slf4j.Logger; +import org.slf4j.LoggerFactory; + +/** + * A class that is registered as an OSGi service via the manifest. If JGit runs + * in OSGi, OSGi will instantiate a singleton as soon as the bundle is activated + * since this class is an immediate OSGi component with no dependencies. OSGi + * will then call its {@link #start()} method. If JGit is not running in OSGi, + * {@link #getInstance()} will lazily create an instance. + * <p> + * An OSGi-created {@link CleanupService} will run the registered cleanup when + * the {@code org.eclipse.jgit} bundle is deactivated. A lazily created instance + * will register the cleanup as a JVM shutdown hook. + * </p> + */ +public final class CleanupService { + + private static final Logger LOG = LoggerFactory + .getLogger(CleanupService.class); + + private static final Object LOCK = new Object(); + + private static CleanupService INSTANCE; + + private final boolean isOsgi; + + private JGitText jgitText; + + private Runnable cleanup; + + /** + * Public component constructor for OSGi DS. Do <em>not</em> call this + * explicitly! (Unfortunately this constructor must be public because of + * OSGi requirements.) + */ + public CleanupService() { + this.isOsgi = true; + setInstance(this); + } + + private CleanupService(boolean isOsgi) { + this.isOsgi = isOsgi; + } + + private static void setInstance(CleanupService service) { + synchronized (LOCK) { + INSTANCE = service; + } + } + + /** + * Obtains the singleton instance of the {@link CleanupService} that knows + * whether or not it is running on OSGi. + * + * @return the {@link CleanupService}Â singleton instance + */ + public static CleanupService getInstance() { + synchronized (LOCK) { + if (INSTANCE == null) { + INSTANCE = new CleanupService(false); + } + return INSTANCE; + } + } + + void start() { + // Nothing to do + } + + void register(Runnable cleanUp) { + if (isOsgi) { + cleanup = cleanUp; + } else { + // Ensure the JGitText class is loaded. Depending on the framework + // JGit runs in, it may not be possible anymore to load classes when + // the hook runs. For instance when run in a maven plug-in: the + // Plexus class world that loaded JGit may already have been + // disposed by the time the JVM shutdown hook runs when the whole + // maven build terminates. + jgitText = JGitText.get(); + assert jgitText != null; + try { + Runtime.getRuntime().addShutdownHook(new Thread(() -> { + try { + cleanUp.run(); + // Don't catch exceptions; let the JVM do the problem + // reporting. + } finally { + jgitText = null; + } + })); + } catch (IllegalStateException e) { + // Ignore -- the JVM is already shutting down. + } + } + } + + void shutDown() { + if (isOsgi && cleanup != null) { + Runnable r = cleanup; + cleanup = null; + try { + r.run(); + } catch (RuntimeException e) { + LOG.error(JGitText.get().shutdownCleanupFailed, e); + } + } + } +} diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/internal/util/ShutdownHook.java b/org.eclipse.jgit/src/org/eclipse/jgit/internal/util/ShutdownHook.java index f52025fd6b..f6b4723489 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/internal/util/ShutdownHook.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/internal/util/ShutdownHook.java @@ -15,17 +15,21 @@ import java.util.concurrent.ConcurrentHashMap; import java.util.concurrent.ExecutionException; import java.util.concurrent.ExecutorService; import java.util.concurrent.Executors; -import java.util.concurrent.RejectedExecutionException; import java.util.concurrent.TimeUnit; import java.util.concurrent.TimeoutException; +import java.util.concurrent.atomic.AtomicBoolean; import org.eclipse.jgit.internal.JGitText; import org.slf4j.Logger; import org.slf4j.LoggerFactory; /** - * A hook registered as a JVM shutdown hook managing a set of objects needing - * cleanup during JVM shutdown. See {@link Runtime#addShutdownHook}. + * The singleton {@link ShutdownHook} provides a means to register + * {@link Listener}s that are run when JGit is uninstalled, either + * <ul> + * <li>in an OSGi framework when this bundle is deactivated, or</li> + * <li>otherwise, when the JVM as a whole shuts down.</li> + * </ul> */ @SuppressWarnings("ImmutableEnumChecker") public enum ShutdownHook { @@ -35,11 +39,11 @@ public enum ShutdownHook { INSTANCE; /** - * Object that needs to cleanup on JVM shutdown. + * Object that needs to cleanup on shutdown. */ public interface Listener { /** - * Cleanup resources when JVM shuts down, called from JVM shutdown hook. + * Cleanup resources when JGit is shut down. * <p> * Implementations should be coded defensively * <ul> @@ -62,31 +66,27 @@ public enum ShutdownHook { private final Set<Listener> listeners = ConcurrentHashMap.newKeySet(); - private volatile boolean shutdownInProgress; + private final AtomicBoolean shutdownInProgress = new AtomicBoolean(); private ShutdownHook() { - try { - Runtime.getRuntime().addShutdownHook(new Thread(this::cleanup)); - } catch (IllegalStateException e) { - // ignore - the VM is already shutting down - } + CleanupService.getInstance().register(this::cleanup); } private void cleanup() { - shutdownInProgress = true; - ExecutorService runner = Executors.newWorkStealingPool(); - try { - runner.submit(() -> { - this.doCleanup(); - return null; - }).get(30L, TimeUnit.SECONDS); - } catch (RejectedExecutionException | InterruptedException - | ExecutionException | TimeoutException e) { - // message isn't localized since during shutdown there's no - // guarantee which classes are still loaded - LOG.error("Cleanup during JVM shutdown failed", e); //$NON-NLS-1$ + if (!shutdownInProgress.getAndSet(true)) { + ExecutorService runner = Executors.newWorkStealingPool(); + try { + runner.submit(() -> { + this.doCleanup(); + return null; + }).get(30L, TimeUnit.SECONDS); + } catch (InterruptedException | ExecutionException + | TimeoutException e) { + throw new RuntimeException(e.getMessage(), e); + } finally { + runner.shutdownNow(); + } } - runner.shutdownNow(); } private void doCleanup() { @@ -104,17 +104,17 @@ public enum ShutdownHook { } /** - * Register object that needs cleanup during JVM shutdown if it is not - * already registered. Registration is disabled when JVM shutdown is already - * in progress. + * Register object that needs cleanup during JGit shutdown if it is not + * already registered. Registration is disabled when JGit shutdown is + * already in progress. * * @param l - * the object to call {@link Listener#onShutdown} on when JVM + * the object to call {@link Listener#onShutdown} on when JGit * shuts down * @return {@code true} if this object has been registered */ public boolean register(Listener l) { - if (shutdownInProgress) { + if (shutdownInProgress.get()) { return listeners.contains(l); } LOG.debug("register {} with shutdown hook", l); //$NON-NLS-1$ @@ -123,8 +123,8 @@ public enum ShutdownHook { } /** - * Unregister object that no longer needs cleanup during JVM shutdown if it - * is still registered. Unregistration is disabled when JVM shutdown is + * Unregister object that no longer needs cleanup during JGit shutdown if it + * is still registered. Unregistration is disabled when JGit shutdown is * already in progress. * * @param l @@ -133,7 +133,7 @@ public enum ShutdownHook { * @return {@code true} if this object is no longer registered */ public boolean unregister(Listener l) { - if (shutdownInProgress) { + if (shutdownInProgress.get()) { return !listeners.contains(l); } LOG.debug("unregister {} from shutdown hook", l); //$NON-NLS-1$ @@ -142,11 +142,11 @@ public enum ShutdownHook { } /** - * Whether a JVM shutdown is in progress + * Whether a JGit shutdown is in progress * - * @return {@code true} if a JVM shutdown is in progress + * @return {@code true} if a JGit shutdown is in progress */ public boolean isShutdownInProgress() { - return shutdownInProgress; + return shutdownInProgress.get(); } } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/lib/RebaseTodoFile.java b/org.eclipse.jgit/src/org/eclipse/jgit/lib/RebaseTodoFile.java index c716f464d3..b036a0b6a1 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/lib/RebaseTodoFile.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/lib/RebaseTodoFile.java @@ -17,7 +17,7 @@ import java.io.File; import java.io.FileOutputStream; import java.io.IOException; import java.io.OutputStream; -import java.util.LinkedList; +import java.util.ArrayList; import java.util.List; import org.eclipse.jgit.lib.RebaseTodoLine.Action; @@ -62,7 +62,7 @@ public class RebaseTodoFile { byte[] buf = IO.readFully(new File(repo.getDirectory(), path)); int ptr = 0; int tokenBegin = 0; - List<RebaseTodoLine> r = new LinkedList<>(); + List<RebaseTodoLine> r = new ArrayList<>(); while (ptr < buf.length) { tokenBegin = ptr; ptr = RawParseUtils.nextLF(buf, ptr); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/merge/MergeAlgorithm.java b/org.eclipse.jgit/src/org/eclipse/jgit/merge/MergeAlgorithm.java index b902492366..5734a25276 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/merge/MergeAlgorithm.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/merge/MergeAlgorithm.java @@ -218,13 +218,18 @@ public final class MergeAlgorithm { // set some initial values for the ranges in A and B which we // want to handle + int oursBeginA = oursEdit.getBeginA(); + int theirsBeginA = theirsEdit.getBeginA(); int oursBeginB = oursEdit.getBeginB(); int theirsBeginB = theirsEdit.getBeginB(); // harmonize the start of the ranges in A and B if (oursEdit.getBeginA() < theirsEdit.getBeginA()) { + theirsBeginA -= theirsEdit.getBeginA() + - oursEdit.getBeginA(); theirsBeginB -= theirsEdit.getBeginA() - oursEdit.getBeginA(); } else { + oursBeginA -= oursEdit.getBeginA() - theirsEdit.getBeginA(); oursBeginB -= oursEdit.getBeginA() - theirsEdit.getBeginA(); } @@ -270,11 +275,15 @@ public final class MergeAlgorithm { } // harmonize the end of the ranges in A and B + int oursEndA = oursEdit.getEndA(); + int theirsEndA = theirsEdit.getEndA(); int oursEndB = oursEdit.getEndB(); int theirsEndB = theirsEdit.getEndB(); if (oursEdit.getEndA() < theirsEdit.getEndA()) { + oursEndA += theirsEdit.getEndA() - oursEdit.getEndA(); oursEndB += theirsEdit.getEndA() - oursEdit.getEndA(); } else { + theirsEndA += oursEdit.getEndA() - theirsEdit.getEndA(); theirsEndB += oursEdit.getEndA() - theirsEdit.getEndA(); } @@ -329,10 +338,10 @@ public final class MergeAlgorithm { oursEndB - commonSuffix, ConflictState.FIRST_CONFLICTING_RANGE); - int baseBegin = Math.min(oursBeginB, theirsBeginB) + int baseBegin = Math.min(oursBeginA, theirsBeginA) + commonPrefix; int baseEnd = Math.min(base.size(), - Math.max(oursEndB, theirsEndB)) - commonSuffix; + Math.max(oursEndA, theirsEndA)) - commonSuffix; result.add(0, baseBegin, baseEnd, ConflictState.BASE_CONFLICTING_RANGE); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/merge/ResolveMerger.java b/org.eclipse.jgit/src/org/eclipse/jgit/merge/ResolveMerger.java index 13cccee16b..1ad41be423 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/merge/ResolveMerger.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/merge/ResolveMerger.java @@ -32,7 +32,6 @@ import java.util.ArrayList; import java.util.Arrays; import java.util.Collections; import java.util.HashMap; -import java.util.LinkedList; import java.util.List; import java.util.Map; import java.util.Objects; @@ -106,9 +105,9 @@ public class ResolveMerger extends ThreeWayMerger { */ public static class Result { - private final List<String> modifiedFiles = new LinkedList<>(); + private final List<String> modifiedFiles = new ArrayList<>(); - private final List<String> failedToDelete = new LinkedList<>(); + private final List<String> failedToDelete = new ArrayList<>(); private ObjectId treeId = null; @@ -1274,10 +1273,15 @@ public class ResolveMerger extends ThreeWayMerger { default: break; } + // add the conflicting path to merge result + String currentPath = tw.getPathString(); + MergeResult<RawText> result = new MergeResult<>( + Collections.emptyList()); + result.setContainsConflicts(true); + mergeResults.put(currentPath, result); addConflict(base, ours, theirs); - // attribute merge issues are conflicts but not failures - unmergedPaths.add(tw.getPathString()); + unmergedPaths.add(currentPath); return true; } @@ -1289,38 +1293,48 @@ public class ResolveMerger extends ThreeWayMerger { MergeResult<RawText> result = null; boolean hasSymlink = FileMode.SYMLINK.equals(modeO) || FileMode.SYMLINK.equals(modeT); + + String currentPath = tw.getPathString(); + // if the path is not a symlink in ours and theirs if (!hasSymlink) { try { result = contentMerge(base, ours, theirs, attributes, getContentMergeStrategy()); - } catch (BinaryBlobException e) { - // result == null - } - } - if (result == null) { - switch (getContentMergeStrategy()) { - case OURS: - keep(ourDce); - return true; - case THEIRS: - DirCacheEntry e = add(tw.getRawPath(), theirs, - DirCacheEntry.STAGE_0, EPOCH, 0); - if (e != null) { - addToCheckout(tw.getPathString(), e, attributes); + if (result.containsConflicts() && !ignoreConflicts) { + result.setContainsConflicts(true); + unmergedPaths.add(currentPath); + } else if (ignoreConflicts) { + result.setContainsConflicts(false); } + updateIndex(base, ours, theirs, result, attributes[T_OURS]); + workTreeUpdater.markAsModified(currentPath); + // Entry is null - only add the metadata + addToCheckout(currentPath, null, attributes); return true; - default: - result = new MergeResult<>(Collections.emptyList()); - result.setContainsConflicts(true); - break; + } catch (BinaryBlobException e) { + // if the file is binary in either OURS, THEIRS or BASE + // here, we don't have an option to ignore conflicts } } - if (ignoreConflicts) { - result.setContainsConflicts(false); + switch (getContentMergeStrategy()) { + case OURS: + keep(ourDce); + return true; + case THEIRS: + DirCacheEntry e = add(tw.getRawPath(), theirs, + DirCacheEntry.STAGE_0, EPOCH, 0); + if (e != null) { + addToCheckout(currentPath, e, attributes); + } + return true; + default: + result = new MergeResult<>(Collections.emptyList()); + result.setContainsConflicts(true); + break; } - String currentPath = tw.getPathString(); if (hasSymlink) { if (ignoreConflicts) { + result.setContainsConflicts(false); if (((modeT & FileMode.TYPE_MASK) == FileMode.TYPE_FILE)) { DirCacheEntry e = add(tw.getRawPath(), theirs, DirCacheEntry.STAGE_0, EPOCH, 0); @@ -1329,9 +1343,9 @@ public class ResolveMerger extends ThreeWayMerger { keep(ourDce); } } else { - // Record the conflict DirCacheEntry e = addConflict(base, ours, theirs); mergeResults.put(currentPath, result); + unmergedPaths.add(currentPath); // If theirs is a file, check it out. In link/file // conflicts, C git prefers the file. if (((modeT & FileMode.TYPE_MASK) == FileMode.TYPE_FILE) @@ -1340,14 +1354,12 @@ public class ResolveMerger extends ThreeWayMerger { } } } else { - updateIndex(base, ours, theirs, result, attributes[T_OURS]); - } - if (result.containsConflicts() && !ignoreConflicts) { + result.setContainsConflicts(true); + addConflict(base, ours, theirs); unmergedPaths.add(currentPath); + mergeResults.put(currentPath, result); } - workTreeUpdater.markAsModified(currentPath); - // Entry is null - only adds the metadata. - addToCheckout(currentPath, null, attributes); + return true; } else if (modeO != modeT) { // OURS or THEIRS has been deleted if (((modeO != 0 && !tw.idEqual(T_BASE, T_OURS)) || (modeT != 0 && !tw diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/patch/PatchApplier.java b/org.eclipse.jgit/src/org/eclipse/jgit/patch/PatchApplier.java index a327095c81..cb6cc6efa7 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/patch/PatchApplier.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/patch/PatchApplier.java @@ -23,6 +23,7 @@ import java.io.IOException; import java.io.InputStream; import java.io.OutputStream; import java.nio.ByteBuffer; +import java.nio.charset.Charset; import java.nio.charset.StandardCharsets; import java.nio.file.Files; import java.nio.file.StandardCopyOption; @@ -33,9 +34,11 @@ import java.util.Arrays; import java.util.HashSet; import java.util.Iterator; import java.util.List; +import java.util.Objects; import java.util.Set; import java.util.stream.Collectors; import java.util.zip.InflaterInputStream; + import org.eclipse.jgit.annotations.Nullable; import org.eclipse.jgit.api.errors.FilterFailedException; import org.eclipse.jgit.api.errors.PatchFormatException; @@ -101,11 +104,12 @@ import org.eclipse.jgit.util.sha1.SHA1; * @since 6.4 */ public class PatchApplier { - private static final byte[] NO_EOL = "\\ No newline at end of file" //$NON-NLS-1$ .getBytes(StandardCharsets.US_ASCII); - /** The tree before applying the patch. Only non-null for inCore operation. */ + /** + * The tree before applying the patch. Only non-null for inCore operation. + */ @Nullable private final RevTree beforeTree; @@ -115,10 +119,14 @@ public class PatchApplier { private final ObjectReader reader; + private final Charset charset; + private WorkingTreeOptions workingTreeOptions; private int inCoreSizeLimit; + private boolean allowConflicts; + /** * @param repo * repository to apply the patch in @@ -128,7 +136,8 @@ public class PatchApplier { inserter = repo.newObjectInserter(); reader = inserter.newReader(); beforeTree = null; - + allowConflicts = false; + charset = StandardCharsets.UTF_8; Config config = repo.getConfig(); workingTreeOptions = config.get(WorkingTreeOptions.KEY); inCoreSizeLimit = config.getInt(ConfigConstants.CONFIG_MERGE_SECTION, @@ -143,11 +152,14 @@ public class PatchApplier { * @param oi * to be used for modifying objects */ - public PatchApplier(Repository repo, RevTree beforeTree, ObjectInserter oi) { + public PatchApplier(Repository repo, RevTree beforeTree, + ObjectInserter oi) { this.repo = repo; this.beforeTree = beforeTree; inserter = oi; reader = oi.newReader(); + allowConflicts = false; + charset = StandardCharsets.UTF_8; } /** @@ -157,7 +169,6 @@ public class PatchApplier { * @since 6.3 */ public static class Result { - /** * A wrapper for a patch applying error that affects a given file. * @@ -166,28 +177,68 @@ public class PatchApplier { // TODO(ms): rename this class in next major release @SuppressWarnings("JavaLangClash") public static class Error { + final String msg; + + final String oldFileName; + + @Nullable + final HunkHeader hh; - private String msg; - private String oldFileName; - private @Nullable HunkHeader hh; + final boolean isGitConflict; - private Error(String msg, String oldFileName, - @Nullable HunkHeader hh) { + Error(String msg, String oldFileName, @Nullable HunkHeader hh, + boolean isGitConflict) { this.msg = msg; this.oldFileName = oldFileName; this.hh = hh; + this.isGitConflict = isGitConflict; + } + + /** + * Signals if as part of encountering this error, conflict markers + * were added to the file. + * + * @return {@code true} if conflict markers were added for this + * error. + * + * @since 6.10 + */ + public boolean isGitConflict() { + return isGitConflict; } @Override public String toString() { if (hh != null) { - return MessageFormat.format(JGitText.get().patchApplyErrorWithHunk, - oldFileName, hh, msg); + return MessageFormat.format( + JGitText.get().patchApplyErrorWithHunk, oldFileName, + hh, msg); + } + return MessageFormat.format( + JGitText.get().patchApplyErrorWithoutHunk, oldFileName, + msg); + } + + @Override + public boolean equals(Object o) { + if (this == o) { + return true; + } + if (o == null || !(o instanceof Error)) { + return false; } - return MessageFormat.format(JGitText.get().patchApplyErrorWithoutHunk, - oldFileName, msg); + Error error = (Error) o; + return Objects.equals(msg, error.msg) + && Objects.equals(oldFileName, error.oldFileName) + && Objects.equals(hh, error.hh) + && isGitConflict == error.isGitConflict; } + @Override + public int hashCode() { + return Objects.hash(msg, oldFileName, hh, + Boolean.valueOf(isGitConflict)); + } } private ObjectId treeId; @@ -225,8 +276,14 @@ public class PatchApplier { return errors; } - private void addError(String msg,String oldFileName, @Nullable HunkHeader hh) { - errors.add(new Error(msg, oldFileName, hh)); + private void addError(String msg, String oldFileName, + @Nullable HunkHeader hh) { + errors.add(new Error(msg, oldFileName, hh, false)); + } + + private void addErrorWithGitConflict(String msg, String oldFileName, + @Nullable HunkHeader hh) { + errors.add(new Error(msg, oldFileName, hh, true)); } } @@ -357,6 +414,17 @@ public class PatchApplier { return result; } + /** + * Sets up the {@link PatchApplier} to apply patches even if they conflict. + * + * @return the {@link PatchApplier} to apply any patches + * @since 6.10 + */ + public PatchApplier allowConflicts() { + allowConflicts = true; + return this; + } + private File getFile(String path) { return inCore() ? null : new File(repo.getWorkTree(), path); } @@ -439,6 +507,7 @@ public class PatchApplier { return false; } } + private static final int FILE_TREE_INDEX = 1; /** @@ -539,7 +608,9 @@ public class PatchApplier { convertCrLf); resultStreamLoader = applyText(raw, fh, result); } - if (resultStreamLoader == null || !result.getErrors().isEmpty()) { + if (resultStreamLoader == null + || (!result.getErrors().isEmpty() && result.getErrors().stream() + .anyMatch(e -> !e.msg.equals("cannot apply hunk")))) { //$NON-NLS-1$ return; } @@ -961,9 +1032,51 @@ public class PatchApplier { } } if (!applies) { - result.addError(JGitText.get().applyTextPatchCannotApplyHunk, - fh.getOldPath(), hh); - return null; + if (!allowConflicts) { + result.addError( + JGitText.get().applyTextPatchCannotApplyHunk, + fh.getOldPath(), hh); + return null; + } + // Insert conflict markers. This is best-guess because the + // file might have changed completely. But at least we give + // the user a graceful state that they can resolve manually. + // An alternative to this is using the 3-way merger. This + // only works if the pre-image SHA is contained in the repo. + // If that was the case, cherry-picking the original commit + // should be preferred to apply a patch. + result.addErrorWithGitConflict("cannot apply hunk", fh.getOldPath(), hh); //$NON-NLS-1$ + newLines.add(Math.min(applyAt++, newLines.size()), + asBytes("<<<<<<< HEAD")); //$NON-NLS-1$ + applyAt += hh.getOldImage().lineCount; + newLines.add(Math.min(applyAt++, newLines.size()), + asBytes("=======")); //$NON-NLS-1$ + + int sz = hunkLines.size(); + for (int j = 1; j < sz; j++) { + ByteBuffer hunkLine = hunkLines.get(j); + if (!hunkLine.hasRemaining()) { + // Completely empty line; accept as empty context + // line + applyAt++; + lastWasRemoval = false; + continue; + } + switch (hunkLine.array()[hunkLine.position()]) { + case ' ': + case '+': + newLines.add(Math.min(applyAt++, newLines.size()), + slice(hunkLine, 1)); + break; + case '-': + case '\\': + default: + break; + } + } + newLines.add(Math.min(applyAt++, newLines.size()), + asBytes(">>>>>>> PATCH")); //$NON-NLS-1$ + continue; } // Hunk applies at applyAt. Apply it, and update afterLastHunk and // lineNumberShift @@ -1010,7 +1123,11 @@ public class PatchApplier { } else if (!rt.isMissingNewlineAtEnd()) { newLines.add(null); } + return toContentStreamLoader(newLines); + } + private static ContentStreamLoader toContentStreamLoader( + List<ByteBuffer> newLines) throws IOException { // We could check if old == new, but the short-circuiting complicates // logic for inCore patching, so just write the new thing regardless. TemporaryBuffer buffer = new TemporaryBuffer.LocalFile(null); @@ -1034,6 +1151,10 @@ public class PatchApplier { } } + private ByteBuffer asBytes(String str) { + return ByteBuffer.wrap(str.getBytes(charset)); + } + @SuppressWarnings("ByteBufferBackingArray") private boolean canApplyAt(List<ByteBuffer> hunkLines, List<ByteBuffer> newLines, int line) { @@ -1123,4 +1244,4 @@ public class PatchApplier { in.close(); } } -} +}
\ No newline at end of file diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/MergeBaseGenerator.java b/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/MergeBaseGenerator.java index a213dd47c6..be29dc3138 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/MergeBaseGenerator.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/MergeBaseGenerator.java @@ -12,7 +12,7 @@ package org.eclipse.jgit.revwalk; import java.io.IOException; import java.text.MessageFormat; -import java.util.LinkedList; +import java.util.ArrayDeque; import org.eclipse.jgit.errors.IncorrectObjectTypeException; import org.eclipse.jgit.errors.MissingObjectException; @@ -47,7 +47,8 @@ class MergeBaseGenerator extends Generator { private int recarryTest; private int recarryMask; private int mergeBaseAncestor = -1; - private LinkedList<RevCommit> ret = new LinkedList<>(); + + private ArrayDeque<RevCommit> ret = new ArrayDeque<>(); private CarryStack stack; diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/TreeRevFilter.java b/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/TreeRevFilter.java index 43571a6868..99943b78e6 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/TreeRevFilter.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/revwalk/TreeRevFilter.java @@ -139,11 +139,8 @@ public class TreeRevFilter extends RevFilter { .getPathsBestEffort(); if (paths.isPresent()) { changedPathFilterUsed = true; - for (byte[] path : paths.get()) { - if (!cpf.maybeContains(path)) { - mustCalculateChgs = false; - break; - } + if (paths.get().stream().noneMatch(cpf::maybeContains)) { + mustCalculateChgs = false; } } } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/Transport.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/Transport.java index 4a02d6d452..b335675da5 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/Transport.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/Transport.java @@ -33,10 +33,8 @@ import java.util.Collection; import java.util.Collections; import java.util.Enumeration; import java.util.LinkedHashSet; -import java.util.LinkedList; import java.util.List; import java.util.Map; -import java.util.Vector; import java.util.concurrent.CopyOnWriteArrayList; import org.eclipse.jgit.annotations.NonNull; @@ -109,7 +107,7 @@ public abstract class Transport implements AutoCloseable { String name = prefix + Transport.class.getName(); return ldr.getResources(name); } catch (IOException err) { - return new Vector<URL>().elements(); + return Collections.emptyEnumeration(); } } @@ -595,7 +593,7 @@ public abstract class Transport implements AutoCloseable { Collection<RefSpec> fetchSpecs) throws IOException { if (fetchSpecs == null) fetchSpecs = Collections.emptyList(); - final List<RemoteRefUpdate> result = new LinkedList<>(); + final List<RemoteRefUpdate> result = new ArrayList<>(); final Collection<RefSpec> procRefs = expandPushWildcardsFor(db, specs); for (RefSpec spec : procRefs) { diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java index 3162b89908..a65d0b756c 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/TransportHttp.java @@ -66,7 +66,6 @@ import java.util.Collections; import java.util.EnumSet; import java.util.HashSet; import java.util.LinkedHashSet; -import java.util.LinkedList; import java.util.List; import java.util.Locale; import java.util.Map; @@ -763,7 +762,7 @@ public class TransportHttp extends HttpTransport implements WalkTransport, void processResponseCookies(HttpConnection conn) { if (cookieFile != null && http.getSaveCookies()) { - List<HttpCookie> foundCookies = new LinkedList<>(); + List<HttpCookie> foundCookies = new ArrayList<>(); List<String> cookieHeaderValues = conn .getHeaderFields(HDR_SET_COOKIE); @@ -795,7 +794,7 @@ public class TransportHttp extends HttpTransport implements WalkTransport, private List<HttpCookie> extractCookies(String headerKey, List<String> headerValues) { - List<HttpCookie> foundCookies = new LinkedList<>(); + List<HttpCookie> foundCookies = new ArrayList<>(); for (String headerValue : headerValues) { foundCookies .addAll(HttpCookie.parse(headerKey + ':' + headerValue)); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/WalkFetchConnection.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/WalkFetchConnection.java index 8d89107c2b..b7bb0cbce3 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/WalkFetchConnection.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/WalkFetchConnection.java @@ -16,13 +16,16 @@ import java.io.FileNotFoundException; import java.io.FileOutputStream; import java.io.IOException; import java.text.MessageFormat; +import java.util.ArrayDeque; import java.util.ArrayList; import java.util.Collection; +import java.util.Deque; import java.util.HashMap; import java.util.HashSet; -import java.util.Iterator; -import java.util.LinkedList; +import java.util.LinkedHashMap; import java.util.List; +import java.util.Map; +import java.util.Map.Entry; import java.util.Set; import org.eclipse.jgit.errors.CompoundException; @@ -112,16 +115,16 @@ class WalkFetchConnection extends BaseFetchConnection { private final DateRevQueue localCommitQueue; /** Objects we need to copy from the remote repository. */ - private LinkedList<ObjectId> workQueue; + private Deque<ObjectId> workQueue; /** Databases we have not yet obtained the list of packs from. */ - private final LinkedList<WalkRemoteObjectDatabase> noPacksYet; + private final Deque<WalkRemoteObjectDatabase> noPacksYet; /** Databases we have not yet obtained the alternates from. */ - private final LinkedList<WalkRemoteObjectDatabase> noAlternatesYet; + private final Deque<WalkRemoteObjectDatabase> noAlternatesYet; /** Packs we have discovered, but have not yet fetched locally. */ - private final LinkedList<RemotePack> unfetchedPacks; + private final Map<String, RemotePack> unfetchedPacks; /** * Packs whose indexes we have looked at in {@link #unfetchedPacks}. @@ -163,13 +166,13 @@ class WalkFetchConnection extends BaseFetchConnection { remotes = new ArrayList<>(); remotes.add(w); - unfetchedPacks = new LinkedList<>(); + unfetchedPacks = new LinkedHashMap<>(); packsConsidered = new HashSet<>(); - noPacksYet = new LinkedList<>(); + noPacksYet = new ArrayDeque<>(); noPacksYet.add(w); - noAlternatesYet = new LinkedList<>(); + noAlternatesYet = new ArrayDeque<>(); noAlternatesYet.add(w); fetchErrors = new HashMap<>(); @@ -183,7 +186,7 @@ class WalkFetchConnection extends BaseFetchConnection { LOCALLY_SEEN = revWalk.newFlag("LOCALLY_SEEN"); //$NON-NLS-1$ localCommitQueue = new DateRevQueue(); - workQueue = new LinkedList<>(); + workQueue = new ArrayDeque<>(); } @Override @@ -226,7 +229,7 @@ class WalkFetchConnection extends BaseFetchConnection { public void close() { inserter.close(); reader.close(); - for (RemotePack p : unfetchedPacks) { + for (RemotePack p : unfetchedPacks.values()) { if (p.tmpIdx != null) p.tmpIdx.delete(); } @@ -421,8 +424,9 @@ class WalkFetchConnection extends BaseFetchConnection { if (packNameList == null || packNameList.isEmpty()) continue; for (String packName : packNameList) { - if (packsConsidered.add(packName)) - unfetchedPacks.add(new RemotePack(wrr, packName)); + if (packsConsidered.add(packName)) { + unfetchedPacks.put(packName, new RemotePack(wrr, packName)); + } } if (downloadPackedObject(pm, id)) return; @@ -465,15 +469,27 @@ class WalkFetchConnection extends BaseFetchConnection { } } + private boolean downloadPackedObject(ProgressMonitor monitor, + AnyObjectId id) throws TransportException { + Set<String> brokenPacks = new HashSet<>(); + try { + return downloadPackedObject(monitor, id, brokenPacks); + } finally { + brokenPacks.forEach(unfetchedPacks::remove); + } + } + @SuppressWarnings("Finally") private boolean downloadPackedObject(final ProgressMonitor monitor, - final AnyObjectId id) throws TransportException { + final AnyObjectId id, Set<String> brokenPacks) throws TransportException { // Search for the object in a remote pack whose index we have, // but whose pack we do not yet have. // - final Iterator<RemotePack> packItr = unfetchedPacks.iterator(); - while (packItr.hasNext() && !monitor.isCancelled()) { - final RemotePack pack = packItr.next(); + for (Entry<String, RemotePack> entry : unfetchedPacks.entrySet()) { + if (monitor.isCancelled()) { + break; + } + final RemotePack pack = entry.getValue(); try { pack.openIndex(monitor); } catch (IOException err) { @@ -483,7 +499,7 @@ class WalkFetchConnection extends BaseFetchConnection { // another source, so don't consider it a failure. // recordError(id, err); - packItr.remove(); + brokenPacks.add(entry.getKey()); continue; } @@ -534,7 +550,7 @@ class WalkFetchConnection extends BaseFetchConnection { } throw new TransportException(e.getMessage(), e); } - packItr.remove(); + brokenPacks.add(entry.getKey()); } if (!alreadyHave(id)) { @@ -549,11 +565,9 @@ class WalkFetchConnection extends BaseFetchConnection { // Complete any other objects that we can. // - final Iterator<ObjectId> pending = swapFetchQueue(); - while (pending.hasNext()) { - final ObjectId p = pending.next(); + final Deque<ObjectId> pending = swapFetchQueue(); + for (ObjectId p : pending) { if (pack.index.hasObject(p)) { - pending.remove(); process(p); } else { workQueue.add(p); @@ -565,9 +579,9 @@ class WalkFetchConnection extends BaseFetchConnection { return false; } - private Iterator<ObjectId> swapFetchQueue() { - final Iterator<ObjectId> r = workQueue.iterator(); - workQueue = new LinkedList<>(); + private Deque<ObjectId> swapFetchQueue() { + final Deque<ObjectId> r = workQueue; + workQueue = new ArrayDeque<>(); return r; } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/transport/http/JDKHttpConnection.java b/org.eclipse.jgit/src/org/eclipse/jgit/transport/http/JDKHttpConnection.java index 8e9be1dde8..e20acadc4a 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/transport/http/JDKHttpConnection.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/transport/http/JDKHttpConnection.java @@ -20,7 +20,7 @@ import java.net.URL; import java.security.KeyManagementException; import java.security.NoSuchAlgorithmException; import java.security.SecureRandom; -import java.util.LinkedList; +import java.util.ArrayList; import java.util.List; import java.util.Map; @@ -152,7 +152,7 @@ public class JDKHttpConnection implements HttpConnection { private static List<String> mapValuesToListIgnoreCase(String keyName, Map<String, List<String>> m) { - List<String> fields = new LinkedList<>(); + List<String> fields = new ArrayList<>(); m.entrySet().stream().filter(e -> keyName.equalsIgnoreCase(e.getKey())) .filter(e -> e.getValue() != null) .forEach(e -> fields.addAll(e.getValue())); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/ByteArraySet.java b/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/ByteArraySet.java index c94160144e..bcf79a285d 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/ByteArraySet.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/ByteArraySet.java @@ -15,6 +15,10 @@ package org.eclipse.jgit.treewalk.filter; import org.eclipse.jgit.util.RawParseUtils; +import java.util.Arrays; +import java.util.Set; +import java.util.stream.Collectors; + /** * Specialized set for byte arrays, interpreted as strings for use in * {@link PathFilterGroup.Group}. Most methods assume the hash is already know @@ -291,4 +295,8 @@ class ByteArraySet { return ret; } + Set<byte[]> toSet() { + return Arrays.stream(toArray()).collect(Collectors.toSet()); + } + } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/IndexDiffFilter.java b/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/IndexDiffFilter.java index 699ff6b68b..cfdc4dd358 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/IndexDiffFilter.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/IndexDiffFilter.java @@ -10,8 +10,9 @@ package org.eclipse.jgit.treewalk.filter; import java.io.IOException; +import java.util.ArrayDeque; +import java.util.ArrayList; import java.util.HashSet; -import java.util.LinkedList; import java.util.List; import java.util.Set; @@ -62,9 +63,9 @@ public class IndexDiffFilter extends TreeFilter { private final Set<String> ignoredPaths = new HashSet<>(); - private final LinkedList<String> untrackedParentFolders = new LinkedList<>(); + private final ArrayDeque<String> untrackedParentFolders = new ArrayDeque<>(); - private final LinkedList<String> untrackedFolders = new LinkedList<>(); + private final ArrayDeque<String> untrackedFolders = new ArrayDeque<>(); /** * Creates a new instance of this filter. Do not use an instance of this @@ -272,12 +273,14 @@ public class IndexDiffFilter extends TreeFilter { * empty list will be returned. */ public List<String> getUntrackedFolders() { - LinkedList<String> ret = new LinkedList<>(untrackedFolders); + ArrayList<String> ret = new ArrayList<>(untrackedFolders); if (!untrackedParentFolders.isEmpty()) { String toBeAdded = untrackedParentFolders.getLast(); - while (!ret.isEmpty() && ret.getLast().startsWith(toBeAdded)) - ret.removeLast(); - ret.addLast(toBeAdded); + while (!ret.isEmpty() + && ret.get(ret.size() - 1).startsWith(toBeAdded)) { + ret.remove(ret.size() - 1); + } + ret.add(toBeAdded); } return ret; } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/PathFilterGroup.java b/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/PathFilterGroup.java index 59855572f2..4c0604ad56 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/PathFilterGroup.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/PathFilterGroup.java @@ -12,6 +12,8 @@ package org.eclipse.jgit.treewalk.filter; import java.util.Collection; +import java.util.Optional; +import java.util.Set; import org.eclipse.jgit.errors.StopWalkException; import org.eclipse.jgit.internal.JGitText; @@ -232,6 +234,15 @@ public class PathFilterGroup { } @Override + public Optional<Set<byte[]>> getPathsBestEffort() { + Set<byte[]> result = fullpaths.toSet(); + if (result.isEmpty()) { + return Optional.empty(); + } + return Optional.of(result); + } + + @Override public TreeFilter clone() { return this; } diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/TreeFilter.java b/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/TreeFilter.java index 22d430bc27..a9066dc8f8 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/TreeFilter.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/treewalk/filter/TreeFilter.java @@ -210,7 +210,7 @@ public abstract class TreeFilter { public abstract boolean shouldBeRecursive(); /** - * If this filter checks that a specific set of paths have all been + * If this filter checks that at least one of the paths in a set has been * modified, returns that set of paths to be checked against a changed path * filter. Otherwise, returns empty. * diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/util/FS_POSIX.java b/org.eclipse.jgit/src/org/eclipse/jgit/util/FS_POSIX.java index d91f37b51a..e73095f5a8 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/util/FS_POSIX.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/util/FS_POSIX.java @@ -1,5 +1,5 @@ /* - * Copyright (C) 2010, Robin Rosenberg and others + * Copyright (C) 2010, 2024, Robin Rosenberg and others * * This program and the accompanying materials are made available under the * terms of the Eclipse Distribution License v. 1.0 which is available at @@ -203,7 +203,16 @@ public class FS_POSIX extends FS { /** {@inheritDoc} */ @Override public boolean canExecute(File f) { - return FileUtils.canExecute(f); + if (!isFile(f)) { + return false; + } + try { + Path path = FileUtils.toPath(f); + Set<PosixFilePermission> pset = Files.getPosixFilePermissions(path); + return pset.contains(PosixFilePermission.OWNER_EXECUTE); + } catch (IOException ex) { + return false; + } } /** {@inheritDoc} */ @@ -250,8 +259,12 @@ public class FS_POSIX extends FS { /** {@inheritDoc} */ @Override public ProcessBuilder runInShell(String cmd, String[] args) { - List<String> argv = new ArrayList<>(4 + args.length); + List<String> argv = new ArrayList<>(5 + args.length); argv.add("sh"); //$NON-NLS-1$ + if (SystemReader.getInstance().isMacOS()) { + // Use a login shell to get the full normal $PATH + argv.add("-l"); //$NON-NLS-1$ + } argv.add("-c"); //$NON-NLS-1$ argv.add(cmd + " \"$@\""); //$NON-NLS-1$ argv.add(cmd); diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/util/io/UnionInputStream.java b/org.eclipse.jgit/src/org/eclipse/jgit/util/io/UnionInputStream.java index b37f28b161..7e950f6529 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/util/io/UnionInputStream.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/util/io/UnionInputStream.java @@ -12,8 +12,8 @@ package org.eclipse.jgit.util.io; import java.io.IOException; import java.io.InputStream; -import java.util.Iterator; -import java.util.LinkedList; +import java.util.ArrayDeque; +import java.util.Deque; /** * An InputStream which reads from one or more InputStreams. @@ -34,7 +34,7 @@ public class UnionInputStream extends InputStream { } }; - private final LinkedList<InputStream> streams = new LinkedList<>(); + private final Deque<InputStream> streams = new ArrayDeque<>(); /** * Create an empty InputStream that is currently at EOF state. @@ -163,14 +163,14 @@ public class UnionInputStream extends InputStream { public void close() throws IOException { IOException err = null; - for (Iterator<InputStream> i = streams.iterator(); i.hasNext();) { + for (InputStream stream : streams) { try { - i.next().close(); + stream.close(); } catch (IOException closeError) { err = closeError; } - i.remove(); } + streams.clear(); if (err != null) throw err; @@ -18,7 +18,7 @@ <groupId>org.eclipse.jgit</groupId> <artifactId>org.eclipse.jgit-parent</artifactId> <packaging>pom</packaging> - <version>6.9.1-SNAPSHOT</version> + <version>6.10.1-SNAPSHOT</version> <name>JGit - Parent</name> <url>${jgit-url}</url> @@ -118,37 +118,37 @@ <project.build.outputTimestamp>${commit.time.iso}</project.build.outputTimestamp> - <jgit-last-release-version>6.8.0.202311291450-r</jgit-last-release-version> + <jgit-last-release-version>6.9.0.202403050737-r</jgit-last-release-version> <ant-version>1.10.14</ant-version> - <apache-sshd-version>2.12.0</apache-sshd-version> + <apache-sshd-version>2.12.1</apache-sshd-version> <jsch-version>0.1.55</jsch-version> <jzlib-version>1.1.3</jzlib-version> <javaewah-version>1.2.3</javaewah-version> <junit-version>4.13.2</junit-version> <test-fork-count>1C</test-fork-count> - <args4j-version>2.33</args4j-version> - <commons-compress-version>1.26.0</commons-compress-version> + <args4j-version>2.37</args4j-version> + <commons-compress-version>1.26.2</commons-compress-version> <osgi-core-version>6.0.0</osgi-core-version> <servlet-api-version>4.0.4</servlet-api-version> - <jetty-version>10.0.20</jetty-version> - <japicmp-version>0.18.5</japicmp-version> + <jetty-version>10.0.21</jetty-version> + <japicmp-version>0.21.2</japicmp-version> <httpclient-version>4.5.14</httpclient-version> <httpcore-version>4.4.16</httpcore-version> <slf4j-version>1.7.36</slf4j-version> <maven-javadoc-plugin-version>3.6.3</maven-javadoc-plugin-version> - <gson-version>2.10.1</gson-version> - <bouncycastle-version>1.77</bouncycastle-version> - <spotbugs-maven-plugin-version>4.8.3.1</spotbugs-maven-plugin-version> + <gson-version>2.11.0</gson-version> + <bouncycastle-version>1.78.1</bouncycastle-version> + <spotbugs-maven-plugin-version>4.8.5.0</spotbugs-maven-plugin-version> <maven-project-info-reports-plugin-version>3.5.1</maven-project-info-reports-plugin-version> <maven-jxr-plugin-version>3.3.2</maven-jxr-plugin-version> <maven-surefire-plugin-version>3.2.5</maven-surefire-plugin-version> <maven-surefire-report-plugin-version>${maven-surefire-plugin-version}</maven-surefire-report-plugin-version> - <maven-compiler-plugin-version>3.12.1</maven-compiler-plugin-version> + <maven-compiler-plugin-version>3.13.0</maven-compiler-plugin-version> <plexus-compiler-version>2.13.0</plexus-compiler-version> <hamcrest-version>2.2</hamcrest-version> - <assertj-version>3.25.3</assertj-version> + <assertj-version>3.26.0</assertj-version> <jna-version>5.14.0</jna-version> - <byte-buddy-version>1.14.12</byte-buddy-version> + <byte-buddy-version>1.14.16</byte-buddy-version> <!-- Properties to enable jacoco code coverage analysis --> <sonar.core.codeCoveragePlugin>jacoco</sonar.core.codeCoveragePlugin> @@ -184,7 +184,7 @@ <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-jar-plugin</artifactId> - <version>3.3.0</version> + <version>3.4.1</version> <configuration> <archive> <manifestEntries> @@ -214,7 +214,7 @@ <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-shade-plugin</artifactId> - <version>3.5.1</version> + <version>3.5.3</version> </plugin> <plugin> @@ -232,7 +232,7 @@ <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-source-plugin</artifactId> - <version>3.3.0</version> + <version>3.3.1</version> </plugin> <plugin> @@ -255,7 +255,7 @@ <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>build-helper-maven-plugin</artifactId> - <version>3.5.0</version> + <version>3.6.0</version> </plugin> <plugin> @@ -277,7 +277,7 @@ <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-pmd-plugin</artifactId> - <version>3.21.2</version> + <version>3.22.0</version> <configuration> <inputEncoding>${project.build.sourceEncoding}</inputEncoding> <minimumTokens>100</minimumTokens> @@ -305,12 +305,12 @@ <plugin> <groupId>org.jacoco</groupId> <artifactId>jacoco-maven-plugin</artifactId> - <version>0.8.11</version> + <version>0.8.12</version> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-site-plugin</artifactId> - <version>4.0.0-M13</version> + <version>4.0.0-M14</version> <dependencies> <dependency><!-- add support for ssh/scp --> <groupId>org.apache.maven.wagon</groupId> @@ -337,12 +337,12 @@ <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-deploy-plugin</artifactId> - <version>3.1.1</version> + <version>3.1.2</version> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-install-plugin</artifactId> - <version>3.1.1</version> + <version>3.1.2</version> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> @@ -357,7 +357,7 @@ <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> - <version>2.7.13</version> + <version>2.7.18</version> </plugin> <plugin> <groupId>org.eclipse.dash</groupId> @@ -367,12 +367,12 @@ <plugin> <groupId>org.cyclonedx</groupId> <artifactId>cyclonedx-maven-plugin</artifactId> - <version>2.7.10</version> + <version>2.8.0</version> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-artifact-plugin</artifactId> - <version>3.5.0</version> + <version>3.5.1</version> <configuration> <ignore>**/*cyclonedx.json</ignore> <reproducible>true</reproducible> @@ -623,7 +623,7 @@ <plugin> <groupId>io.github.git-commit-id</groupId> <artifactId>git-commit-id-maven-plugin</artifactId> - <version>7.0.0</version> + <version>8.0.2</version> <executions> <execution> <id>get-the-git-infos</id> @@ -647,13 +647,13 @@ <dependency> <groupId>org.apache.groovy</groupId> <artifactId>groovy</artifactId> - <version>4.0.15</version> + <version>4.0.21</version> <scope>runtime</scope> </dependency> <dependency> <groupId>org.apache.groovy</groupId> <artifactId>groovy-ant</artifactId> - <version>4.0.15</version> + <version>4.0.21</version> <scope>runtime</scope> </dependency> </dependencies> @@ -884,12 +884,30 @@ </dependency> <dependency> + <groupId>commons-codec</groupId> + <artifactId>commons-codec</artifactId> + <version>1.17.0</version> + </dependency> + + <dependency> <groupId>org.apache.commons</groupId> <artifactId>commons-compress</artifactId> <version>${commons-compress-version}</version> </dependency> <dependency> + <groupId>org.apache.commons</groupId> + <artifactId>commons-io</artifactId> + <version>2.16.1</version> + </dependency> + + <dependency> + <groupId>commons-logging</groupId> + <artifactId>commons-logging</artifactId> + <version>1.3.2</version> + </dependency> + + <dependency> <groupId>org.tukaani</groupId> <artifactId>xz</artifactId> <version>1.9</version> @@ -983,7 +1001,7 @@ <dependency> <groupId>org.mockito</groupId> <artifactId>mockito-core</artifactId> - <version>5.10.0</version> + <version>5.12.0</version> </dependency> <dependency> @@ -1092,7 +1110,7 @@ <dependency> <groupId>org.eclipse.jdt</groupId> <artifactId>ecj</artifactId> - <version>3.36.0</version> + <version>3.37.0</version> </dependency> </dependencies> </plugin> diff --git a/tools/BUILD b/tools/BUILD index c2b2366c49..c7ec638645 100644 --- a/tools/BUILD +++ b/tools/BUILD @@ -17,7 +17,7 @@ default_java_toolchain( default_java_toolchain( name = "error_prone_warnings_toolchain_java17", configuration = dict(), - java_runtime = "@bazel_tools//tools/jdk:remotejdk_17", + java_runtime = "@rules_java//toolchains:remotejdk_17", package_configuration = [ ":error_prone", ], @@ -26,6 +26,18 @@ default_java_toolchain( visibility = ["//visibility:public"], ) +default_java_toolchain( + name = "error_prone_warnings_toolchain_java21", + configuration = dict(), + java_runtime = "@rules_java//toolchains:remotejdk_21", + package_configuration = [ + ":error_prone", + ], + source_version = "21", + target_version = "21", + visibility = ["//visibility:public"], +) + # Error Prone errors enabled by default; see ../.bazelrc for how this is # enabled. This warnings list is originally based on: # https://github.com/bazelbuild/BUILD_file_generator/blob/master/tools/bazel_defs/java.bzl @@ -62,7 +74,7 @@ java_package_configuration( "-Xep:AutoValueSubclassLeaked:WARN", "-Xep:BadAnnotationImplementation:ERROR", "-Xep:BadComparable:ERROR", - "-Xep:BadImport:WARN", + "-Xep:BadImport:ERROR", "-Xep:BadInstanceof:ERROR", "-Xep:BadShiftAmount:ERROR", "-Xep:BanSerializableRead:ERROR", @@ -75,8 +87,8 @@ java_package_configuration( "-Xep:CacheLoaderNull:ERROR", "-Xep:CannotMockFinalClass:ERROR", "-Xep:CanonicalDuration:ERROR", - "-Xep:CatchAndPrintStackTrace:WARN", - "-Xep:CatchFail:WARN", + "-Xep:CatchAndPrintStackTrace:ERROR", + "-Xep:CatchFail:ERROR", "-Xep:ChainedAssertionLosesContext:ERROR", "-Xep:ChainingConstructorIgnoresParameter:ERROR", "-Xep:CharacterGetNumericValue:ERROR", @@ -158,7 +170,7 @@ java_package_configuration( "-Xep:FromTemporalAccessor:ERROR", "-Xep:FunctionalInterfaceClash:ERROR", "-Xep:FunctionalInterfaceMethodChanged:ERROR", - "-Xep:FutureReturnValueIgnored:WARN", + "-Xep:FutureReturnValueIgnored:ERROR", "-Xep:FuturesGetCheckedIllegalExceptionType:ERROR", "-Xep:GetClassOnAnnotation:ERROR", "-Xep:GetClassOnClass:ERROR", @@ -222,7 +234,7 @@ java_package_configuration( "-Xep:JavaPeriodGetDays:ERROR", "-Xep:JavaTimeDefaultTimeZone:ERROR", "-Xep:JavaUtilDate:WARN", - "-Xep:JdkObsolete:WARN", + "-Xep:JdkObsolete:ERROR", "-Xep:JodaConstructors:ERROR", "-Xep:JodaDateTimeConstants:ERROR", "-Xep:JodaDurationWithMillis:ERROR", @@ -251,7 +263,7 @@ java_package_configuration( "-Xep:LockOnBoxedPrimitive:ERROR", "-Xep:LogicalAssignment:ERROR", "-Xep:LongFloatConversion:ERROR", - "-Xep:LongLiteralLowerCaseSuffix:WARN", + "-Xep:LongLiteralLowerCaseSuffix:ERROR", "-Xep:LoopConditionChecker:ERROR", "-Xep:LoopOverCharArray:ERROR", "-Xep:LossyPrimitiveCompare:ERROR", @@ -270,7 +282,7 @@ java_package_configuration( "-Xep:MixedDescriptors:ERROR", "-Xep:MixedMutabilityReturnType:WARN", "-Xep:MockitoUsage:ERROR", - "-Xep:ModifiedButNotUsed:WARN", + "-Xep:ModifiedButNotUsed:ERROR", "-Xep:ModifyCollectionInEnhancedForLoop:ERROR", "-Xep:ModifyingCollectionWithItself:ERROR", "-Xep:ModifySourceCollectionInStream:ERROR", @@ -323,7 +335,7 @@ java_package_configuration( "-Xep:PreferredInterfaceType:OFF", "-Xep:PrimitiveAtomicReference:ERROR", "-Xep:PrivateSecurityContractProtoAccess:ERROR", - "-Xep:ProtectedMembersInFinalClass:WARN", + "-Xep:ProtectedMembersInFinalClass:ERROR", "-Xep:ProtoBuilderReturnValueIgnored:ERROR", "-Xep:ProtocolBufferOrdinal:ERROR", "-Xep:ProtoDurationGetSecondsGetNano:ERROR", @@ -396,7 +408,7 @@ java_package_configuration( "-Xep:UnnecessaryLambda:ERROR", "-Xep:UnnecessaryMethodInvocationMatcher:ERROR", "-Xep:UnnecessaryMethodReference:ERROR", - "-Xep:UnnecessaryParentheses:WARN", + "-Xep:UnnecessaryParentheses:ERROR", "-Xep:UnnecessaryTypeArgument:ERROR", "-Xep:UnrecognisedJavadocTag:ERROR", "-Xep:UnsafeFinalization:ERROR", @@ -407,10 +419,10 @@ java_package_configuration( "-Xep:UnusedException:ERROR", "-Xep:UnusedMethod:WARN", "-Xep:UnusedNestedClass:ERROR", - "-Xep:UnusedVariable:WARN", + "-Xep:UnusedVariable:ERROR", "-Xep:URLEqualsHashCode:ERROR", "-Xep:UseBinds:ERROR", - "-Xep:UseCorrectAssertInTests:WARN", + "-Xep:UseCorrectAssertInTests:ERROR", "-Xep:VariableNameSameAsType:ERROR", "-Xep:VarTypeName:ERROR", "-Xep:WaitNotInLoop:ERROR", diff --git a/tools/remote-bazelrc b/tools/remote-bazelrc index 0c558f8136..f8aabd28ae 100644 --- a/tools/remote-bazelrc +++ b/tools/remote-bazelrc @@ -30,12 +30,11 @@ build:remote --disk_cache= # Set several flags related to specifying the platform, toolchain and java # properties. -build:remote --crosstool_top=@rbe_jdk11//cc:toolchain -build:remote --extra_toolchains=@rbe_jdk11//config:cc-toolchain -build:remote --extra_execution_platforms=@rbe_jdk11//config:platform -build:remote --host_platform=@rbe_jdk11//config:platform -build:remote --platforms=@rbe_jdk11//config:platform -build:remote --action_env=BAZEL_DO_NOT_DETECT_CPP_TOOLCHAIN=1 +build:remote --crosstool_top=@ubuntu2204_jdk17//cc:toolchain +build:remote --extra_toolchains=@ubuntu2204_jdk17//config:cc-toolchain +build:remote --extra_execution_platforms=@ubuntu2204_jdk17//config:platform +build:remote --host_platform=@ubuntu2204_jdk17//config:platform +build:remote --platforms=@ubuntu2204_jdk17//config:platform # Set various strategies so that all actions execute remotely. Mixing remote # and local execution will lead to errors unless the toolchain and remote |