public inbox for git-commits@fedoraproject.org
help / color / mirror / Atom feed
* [rpms/mysql-connector-java] f45: Update to upstream version 9.7.0 and add tests subpackage
@ 2026-08-17  8:31 Marian Koncek
  0 siblings, 0 replies; only message in thread
From: Marian Koncek @ 2026-08-17  8:31 UTC (permalink / raw)
  To: git-commits

A new commit has been pushed.

Repo   : rpms/mysql-connector-java
Branch : f45
Commit : f59103549d6765cb6140e644151c7bfd6ce72a10
Author : Marian Koncek <mkoncek@redhat.com>
Date   : 2026-08-12T11:43:27+02:00
Stats  : +435/-574 in 11 file(s)
URL    : https://src.fedoraproject.org/rpms/mysql-connector-java/c/f59103549d6765cb6140e644151c7bfd6ce72a10?branch=f45

Log:
Update to upstream version 9.7.0 and add tests subpackage

---
diff --git a/.gitignore b/.gitignore
index 9edddea..f28f20f 100644
--- a/.gitignore
+++ b/.gitignore
@@ -24,3 +24,4 @@
 /mysql-connector-java-8.0.28-nojars.tar.xz
 /mysql-connector-java-8.0.29-nojars.tar.xz
 /mysql-connector-java-8.0.30-nojars.tar.xz
+/mysql-connector-java-9.7.0.tar.zst

diff --git a/0001-Remove-coverage-test.patch b/0001-Remove-coverage-test.patch
deleted file mode 100644
index 58a84ea..0000000
--- a/0001-Remove-coverage-test.patch
+++ /dev/null
@@ -1,192 +0,0 @@
-From cde027a4886ac1160ac42a6e4ba1fa2d271009be Mon Sep 17 00:00:00 2001
-From: Ondrej Dubaj <odubaj@redhat.com>
-Date: Thu, 28 Jul 2022 09:54:06 +0200
-Subject: [PATCH] Remove coverage test
-
----
- build.xml | 162 ------------------------------------------------------
- 1 file changed, 162 deletions(-)
-
-diff --git a/build.xml b/build.xml
-index 8c4e9f5..3d13bf4 100644
---- a/build.xml
-+++ b/build.xml
-@@ -1279,82 +1279,6 @@ See also com.mysql.cj.conf.PropertyDefinitions.SYSP_* variables for other test o
-         </condition>
-         <echo>${com.mysql.cj.testsuite.message.test.mode}</echo>
- 
--        <local name="com.mysql.cj.testsuite.test.coverage" />
--        <condition property="com.mysql.cj.testsuite.test.coverage" value="true" else="false">
--            <isset property="com.mysql.cj.coverage.result.dir.final" />
--        </condition>
--
--        <local name="com.mysql.cj.testsuite.test.coverage.jvmargfinal" />
--        <condition property="com.mysql.cj.testsuite.test.coverage.jvmargfinal"
--                   value="${com.mysql.cj.testsuite.test.coverage.jvmarg}"
--                   else="-Dcoverage=disabled">
--            <and>
--                <isset property="com.mysql.cj.testsuite.test.coverage.jvmarg" />
--                <not>
--                    <equals arg1="${com.mysql.cj.testsuite.test.coverage.jvmarg}" arg2="" />
--                </not>
--            </and>
--        </condition>
--
--        <!-- ant 1.10.10 and above print report summaries to the console from where test counts can be retrieved. -->
--        <antversion property="com.mysql.cj.testsuite.ant.version" atleast="1.10.10" />
--
--        <junitlauncher haltOnFailure="false" printSummary="true" failureProperty="com.mysql.cj.testsuite.junit.fail">
--            <classpath refid="com.mysql.cj.testsuite.build.classpath" />
--
--            <test if="${com.mysql.cj.testsuite.test.methods.enabled}"
--                  name="${com.mysql.cj.testsuite.test.class}"
--                  methods="${com.mysql.cj.testsuite.test.methods}"
--                  outputdir="${com.mysql.cj.testsuite.junit.results}">
--                <fork>
--                    <jvmarg value="-Dfile.encoding=UTF-8" />
--                    <jvmarg value="-Xmx1024m" />
--                    <jvmarg value="${com.mysql.cj.testsuite.test.coverage.jvmargfinal}" />
--                    <syspropertyset refid="junit.system.properties" />
--                </fork>
--                <listener classname="testsuite.JUnitSummary" unless="com.mysql.cj.testsuite.ant.version" />
--                <listener type="legacy-xml" sendSysOut="true" sendSysErr="true" />
--                <listener type="legacy-plain" sendSysOut="true" sendSysErr="true" />
--            </test>
--
--            <test if="com.mysql.cj.testsuite.test.class"
--                  unless="com.mysql.cj.testsuite.test.methods"
--                  name="${com.mysql.cj.testsuite.test.class}"
--                  outputdir="${com.mysql.cj.testsuite.junit.results}">
--                <fork>
--                    <jvmarg value="-Dfile.encoding=UTF-8" />
--                    <jvmarg value="-Xmx1024m" />
--                    <jvmarg value="${com.mysql.cj.testsuite.test.coverage.jvmargfinal}" />
--                    <syspropertyset refid="junit.system.properties" />
--                </fork>
--                <listener classname="testsuite.JUnitSummary" unless="com.mysql.cj.testsuite.ant.version" />
--                <listener type="legacy-xml" sendSysOut="true" sendSysErr="true" />
--                <listener type="legacy-plain" sendSysOut="true" sendSysErr="true" />
--            </test>
--
--            <testclasses unless="com.mysql.cj.testsuite.test.class" outputdir="${com.mysql.cj.testsuite.junit.results}">
--                <fileset dir="${com.mysql.cj.testsuite.build.dir}/${com.mysql.cj.build.driver.fullName}">
--                    <include name="**/*Test.class" />
--                    <exclude name="**/perf/*.class" />
--                </fileset>
--                <fork>
--                    <jvmarg value="-Dfile.encoding=UTF-8" />
--                    <jvmarg value="-Xmx1024m" />
--                    <jvmarg value="${com.mysql.cj.testsuite.test.coverage.jvmargfinal}" />
--                    <syspropertyset refid="junit.system.properties" />
--                </fork>
--                <listener classname="testsuite.JUnitSummary" unless="com.mysql.cj.testsuite.ant.version" />
--                <listener type="legacy-xml" sendSysOut="true" sendSysErr="true" />
--                <listener type="legacy-plain" sendSysOut="true" sendSysErr="true" />
--            </testclasses>
--        </junitlauncher>
--
--        <junitreport todir="${com.mysql.cj.testsuite.junit.results}/report">
--            <fileset dir="${com.mysql.cj.testsuite.junit.results}">
--                <include name="**/TEST-*.xml" />
--            </fileset>
--            <report styledir="${junit.styledir}" format="frames" todir="${com.mysql.cj.testsuite.junit.results}/report" />
--        </junitreport>
- 
-         <!-- Don't fail the build if we're doing coverage test. -->
-         <fail message="Tests failed. Check logs and/or reports in '${com.mysql.cj.testsuite.junit.results}'.">
-@@ -1367,92 +1291,6 @@ See also com.mysql.cj.conf.PropertyDefinitions.SYSP_* variables for other test o
-     </target>
- 
- 
--    <!-- ********************************* -->
--    <!-- ***** TESTING CODE COVERAGE ***** -->
--    <!-- ********************************* -->
--
--
--    <target name="test-coverage" description="Runs tests collecting coverage results." depends="-setup-test-coverage-agent, test" />
--
--
--    <target name="-set-test-coverage-defaults" depends="-extra-libs-check">
--        <condition property="com.mysql.cj.coverage.result.dir.final"
--                   value="${com.mysql.cj.coverage.result.dir}"
--                   else="${com.mysql.cj.testsuite.build.dir}/coverage">
--            <isset property="com.mysql.cj.coverage.result.dir" />
--        </condition>
--        <condition property="com.mysql.cj.coverage.result.name.final" value="${com.mysql.cj.coverage.result.name}" else="jacoco.exec">
--            <isset property="com.mysql.cj.coverage.result.name" />
--        </condition>
--
--        <taskdef uri="antlib:org.jacoco.ant" resource="org/jacoco/ant/antlib.xml">
--            <classpath>
--                <fileset dir="${com.mysql.cj.extra.libs}">
--                    <include name="**/jacocoant.jar" />
--                </fileset>
--            </classpath>
--        </taskdef>
--    </target>
--
--
--    <target name="-setup-test-coverage-agent" depends="-set-test-coverage-defaults">
--        <jacoco:agent destfile="${com.mysql.cj.coverage.result.dir.final}/${com.mysql.cj.coverage.result.name.final}"
--                      property="com.mysql.cj.testsuite.test.coverage.jvmarg" />
--    </target>
--
--
--    <!-- *********************************** -->
--    <!-- ***** REPORTING CODE COVERAGE ***** -->
--    <!-- *********************************** -->
--
--
--    <target name="report-coverage"
--            depends="-set-report-coverage-defaults, -jacoco-merge"
--            description="Merges coverage results and creates HTML coverage report.">
--        <jacoco:report>
--            <executiondata>
--                <file file="${com.mysql.cj.coverage.merge.result.final}" />
--            </executiondata>
--
--            <structure name="Connector/J classes">
--                <classfiles>
--                    <fileset dir="${com.mysql.cj.build.dir.driver}">
--                        <include name="com/mysql/cj/**" />
--                        <exclude name="com/mysql/cj/x/protobuf/**" />
--                    </fileset>
--                </classfiles>
--                <sourcefiles encoding="UTF-8">
--                    <fileset dir="${com.mysql.cj.build.dir.driver}">
--                        <include name="com/mysql/cj/**" />
--                        <exclude name="com/mysql/cj/x/protobuf/**" />
--                    </fileset>
--                </sourcefiles>
--            </structure>
--
--            <html destdir="${com.mysql.cj.coverage.report.dir.final}" />
--        </jacoco:report>
--    </target>
--
--
--    <target name="-jacoco-merge" depends="-set-report-coverage-defaults" if="com.mysql.cj.coverage.merge.files">
--        <jacoco:merge destfile="${com.mysql.cj.coverage.merge.result.final}">
--            <fileset dir="${com.mysql.cj.coverage.result.dir.final}" includes="${com.mysql.cj.coverage.merge.files}" />
--        </jacoco:merge>
--    </target>
--
--
--    <target name="-set-report-coverage-defaults" depends="-set-test-coverage-defaults">
--        <condition property="com.mysql.cj.coverage.merge.result.final"
--                   value="${com.mysql.cj.coverage.merge.result}"
--                   else="${com.mysql.cj.coverage.result.dir.final}/jacoco.exec">
--            <isset property="com.mysql.cj.coverage.merge.result" />
--        </condition>
--        <condition property="com.mysql.cj.coverage.report.dir.final"
--                   value="${com.mysql.cj.coverage.report.dir}"
--                   else="${com.mysql.cj.coverage.result.dir.final}/report">
--            <isset property="com.mysql.cj.coverage.report.dir" />
--        </condition>
--    </target>
- 
- 
-     <!-- ***************************** -->
--- 
-2.48.1
-

