Skip to content

Commit

Permalink
build: disable stack-trace trimming in surefire
Browse files Browse the repository at this point in the history
Motivation:

Surefire has a feature where it tries to guess initial frames of a
stack-trace that comes from "boring" code (such as JRE libraries).
Unfortunately it is both enabled by default (to solicit feedback) and
quite broken, as it often considers dCache code as "not of interest".

Modification:

Disable stack-trace filtering in surefire.

Result:

Unit-test stack-traces (ones printed when running unit tests) now
include all elements (method calls) up to the point where the exception
was thrown.  This results in longer stack-traces, but eliminates the
risk that surefire mistakenly excludes frames that are important in
understanding what just happened.

Target: master
Requires-notes: no
Requires-book: no
Patch: https://rb.dcache.org/r/13025/
Acked-by: Lea Morschel
  • Loading branch information
paulmillar committed May 11, 2021
1 parent 206185d commit 275df29
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -1126,6 +1126,11 @@
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.0.0-M4</version>
<configuration>
<!-- Disable stack-trace trimming as
surefire makes bad decisions too often. -->
<trimStackTrace>false</trimStackTrace>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
Expand Down

0 comments on commit 275df29

Please sign in to comment.