Re: log4j2 performance issues with Java 11

2020-11-21 Thread Lisa Ruby
Thanks Ralph. I use logging throughout the application, as well as during initialization. It has helped me many times to quickly debug issues during development and testing. I can look into asynchronous logging to see if it will work for me and help with the performance issue. Lisa On 11/21/20

Re: log4j2 performance issues with Java 11

2020-11-21 Thread Ralph Goers
As I said, if you want to keep logging to the console you might consider configuring the Loggers to be asynchronous. That way it shouldn’t affect the speed of the application much, especially if you are primarily performing trace and debug logging during initialization. I might play around with

Re: log4j2 performance issues with Java 11

2020-11-21 Thread Lisa Ruby
Hi Ralph, Thank you for taking the time to investigate this, and for all of the information. You are correct, I forgot that I'd tested in Java 8 with the RollingFileAppender removed, and I obtained the YourKit profiler data without it. If you think it would be useful in any way I can also cap

Re: log4j2 performance issues with Java 11

2020-11-21 Thread Lisa Ruby
Hi Ralph, Thank you for taking the time to investigate this, and for all of the information. You are correct, I forgot that I'd tested in Java 8 with the RollingFileAppender removed, and I obtained the YourKit profiler data without it. If you think it would be useful in any way I can also cap

Re: log4j2 performance issues with Java 11

2020-11-21 Thread Ralph Goers
One other thing you could do to work around the problem I you really need to log to the console is to configure your Loggers to be Async Loggers. If you do that the I/O will still be slow but it shouldn’t impact the performance of your application unless it is on a machine that only has a single

Re: log4j2 performance issues with Java 11

2020-11-21 Thread Ralph Goers
Lisa, I am replying on list for others benefit but won’t include any details about your application. Lisa provided me with 3 snapshots: one running in Java 8, one running in Java 11 with %logger{36}, and one in Java 11 without it. First, the snapshots don’t show Log4j to be the main area of ove

Re: log4j2 performance issues with Java 11

2020-11-20 Thread Matt Sicker
raumatic for us... this > >>> breakdown of log4j performance at the feature level is fascinating to > >>> see. I hope some article comes out of this once you all have figured it > >>> out. > >>> > >>> Thank you, > >>> Lauren

Re: log4j2 performance issues with Java 11

2020-11-20 Thread Lisa Ruby
e figured it out. >>> >>> Thank you, >>> Laurent. >>> >>> Sent from my BlackBerry - the most secure mobile device >>> From: ralph.go...@dslextreme.com >>> Sent: November 19, 2020 21:07 >>> To: lbru...@protonmail.com >>> Re

Re: log4j2 performance issues with Java 11

2020-11-20 Thread Matt Sicker
obile device > > From: ralph.go...@dslextreme.com > > Sent: November 19, 2020 21:07 > > To: lbru...@protonmail.com > > Reply-to: log4j-user@logging.apache.org > > Cc: volkan.yaz...@gmail.com; log4j-user@logging.apache.org > > Subject: Re: log4j2 performance issues

Re: log4j2 performance issues with Java 11

2020-11-19 Thread Ralph Goers
o: lbru...@protonmail.com > Reply-to: log4j-user@logging.apache.org > Cc: volkan.yaz...@gmail.com; log4j-user@logging.apache.org > Subject: Re: log4j2 performance issues with Java 11 > > I am assuming you captured the snapshot from your profiling session? If so it > would be

Re: log4j2 performance issues with Java 11

2020-11-19 Thread Ralph Goers
That could be. Having the snapshot with all the options enabled should be able to pinpoint what is using up the cpu time. Ralph > On Nov 19, 2020, at 8:39 PM, Lisa Ruby wrote: > > I did not grab the information from a Snapshot, just from the live capture on > the screen. I will send you a pri

Re: log4j2 performance issues with Java 11

2020-11-19 Thread Lisa Ruby
I did not grab the information from a Snapshot, just from the live capture on the screen. I will send you a private email regarding giving you an entire Snapshot. Regarding %logger{36}, I tested again, starting with my original xml config file and removing only the %logger{36} from the Console