diff --git a/0002-Remove-authentication-plugin.patch b/0002-Remove-authentication-plugin.patch
deleted file mode 100644
index 270f72f..0000000
--- a/0002-Remove-authentication-plugin.patch
+++ /dev/null
@@ -1,235 +0,0 @@
-From 47793b89300a19c5fd13b781f03dd580fc0186a6 Mon Sep 17 00:00:00 2001
-From: Ondrej Dubaj <odubaj@redhat.com>
-Date: Tue, 18 Jan 2022 14:58:57 +0100
-Subject: [PATCH] remove AuthenticationOciClient plugin due to missing oracle dependency
-
----
- .../a/NativeAuthenticationProvider.java       |   2 -
- .../AuthenticationOciClient.java              | 177 ------------------
- .../cj/LocalizedErrorMessages.properties      |   6 -
- 3 files changed, 185 deletions(-)
- delete mode 100644 src/main/protocol-impl/java/com/mysql/cj/protocol/a/authentication/AuthenticationOciClient.java
-
-diff --git a/src/main/protocol-impl/java/com/mysql/cj/protocol/a/NativeAuthenticationProvider.java b/src/main/protocol-impl/java/com/mysql/cj/protocol/a/NativeAuthenticationProvider.java
-index 0d94061..58bbf23 100644
---- a/src/main/protocol-impl/java/com/mysql/cj/protocol/a/NativeAuthenticationProvider.java
-+++ b/src/main/protocol-impl/java/com/mysql/cj/protocol/a/NativeAuthenticationProvider.java
-@@ -58,7 +58,6 @@ import com.mysql.cj.protocol.a.NativeConstants.StringSelfDataType;
- import com.mysql.cj.protocol.a.authentication.AuthenticationFidoClient;
- import com.mysql.cj.protocol.a.authentication.AuthenticationKerberosClient;
- import com.mysql.cj.protocol.a.authentication.AuthenticationLdapSaslClientPlugin;
--import com.mysql.cj.protocol.a.authentication.AuthenticationOciClient;
- import com.mysql.cj.protocol.a.authentication.CachingSha2PasswordPlugin;
- import com.mysql.cj.protocol.a.authentication.MysqlClearPasswordPlugin;
- import com.mysql.cj.protocol.a.authentication.MysqlNativePasswordPlugin;
-@@ -256,7 +255,6 @@ public class NativeAuthenticationProvider implements AuthenticationProvider<Nati
-         pluginsToInit.add(new MysqlOldPasswordPlugin());
-         pluginsToInit.add(new AuthenticationLdapSaslClientPlugin());
-         pluginsToInit.add(new AuthenticationKerberosClient());
--        pluginsToInit.add(new AuthenticationOciClient());
-         pluginsToInit.add(new AuthenticationFidoClient());
- 
-         // plugins from authenticationPluginClasses connection parameter
-diff --git a/src/main/protocol-impl/java/com/mysql/cj/protocol/a/authentication/AuthenticationOciClient.java b/src/main/protocol-impl/java/com/mysql/cj/protocol/a/authentication/AuthenticationOciClient.java
-deleted file mode 100644
-index 473e532..0000000
---- a/src/main/protocol-impl/java/com/mysql/cj/protocol/a/authentication/AuthenticationOciClient.java
-+++ /dev/null
-@@ -1,177 +0,0 @@
--/*
-- * Copyright (c) 2021, 2022, Oracle and/or its affiliates.
-- *
-- * This program is free software; you can redistribute it and/or modify it under
-- * the terms of the GNU General Public License, version 2.0, as published by the
-- * Free Software Foundation.
-- *
-- * This program is also distributed with certain software (including but not
-- * limited to OpenSSL) that is licensed under separate terms, as designated in a
-- * particular file or component or in included license documentation. The
-- * authors of MySQL hereby grant you an additional permission to link the
-- * program and your derivative works with the separately licensed software that
-- * they have included with MySQL.
-- *
-- * Without limiting anything contained in the foregoing, this file, which is
-- * part of MySQL Connector/J, is also subject to the Universal FOSS Exception,
-- * version 1.0, a copy of which can be found at
-- * http://oss.oracle.com/licenses/universal-foss-exception.
-- *
-- * This program is distributed in the hope that it will be useful, but WITHOUT
-- * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
-- * FOR A PARTICULAR PURPOSE. See the GNU General Public License, version 2.0,
-- * for more details.
-- *
-- * You should have received a copy of the GNU General Public License along with
-- * this program; if not, write to the Free Software Foundation, Inc.,
-- * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301  USA
-- */
--
--package com.mysql.cj.protocol.a.authentication;
--
--import java.io.IOException;
--import java.nio.charset.Charset;
--import java.nio.file.Files;
--import java.nio.file.Paths;
--import java.security.interfaces.RSAPrivateKey;
--import java.util.Base64;
--import java.util.List;
--
--import com.mysql.cj.Messages;
--import com.mysql.cj.callback.MysqlCallbackHandler;
--import com.mysql.cj.callback.UsernameCallback;
--import com.mysql.cj.conf.PropertyKey;
--import com.mysql.cj.exceptions.ExceptionFactory;
--import com.mysql.cj.exceptions.RSAException;
--import com.mysql.cj.protocol.AuthenticationPlugin;
--import com.mysql.cj.protocol.ExportControlled;
--import com.mysql.cj.protocol.Protocol;
--import com.mysql.cj.protocol.a.NativeConstants.StringSelfDataType;
--import com.mysql.cj.protocol.a.NativePacketPayload;
--import com.mysql.cj.util.StringUtils;
--import com.oracle.bmc.ConfigFileReader;
--import com.oracle.bmc.ConfigFileReader.ConfigFile;
--
--/**
-- * MySQL 'authentication_iam_client' authentication plugin.
-- */
--public class AuthenticationOciClient implements AuthenticationPlugin<NativePacketPayload> {
--    public static String PLUGIN_NAME = "authentication_oci_client";
--
--    private String sourceOfAuthData = PLUGIN_NAME;
--
--    protected Protocol<NativePacketPayload> protocol = null;
--    private MysqlCallbackHandler usernameCallbackHandler = null;
--    private String fingerprint = null;
--    private RSAPrivateKey privateKey = null;
--
--    @Override
--    public void init(Protocol<NativePacketPayload> prot, MysqlCallbackHandler cbh) {
--        this.protocol = prot;
--        this.usernameCallbackHandler = cbh;
--    }
--
--    @Override
--    public void reset() {
--        this.fingerprint = null;
--        this.privateKey = null;
--    }
--
--    @Override
--    public void destroy() {
--        reset();
--        this.protocol = null;
--        this.usernameCallbackHandler = null;
--    }
--
--    @Override
--    public String getProtocolPluginName() {
--        return PLUGIN_NAME;
--    }
--
--    @Override
--    public boolean requiresConfidentiality() {
--        return false;
--    }
--
--    @Override
--    public boolean isReusable() {
--        return false;
--    }
--
--    @Override
--    public void setAuthenticationParameters(String user, String password) {
--        if (user == null && this.usernameCallbackHandler != null) {
--            // Fall back to system login user.
--            this.usernameCallbackHandler.handle(new UsernameCallback(System.getProperty("user.name")));
--        }
--    }
--
--    @Override
--    public void setSourceOfAuthData(String sourceOfAuthData) {
--        this.sourceOfAuthData = sourceOfAuthData;
--    }
--
--    @Override
--    public boolean nextAuthenticationStep(NativePacketPayload fromServer, List<NativePacketPayload> toServer) {
--        toServer.clear();
--
--        if (!this.sourceOfAuthData.equals(PLUGIN_NAME) || fromServer.getPayloadLength() == 0) {
--            // Cannot do anything with whatever payload comes from the server, so just skip this iteration and wait for a Protocol::AuthSwitchRequest or a
--            // Protocol::AuthNextFactor.
--            toServer.add(new NativePacketPayload(0));
--            return true;
--        }
--
--        initializePrivateKey();
--
--        byte[] nonce = fromServer.readBytes(StringSelfDataType.STRING_EOF);
--        byte[] signature = ExportControlled.sign(nonce, this.privateKey);
--        if (signature == null) {
--            signature = new byte[0];
--        }
--        String payload = String.format("{\"fingerprint\":\"%s\", \"signature\":\"%s\"}", this.fingerprint, Base64.getEncoder().encodeToString(signature));
--        toServer.add(new NativePacketPayload(payload.getBytes(Charset.defaultCharset())));
--        return true;
--    }
--
--    private void initializePrivateKey() {
--        if (this.privateKey != null) {
--            // Already initialized.
--            return;
--        }
--
--        ConfigFile configFile;
--        try {
--            String configFilePath = this.protocol.getPropertySet().getStringProperty(PropertyKey.ociConfigFile.getKeyName()).getStringValue();
--            if (StringUtils.isNullOrEmpty(configFilePath)) {
--                configFile = ConfigFileReader.parseDefault();
--            } else if (Files.exists(Paths.get(configFilePath))) {
--                configFile = ConfigFileReader.parse(configFilePath);
--            } else {
--                throw ExceptionFactory.createException("configuration file does not exist");
--            }
--        } catch (NoClassDefFoundError e) {
--            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.SdkNotFound"), e);
--        } catch (IOException e) {
--            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.OciConfigFileError"), e);
--        }
--        this.fingerprint = configFile.get("fingerprint");
--        if (StringUtils.isNullOrEmpty(this.fingerprint)) {
--            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.OciConfigFileMissingEntry"));
--        }
--        String keyFilePath = configFile.get("key_file");
--        if (StringUtils.isNullOrEmpty(keyFilePath)) {
--            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.OciConfigFileMissingEntry"));
--        }
--
--        try {
--            String key = new String(Files.readAllBytes(Paths.get(keyFilePath)), Charset.defaultCharset());
--            this.privateKey = ExportControlled.decodeRSAPrivateKey(key);
--        } catch (IOException e) {
--            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.PrivateKeyNotFound"), e);
--        } catch (RSAException | IllegalArgumentException e) {
--            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.PrivateKeyNotValid"), e);
--        }
--    }
--}
-diff --git a/src/main/resources/com/mysql/cj/LocalizedErrorMessages.properties b/src/main/resources/com/mysql/cj/LocalizedErrorMessages.properties
-index 8a5bfc1..53affc4 100644
---- a/src/main/resources/com/mysql/cj/LocalizedErrorMessages.properties
-+++ b/src/main/resources/com/mysql/cj/LocalizedErrorMessages.properties
-@@ -50,12 +50,6 @@ AuthenticationLdapSaslClientPlugin.MissingLdapServerHostname=An LDAP Server host
- AuthenticationLdapSaslClientPlugin.FailCreateSaslClient=Failed creating a SASL client for the authentication mechanism ''{0}''.
- AuthenticationLdapSaslClientPlugin.ErrProcessingAuthIter=Error while processing an authentication iteration for the authentication mechanism ''{0}''.
- 
--AuthenticationOciClientPlugin.SdkNotFound=The OCI SDK could not be found or is not installed.
--AuthenticationOciClientPlugin.OciConfigFileError=OCI configuration file could not be read.
--AuthenticationOciClientPlugin.OciConfigFileMissingEntry=OCI configuration file does not contain a ''fingerprint'' or ''key_file'' entry.
--AuthenticationOciClientPlugin.PrivateKeyNotFound=Private key could not be found at location given by OCI configuration entry ''key_file''.
--AuthenticationOciClientPlugin.PrivateKeyNotValid=OCI configuration entry ''key_file'' does not reference a valid key file.
--
- AuthenticationProvider.BadAuthenticationPlugin=Unable to load authentication plugin ''{0}''.
- AuthenticationProvider.BadDefaultAuthenticationPlugin=Improper value "{0}" for property ''defaultAuthenticationPlugin''.
- AuthenticationProvider.DefaultAuthenticationPluginIsNotListed=Default authentication plugin "{0}" is neither one of the built-in plugins nor one of the plugins listed in ''authenticationPlugins''.
--- 
-2.48.1
-

