From 4c9b45e6ebacb226b0c7330b89d4825b1fb6c7a7 Mon Sep 17 00:00:00 2001 From: "Lukas Rieger (Blue)" Date: Thu, 18 Aug 2022 18:06:55 +0200 Subject: [PATCH] Fix sql-config-template, remove debug-log and add map-id to cli-filewatcher output --- .../bluemap/common/plugin/RegionFileWatchService.java | 2 +- .../de/bluecolored/bluemap/config/storages/sql.conf | 6 +++--- .../de/bluecolored/bluemap/core/storage/sql/SQLStorage.java | 2 -- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/BlueMapCommon/src/main/java/de/bluecolored/bluemap/common/plugin/RegionFileWatchService.java b/BlueMapCommon/src/main/java/de/bluecolored/bluemap/common/plugin/RegionFileWatchService.java index 857552ac..681264de 100644 --- a/BlueMapCommon/src/main/java/de/bluecolored/bluemap/common/plugin/RegionFileWatchService.java +++ b/BlueMapCommon/src/main/java/de/bluecolored/bluemap/common/plugin/RegionFileWatchService.java @@ -125,7 +125,7 @@ public void run() { scheduledUpdates.remove(regionPos); renderManager.scheduleRenderTask(task); - if (verbose) Logger.global.logInfo("Scheduled update for region-file: " + regionPos); + if (verbose) Logger.global.logInfo("Scheduled update for region-file: " + regionPos + " (Map: " + map.getId() + ")"); } } }; diff --git a/BlueMapCommon/src/main/resources/de/bluecolored/bluemap/config/storages/sql.conf b/BlueMapCommon/src/main/resources/de/bluecolored/bluemap/config/storages/sql.conf index 28a763c7..6dc368f5 100644 --- a/BlueMapCommon/src/main/resources/de/bluecolored/bluemap/config/storages/sql.conf +++ b/BlueMapCommon/src/main/resources/de/bluecolored/bluemap/config/storages/sql.conf @@ -11,9 +11,9 @@ storage-type: SQL # The JDBC-Connection URL that is used to connect to the database. # The format for this url is usually something like: jdbc:[driver]://[host]:[port]/[database]?user=[user]&password=[password] # The exact format of the url is determined by the JDBC-Driver you are using. -db-connection-url: "jdbc:mysql://localhost/bluemap?permitMysqlScheme" -#db-connection-url: "jdbc:mariadb://localhost/bluemap?user=root" -#db-connection-url: "jdbc:mysql://localhost:3306/bluemap?user=root&password=password" +connection-url: "jdbc:mysql://localhost/bluemap?permitMysqlScheme" +#connection-url: "jdbc:mariadb://localhost/bluemap?user=root" +#connection-url: "jdbc:mysql://localhost:3306/bluemap?user=root&password=password" # This can be used to load a custom jdbc-driver from a .jar file. # E.g. if your runtime-environment is not already providing the sql-driver you need, diff --git a/BlueMapCore/src/main/java/de/bluecolored/bluemap/core/storage/sql/SQLStorage.java b/BlueMapCore/src/main/java/de/bluecolored/bluemap/core/storage/sql/SQLStorage.java index b1a40a73..65e01baf 100644 --- a/BlueMapCore/src/main/java/de/bluecolored/bluemap/core/storage/sql/SQLStorage.java +++ b/BlueMapCore/src/main/java/de/bluecolored/bluemap/core/storage/sql/SQLStorage.java @@ -622,12 +622,10 @@ private int lookupFK(String table, String idField, String valueField, String val } private DataSource createDataSource(String dbUrl) { - Logger.global.logInfo("Creating datasource for: " + dbUrl); return createDataSource(new DriverManagerConnectionFactory(dbUrl)); } private DataSource createDataSource(String dbUrl, Driver driver) { - Logger.global.logInfo("Creating driver-datasource for: " + dbUrl); ConnectionFactory connectionFactory = new DriverConnectionFactory( driver, dbUrl,