RE: log4j2 performance issues with Java 11

2020-11-19 Thread Laurent Hasson
ng to see. Thanks to you and all the team. Laurent Hasson Co-Founder and CTO CapsicoHealth Inc. -Original Message- From: Ralph Goers Sent: Thursday, November 19, 2020 22:11 To: Log4J Users List Subject: Re: log4j2 performance issues with Java 11 If you have encountered performance i

Re: log4j2 performance issues with Java 11

2020-11-19 Thread Ralph Goers
t secure mobile device > From: ralph.go...@dslextreme.com > Sent: November 19, 2020 21:07 > To: lbru...@protonmail.com > Reply-to: log4j-user@logging.apache.org > Cc: volkan.yaz...@gmail.com; log4j-user@logging.apache.org > Subject: Re: log4j2 performance issues with Java 11 > > I am assumi

Re: log4j2 performance issues with Java 11

2020-11-19 Thread Laurent Hasson
performance issues with Java 11 I am assuming you captured the snapshot from your profiling session? If so it would be great it you could send it to me. I can email you privately with a dropbox location where you can place the file if that will work for you. FWIW, I find your results surprising

Re: log4j2 performance issues with Java 11

2020-11-19 Thread Ralph Goers
I am assuming you captured the snapshot from your profiling session? If so it would be great it you could send it to me. I can email you privately with a dropbox location where you can place the file if that will work for you. FWIW, I find your results surprising as all %logger{36} should be doi

Re: log4j2 performance issues with Java 11

2020-11-19 Thread Lisa Ruby
Thank you for the suggestion. I will do that. Lisa On 11/19/2020 5:51 AM, Volkan Yazıcı wrote: > In the light of what Ralph mentioned about %L pattern, @Lisa, would you mind > seeing if simplifying the pattern (that is, removing certain directives bit > by bit, e.g., starting with %L) helps? P

Re: log4j2 performance issues with Java 11

2020-11-19 Thread Volkan Yazıcı
In the light of what Ralph mentioned about %L pattern, @Lisa, would you mind seeing if simplifying the pattern (that is, removing certain directives bit by bit, e.g., starting with %L) helps? Pinning down the actual smoking gun would help us a lot. On Wed, Nov 18, 2020 at 4:50 PM Ralph Goers wrot

Re: log4j2 performance issues with Java 11

2020-11-18 Thread Lisa Ruby
Than you for the input. I have added all of the apache jar files I need via Classpath, and have no need to modularize my application. Still having issues. My build is being created with ANT. Will try the profiling as soon as I can and get back to you. Lisa Original Message On

Re: log4j2 performance issues with Java 11

2020-11-18 Thread Ralph Goers
It should be. Normally you just have to add an agent to the command line for the application. If you are just placing everything on the classpath Java 11 should behave more or less like Java 8. However, if you are trying to use the module path and Java 11 modules you will likely have all kinds

Re: log4j2 performance issues with Java 11

2020-11-18 Thread Lisa Ruby
Do you know if it's possible to run YourKit under NetBeans? I can try it if I can do that.  I'm having all kinds of other issues right now trying to run my application outside of NetBeans. I'm using Apache FOP and there are issues with the module architecture of Java 9+ and the jar files needed

Re: log4j2 performance issues with Java 11

2020-11-18 Thread Ralph Goers
Is there any chance you could run your application under YourKit and profile startup? Your partner uses %L so each log event needs to locate the location of the caller. In Java 8 that used the com.sun.Reflection class but that was removed in Java 9 so in Java 11 it would be using java.util.St

log4j2 performance issues with Java 11

2020-11-17 Thread Lisa Ruby
I am working on moving my Java application development from Java 8 and JavaFX 8 to Java 11 and JavaFX 11, and am seeing a large performance degradation in log4j between Java 8 and Java 11. I've found these two issues that appear to have been addressed. Assuming whatever changes/fixes were invol