diff --git a/0003-Remove-StatementsTest.patch b/0003-Remove-StatementsTest.patch
deleted file mode 100644
index 201a330..0000000
--- a/0003-Remove-StatementsTest.patch
+++ /dev/null
@@ -1,87 +0,0 @@
-From b9a7a929f547d1408c42aca31603d52518f6296b Mon Sep 17 00:00:00 2001
-From: Zuzana Miklankova <zmiklank@redhat.com>
-Date: Tue, 18 Jan 2022 15:04:09 +0100
-Subject: [PATCH] patch
-
----
- .../regression/StatementRegressionTest.java   | 50 -------------------
- 1 file changed, 50 deletions(-)
-
-diff --git a/src/test/java/testsuite/regression/StatementRegressionTest.java b/src/test/java/testsuite/regression/StatementRegressionTest.java
-index 7e5a5f8..8e77de5 100644
---- a/src/test/java/testsuite/regression/StatementRegressionTest.java
-+++ b/src/test/java/testsuite/regression/StatementRegressionTest.java
-@@ -156,7 +156,6 @@ import com.mysql.cj.util.TimeUtil;
- import testsuite.BaseQueryInterceptor;
- import testsuite.BaseTestCase;
- import testsuite.UnreliableSocketFactory;
--import testsuite.simple.StatementsTest;
- 
- /**
-  * Regression tests for the Statement class
-@@ -11607,20 +11606,6 @@ public class StatementRegressionTest extends BaseTestCase {
-         }
-     }
- 
--    /**
--     * Tests fix for Bug#23204652, CURSOR POSITIONING API'S DOESNOT CHECK THE VALIDITY OF RESULTSET.
--     * 
--     * @throws Exception
--     * 
--     * @see StatementsTest#testResultSetProducingQueries()
--     */
--    @Test
--    public void testBug23204652() throws Exception {
--        assertThrows(SQLException.class, "Statement\\.executeQuery\\(\\) cannot issue statements that do not produce result sets\\.", () -> {
--            this.stmt.executeQuery("DO 1 + 2");
--            return null;
--        });
--    }
- 
-     /**
-      * Tests fix for Bug#71929 (18346501), Prefixing query with double comments cancels query DML validation.
-@@ -11648,41 +11633,6 @@ public class StatementRegressionTest extends BaseTestCase {
-         }
-     }
- 
--    /**
--     * Test fix for Bug#103612 (32902019), Incorrectly identified WITH...SELECT as unsafe for read-only connections.
--     * 
--     * @throws Exception
--     * 
--     * @see StatementsTest#testReadOnlySafeStatements()
--     */
--    @Test
--    public void testBug103612() throws Exception {
--        assumeTrue(versionMeetsMinimum(8, 0, 1), "MySQL 8.0.1+ is required to run this test.");
--
--        createTable("testBug103612", "(id INT)");
--        String query = "WITH cte AS (SELECT * FROM testBug103612) SELECT * FROM cte";
--
--        boolean useSPS = false;
--        boolean readOnly = false;
--        do {
--            final String testCase = String.format("Case [SPS: %s, ReadOnly: %s]", useSPS ? "Y" : "N", readOnly ? "Y" : "N");
--
--            Properties props = new Properties();
--            props.setProperty(PropertyKey.useServerPrepStmts.getKeyName(), Boolean.toString(useSPS));
--            Connection testConn = getConnectionWithProps(props);
--            testConn.setReadOnly(readOnly);
--
--            try (Statement testStmt = testConn.createStatement()) {
--                assertTrue(testStmt.execute(query), testCase);
--            }
--            try (PreparedStatement testPstmt = testConn.prepareStatement(query)) {
--                assertTrue(testPstmt.execute(), testCase);
--            }
--
--            testConn.close();
--        } while ((useSPS = !useSPS) || (readOnly = !readOnly));
--    }
--
-     /**
-      * Tests fix for Bug#101389 (32089018), GETWARNINGS SHOULD CHECK WARNING COUNT BEFORE SENDING SHOW.
-      * 
--- 
-2.48.1
-

diff --git a/0004-Port-to-Java-21.patch b/0004-Port-to-Java-21.patch
deleted file mode 100644
index 576594b..0000000
--- a/0004-Port-to-Java-21.patch
+++ /dev/null
@@ -1,42 +0,0 @@
-From 790e9bdb1c73b3695a1bea9d0fccf91341728fc7 Mon Sep 17 00:00:00 2001
-From: rpm-build <rpm-build>
-Date: Fri, 24 Jan 2025 10:09:16 +0100
-Subject: [PATCH 4/4] Port to Java 21
-
----
- build.xml | 12 +-----------
- 1 file changed, 1 insertion(+), 11 deletions(-)
-
-diff --git a/build.xml b/build.xml
-index 3d13bf4..b3437d5 100644
---- a/build.xml
-+++ b/build.xml
-@@ -350,17 +350,6 @@ See also com.mysql.cj.conf.PropertyDefinitions.SYSP_* variables for other test o
-             <arg value="-version" />
-         </exec>
- 
--        <fail message="Java 8 is required. Set the full path to this JDK home with the property 'com.mysql.cj.build.jdk'. Default: '/usr/lib/jvm/jdk1.8').">
--            <condition>
--                <not>
--                    <and>
--                        <equals arg1="${com.mysql.cj.build.jdk.exitStatus}" arg2="0" />
--                        <contains string="${com.mysql.cj.build.jdk.version}" substring="version &quot;1.8" casesensitive="true" />
--                    </and>
--                </not>
--            </condition>
--        </fail>
--
-         <exec executable="${com.mysql.cj.build.jdk.javac}"
-               outputproperty="com.mysql.cj.dist.jdk.compilerVersion"
-               failonerror="true"
-@@ -1054,6 +1043,7 @@ See also com.mysql.cj.conf.PropertyDefinitions.SYSP_* variables for other test o
-                executable="${com.mysql.cj.build.jdk.javac}"
-                compiler="modern"
-                includeantruntime="false"
-+               release="8"
-                encoding="UTF-8">
-             <include name="**/*.java" />
-             <exclude name="testsuite/**" />
--- 
-2.48.1
-

