Updated MySQL connector to 8.x
This commit is contained in:
1 parent
c92b9317de
commit
967856ce57
3 files changed
+99
-3
No files matched your search
@@ -1,9 +1,10 @@
|
||||
package netneutrality.db;
|
||||
|
||||
import com.mysql.cj.jdbc.MysqlConnectionPoolDataSource;
|
||||
|
||||
import java.sql.Connection;
|
||||
import java.sql.SQLException;
|
||||
|
||||
import com.mysql.jdbc.jdbc2.optional.MysqlConnectionPoolDataSource;
|
||||
|
||||
public class MysqlConnector {
|
||||
|
||||
@@ -34,7 +35,7 @@ public class MysqlConnector {
|
||||
dataSource.setPort(3306);
|
||||
dataSource.setDatabaseName(dbName);
|
||||
dataSource.setAutoReconnect(true);
|
||||
dataSource.setAutoReconnectForConnectionPools(true);
|
||||
dataSource.setAutoReconnectForPools(true);
|
||||
c = dataSource.getConnection();
|
||||
return this;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user