From ea4540095fa470284bc1ed28b0e7c2d0cd54c7b0 Mon Sep 17 00:00:00 2001 From: Abel Salgado Romero Date: Sat, 2 Nov 2024 17:04:33 +0100 Subject: [PATCH] Unify loggers to be static (#971) --- CHANGELOG.adoc | 6 +++++- .../maven/site/AsciidoctorConverterDoxiaParser.java | 2 +- .../maven/site/parser/AsciidoctorAstDoxiaParser.java | 2 +- .../maven/site/parser/processors/NoOpNodeProcessor.java | 2 +- .../maven/site/parser/processors/SectionNodeProcessor.java | 2 +- 5 files changed, 9 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.adoc b/CHANGELOG.adoc index e3d9698b..f9ccdbcf 100644 --- a/CHANGELOG.adoc +++ b/CHANGELOG.adoc @@ -15,7 +15,11 @@ For a detailed view of what has changed, refer to the {uri-repo}/commits/main[co Bug Fixes (Site Modules):: -* Fix resolution of baseDir for Doxia modules (#968) + * Fix resolution of baseDir for Doxia modules (#968) + +Improvements (Site Modules):: + + * Unify loggers initialization to be static (#) == v3.1.0 (2024-10-30) diff --git a/asciidoctor-converter-doxia-module/src/main/java/org/asciidoctor/maven/site/AsciidoctorConverterDoxiaParser.java b/asciidoctor-converter-doxia-module/src/main/java/org/asciidoctor/maven/site/AsciidoctorConverterDoxiaParser.java index cb564948..e334ad3d 100644 --- a/asciidoctor-converter-doxia-module/src/main/java/org/asciidoctor/maven/site/AsciidoctorConverterDoxiaParser.java +++ b/asciidoctor-converter-doxia-module/src/main/java/org/asciidoctor/maven/site/AsciidoctorConverterDoxiaParser.java @@ -43,7 +43,7 @@ @Component(role = Parser.class, hint = AsciidoctorConverterDoxiaParser.ROLE_HINT) public class AsciidoctorConverterDoxiaParser extends AbstractTextParser { - private final Logger logger = LoggerFactory.getLogger(AsciidoctorConverterDoxiaParser.class); + private static final Logger logger = LoggerFactory.getLogger(AsciidoctorConverterDoxiaParser.class); @Inject protected Provider mavenProjectProvider; diff --git a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java index d3fe9434..bc0602ce 100644 --- a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java +++ b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/AsciidoctorAstDoxiaParser.java @@ -48,7 +48,7 @@ @Component(role = Parser.class, hint = AsciidoctorAstDoxiaParser.ROLE_HINT) public class AsciidoctorAstDoxiaParser extends AbstractTextParser { - private final org.slf4j.Logger logger = LoggerFactory.getLogger(AsciidoctorAstDoxiaParser.class); + private static final org.slf4j.Logger logger = LoggerFactory.getLogger(AsciidoctorAstDoxiaParser.class); @Inject protected Provider mavenProjectProvider; diff --git a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/NoOpNodeProcessor.java b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/NoOpNodeProcessor.java index 8aa8fc8e..56a09e9e 100644 --- a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/NoOpNodeProcessor.java +++ b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/NoOpNodeProcessor.java @@ -14,7 +14,7 @@ */ public class NoOpNodeProcessor extends AbstractSinkNodeProcessor implements NodeProcessor { - private final org.slf4j.Logger logger = LoggerFactory.getLogger(AsciidoctorAstDoxiaParser.class); + private static final org.slf4j.Logger logger = LoggerFactory.getLogger(NoOpNodeProcessor.class); /** * Constructor. diff --git a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/SectionNodeProcessor.java b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/SectionNodeProcessor.java index 7fc224ec..d24e589d 100644 --- a/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/SectionNodeProcessor.java +++ b/asciidoctor-parser-doxia-module/src/main/java/org/asciidoctor/maven/site/parser/processors/SectionNodeProcessor.java @@ -21,7 +21,7 @@ */ public class SectionNodeProcessor extends AbstractSinkNodeProcessor implements NodeProcessor { - private final Logger logger = LoggerFactory.getLogger(SectionNodeProcessor.class); + private static final Logger logger = LoggerFactory.getLogger(SectionNodeProcessor.class); /** * Constructor.