13
0
geforkt von Mirrors/Paper

Fix ugly java logger format for paper plugin dependency loader (#9395)

Dieser Commit ist enthalten in:
powercas_gamer 2023-06-25 09:57:45 +02:00
Ursprung ec0be3fbf2
Commit 9696b46122

Datei anzeigen

@ -784,12 +784,12 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+import org.eclipse.aether.transfer.TransferEvent;
+import org.eclipse.aether.transport.http.HttpTransporterFactory;
+import org.jetbrains.annotations.NotNull;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+import java.io.File;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.logging.Level;
+import java.util.logging.Logger;
+
+/**
+ * The maven library resolver acts as a resolver for yet to be resolved jar libraries that may be pulled from a
@ -810,7 +810,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+ */
+public class MavenLibraryResolver implements ClassPathLibrary {
+
+ private static final Logger logger = Logger.getLogger("MavenLibraryResolver");
+ private static final Logger logger = LoggerFactory.getLogger("MavenLibraryResolver");
+
+ private final RepositorySystem repository;
+ private final DefaultRepositorySystemSession session;
@ -838,7 +838,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+ this.session.setTransferListener(new AbstractTransferListener() {
+ @Override
+ public void transferInitiated(@NotNull TransferEvent event) throws TransferCancelledException {
+ logger.log(Level.INFO, "Downloading {0}", event.getResource().getRepositoryUrl() + event.getResource().getResourceName());
+ logger.info("Downloading {}", event.getResource().getRepositoryUrl() + event.getResource().getResourceName());
+ }
+ });
+ this.session.setReadOnly();