From fbf693e10e2ba35f41ad3c9bbed3ae2ccf96bad4 Mon Sep 17 00:00:00 2001 From: Maxim Nesen Date: Tue, 7 Oct 2025 12:34:14 +0200 Subject: [PATCH] JDK 26 compatibility Signed-off-by: Maxim Nesen --- .../jersey/internal/guava/Ordering.java | 4 ++-- tests/e2e-client/pom.xml | 12 ++++++++++++ .../test/resources/disabled_tls.properties | 19 +++++++++++++++++++ 3 files changed, 33 insertions(+), 2 deletions(-) create mode 100644 tests/e2e-client/src/test/resources/disabled_tls.properties diff --git a/core-common/src/main/java/org/glassfish/jersey/internal/guava/Ordering.java b/core-common/src/main/java/org/glassfish/jersey/internal/guava/Ordering.java index a544e36037d..c87d6a50979 100644 --- a/core-common/src/main/java/org/glassfish/jersey/internal/guava/Ordering.java +++ b/core-common/src/main/java/org/glassfish/jersey/internal/guava/Ordering.java @@ -203,7 +203,7 @@ E min(Iterable iterable) { * @throws ClassCastException if the parameters are not mutually * comparable under this ordering. */ - E min(E a, E b) { + public E min(E a, E b) { return (compare(a, b) <= 0) ? a : b; } @@ -278,7 +278,7 @@ E max(Iterable iterable) { * @throws ClassCastException if the parameters are not mutually * comparable under this ordering. */ - E max(E a, E b) { + public E max(E a, E b) { return (compare(a, b) >= 0) ? a : b; } diff --git a/tests/e2e-client/pom.xml b/tests/e2e-client/pom.xml index 6f3aac56a5b..d647b0efc8d 100644 --- a/tests/e2e-client/pom.xml +++ b/tests/e2e-client/pom.xml @@ -245,6 +245,18 @@ -Djdk.tls.server.protocols=TLSv1.2 + + jdk26+ + + [26,) + + + + -Djdk.tls.server.protocols=TLSv1.2 + -Djava.security.properties=${project.build.directory}/test-classes/disabled_tls.properties + + + xdk diff --git a/tests/e2e-client/src/test/resources/disabled_tls.properties b/tests/e2e-client/src/test/resources/disabled_tls.properties new file mode 100644 index 00000000000..41cb0b9a186 --- /dev/null +++ b/tests/e2e-client/src/test/resources/disabled_tls.properties @@ -0,0 +1,19 @@ +# +# Copyright (c) 2012, 2025 Oracle and/or its affiliates. All rights reserved. +# +# This program and the accompanying materials are made available under the +# terms of the Eclipse Public License v. 2.0, which is available at +# http://www.eclipse.org/legal/epl-2.0. +# +# This Source Code may also be made available under the following Secondary +# Licenses when the conditions for such availability set forth in the +# Eclipse Public License v. 2.0 are satisfied: GNU General Public License, +# version 2 with the GNU Classpath Exception, which is available at +# https://www.gnu.org/software/classpath/license.html. +# +# SPDX-License-Identifier: EPL-2.0 OR GPL-2.0 WITH Classpath-exception-2.0 +# + +jdk.tls.disabledAlgorithms=SSLv3, TLSv1, TLSv1.1, DTLSv1.0, RC4, DES, \ + MD5withRSA, DH keySize < 1024, EC keySize < 224, 3DES_EDE_CBC, anon, NULL, \ + ECDH \ No newline at end of file