You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@logging.apache.org by "i-make-robots (via GitHub)" <gi...@apache.org> on 2025/06/30 20:06:55 UTC
[D] Log4j creates an empty log file and refuses to fill it? [logging-log4j2]
GitHub user i-make-robots created a discussion: Log4j creates an empty log file and refuses to fill it?
Hello, everyone. I hope you're doing well.
My Java 22 open source project is https://github.com/MarginallyClever/Makelangelo-software/.
I'm using logback and log4j with a rolling file appender. My config file is https://github.com/MarginallyClever/Makelangelo-software/blob/master/src/main/resources/logback.xml
I then use JPackage to distribute my app with all the dependencies baked into a fat jar.
In short, for MOST people the log file appears and fills normally.
For a select number of users the log file appears but stays empty. They have been gracious enough to try running the JAR from the command line but we've seen no extra console messages.
Running in administrator mode doesn't help.
Immediate flushing doesn't help.
Adding a logback status listener (logback-status.log) also doesn't appear for those tricky users.
Can someone please give me a hint what I'm doing wrong?
GitHub link: https://github.com/apache/logging-log4j2/discussions/3793
----
This is an automatically sent email for dev@logging.apache.org.
To unsubscribe, please send an email to: dev-unsubscribe@logging.apache.org
Re: [D] Log4j creates an empty log file and refuses to fill it? [logging-log4j2]
Posted by "ppkarwasz (via GitHub)" <gi...@apache.org>.
GitHub user ppkarwasz added a comment to the discussion: Log4j creates an empty log file and refuses to fill it?
Hi @i-make-robots,
> My Java 22 open source project is [https://github.com/MarginallyClever/Makelangelo-software/](https://github.com/MarginallyClever/Makelangelo-software/). I'm using logback and log4j with a rolling file appender.
After reviewing your repository, it appears that the project uses [SLF4J](http://www.slf4j.org/) as the logging API and [Logback](https://github.com/qos-ch/logback) as the underlying implementation. It doesn't use neither the [Log4j 2 API](https://logging.apache.org/log4j/2.x/manual/api.html) nor its [Log4j Core implementation](https://logging.apache.org/log4j/2.x/manual/implementation.html).
Since your setup is based on Logback rather than Log4j 2, you'd likely get more relevant support by posting your question in the [Logback Discussions](https://github.com/qos-ch/logback/discussions) page.
Hope this helps!
GitHub link: https://github.com/apache/logging-log4j2/discussions/3793#discussioncomment-13632248
----
This is an automatically sent email for dev@logging.apache.org.
To unsubscribe, please send an email to: dev-unsubscribe@logging.apache.org
Re: [D] Log4j creates an empty log file and refuses to fill it? [logging-log4j2]
Posted by "i-make-robots (via GitHub)" <gi...@apache.org>.
GitHub user i-make-robots added a comment to the discussion: Log4j creates an empty log file and refuses to fill it?
Whoops.Sent from my iPhoneOn Jul 1, 2025, at 11:54 AM, Piotr P. Karwasz ***@***.***> wrote:
Hi @i-make-robots,
My Java 22 open source project is https://github.com/MarginallyClever/Makelangelo-software/. I'm using logback and log4j with a rolling file appender.
After reviewing your repository, it appears that the project uses SLF4J as the logging API and Logback as the underlying implementation. It doesn't use neither the Log4j 2 API nor its Log4j Core implementation.
Since your setup is based on Logback rather than Log4j 2, you'd likely get more relevant support by posting your question in the Logback Discussions page.
Hope this helps!
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you were mentioned.Message ID: ***@***.***>
GitHub link: https://github.com/apache/logging-log4j2/discussions/3793#discussioncomment-13636074
----
This is an automatically sent email for dev@logging.apache.org.
To unsubscribe, please send an email to: dev-unsubscribe@logging.apache.org
Re: [D] Log4j creates an empty log file and refuses to fill it? [logging-log4j2]
Posted by "i-make-robots (via GitHub)" <gi...@apache.org>.
GitHub user i-make-robots edited a discussion: Log4j creates an empty log file and refuses to fill it?
Hello, everyone. I hope you're doing well.
My Java 22 open source project is https://github.com/MarginallyClever/Makelangelo-software/.
I'm using logback and log4j with a rolling file appender. My config file is https://github.com/MarginallyClever/Makelangelo-software/blob/master/src/main/resources/logback.xml
I then use JPackage to distribute my app with all the dependencies baked into a fat jar.
For MOST people the log file appears and fills normally. For a select number of users the log file appears but stays empty.
They have been gracious enough to try running the JAR from the command line but we've seen no extra console messages.
Running in administrator mode doesn't help.
Immediate flushing doesn't help.
Adding a logback status listener (logback-status.log) also doesn't appear for those tricky users.
Can someone please give me a hint what I'm doing wrong?
GitHub link: https://github.com/apache/logging-log4j2/discussions/3793
----
This is an automatically sent email for dev@logging.apache.org.
To unsubscribe, please send an email to: dev-unsubscribe@logging.apache.org
Re: [D] Log4j creates an empty log file and refuses to fill it? [logging-log4j2]
Posted by "i-make-robots (via GitHub)" <gi...@apache.org>.
GitHub user i-make-robots edited a comment on the discussion: Log4j creates an empty log file and refuses to fill it?
Whoops.
GitHub link: https://github.com/apache/logging-log4j2/discussions/3793#discussioncomment-13636074
----
This is an automatically sent email for dev@logging.apache.org.
To unsubscribe, please send an email to: dev-unsubscribe@logging.apache.org