From c6962ef4d2450c7350b76d82a8f0180f373b53ed Mon Sep 17 00:00:00 2001 From: N0tMyFaultOG Date: Mon, 13 Jul 2020 19:56:34 +0200 Subject: [PATCH] Shift a few more messages to debug --- Bukkit/pom.xml | 6 ++++++ .../src/main/java/com/plotsquared/bukkit/BukkitMain.java | 2 +- Core/pom.xml | 6 ++++++ .../java/com/plotsquared/core/util/SchematicHandler.java | 9 ++++----- .../java/com/plotsquared/core/uuid/UUIDPipeline.java | 4 ++-- 5 files changed, 19 insertions(+), 8 deletions(-) diff --git a/Bukkit/pom.xml b/Bukkit/pom.xml index d01f91307..fa9ecf402 100644 --- a/Bukkit/pom.xml +++ b/Bukkit/pom.xml @@ -78,6 +78,12 @@ + + org.slf4j + slf4j-jdk14 + 2.0.0-alpha1 + compile + com.sk89q.worldedit worldedit-core diff --git a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitMain.java b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitMain.java index 780c36326..1c9588b90 100644 --- a/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitMain.java +++ b/Bukkit/src/main/java/com/plotsquared/bukkit/BukkitMain.java @@ -536,7 +536,7 @@ public final class BukkitMain extends JavaPlugin implements Listener, IPlotMain< uuidList.clear(); // Print progress final double percentage = ((double) read / (double) totalSize) * 100.0D; - logger.info("(UUID) PlotSquared has cached {} of UUIDs", String.format("%.1f%%", percentage)); + logger.debug("(UUID) PlotSquared has cached {} of UUIDs", String.format("%.1f%%", percentage)); } catch (final InterruptedException | ExecutionException e) { logger.error("(UUID) Failed to retrieve last batch. Will try again", e); e.printStackTrace(); diff --git a/Core/pom.xml b/Core/pom.xml index d69f10a99..3a66b7985 100644 --- a/Core/pom.xml +++ b/Core/pom.xml @@ -98,6 +98,12 @@ 1.7.0-SNAPSHOT runtime + + org.slf4j + slf4j-api + 2.0.0-alpha1 + runtime + junit junit diff --git a/Core/src/main/java/com/plotsquared/core/util/SchematicHandler.java b/Core/src/main/java/com/plotsquared/core/util/SchematicHandler.java index c4fee2dbe..d16ecbe7b 100644 --- a/Core/src/main/java/com/plotsquared/core/util/SchematicHandler.java +++ b/Core/src/main/java/com/plotsquared/core/util/SchematicHandler.java @@ -152,17 +152,16 @@ public abstract class SchematicHandler { SchematicHandler.manager.getCompoundTag(plot, new RunnableVal() { @Override public void run(final CompoundTag value) { if (value == null) { - MainUtil.sendMessage(null, "&7 - Skipped plot &c" + plot.getId()); + logger.debug("Skipped plot {}", plot.getId()); } else { TaskManager.runTaskAsync(() -> { - MainUtil.sendMessage(null, "&6ID: " + plot.getId()); + logger.debug("ID: {}", plot.getId()); boolean result = SchematicHandler.manager .save(value, directory + File.separator + name + ".schem"); if (!result) { - MainUtil - .sendMessage(null, "&7 - Failed to save &c" + plot.getId()); + logger.error("Failed to save {}", plot.getId()); } else { - MainUtil.sendMessage(null, "&7 - &a success: " + plot.getId()); + logger.debug("success: {}", plot.getId()); } TaskManager.runTask(THIS); }); diff --git a/Core/src/main/java/com/plotsquared/core/uuid/UUIDPipeline.java b/Core/src/main/java/com/plotsquared/core/uuid/UUIDPipeline.java index fc03f7326..88dfaeb11 100644 --- a/Core/src/main/java/com/plotsquared/core/uuid/UUIDPipeline.java +++ b/Core/src/main/java/com/plotsquared/core/uuid/UUIDPipeline.java @@ -325,7 +325,7 @@ public class UUIDPipeline { this.consume(mappings); return mappings; } else if (Settings.DEBUG) { - logger.debug("Failed to find all usernames"); + logger.debug("(UUID) Failed to find all usernames"); } if (Settings.UUID.UNKNOWN_AS_DEFAULT) { @@ -388,7 +388,7 @@ public class UUIDPipeline { this.consume(mappings); return mappings; } else if (Settings.DEBUG) { - logger.debug("Failed to find all UUIDs"); + logger.debug("(UUID) Failed to find all UUIDs"); } throw new ServiceError("End of pipeline");