diff --git a/maven-embedder/src/site/apt/logging.apt b/maven-embedder/src/site/apt/logging.apt index 7ff312909f5a..3793ba762312 100644 --- a/maven-embedder/src/site/apt/logging.apt +++ b/maven-embedder/src/site/apt/logging.apt @@ -25,7 +25,7 @@ Maven Logging - End-user logging documentation is available {{{/maven-logging.html}in Maven site}}. + {{{/maven-logging.html}End-user logging documentation}} is available {{{/maven-logging.html}in Maven site}}. This documentation is focused on internal implementation details. * Logging API @@ -48,7 +48,7 @@ Maven Logging * Logging Implementation - Maven 3.1.0 ships bundled with {{{http://www.slf4j.org/apidocs/org/slf4j/impl/SimpleLogger.html}SLF4J simple logger}}, + Maven 3.1.0 ships bundled with {{{https://www.slf4j.org/api/org/slf4j/simple/SimpleLogger.html}SLF4J simple logger}} and since 3.5.0 {{{../maven-slf4j-provider/}Maven-customized <<>>}}, but is ready to use other logging implementations: SLF4J is responsible for loading the implementation, referred to as {{{http://www.slf4j.org/manual.html#swapping}"SLF4J bindings"}}. @@ -62,6 +62,8 @@ Maven Logging {{{./apidocs/org/apache/maven/cli/logging/Slf4jConfigurationFactory.html}Slf4jConfigurationFactory}} / {{{./apidocs/org/apache/maven/cli/logging/Slf4jConfiguration.html}Slf4jConfiguration}}. +~~ TODO document META-INF/maven/slf4j-configuration.properties + * Getting Logger Instance Starting with Maven 3.1.0, SLF4J Logger can be used directly. This technique can be used safely in Maven core @@ -79,14 +81,7 @@ public class MyClass * Logger Name - Before Maven 3.1.0, with logging implementation done in Maven, logger name wasn't used by basic console logging implementation: - they are as-is, without clear convention on when to pass logger from class to class or when to create a new logger. - - Starting with Maven 3.1.0, logging implementation can be of greatest use if logger names are well defined. This definition still - needs to be defined and implemented: - - * classical "class name" pattern? - - * Maven-specific name hierarchy? + Logger name is basically the classical fully qualified class name: it's not visible by default, but can be activated (see {{{/maven-logging.html}user documentation}}). - * a mix (some with class name, some with Maven-specific hierarchy)? + Notice that before Maven 3.1.0, with logger created by Maven, some code used to pass logger from class to class because it could not create a new logger: + discrepencies between logger name and actual class may happen. diff --git a/maven-slf4j-provider/src/site/apt/index.apt b/maven-slf4j-provider/src/site/apt/index.apt new file mode 100644 index 000000000000..802632a9c027 --- /dev/null +++ b/maven-slf4j-provider/src/site/apt/index.apt @@ -0,0 +1,35 @@ +~~ Licensed to the Apache Software Foundation (ASF) under one +~~ or more contributor license agreements. See the NOTICE file +~~ distributed with this work for additional information +~~ regarding copyright ownership. The ASF licenses this file +~~ to you under the Apache License, Version 2.0 (the +~~ "License"); you may not use this file except in compliance +~~ with the License. You may obtain a copy of the License at +~~ +~~ http://www.apache.org/licenses/LICENSE-2.0 +~~ +~~ Unless required by applicable law or agreed to in writing, +~~ software distributed under the License is distributed on an +~~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +~~ KIND, either express or implied. See the License for the +~~ specific language governing permissions and limitations +~~ under the License. + + ----- + About + ----- + Hervé Boutemy + ----- + 2023-06-19 + ----- + +Maven SLF4J Provider + + An extension to {{{https://www.slf4j.org/api/org/slf4j/simple/SimpleLogger.html}SLF4J Simple}} to add enhanced color support. + + Color is managed by <<>>, created by <<>>, and injected by <<>>: everything else is + copied at build time from {{{https://www.slf4j.org/api/org/slf4j/simple/SimpleLogger.html}SLF4J Simple}} + +* See Also + + * {{{../maven-embedder/logging.html}Maven Logging}}