[
https://issues.apache.org/jira/browse/LOG4J2-2475?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16652584#comment-16652584
]
ASF GitHub Bot commented on LOG4J2-2475:
----------------------------------------
GitHub user cakofony opened a pull request:
https://github.com/apache/logging-log4j2/pull/220
[WIP][LOG4J2-2475] ReusableMessageFactory uses non-reusable messages in
some cases
Large parameter arrays passed to the logger will result in a
ParameterizedMessage instance being created rather than
adding the varargs to a ReusableParameterizedMessage instance.
This avoids potential mutation of the input array when it
is reused later.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/cakofony/logging-log4j2
reusable_message_object_parameters
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/logging-log4j2/pull/220.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 #220
----
commit 0ea9702ac218aea566f1b40213e99018beb381a3
Author: Carter Kozak <ckozak@...>
Date: 2018-10-16T22:18:46Z
[LOG4J2-2475] ReusableMessageFactory uses non-reusable messages in some
cases
Large parameter arrays passed to the logger will result in a
ParameterizedMessage instance being created rather than
adding the varargs to a ReusableParameterizedMessage instance.
This avoids potential mutation of the input array when it
is reused later.
----
> Limit reusable event.clear parameter clearing to argsCount
> ----------------------------------------------------------
>
> Key: LOG4J2-2475
> URL: https://issues.apache.org/jira/browse/LOG4J2-2475
> Project: Log4j 2
> Issue Type: Improvement
> Components: Core
> Reporter: Carter Kozak
> Assignee: Carter Kozak
> Priority: Major
>
> Larger parameter arrays may make their way into log4j when passed into the
> logger directly. These may take longer to clear, despite only containing one
> or two parameters.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)