You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@logging.apache.org by "grobmeier (via GitHub)" <gi...@apache.org> on 2024/12/26 16:56:04 UTC
[PR] Fixes in dev docs (logging-log4j2)
grobmeier opened a new pull request, #3333:
URL: https://github.com/apache/logging-log4j2/pull/3333
Improved writing (active/passive, typos, grammar) for several pages.
FInal checks for MS30: #1867
--
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-unsubscribe@logging.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fixes in dev docs (logging-log4j2)
Posted by "grobmeier (via GitHub)" <gi...@apache.org>.
grobmeier commented on code in PR #3333:
URL: https://github.com/apache/logging-log4j2/pull/3333#discussion_r1898973662
##########
src/site/antora/modules/ROOT/pages/faq.adoc:
##########
@@ -122,15 +122,15 @@ You can set the logging level on the `AppenderRef` element.
. Make sure you have xref:manual/installation.adoc[the right JAR files] on your classpath.
. Check the name of your configuration file.
-By default, Log4j looks for a configuration file named `log4j2.xml` on the classpath.
+Log4j looks for a configuration file named `log4j2.xml` on the classpath by default.
Note the `2` in the file name!
(See xref:manual/configuration.adoc[the Configuration page] for more details.)
. Increase the logging verbosity of the internal xref:manual/status-logger.adoc[]: +
`-Dlog4j2.statusLoggerLevel=TRACE`
. Enable all internal debug logging: `-Dlog4j2.debug`.
-This disables level-based xref:manual/status-logger.adoc[] filtering and effectively allows all status logs.
+This turns-off level-based xref:manual/status-logger.adoc[] filtering and effectively allows all status logs.
Review Comment:
Disabled people will thank us for not using this terminology. We can keep it, but I think it is a negative wording. Please confirm you want to do that.
--
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-unsubscribe@logging.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fixes in dev docs (logging-log4j2)
Posted by "vy (via GitHub)" <gi...@apache.org>.
vy commented on code in PR #3333:
URL: https://github.com/apache/logging-log4j2/pull/3333#discussion_r1898964143
##########
src/site/antora/modules/ROOT/pages/development.adoc:
##########
@@ -73,9 +73,9 @@ See {project-github-url}/FUZZING.adoc[the fuzzing instructions].
[#contributor]
== I am **not** a committer. How shall I submit a patch?
-. Is this a _trivial fix_ such as code or documentation typo?
+. Is this a _trivial fix_ such as a code or documentation typo?
Simply submit a pull request.
-Changelog entry is not needed and make sure `./mvnw verify site` succeeds.
+A Changelog entry is unnecessary. Please ensure that `./mvnw verify site` succeeds.
Review Comment:
```suggestion
A changelog entry is unnecessary. Please ensure that `./mvnw verify site` succeeds.
```
##########
src/site/antora/modules/ROOT/pages/faq.adoc:
##########
@@ -122,15 +122,15 @@ You can set the logging level on the `AppenderRef` element.
. Make sure you have xref:manual/installation.adoc[the right JAR files] on your classpath.
. Check the name of your configuration file.
-By default, Log4j looks for a configuration file named `log4j2.xml` on the classpath.
+Log4j looks for a configuration file named `log4j2.xml` on the classpath by default.
Note the `2` in the file name!
(See xref:manual/configuration.adoc[the Configuration page] for more details.)
. Increase the logging verbosity of the internal xref:manual/status-logger.adoc[]: +
`-Dlog4j2.statusLoggerLevel=TRACE`
. Enable all internal debug logging: `-Dlog4j2.debug`.
-This disables level-based xref:manual/status-logger.adoc[] filtering and effectively allows all status logs.
+This turns-off level-based xref:manual/status-logger.adoc[] filtering and effectively allows all status logs.
Review Comment:
We technically always use `enable` and `disable` to denote activation – I think we should stick to that.
--
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-unsubscribe@logging.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fixes in dev docs (logging-log4j2)
Posted by "jvz (via GitHub)" <gi...@apache.org>.
jvz commented on code in PR #3333:
URL: https://github.com/apache/logging-log4j2/pull/3333#discussion_r1899696967
##########
src/site/antora/modules/ROOT/pages/faq.adoc:
##########
@@ -18,7 +18,7 @@ Licensed to the Apache Software Foundation (ASF) under one or more
= F.A.Q.
This page compiles a list of frequently asked questions.
-If you don't find the answer to your question, please consult to link:{logging-services-url}/support.html[the support page].
+If you don't find the answer to your question, please consult the link:{logging-services-url}/support.html[the support page].
Review Comment:
```suggestion
If you don't find the answer to your question, please consult link:{logging-services-url}/support.html[the support page].
```
"The" is repeated otherwise.
##########
src/site/antora/modules/ROOT/pages/faq.adoc:
##########
@@ -122,15 +122,15 @@ You can set the logging level on the `AppenderRef` element.
. Make sure you have xref:manual/installation.adoc[the right JAR files] on your classpath.
. Check the name of your configuration file.
-By default, Log4j looks for a configuration file named `log4j2.xml` on the classpath.
+Log4j looks for a configuration file named `log4j2.xml` on the classpath by default.
Note the `2` in the file name!
(See xref:manual/configuration.adoc[the Configuration page] for more details.)
. Increase the logging verbosity of the internal xref:manual/status-logger.adoc[]: +
`-Dlog4j2.statusLoggerLevel=TRACE`
. Enable all internal debug logging: `-Dlog4j2.debug`.
-This disables level-based xref:manual/status-logger.adoc[] filtering and effectively allows all status logs.
+This turns-off level-based xref:manual/status-logger.adoc[] filtering and effectively allows all status logs.
Review Comment:
How about "This allows for all kinds of status log messages to be written" or something like that.
##########
src/site/antora/modules/ROOT/pages/development.adoc:
##########
@@ -87,32 +87,32 @@ Pitch it in a {logging-services-url}/support.html#discussions-maintainer[maintai
Go ahead and push it.
. Otherwise, submit a pull request.
-Make sure a changelog entry is attached and `./mvnw verify site` succeeds.
+Ensure a changelog entry is attached and `./mvnw verify site` succeeds.
+
[TIP]
====
-You are strongly advised to spar with another maintainer first (see {logging-services-url}/support.html#discussions-maintainer[maintainer discussion channels]) before starting to code.
+We strongly advise you to spar with another maintainer first (see {logging-services-url}/support.html#discussions-maintainer[maintainer discussion channels]) before starting to code.
Review Comment:
Is "spar" the right term here? I only know that in context of practice martial arts fights (and apparently it's some part of a ship). I might go with something like "discuss" here.
##########
src/site/antora/modules/ROOT/pages/development.adoc:
##########
@@ -54,7 +54,7 @@ The following branching scheme is followed:
`<sourceBranch>-site-<environment>`::
`<sourceBranch>-site-<environment>-out`::
Branches used to serve the staging and production websites.
-`out`-suffixed ones are automatically populated by CI, you are not supposed to touch them.
+CI automatically populates `out`-suffixed ones; you are not supposed to touch them.
Review Comment:
```suggestion
CI automatically populates `out`-suffixed branch names; you are not supposed to touch them.
```
--
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-unsubscribe@logging.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fixes in dev docs (logging-log4j2)
Posted by "ppkarwasz (via GitHub)" <gi...@apache.org>.
ppkarwasz commented on code in PR #3333:
URL: https://github.com/apache/logging-log4j2/pull/3333#discussion_r1899114288
##########
src/site/antora/modules/ROOT/pages/faq.adoc:
##########
@@ -97,8 +97,8 @@ You can set the logging level on the `AppenderRef` element.
<Configuration xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns="https://logging.apache.org/xml/ns"
xsi:schemaLocation="
- https://logging.apache.org/xml/ns
- https://logging.apache.org/xml/ns/log4j-config-2.xsd">
+ https://logging.apache.org/xml/ns
+ https://logging.apache.org/xml/ns/log4j-config-2.xsd">
Review Comment:
I prefer the previous indentation.
##########
src/site/antora/modules/ROOT/pages/faq.adoc:
##########
@@ -142,20 +142,20 @@ You can use xref:manual/appenders/delegating.adoc#RoutingAppender[the routing ap
Log4j API and SLF4J have a lot in common.
They both share the objective of cleanly separating the logging API from the implementation.
-We believe that Log4j API can help make your application more performant while offering more functionality and more flexibility.
+Log4j API can help make your application more performant while offering more functionality and flexibility.
-There may be a concern that using the Log4j API will tightly couple your application to Log4j.
+There may be a concern that the Log4j API will tightly couple your application to Log4j.
This is not the case: applications coded to Log4j API always have the option to use any SLF4J-compliant logging implementation with the `log4j-to-slf4j` bridge.
See xref:manual/installation.adoc[the Installation page] for details.
There are several advantages to using Log4j API:
* SLF4J forces your application to log ``String``s.
Log4j API supports logging any `CharSequence` if you want to log text, but also supports logging any `Object` as is.
-It is the responsibility of the logging _implementation_ to handle this object, and we consider it a design mistake to limit applications to logging ``String``s.
+The logging _implementation_ is responsible for handling this object, and we consider it a design mistake to limit applications to logging ``Strings``.
Review Comment:
```suggestion
The logging _implementation_ is responsible for handling this object, and we consider it a design mistake to limit applications to logging ``String``s.
```
I prefer not to modify the name of classes.
##########
src/site/antora/modules/ROOT/pages/development.adoc:
##########
@@ -87,32 +87,32 @@ Pitch it in a {logging-services-url}/support.html#discussions-maintainer[maintai
Go ahead and push it.
. Otherwise, submit a pull request.
-Make sure a changelog entry is attached and `./mvnw verify site` succeeds.
+Ensure a changelog entry is attached and `./mvnw verify site` succeeds.
+
[TIP]
====
-You are strongly advised to spar with another maintainer first (see {logging-services-url}/support.html#discussions-maintainer[maintainer discussion channels]) before starting to code.
+We strongly advise you to spar with another maintainer first (see {logging-services-url}/support.html#discussions-maintainer[maintainer discussion channels]) before starting to code.
====
[#release-project]
== I am a PMC member. How do I make a new release?
All Maven-based Logging Services projects are parented by
{logging-services-url}/logging-parent/index.html[Logging Parent],
-which streamlines several project-wide processes, including making a new release.
+streamlining several project-wide processes, including making a new release.
See {logging-services-url}/logging-parent/release-instructions-project.html[its release instructions for projects].
[#release-xml-schema]
== I am a PMC member. How do I publish a new XML schema?
All Maven-based Logging Services projects are parented by
{logging-services-url}/logging-parent/index.html[Logging Parent],
-which streamlines several project-wide processes, including publishing XML schemas.
+streamlining several project-wide processes, including publishing XML schemas.
See {logging-services-url}/logging-parent/release-instructions-xml-schema.html[its release instructions for XML schemas].
[WARNING]
====
**Projects and XML schemas have different lifecycles!**
-A new release of a project does not necessarily mean a new release of its XML schemas.
-XML schemas might have been untouched, or they might contain minor changes while the project itself contains breaking changes, etc.
+A project's new release does not necessarily mean a new release of its XML schemas.
Review Comment:
```suggestion
A new project release does not necessarily mean a new release of its XML schemas.
```
##########
src/site/antora/modules/ROOT/pages/faq.adoc:
##########
@@ -181,25 +181,25 @@ It creates a new message object for each call.
== How do I log my domain object without creating garbage?
One option is to let the domain object implement `CharSequence`.
-However, for many domain objects it may not be trivial to implement this without allocating temporary objects.
+However, for many domain objects, it may not be trivial to implement this without allocating temporary objects.
-An alternative is to implement the `org.apache.logging.log4j.util.StringBuilderFormattable` interface.
-If an object is logged that implements this interface, its `formatTo(StringBuilder)` method is called instead of `toString()`.
+An alternative is implementing the `org.apache.logging.log4j.util.StringBuilderFormattable` interface.
+If an object that implements this interface is logged, its `formatTo(StringBuilder)` method is called instead of `toString().`
[#logger-wrapper]
== How do I create a custom logger wrapper that shows the correct class, method, and line number?
-Log4j remembers the fully qualified class name (FQCN) of the logger and uses this to walk the stack trace for every log event when configured to print location.
+Log4j remembers the logger's fully qualified class name (FQCN) and uses this to walk the stack trace for every log event when configured to print location.
[WARNING]
====
Be aware that logging with location is slow and may impact the performance of your application.
====
-The problem with custom logger wrappers is that they have a different FQCN than the actual logger, so Log4j can't find the place where your custom logger was called.
+The problem with custom logger wrappers is that they have a different FQCN than the actual logger, so Log4j can't find where your custom logger was called.
The solution is to provide the correct FQCN.
-The easiest way to do this is to let Log4j generate the logger wrapper for you.
+The easiest way is to let Log4j generate the logger wrapper for you.
Log4j comes with a Logger wrapper generator tool.
This tool was originally meant to support custom log levels and was moved to the
{logging-services-url}/log4j/transform/latest/index.html[Log4j Transform subproject].
Review Comment:
The tool was removed from Log4j Transform too, should we remove this paragraph?
--
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-unsubscribe@logging.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fixes in dev docs (logging-log4j2)
Posted by "ppkarwasz (via GitHub)" <gi...@apache.org>.
ppkarwasz commented on code in PR #3333:
URL: https://github.com/apache/logging-log4j2/pull/3333#discussion_r1899113958
##########
src/site/antora/modules/ROOT/pages/faq.adoc:
##########
@@ -122,15 +122,15 @@ You can set the logging level on the `AppenderRef` element.
. Make sure you have xref:manual/installation.adoc[the right JAR files] on your classpath.
. Check the name of your configuration file.
-By default, Log4j looks for a configuration file named `log4j2.xml` on the classpath.
+Log4j looks for a configuration file named `log4j2.xml` on the classpath by default.
Note the `2` in the file name!
(See xref:manual/configuration.adoc[the Configuration page] for more details.)
. Increase the logging verbosity of the internal xref:manual/status-logger.adoc[]: +
`-Dlog4j2.statusLoggerLevel=TRACE`
. Enable all internal debug logging: `-Dlog4j2.debug`.
-This disables level-based xref:manual/status-logger.adoc[] filtering and effectively allows all status logs.
+This turns-off level-based xref:manual/status-logger.adoc[] filtering and effectively allows all status logs.
Review Comment:
> Disabled people will thank us for not using this terminology.
You mean "people with disabilities" :wink:? I don't think anybody thinks about physical disabilities, when reading a technical documentation, but if we are going to ban the `disable` verb, we should do it in the entire documentation.
--
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-unsubscribe@logging.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fixes in dev docs (logging-log4j2)
Posted by "vy (via GitHub)" <gi...@apache.org>.
vy commented on code in PR #3333:
URL: https://github.com/apache/logging-log4j2/pull/3333#discussion_r1899185445
##########
src/site/antora/modules/ROOT/pages/faq.adoc:
##########
@@ -181,25 +181,25 @@ It creates a new message object for each call.
== How do I log my domain object without creating garbage?
One option is to let the domain object implement `CharSequence`.
-However, for many domain objects it may not be trivial to implement this without allocating temporary objects.
+However, for many domain objects, it may not be trivial to implement this without allocating temporary objects.
-An alternative is to implement the `org.apache.logging.log4j.util.StringBuilderFormattable` interface.
-If an object is logged that implements this interface, its `formatTo(StringBuilder)` method is called instead of `toString()`.
+An alternative is implementing the `org.apache.logging.log4j.util.StringBuilderFormattable` interface.
+If an object that implements this interface is logged, its `formatTo(StringBuilder)` method is called instead of `toString().`
[#logger-wrapper]
== How do I create a custom logger wrapper that shows the correct class, method, and line number?
-Log4j remembers the fully qualified class name (FQCN) of the logger and uses this to walk the stack trace for every log event when configured to print location.
+Log4j remembers the logger's fully qualified class name (FQCN) and uses this to walk the stack trace for every log event when configured to print location.
[WARNING]
====
Be aware that logging with location is slow and may impact the performance of your application.
====
-The problem with custom logger wrappers is that they have a different FQCN than the actual logger, so Log4j can't find the place where your custom logger was called.
+The problem with custom logger wrappers is that they have a different FQCN than the actual logger, so Log4j can't find where your custom logger was called.
The solution is to provide the correct FQCN.
-The easiest way to do this is to let Log4j generate the logger wrapper for you.
+The easiest way is to let Log4j generate the logger wrapper for you.
Log4j comes with a Logger wrapper generator tool.
This tool was originally meant to support custom log levels and was moved to the
{logging-services-url}/log4j/transform/latest/index.html[Log4j Transform subproject].
Review Comment:
@ppkarwasz, good catch, yes, we should.
--
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-unsubscribe@logging.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] Fixes in dev docs (logging-log4j2)
Posted by "vy (via GitHub)" <gi...@apache.org>.
vy commented on code in PR #3333:
URL: https://github.com/apache/logging-log4j2/pull/3333#discussion_r1899185371
##########
src/site/antora/modules/ROOT/pages/faq.adoc:
##########
@@ -122,15 +122,15 @@ You can set the logging level on the `AppenderRef` element.
. Make sure you have xref:manual/installation.adoc[the right JAR files] on your classpath.
. Check the name of your configuration file.
-By default, Log4j looks for a configuration file named `log4j2.xml` on the classpath.
+Log4j looks for a configuration file named `log4j2.xml` on the classpath by default.
Note the `2` in the file name!
(See xref:manual/configuration.adoc[the Configuration page] for more details.)
. Increase the logging verbosity of the internal xref:manual/status-logger.adoc[]: +
`-Dlog4j2.statusLoggerLevel=TRACE`
. Enable all internal debug logging: `-Dlog4j2.debug`.
-This disables level-based xref:manual/status-logger.adoc[] filtering and effectively allows all status logs.
+This turns-off level-based xref:manual/status-logger.adoc[] filtering and effectively allows all status logs.
Review Comment:
> Please confirm you want to do that.
@grobmeier, I confirm that *I prefer* replacing `turns-off` with `disables`. Though I leave it to your discretion.
--
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-unsubscribe@logging.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org