Skip to content

Commit

Permalink
Merge branch 'release/3.3.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
rusher committed Nov 6, 2023
2 parents 706016b + 7ef158f commit d9b3688
Show file tree
Hide file tree
Showing 351 changed files with 4,036 additions and 3,373 deletions.
14 changes: 4 additions & 10 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ language: java
services:
- docker
- mysql
jdk: openjdk11
jdk: openjdk17
addons:
hosts:
- mariadb.example.com
Expand Down Expand Up @@ -48,8 +48,6 @@ jobs:
- env: srv=build
- env: srv=xpand TEST_DB_OTHER="&initSql=SET NAMES UTF8"
- env: srv=mariadb-es local=1
- env: srv=skysql
- env: srv=skysql-ha
include:
- stage: Minimal
env: srv=mariadb v=10.6 packet=8
Expand All @@ -75,10 +73,6 @@ jobs:
name: "Maxscale"
- env: srv=xpand TEST_DB_OTHER="&initSql=SET NAMES UTF8"
name: "Xpand"
- env: srv=skysql
name: "SkySQL"
- env: srv=skysql-ha
name: "SkySQL with replication"

- stage: Community
env: srv=mariadb v=10.6
Expand All @@ -99,11 +93,11 @@ jobs:
name: "CS 10.11"
- env: srv=mariadb v=11.0 local=1
name: "CS 11.0"
- env: srv=mariadb v=11.1-rc local=1
- env: srv=mariadb v=11.1 local=1
name: "CS 11.1"
- env: srv=mariadb v=10.6 packet=40
jdk: openjdk17
name: "CS 10.6 - openjdk 17"
jdk: openjdk11
name: "CS 10.6 - openjdk 11"
- env: srv=mariadb v=10.6 packet=8
name: "CS 10.6 - packet 8M"
- env: srv=mariadb v=10.6 local=1 BENCH=1
Expand Down
678 changes: 443 additions & 235 deletions CHANGELOG.md

Large diffs are not rendered by default.

73 changes: 43 additions & 30 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,70 +1,80 @@
# Contributing

Each pull request should address a single issue, and contain both the fix and a description of how the pull request and tests that validate that the PR fixes the issue in question.
Each pull request should address a single issue, and contain both the fix and a description of how the pull request and
tests that validate that the PR fixes the issue in question.

