diff --git a/src/common/codeine/db/mysql/DbUtils.java b/src/common/codeine/db/mysql/DbUtils.java index bcbe290b..9188f08a 100755 --- a/src/common/codeine/db/mysql/DbUtils.java +++ b/src/common/codeine/db/mysql/DbUtils.java @@ -154,7 +154,12 @@ private Connection getConnection(boolean useCompression) { String mysqlAddress = hostSelector.mysql().host() + ":" + hostSelector.mysql().port(); String jdbcUrl = "jdbc:mysql://" + mysqlAddress + "/" + MysqlConstants.DB_NAME + "?useCompression=true"; try { - return getDBConnection(jdbcUrl, hostSelector.mysql()); + if (globalConfigurationJsonStore.get().large_deployment()) { + return DriverManager + .getConnection(jdbcUrl, hostSelector.mysql().user(), hostSelector.mysql().password()); + } else { + return getDBConnection(jdbcUrl, hostSelector.mysql()); + } } catch (SQLException e) { throw new ConnectToDatabaseException(jdbcUrl, e); }