ppkarwasz commented on code in PR #2619: URL: https://github.com/apache/logging-log4j2/pull/2619#discussion_r1615917938
########## src/site/antora/modules/ROOT/pages/manual/simple-logger.adoc: ########## @@ -0,0 +1,29 @@ +//// + 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. +//// + += Simple Logger + +Even though Log4j Core is the reference implementation of xref:manual/api.adoc[Log4j API], Log4j API itself also provides a very minimalist implementation: link:../javadoc/log4j-api/org/apache/logging/log4j/simple/SimpleLogger.html[`SimpleLogger`]. +This is a convenience for environments where either a fully-fledged logging implementation is missing, or cannot be included for other reasons. +`SimpleLogger` is the default Log4j API implementation if no other is available in the classpath. + +[#config] +== Configuration + +`SimpleLogger` can be configured using the following system properties: + +include::partial$manual/systemproperties/properties-simple-logger.adoc[leveloffset=+1] Review Comment: There are two components of `SimpleLogger` configuration: * the configuration of `SimpleLogger`, * the configuration of `ThreadContextMap`. Currently the latter is common with `log4j-core`, but there is no reason for it to be this way. For example if `log4j2.simpleLogShowContextMap` is set to `false` (default), the `ThreadContextMap` should probably be a no-op. ########## src/site/antora/modules/ROOT/pages/manual/api.adoc: ########## @@ -220,7 +221,25 @@ link:../javadoc/log4j-api/org/apache/logging/log4j/LogManager.html[`EventLogger` xref:manual/eventlogging.adoc[Read more on event loggers...] -[#feature-fluent-api] +[#simple-logger] +=== Simple logger + +Even though Log4j Core is the reference implementation of Log4j API, Log4j API itself also provides a very minimalist implementation: _Simple Logger_. +This is a convenience for environments where either a fully-fledged logging implementation is missing, or cannot be included for other reasons. +`SimpleLogger` is the default Log4j API implementation if no other is available in the classpath. Review Comment: Maybe I would say it is the "fallback" Log4j API implementation, since unlike other implementations a warning is always logged, whenever it is used. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: notifications-unsubscr...@logging.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org