Skip to content

Commit

Permalink
Add log line in console when system property 'jdbc.drivers' has non-e…
Browse files Browse the repository at this point in the history
…mpty value
  • Loading branch information
jan-at-the-hyve committed Nov 1, 2022
1 parent 512a076 commit 93d25ed
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ public static void main(String[] args) {

// If dbType.BIGQUERY: domain field has been replaced with database field
public static Connection connect(String server, String domain, String user, String password, DbType dbType) {
if (System.getProperty("jdbc.drivers") != null && !System.getProperty("jdbc.drivers").equals("")) {
System.out.println("The following jdbc drivers will be loaded because they are set in system property 'jdbc.drivers': '" + System.getProperty("jdbc.drivers") + "'");
}
if (dbType.equals(DbType.MYSQL))
return DBConnector.connectToMySQL(server, user, password);
else if (dbType.equals(DbType.MSSQL) || dbType.equals(DbType.PDW) || dbType.equals(DbType.AZURE))
Expand Down

0 comments on commit 93d25ed

Please sign in to comment.