Skip to content

Commit

Permalink
fix format
Browse files Browse the repository at this point in the history
  • Loading branch information
StrikeW committed Jun 13, 2024
1 parent 55809f2 commit 4af7455
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@

public abstract class JdbcUtils {

static final int CONNECTION_TIMEOUT = 30;
static final int SOCKET_TIMEOUT = 300;

public static Optional<JdbcDialectFactory> getDialectFactory(String jdbcUrl) {
if (jdbcUrl.startsWith("jdbc:mysql")) {
return Optional.of(new MySqlDialectFactory());
Expand All @@ -45,8 +48,6 @@ public static Connection getConnection(String jdbcUrl) throws SQLException {
props.setProperty("tcpKeepAlive", "true");

// default timeout in seconds
final int CONNECTION_TIMEOUT = 30;
final int SOCKET_TIMEOUT = 300;
boolean isPg = jdbcUrl.startsWith("jdbc:postgresql");

// postgres use seconds and mysql use milliseconds
Expand Down

0 comments on commit 4af7455

Please sign in to comment.