diff --git a/Add-package-tests-target.patch b/Add-package-tests-target.patch
new file mode 100644
index 0000000..2262adc
--- /dev/null
+++ b/Add-package-tests-target.patch
@@ -0,0 +1,37 @@
+From 00430cd6f76ae8d5cf7b9a52a64d922577e00214 Mon Sep 17 00:00:00 2001
+From: Marian Koncek <mkoncek@redhat.com>
+Date: Mon, 10 Aug 2026 12:47:19 +0200
+Subject: [PATCH] Add package-tests target
+
+---
+ build.xml | 14 ++++++++++++++
+ 1 file changed, 14 insertions(+)
+
+diff --git a/build.xml b/build.xml
+index 8ac51fc..d3a830c 100644
+--- a/build.xml
++++ b/build.xml
+@@ -804,6 +804,20 @@ See also com.mysql.cj.conf.PropertyDefinitions.SYSP_* variables for other test o
+             depends="-clean-all, build, -set-no-sources, -make-packages, -remove-sources, -create-archives" />
+ 
+ 
++    <!-- Compile the test suite and package it into a JAR with a classpath file. -->
++    <target name="package-tests"
++            description="Compiles the test suite and creates a tests JAR and a classpath file for running them."
++            depends="-compile-testsuite">
++        <jar jarfile="${com.mysql.cj.build.dir}/${com.mysql.cj.build.driver.extendedName}-tests.jar"
++             basedir="${com.mysql.cj.testsuite.compiler.output}"
++             includes="**/*.class" />
++
++        <pathconvert property="com.mysql.cj.testsuite.run.classpath" refid="com.mysql.cj.extra.libs.classpath" />
++        <echo file="${com.mysql.cj.build.dir}/tests-classpath"
++              message="${com.mysql.cj.testsuite.run.classpath}" />
++    </target>
++
++
+     <!-- Build and install the driver jar into the local maven repository. -->
+     <target name="install" description="Builds and installs the driver jar into the local maven repository." depends="package">
+         <exec executable="mvn" osfamily="unix" failonerror="true" failifexecutionfails="true">
+-- 
+2.54.0
+

