Skip to content

Commit 9a10103

Browse files
committed
Update version and add connection test query
The version of MYSQL-Api in pom.xml is updated from 5.7.5 to 5.7.6. Additionally, a connection test query is added in MYSQL.java to test the validity of a connection by executing a query that most probably be valid on the database. These changes ensure project dependencies are up to date and increase the robustness of the database connection handling.
1 parent f0199c1 commit 9a10103

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
<groupId>de.goldendeveloper</groupId>
77
<artifactId>MYSQL-Api</artifactId>
8-
<version>5.7.5</version>
8+
<version>5.7.6</version>
99
<packaging>jar</packaging>
1010
<url>https://github.com/Golden-Developer/MYSQL-Api</url>
1111

src/main/java/de/goldendeveloper/mysql/MYSQL.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -409,6 +409,7 @@ private void createConnectionConfig() {
409409
config.setLeakDetectionThreshold(TimeUnit.SECONDS.toMillis(60));
410410
config.setUsername(this.username);
411411
config.setPassword(this.password);
412+
config.setConnectionTestQuery("SELECT 1");
412413
try {
413414
this.ds = new HikariDataSource(config);
414415
} catch (Exception e) {

0 commit comments

Comments
 (0)