You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@logging.apache.org by "ASF GitHub Bot (JIRA)" <ji...@apache.org> on 2018/07/24 22:09:00 UTC
[jira] [Commented] (LOG4J2-2391) Investigate ThrowableProxy
performance
[ https://issues.apache.org/jira/browse/LOG4J2-2391?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16554848#comment-16554848 ]
ASF GitHub Bot commented on LOG4J2-2391:
----------------------------------------
GitHub user cakofony opened a pull request:
https://github.com/apache/logging-log4j2/pull/197
[LOG4J2-2391] Benchmarks for logging to disk with a Throwable
Initial results (re-ordered fastest to slowest):
```
Benchmark Mode Cnt Score Error Units
FileAppenderThrowableBenchmark.logbackFile thrpt 3 135260.838 ± 15790.010 ops/s
FileAppenderThrowableBenchmark.log4j2SimpleThrowable thrpt 3 87385.712 ± 8082.803 ops/s
FileAppenderThrowableBenchmark.log4j1 thrpt 3 60359.485 ± 10122.858 ops/s
FileAppenderThrowableBenchmark.julFile thrpt 3 52134.431 ± 1302.365 ops/s
FileAppenderThrowableBenchmark.log4j2ExtendedThrowable thrpt 3 15348.378 ± 1301.501 ops/s
```
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/cakofony/logging-log4j2 LOG4J2-2391
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/logging-log4j2/pull/197.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #197
----
commit a42a80d8bba398a8333964a12333e263314b878f
Author: Carter Kozak <ck...@...>
Date: 2018-07-24T21:59:00Z
[LOG4J2-2391] Benchmarks for logging to disk with a Throwable
Initial results (re-ordered fastest to slowest):
Benchmark Mode Cnt Score Error Units
FileAppenderThrowableBenchmark.logbackFile thrpt 3 135260.838 ± 15790.010 ops/s
FileAppenderThrowableBenchmark.log4j2SimpleThrowable thrpt 3 87385.712 ± 8082.803 ops/s
FileAppenderThrowableBenchmark.log4j1 thrpt 3 60359.485 ± 10122.858 ops/s
FileAppenderThrowableBenchmark.julFile thrpt 3 52134.431 ± 1302.365 ops/s
FileAppenderThrowableBenchmark.log4j2ExtendedThrowable thrpt 3 15348.378 ± 1301.501 ops/s
----
> Investigate ThrowableProxy performance
> --------------------------------------
>
> Key: LOG4J2-2391
> URL: https://issues.apache.org/jira/browse/LOG4J2-2391
> Project: Log4j 2
> Issue Type: Task
> Affects Versions: 2.11.1
> Reporter: Carter Kozak
> Assignee: Carter Kozak
> Priority: Major
>
> I've noticed when applications get into a state where they log more exceptions than usual (e.g. network connectivity issues) thread dumps contain many threads working inside of ThrowableProxy, loading classes.
> A simple jmh benchmark of a pattern layout writing to disk with a message and throwable appears to write about 160,000 events/second using a throwable, and 2,000 events/second using ThrowableProxy.
> I will investigate to understand where the substantial difference is coming from, and clean up the benchmarks to add to the log4j2 benchmarking module.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)