diff --git a/Port-to-Java-21.patch b/Port-to-Java-21.patch
new file mode 100644
index 0000000..31f381a
--- /dev/null
+++ b/Port-to-Java-21.patch
@@ -0,0 +1,42 @@
+From 790e9bdb1c73b3695a1bea9d0fccf91341728fc7 Mon Sep 17 00:00:00 2001
+From: rpm-build <rpm-build>
+Date: Fri, 24 Jan 2025 10:09:16 +0100
+Subject: [PATCH 4/4] Port to Java 21
+
+---
+ build.xml | 12 +-----------
+ 1 file changed, 1 insertion(+), 11 deletions(-)
+
+diff --git a/build.xml b/build.xml
+index 9784e9e..8ac51fc 100644
+--- a/build.xml
++++ b/build.xml
+@@ -351,17 +351,6 @@ See also com.mysql.cj.conf.PropertyDefinitions.SYSP_* variables for other test o
+             <arg value="-version" />
+         </exec>
+ 
+-        <fail message="Java 8 is required for compiling the source code. Set the path to the JDK home with the property 'com.mysql.cj.build.jdk'. Default: '/usr/lib/jvm/jdk1.8').">
+-            <condition>
+-                <not>
+-                    <and>
+-                        <equals arg1="${com.mysql.cj.build.jdk.exitStatus}" arg2="0" />
+-                        <contains string="${com.mysql.cj.build.jdk.version}" substring="version &quot;1.8" casesensitive="true" />
+-                    </and>
+-                </not>
+-            </condition>
+-        </fail>
+-
+         <exec executable="${com.mysql.cj.build.jdk.javac}"
+               outputproperty="com.mysql.cj.dist.jdk.compilerVersion"
+               failonerror="true"
+@@ -1052,6 +1041,7 @@ See also com.mysql.cj.conf.PropertyDefinitions.SYSP_* variables for other test o
+                executable="${com.mysql.cj.build.jdk.javac}"
+                compiler="modern"
+                includeantruntime="false"
++               release="8"
+                encoding="UTF-8">
+             <include name="**/*.java" />
+             <exclude name="testsuite/**" />
+-- 
+2.54.0
+