For significant feature additions, we like to have an open issue in [MariaDB JIRA](https://mariadb.atlassian.net/secure/RapidBoard.jspa?projectKey=CONJ). It is expected that discussion will have taken place in the attached issue.
For significant feature additions, we like to have an open issue
in [MariaDB JIRA](https://mariadb.atlassian.net/secure/RapidBoard.jspa?projectKey=CONJ). It is expected that discussion
will have taken place in the attached issue.

# Install Prerequisites

These are the set of tools which are required in order to complete any build. Follow the links to download and install them on your own before continuing.
These are the set of tools which are required in order to complete any build. Follow the links to download and install
them on your own before continuing.

* At least one GPG Key see https://help.github.com/en/articles/generating-a-new-gpg-key
* [Oracle JDK 8](http://www.oracle.com/technetwork/java/javase/downloads/index.html) ( with [JCE policies](http://www.oracle.com/technetwork/java/javase/downloads/jce8-download-2133166.html) if using TLS/SSL)
* [Oracle JDK 8](http://www.oracle.com/technetwork/java/javase/downloads/index.html) (
with [JCE policies](http://www.oracle.com/technetwork/java/javase/downloads/jce8-download-2133166.html) if using
TLS/SSL)
* IDE (eclipse / netbean / intelliJ) with maven and GIT plugins

# Fork source

Before downloading source, fork the project to your own repository, and use your repository as source.
Before downloading source, fork the project to your own repository, and use your repository as source.

## Branch signification

* master : correspond to the last released version
* develop : Develop new features for upcoming releases (compatible with java 8)
* develop-jre6 : maintenance branch compatible with java 6 / 7
* develop-jre6 : maintenance branch compatible with java 6 / 7

# Run local test

Before any submission :
Run the test locally : by default, you need to have a MySQL/MariaDB server on localhost:3306 with a database named "testj" and a user root without password.
so you can run

Run the test locally : by default, you need to have a MySQL/MariaDB server on localhost:3306 with a database named "
testj" and a user root without password.
so you can run

```script
mvn test
mvn test
```
You can change this parameter by adding -DdbUrl parameter. like :

You can change this parameter by adding -DdbUrl parameter. like :

```script
mvn test -DdbUrl=jdbc:mariadb://127.0.0.1:3306/testj?user=root&password=*****
mvn test -DdbUrl=jdbc:mariadb://127.0.0.1:3306/testj?user=root&password=*****
```

You can launch a specific test by adding -Dtest

```script
mvn test -Dtest=org.mariadb.jdbc.JdbcParserTest
mvn test -Dtest=org.mariadb.jdbc.JdbcParserTest
```

When all test are passing, you can package project.
Additional tests , like javadoc formatting, code style validation will be done :
Additional tests , like javadoc formatting, code style validation will be done :

```script
mvn package -Dmaven.test.skip=true
mvn package -Dmaven.test.skip=true
```

If operation succeed, a new mariadb-java-client jar will be on the target folder.

# Run travis test

You can activate travis to validate your repository.
The advantage of travis compare to running test locally is that it will launch tests for a combination of those parameters :

You can activate travis to validate your repository.
The advantage of travis compare to running test locally is that it will launch tests for a combination of those
parameters :

jdk:

* oraclejdk8
and if your work is on develop-jre6 branch
and if your work is on develop-jre6 branch
* openjdk6
* openjdk7

server :

* MariaDB 5.5
* MariaDB 10.0
* MariaDB 10.1
Expand All @@ -73,17 +83,20 @@ server :
* MySQL 5.7

max_allowed_packet : (this permit to check multipacket send)

* 8M
* 20M
* 40M

For that, you have to go on [travis website](https://travis-ci.org), connect with your github account, and activate your mariadb-connector-j repository.
After this step, every push to your repository will launch a travis test.
For that, you have to go on [travis website](https://travis-ci.org), connect with your github account, and activate your
mariadb-connector-j repository.
After this step, every push to your repository will launch a travis test.

## Submitting a request

When your repository has the correction/change done, you can submit a pull request by clicking the "Pull request" button on github.
Please detail the operation done in your request.
When your repository has the correction/change done, you can submit a pull request by clicking the "Pull request" button
on github.
Please detail the operation done in your request.

## License

Expand Down
44 changes: 24 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,18 @@
<p align="center">
<a href="https://mariadb.com/">
<img src="https://mariadb.com/kb/static/images/logo-2018-black.png">
</a>
<p style="text-align: center;">
<a href="https://mariadb.com/">
<img alt="mariadb logo" src="https://mariadb.com/kb/static/images/logo-2018-black.png">
</a>
</p>

# MariaDB java connector

MariaDB java connector is a JDBC 4.2 compatible driver, used to connect applications developed in Java to MariaDB and MySQL databases. MariaDB Connector/J is LGPL licensed.
MariaDB java connector is a JDBC 4.2 compatible driver, used to connect applications developed in Java to MariaDB and
MySQL databases. MariaDB Connector/J is LGPL licensed.

Tracker link <a href="https://jira.mariadb.org/projects/CONJ/issues/">https://jira.mariadb.org/projects/CONJ/issues/</a>

## Status

[![Linux Build](https://travis-ci.com/mariadb-corporation/mariadb-connector-j.svg?branch=master)](https://app.travis-ci.com/github/mariadb-corporation/mariadb-connector-j)
[![Maven Central](https://maven-badges.herokuapp.com/maven-central/org.mariadb.jdbc/mariadb-java-client/badge.svg)](https://maven-badges.herokuapp.com/maven-central/org.mariadb.jdbc/mariadb-java-client)
[![License (LGPL version 2.1)](https://img.shields.io/badge/license-GNU%20LGPL%20version%202.1-green.svg?style=flat-square)](http://opensource.org/licenses/LGPL-2.1)
Expand All @@ -21,43 +23,45 @@ Tracker link <a href="https://jira.mariadb.org/projects/CONJ/issues/">https://ji
For java 8+ :

The driver (jar) can be downloaded from [mariadb connector download](https://mariadb.com/downloads/#connectors)
or maven :
or maven :

```script
<dependency>
<groupId>org.mariadb.jdbc</groupId>
<artifactId>mariadb-java-client</artifactId>
<version>3.2.0</version>
<version>3.3.0</version>
</dependency>
```


Development snapshot are available on sonatype nexus repository

```script
<repositories>
<repository>
<id>sonatype-nexus-snapshots</id>
<name>Sonatype Nexus Snapshots</name>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
</repository>
<repository>
<id>sonatype-nexus-snapshots</id>
<name>Sonatype Nexus Snapshots</name>
<url>https://oss.sonatype.org/content/repositories/snapshots</url>
</repository>
</repositories>
<dependencies>
<dependency>
<groupId>org.mariadb.jdbc</groupId>
<artifactId>mariadb-java-client</artifactId>
<version>3.2.1-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.mariadb.jdbc</groupId>
<artifactId>mariadb-java-client</artifactId>
<version>3.4.0-SNAPSHOT</version>
</dependency>
</dependencies>
```

## Documentation

For a Getting started guide, API docs, recipes, etc. see the
For a Getting started guide, API docs, recipes, etc. see the

* [About MariaDB connector/J](https://mariadb.com/kb/en/about-mariadb-connector-j/)
* [Install driver](https://mariadb.com/kb/en/installing-mariadb-connectorj/)
* [Changelog](/CHANGELOG.md)
* [Failover and high-availability](https://mariadb.com/kb/en/failover-and-high-availability-with-mariadb-connector-j/)


[codecov-image]:https://codecov.io/gh/mariadb-corporation/mariadb-connector-j/branch/master/graph/badge.svg

[codecov-url]:https://codecov.io/gh/mariadb-corporation/mariadb-connector-j
2 changes: 1 addition & 1 deletion bnd.bnd
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
Export-Package: org.mariadb.jdbc;org.mariadb.jdbc.client;org.mariadb.jdbc.client.util;org.mariadb.jdbc.client.socket;org.mariadb.jdbc.message;org.mariadb.jdbc.type;org.mariadb.jdbc.export;org.mariadb.jdbc.plugin;org.mariadb.jdbc.plugin.codec;org.mariadb.jdbc.plugin.authentication.standard;org.mariadb.jdbc.plugin.authentication.addon;org.mariadb.jdbc.plugin.credential.aws;org.mariadb.jdbc.plugin.credential.env;org.mariadb.jdbc.plugin.credential.system;org.mariadb.jdbc.plugin.tls.main
Export-Package: org.mariadb.jdbc;org.mariadb.jdbc.client;org.mariadb.jdbc.client.util;org.mariadb.jdbc.util.constants;org.mariadb.jdbc.client.socket;org.mariadb.jdbc.message;org.mariadb.jdbc.type;org.mariadb.jdbc.export;org.mariadb.jdbc.plugin;org.mariadb.jdbc.plugin.codec;org.mariadb.jdbc.plugin.authentication.standard;org.mariadb.jdbc.plugin.authentication.addon;org.mariadb.jdbc.plugin.credential.aws;org.mariadb.jdbc.plugin.credential.env;org.mariadb.jdbc.plugin.credential.system;org.mariadb.jdbc.plugin.tls.main

Import-Package: \
javax.naming,\
Expand Down
3 changes: 3 additions & 0 deletions licenseheader.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
// SPDX-License-Identifier: LGPL-2.1-or-later
// Copyright (c) 2012-2014 Monty Program Ab
// Copyright (c) 2015-2023 MariaDB Corporation Ab
78 changes: 56 additions & 22 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,24 +7,25 @@
<artifactId>mariadb-java-client</artifactId>
<packaging>jar</packaging>
<name>mariadb-java-client</name>
<version>3.2.0</version>
<version>3.3.0</version>
<description>JDBC driver for MariaDB and MySQL</description>
<url>https://mariadb.com/kb/en/mariadb/about-mariadb-connector-j/</url>

<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<jmh.version>1.34</jmh.version>
<jmh.version>1.37</jmh.version>
<junit.version>5.8.2</junit.version>
<junit-pioneer.version>1.5.0</junit-pioneer.version>
<assertj.version>3.22.0</assertj.version>
<osgi.version>6.0.0</osgi.version>
<osgi.compendium.version>5.0.0</osgi.compendium.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<logback.version>1.4.4</logback.version>
<jacoco.version>0.8.8</jacoco.version>
<waffle-jna.version>3.2.0</waffle-jna.version>
<mysql-connector-java.version>8.0.31</mysql-connector-java.version>
<jacoco.version>0.8.10</jacoco.version>
<waffle-jna.version>3.3.0</waffle-jna.version>
<mysql-connector-java.version>8.1.0</mysql-connector-java.version>
<bnd-maven-plugin.version>6.3.1</bnd-maven-plugin.version>
<spotless.version>2.40.0</spotless.version>
</properties>

<licenses>
Expand Down Expand Up @@ -79,7 +80,7 @@
<dependency>
<groupId>software.amazon.awssdk</groupId>
<artifactId>bom</artifactId>
<version>2.18.10</version>
<version>2.21.1</version>
<type>pom</type>
<scope>import</scope>
</dependency>
Expand Down Expand Up @@ -231,24 +232,53 @@
</execution>
</executions>
</plugin>

<plugin>
<groupId>com.coveo</groupId>
<artifactId>fmt-maven-plugin</artifactId>
<version>2.13</version>
<executions>
<execution>
<goals>
<goal>format</goal>
</goals>
</execution>
</executions>
<groupId>com.diffplug.spotless</groupId>
<artifactId>spotless-maven-plugin</artifactId>
<version>${spotless.version}</version>
<configuration>
<!-- optional: limit format enforcement to just the files changed by this feature branch -->
<!-- <ratchetFrom>origin/src</ratchetFrom>-->
<formats>
<!-- you can define as many formats as you want, each is independent -->
<format>
<!-- define the files to apply to -->
<includes>
<include>*.md</include>
<include>.gitignore</include>
</includes>
<!-- define the steps to apply to those files -->
<trimTrailingWhitespace/>
<endWithNewline/>
<indent>
<tabs>true</tabs>
<spacesPerTab>2</spacesPerTab>
</indent>
</format>
</formats>
<java>
<excludes>
<exclude>src/main/java/org/mariadb/jdbc/plugin/authentication/standard/ed25519/**/*.java
</exclude>
<exclude>src/main/java/org/mariadb/jdbc/client/socket/impl/UnixDomainSocket.java</exclude>
</excludes>
<googleJavaFormat>
<version>1.18.1</version>
<style>GOOGLE</style>
<reflowLongStrings>true</reflowLongStrings>
<formatJavadoc>true</formatJavadoc>
<groupArtifact>com.google.googlejavaformat:google-java-format</groupArtifact>
</googleJavaFormat>
<licenseHeader>
<file>${project.basedir}/licenseheader.txt</file>
</licenseHeader>
</java>
</configuration>
</plugin>

<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.0.0-M7</version>
<version>3.1.2</version>
</plugin>

<plugin>
Expand Down Expand Up @@ -390,11 +420,15 @@
</dependency>

<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<groupId>com.mysql</groupId>
<artifactId>mysql-connector-j</artifactId>
<version>${mysql-connector-java.version}</version>
</dependency>

<dependency>
<groupId>com.zaxxer</groupId>
<artifactId>HikariCP</artifactId>
<version>5.0.1</version>
</dependency>
</dependencies>

<build>
Expand Down

0 comments on commit d9b3688

Please sign in to comment.