[
https://issues.apache.org/jira/browse/SOLR-18133?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jason Gerlowski resolved SOLR-18133.
------------------------------------
Fix Version/s: main(11.0)
10.1
Resolution: Fixed
Alright, all wrapped up - marking this as "Fix Version" 11 and 10.1, though I'm
not sure the bug was ever released so I'm not sure that's entirely accurate.
> Solr should log full stacktraces rather than abbreviated ones
> -------------------------------------------------------------
>
> Key: SOLR-18133
> URL: https://issues.apache.org/jira/browse/SOLR-18133
> Project: Solr
> Issue Type: Bug
> Components: logging
> Affects Versions: main(11.0)
> Reporter: Jason Gerlowski
> Assignee: Jason Gerlowski
> Priority: Major
> Labels: pull-request-available
> Fix For: main(11.0), 10.1
>
> Time Spent: 50m
> Remaining Estimate: 0h
>
> Many log4j2.xml config files rely on the following pattern for
> "PatternLayout":
> {code}
> %maxLen{%d{yyyy-MM-dd HH:mm:ss.SSS} %-5p (%t)
> [%notEmpty{c:%X{collection}}%notEmpty{ s:%X{shard}}%notEmpty{
> r:%X{replica}}%notEmpty{ x:%X{core}}%notEmpty{ t:%X{trace_id}}] %c{1.}
> %m%notEmpty{ =>%ex{short}}}{10240}%n
> {code}
> Of particular note is the "ex\{short\}" bit at the end of the pattern string
> - this tells log4j2 to only print a "shortened" stacktrace of one or two
> lines instead of the full thing.
> While brevity is always appreciated, this cuts out too much useful
> information and makes it more difficult to debug server behavior.
> *NOTE:*
> There's some uncertainty around when this behavior started. On one hand, I
> don't recollect seeing this in currently released versions of Solr (e.g.
> 9.10.1). But on the other hand...patternLayout string has had "ex{short}"
> since Erick Erickson's work on async logging back in 2019 (0de390 of
> SOLR-12055).
> I suspect (but haven't proved) that there was a bug in past log4j versions
> that prevented us from getting the shortened exception behavior despite our
> config requesting it. And that we only started seeing the shortened behavior
> following a log4j upgrade somewhat recently.
> In any case, I see the shorted stacktrace on 'main' as of 2/25.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]