diff --git a/Remove-authentication-plugin.patch b/Remove-authentication-plugin.patch
new file mode 100644
index 0000000..90d0ef8
--- /dev/null
+++ b/Remove-authentication-plugin.patch
@@ -0,0 +1,275 @@
+From 47793b89300a19c5fd13b781f03dd580fc0186a6 Mon Sep 17 00:00:00 2001
+From: Ondrej Dubaj <odubaj@redhat.com>
+Date: Tue, 18 Jan 2022 14:58:57 +0100
+Subject: [PATCH] remove AuthenticationOciClient plugin due to missing oracle dependency
+
+---
+ .../a/NativeAuthenticationProvider.java       |   2 -
+ .../AuthenticationOciClient.java              | 211 ------------------
+ .../cj/LocalizedErrorMessages.properties      |  12 -
+ 3 files changed, 225 deletions(-)
+ delete mode 100644 src/main/protocol-impl/java/com/mysql/cj/protocol/a/authentication/AuthenticationOciClient.java
+
+diff --git a/src/main/protocol-impl/java/com/mysql/cj/protocol/a/NativeAuthenticationProvider.java b/src/main/protocol-impl/java/com/mysql/cj/protocol/a/NativeAuthenticationProvider.java
+index 5d678af..de4183b 100644
+--- a/src/main/protocol-impl/java/com/mysql/cj/protocol/a/NativeAuthenticationProvider.java
++++ b/src/main/protocol-impl/java/com/mysql/cj/protocol/a/NativeAuthenticationProvider.java
+@@ -48,7 +48,6 @@ import com.mysql.cj.protocol.a.NativeConstants.StringLengthDataType;
+ import com.mysql.cj.protocol.a.NativeConstants.StringSelfDataType;
+ import com.mysql.cj.protocol.a.authentication.AuthenticationKerberosClient;
+ import com.mysql.cj.protocol.a.authentication.AuthenticationLdapSaslClientPlugin;
+-import com.mysql.cj.protocol.a.authentication.AuthenticationOciClient;
+ import com.mysql.cj.protocol.a.authentication.AuthenticationOpenidConnectClient;
+ import com.mysql.cj.protocol.a.authentication.AuthenticationWebAuthnClient;
+ import com.mysql.cj.protocol.a.authentication.CachingSha2PasswordPlugin;
+@@ -249,7 +248,6 @@ public class NativeAuthenticationProvider implements AuthenticationProvider<Nati
+         pluginsToInit.add(new MysqlOldPasswordPlugin());
+         pluginsToInit.add(new AuthenticationLdapSaslClientPlugin());
+         pluginsToInit.add(new AuthenticationKerberosClient());
+-        pluginsToInit.add(new AuthenticationOciClient());
+         pluginsToInit.add(new AuthenticationWebAuthnClient());
+         pluginsToInit.add(new AuthenticationOpenidConnectClient());
+ 
+diff --git a/src/main/protocol-impl/java/com/mysql/cj/protocol/a/authentication/AuthenticationOciClient.java b/src/main/protocol-impl/java/com/mysql/cj/protocol/a/authentication/AuthenticationOciClient.java
+deleted file mode 100644
+index 6c8029f..0000000
+--- a/src/main/protocol-impl/java/com/mysql/cj/protocol/a/authentication/AuthenticationOciClient.java
++++ /dev/null
+@@ -1,211 +0,0 @@
+-/*
+- * Copyright (c) 2021, 2026, Oracle and/or its affiliates.
+- *
+- * This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License, version 2.0, as published by
+- * the Free Software Foundation.
+- *
+- * This program is designed to work with certain software that is licensed under separate terms, as designated in a particular file or component or in
+- * included license documentation. The authors of MySQL hereby grant you an additional permission to link the program and your derivative works with the
+- * separately licensed software that they have either included with the program or referenced in the documentation.
+- *
+- * Without limiting anything contained in the foregoing, this file, which is part of MySQL Connector/J, is also subject to the Universal FOSS Exception,
+- * version 1.0, a copy of which can be found at http://oss.oracle.com/licenses/universal-foss-exception.
+- *
+- * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+- * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License, version 2.0, for more details.
+- *
+- * You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc.,
+- * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+- */
+-
+-package com.mysql.cj.protocol.a.authentication;
+-
+-import java.io.IOException;
+-import java.nio.charset.Charset;
+-import java.nio.file.Files;
+-import java.nio.file.Path;
+-import java.nio.file.Paths;
+-import java.security.interfaces.RSAPrivateKey;
+-import java.util.Base64;
+-import java.util.List;
+-
+-import com.mysql.cj.Messages;
+-import com.mysql.cj.callback.MysqlCallbackHandler;
+-import com.mysql.cj.callback.UsernameCallback;
+-import com.mysql.cj.conf.PropertyKey;
+-import com.mysql.cj.exceptions.ExceptionFactory;
+-import com.mysql.cj.exceptions.RSAException;
+-import com.mysql.cj.protocol.AuthenticationPlugin;
+-import com.mysql.cj.protocol.ExportControlled;
+-import com.mysql.cj.protocol.Protocol;
+-import com.mysql.cj.protocol.a.NativeConstants.StringSelfDataType;
+-import com.mysql.cj.protocol.a.NativePacketPayload;
+-import com.mysql.cj.util.StringUtils;
+-import com.oracle.bmc.ConfigFileReader;
+-import com.oracle.bmc.ConfigFileReader.ConfigFile;
+-
+-/**
+- * MySQL 'authentication_iam_client' authentication plugin.
+- */
+-public class AuthenticationOciClient implements AuthenticationPlugin<NativePacketPayload> {
+-
+-    public static String PLUGIN_NAME = "authentication_oci_client";
+-
+-    private String sourceOfAuthData = PLUGIN_NAME;
+-
+-    protected Protocol<NativePacketPayload> protocol = null;
+-    private MysqlCallbackHandler usernameCallbackHandler = null;
+-    private String configFingerprint = null;
+-    private String configKeyFile = null;
+-    private String configSecurityTokenFile = null;
+-    private RSAPrivateKey privateKey = null;
+-    private byte[] token = null;
+-
+-    @Override
+-    public void init(Protocol<NativePacketPayload> prot, MysqlCallbackHandler cbh) {
+-        this.protocol = prot;
+-        this.usernameCallbackHandler = cbh;
+-    }
+-
+-    @Override
+-    public void reset() {
+-        this.configFingerprint = null;
+-        this.privateKey = null;
+-    }
+-
+-    @Override
+-    public void destroy() {
+-        reset();
+-        this.protocol = null;
+-        this.usernameCallbackHandler = null;
+-    }
+-
+-    @Override
+-    public String getProtocolPluginName() {
+-        return PLUGIN_NAME;
+-    }
+-
+-    @Override
+-    public boolean requiresConfidentiality() {
+-        return false;
+-    }
+-
+-    @Override
+-    public boolean isReusable() {
+-        return false;
+-    }
+-
+-    @Override
+-    public void setAuthenticationParameters(String user, String password) {
+-        if (user == null && this.usernameCallbackHandler != null) {
+-            // Fall back to system login user.
+-            this.usernameCallbackHandler.handle(new UsernameCallback(System.getProperty("user.name")));
+-        }
+-    }
+-
+-    @Override
+-    public void setSourceOfAuthData(String sourceOfAuthData) {
+-        this.sourceOfAuthData = sourceOfAuthData;
+-    }
+-
+-    @Override
+-    public boolean nextAuthenticationStep(NativePacketPayload fromServer, List<NativePacketPayload> toServer) {
+-        toServer.clear();
+-
+-        if (!this.sourceOfAuthData.equals(PLUGIN_NAME) || fromServer.getPayloadLength() == 0) {
+-            // Cannot do anything with whatever payload comes from the server, so just skip this iteration and wait for a Protocol::AuthSwitchRequest or a
+-            // Protocol::AuthNextFactor.
+-            toServer.add(new NativePacketPayload(0));
+-            return true;
+-        }
+-
+-        loadOciConfig();
+-        initializePrivateKey();
+-        initializeToken();
+-
+-        byte[] nonce = fromServer.readBytes(StringSelfDataType.STRING_EOF);
+-        byte[] signature = ExportControlled.sign(nonce, this.privateKey);
+-        if (signature == null) {
+-            signature = new byte[0];
+-        }
+-        String payload = String.format("{\"fingerprint\":\"%s\", \"signature\":\"%s\", \"token\":\"%s\"}", this.configFingerprint,
+-                Base64.getEncoder().encodeToString(signature), new String(this.token));
+-        toServer.add(new NativePacketPayload(payload.getBytes(Charset.defaultCharset())));
+-        return true;
+-    }
+-
+-    private void loadOciConfig() {
+-        ConfigFile configFile;
+-        try {
+-            String configFilePath = this.protocol.getPropertySet().getStringProperty(PropertyKey.ociConfigFile.getKeyName()).getStringValue();
+-            String configProfile = this.protocol.getPropertySet().getStringProperty(PropertyKey.ociConfigProfile.getKeyName()).getStringValue();
+-            if (StringUtils.isNullOrEmpty(configFilePath)) {
+-                configFile = ConfigFileReader.parseDefault(configProfile);
+-            } else if (Files.exists(Paths.get(configFilePath))) {
+-                configFile = ConfigFileReader.parse(configFilePath, configProfile);
+-            } else {
+-                throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.ConfigFileNotFound"));
+-            }
+-        } catch (NoClassDefFoundError e) {
+-            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.OciSdkNotFound"), e);
+-        } catch (IOException e) {
+-            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.OciConfigFileError"), e);
+-        } catch (IllegalArgumentException e) {
+-            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.ProfileNotFound"), e);
+-        }
+-
+-        this.configFingerprint = configFile.get("fingerprint");
+-        if (StringUtils.isNullOrEmpty(this.configFingerprint)) {
+-            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.OciConfigFileMissingEntry"));
+-        }
+-        this.configKeyFile = configFile.get("key_file");
+-        if (StringUtils.isNullOrEmpty(this.configKeyFile)) {
+-            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.OciConfigFileMissingEntry"));
+-        }
+-        this.configSecurityTokenFile = configFile.get("security_token_file");
+-    }
+-
+-    private void initializePrivateKey() {
+-        if (this.privateKey != null) {
+-            // Already initialized.
+-            return;
+-        }
+-        try {
+-            Path keyFilePath = Paths.get(this.configKeyFile);
+-            if (Files.notExists(keyFilePath)) {
+-                throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.PrivateKeyNotFound"));
+-            }
+-            String key = new String(Files.readAllBytes(keyFilePath));
+-            this.privateKey = ExportControlled.decodeRSAPrivateKey(key);
+-        } catch (IOException e) {
+-            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.FailedReadingPrivateKey"), e);
+-        } catch (RSAException | IllegalArgumentException e) {
+-            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.PrivateKeyNotValid"), e);
+-        }
+-    }
+-
+-    private void initializeToken() {
+-        if (this.token != null) {
+-            // Already initialized.
+-            return;
+-        }
+-        if (StringUtils.isNullOrEmpty(this.configSecurityTokenFile)) {
+-            this.token = new byte[0];
+-            return;
+-        }
+-        try {
+-            Path securityTokenFilePath = Paths.get(this.configSecurityTokenFile);
+-            if (Files.notExists(securityTokenFilePath)) {
+-                throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.SecurityTokenFileNotFound"));
+-            }
+-            long size = Files.size(securityTokenFilePath);
+-            if (size > 10240) { // Fail if above 10KB.
+-                throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.SecurityTokenTooBig"));
+-            }
+-            this.token = Files.readAllBytes(Paths.get(this.configSecurityTokenFile));
+-        } catch (IOException e) {
+-            throw ExceptionFactory.createException(Messages.getString("AuthenticationOciClientPlugin.FailedReadingSecurityTokenFile"), e);
+-        }
+-    }
+-
+-}
+diff --git a/src/main/resources/com/mysql/cj/LocalizedErrorMessages.properties b/src/main/resources/com/mysql/cj/LocalizedErrorMessages.properties
+index a6ae017..e41afc0 100644
+--- a/src/main/resources/com/mysql/cj/LocalizedErrorMessages.properties
++++ b/src/main/resources/com/mysql/cj/LocalizedErrorMessages.properties
+@@ -42,18 +42,6 @@ AuthenticationOpenidConnect.MissingIdTokenFileOption=A path to a file containing
+ AuthenticationOpenidConnect.FailReadIdTokenFile=Failed reading the OpenID Identity Token file specified in the connection property ''idTokenFile''.
+ AuthenticationOpenidConnect.InvalidIdTokenFile=The file specified in the connection property ''idTokenFile'' contains an invalid OpenID Identity Token.
+ 
+-AuthenticationOciClientPlugin.ConfigFileNotFound=OCI configuration file not found.
+-AuthenticationOciClientPlugin.OciSdkNotFound=The OCI SDK cannot be found or it is not installed.
+-AuthenticationOciClientPlugin.OciConfigFileError=The OCI configuration file cannot be read.
+-AuthenticationOciClientPlugin.ProfileNotFound=The specified profile is not found in the OCI configuration file.
+-AuthenticationOciClientPlugin.OciConfigFileMissingEntry=The OCI configuration file does not contain a ''fingerprint'' or ''key_file'' entry.
+-AuthenticationOciClientPlugin.PrivateKeyNotFound=The private key cannot be found at the location referenced in the OCI configuration entry ''key_file''.
+-AuthenticationOciClientPlugin.FailedReadingPrivateKey=Failed reading the private key file referenced in the OCI configuration entry ''key_file''.
+-AuthenticationOciClientPlugin.PrivateKeyNotValid=The OCI configuration entry ''key_file'' does not reference a valid key file.
+-AuthenticationOciClientPlugin.SecurityTokenFileNotFound=The security token file cannot be found at the location referenced in the OCI configuration entry ''security_token_file''.
+-AuthenticationOciClientPlugin.SecurityTokenTooBig=Invalid security token file. File size above 10 KB.
+-AuthenticationOciClientPlugin.FailedReadingSecurityTokenFile=Failed reading the security token file referenced in the OCI configuration entry ''security_token_file''.
+-
+ AuthenticationProvider.BadAuthenticationPlugin=Unable to load authentication plugin ''{0}''.
+ AuthenticationProvider.BadDefaultAuthenticationPlugin=Improper value "{0}" for property ''defaultAuthenticationPlugin''.
+ AuthenticationProvider.DefaultAuthenticationPluginIsNotListed=Default authentication plugin "{0}" is neither one of the built-in plugins nor one of the plugins listed in ''authenticationPlugins''.
+-- 
+2.54.0
+

