Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 1 addition & 17 deletions api/src/org/labkey/api/data/DbScope.java
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
import jakarta.servlet.ServletContext;
import jakarta.servlet.ServletException;
import org.apache.commons.collections4.IteratorUtils;
import org.apache.commons.lang3.StringUtils;
import org.apache.commons.lang3.Strings;
import org.apache.logging.log4j.Level;
import org.apache.logging.log4j.Logger;
Expand Down Expand Up @@ -609,7 +608,7 @@ private static LabKeyDataSource setPrimaryDataSource(Map<String, LabKeyDataSourc
LOG.info(
"Initializing DbScope with the following configuration:" +
"\n DataSource Name: " + getDbScopeLoader().getDsName() +
"\n Server URL: " + filterUrl(dbmd.getURL()) +
"\n Server URL: " + dbmd.getURL() +
"\n Database Name: " + _databaseName +
"\n Database Product Name: " + _databaseProductName +
"\n Database Product Version: " + (null != _dialect ? _dialect.getProductVersion(_databaseProductVersion) : _databaseProductVersion) +
Expand All @@ -633,21 +632,6 @@ private static LabKeyDataSource setPrimaryDataSource(Map<String, LabKeyDataSourc
}
}

// MariaDB driver adds username and password to the URL. This masks the password so we don't log it.
private String filterUrl(String url)
{
int start = url.indexOf("password=");
if (start != -1)
{
start = start + 9;
int end = url.indexOf('&', start);
if (end == -1)
end = url.length();
url = url.substring(0, start) + StringUtils.repeat('?', end - start) + url.substring(end);
}
return url;
}

private String determineDriverLocation(Class<Driver> driverClass)
{
try
Expand Down
1 change: 1 addition & 0 deletions api/src/org/labkey/api/data/dialect/sqlKeywords.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1134,6 +1134,7 @@ tinyblob
tinyint
tinytext
to
to_date
token
top
top_level_count
Expand Down
Loading