diff --git a/Remove-usage-of-io.opentelemetry.api.patch b/Remove-usage-of-io.opentelemetry.api.patch
new file mode 100644
index 0000000..d3890fc
--- /dev/null
+++ b/Remove-usage-of-io.opentelemetry.api.patch
@@ -0,0 +1,42 @@
+From e111e3db9f09a8e9ea6ae0abc5152d7dc0dd0d3b Mon Sep 17 00:00:00 2001
+From: Marian Koncek <mkoncek@redhat.com>
+Date: Wed, 29 Jul 2026 14:48:14 +0200
+Subject: [PATCH] Remove usage of io.opentelemetry.api
+
+---
+ src/main/core-impl/java/com/mysql/cj/NativeSession.java | 5 +----
+ 1 file changed, 1 insertion(+), 4 deletions(-)
+
+diff --git a/src/main/core-impl/java/com/mysql/cj/NativeSession.java b/src/main/core-impl/java/com/mysql/cj/NativeSession.java
+index b05edd6..843708a 100644
+--- a/src/main/core-impl/java/com/mysql/cj/NativeSession.java
++++ b/src/main/core-impl/java/com/mysql/cj/NativeSession.java
+@@ -54,7 +54,6 @@ import com.mysql.cj.exceptions.MysqlErrorNumbers;
+ import com.mysql.cj.exceptions.OperationCancelledException;
+ import com.mysql.cj.interceptors.QueryInterceptor;
+ import com.mysql.cj.log.Log;
+-import com.mysql.cj.otel.OpenTelemetryHandler;
+ import com.mysql.cj.protocol.ColumnDefinition;
+ import com.mysql.cj.protocol.NetworkResources;
+ import com.mysql.cj.protocol.ProtocolEntityFactory;
+@@ -114,7 +113,7 @@ public class NativeSession extends CoreSession implements Serializable {
+         // Check Telemetry option.
+         RuntimeProperty<OpenTelemetry> openTelemetry = this.propertySet.getEnumProperty(PropertyKey.openTelemetry);
+         if (openTelemetry.getValue() == OpenTelemetry.PREFERRED || openTelemetry.getValue() == OpenTelemetry.REQUIRED) {
+-            if (!OpenTelemetryHandler.isOpenTelemetryApiAvailable()) {
++            if (true) {
+                 if (openTelemetry.getValue() == OpenTelemetry.REQUIRED) {
+                     throw ExceptionFactory.createException(Messages.getString("Connection.OtelApiNotFound"));
+                 }
+@@ -122,8 +121,6 @@ public class NativeSession extends CoreSession implements Serializable {
+                     getLog().logInfo(Messages.getString("Connection.OtelApiNotFound"));
+                 }
+                 setTelemetryHandler(NoopTelemetryHandler.getInstance());
+-            } else {
+-                setTelemetryHandler(new OpenTelemetryHandler());
+             }
+         } else {
+             setTelemetryHandler(NoopTelemetryHandler.getInstance());
+-- 
+2.54.0
+

diff --git a/mysql-connector-java.spec b/mysql-connector-java.spec
index 74bd3fb..9ffc5a7 100644
--- a/mysql-connector-java.spec
+++ b/mysql-connector-java.spec
@@ -1,6 +1,6 @@
 Name:           mysql-connector-java
 Epoch:          1
-Version:        8.0.30
+Version:        9.7.0
 Release:        %autorelease
 Summary:        Official JDBC driver for MySQL
 License:        GPL-2.0-only
@@ -9,19 +9,21 @@ BuildArch:      noarch
 ExclusiveArch:  %{java_arches} noarch
 
 # Generated with generate-tarball.sh
-Source0:        %{name}-%{version}-nojars.tar.xz
+Source0:        %{name}-%{version}.tar.zst
 Source1:        generate-tarball.sh
 
-Patch:          0001-Remove-coverage-test.patch
-Patch:          0002-Remove-authentication-plugin.patch
-Patch:          0003-Remove-StatementsTest.patch
-Patch:          0004-Port-to-Java-21.patch
+Patch:          Remove-authentication-plugin.patch
+Patch:          Port-to-Java-21.patch
+Patch:          Remove-usage-of-io.opentelemetry.api.patch
+Patch:          Add-package-tests-target.patch
 
 BuildRequires:  javapackages-local-openjdk25
+BuildRequires:  ant-junit
 BuildRequires:  ant-junit5
 BuildRequires:  javassist
 BuildRequires:  protobuf-java
 BuildRequires:  slf4j
+BuildRequires:  hamcrest
 
 %description
 MySQL Connector/J is a native Java driver that converts JDBC (Java Database
@@ -32,33 +34,51 @@ data, even in a heterogeneous environment. MySQL Connector/J is a Type
 IV JDBC driver and has a complete JDBC feature set that supports the
 capabilities of MySQL.
 
+%package tests
+Summary: Tests for %{name}
+
+%description tests
+This package contains tests for %{name}.
+
 %prep
 %autosetup -p1 -C
 
 # xmlstarlet ed -L -N pom="http://maven.apache.org/POM/4.0.0" -u "/project/version" -v "8.0.33" src/build/misc/pom.xml
 %pom_xpath_set 'pom:project/pom:version' %{version} src/build/misc/pom.xml
 
-# We currently need to disable jboss integration because of missing jboss-common-jdbc-wrapper.jar (built from sources).
-# See BZ#480154 and BZ#471915 for details.
-rm -rf src/main/user-impl/java/com/mysql/cj/jdbc/integration/jboss
-rm src/test/java/testsuite/regression/ConnectionRegressionTest.java
-rm src/test/java/testsuite/regression/DataSourceRegressionTest.java
-rm src/test/java/testsuite/simple/StatementsTest.java
+# Remove usage of 'io.opentelemetry.api'
+rm -rv src/main/core-impl/java/com/mysql/cj/otel
 
 %build
-ant -Dcom.mysql.cj.build.jdk=%{java_home} \
-    -Dcom.mysql.cj.extra.libs=%{_javadir} \
-    test dist
+ant package-no-sources \
+ -Dcom.mysql.cj.build.jdk=%{java_home} \
+ -Dcom.mysql.cj.extra.libs=%{_javadir} \
+ -Dcom.mysql.cj.dist.noMaven=true \
+;
+
+# Compile test suite and create tests JAR + classpath file
+ant package-tests \
+ -Dcom.mysql.cj.build.jdk=%{java_home} \
+ -Dcom.mysql.cj.extra.libs=%{_javadir} \
+ -Dcom.mysql.cj.build.noCleanBetweenCompiles=yes \
+;
 
 %install
-# Install the Maven build information
 %mvn_file mysql:mysql-connector-java %{name}
-%mvn_artifact src/build/misc/pom.xml build/%{name}-%{version}-SNAPSHOT/%{name}-%{version}-SNAPSHOT.jar
+%mvn_artifact build/mysql-connector-j-%{version}-SNAPSHOT/pom.xml build/mysql-connector-j-%{version}-SNAPSHOT/mysql-connector-j-%{version}-SNAPSHOT.jar
 %mvn_install
+install -m 644 -D build/mysql-connector-j-tests.jar %{buildroot}%{_javadir}/%{name}-tests.jar
+install -m 644 -D build/tests-classpath %{buildroot}%{_datadir}/%{name}-tests/classpath
+cp -a src/test/config/ssl-test-certs %{buildroot}%{_datadir}/%{name}-tests/ssl-test-certs
 
 %files -f .mfiles
 %doc CHANGES README README.md
 %license LICENSE
 
+%files tests
+%{_javadir}/%{name}-tests.jar
+%{_datadir}/%{name}-tests
+%license LICENSE
+
 %changelog
 %autochangelog

diff --git a/sources b/sources
index 3e8ac7b..8ef0615 100644
--- a/sources
+++ b/sources
@@ -1 +1 @@
-SHA512 (mysql-connector-java-8.0.30-nojars.tar.xz) = 592cd88f7d2f7daec2513846a4f75d2f8b5bc0acec286c5da56e62cfc5366ed62b8bd5c4a120f41f0e2eae3a1889e1ff237dee80c021d27e732bdf604398442d
+SHA512 (mysql-connector-java-9.7.0.tar.zst) = dd0a5b9ce75745dd67cc19f024b8d360706fdd669d0963c99d0fe4d7e5a69a7b17b2d57e23d02572108d486907ec3b4c5d01cb5f5eaf1436205cba1b9635a356

^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2026-08-17  8:31 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-08-17  8:31 [rpms/mysql-connector-java] f45: Update to upstream version 9.7.0 and add tests subpackage Marian Koncek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox