Bug 60620 - [JRE] Memory leak found in java.util.concurrent.ForkJoinPool
Summary: [JRE] Memory leak found in java.util.concurrent.ForkJoinPool
Alias: None
Product: Tomcat 8
Classification: Unclassified
Component: Catalina (show other bugs)
Version: 8.0.39
Hardware: PC All
: P2 normal (vote)
Target Milestone: ----
Assignee: Tomcat Developers Mailing List
Depends on:
Reported: 2017-01-21 08:45 UTC by Konstantin Kolinko
Modified: 2017-01-25 20:45 UTC (History)
0 users


Note You need to log in before you can comment on or make changes to this bug.
Description Konstantin Kolinko 2017-01-21 08:45:28 UTC
Filing a bug for an already fixed issue, to summarize discussions spawned across different mailing lists, and for better changelog.

See "Tomcat 8, 8.5 and 9 returning another apps environment with context.lookup() from a .parallelStream()", 2017-01-08 on users@

See "Memory leak found in java.util.concurrent.ForkJoinPool", 2017-01-09 on dev@
Comment 1 Konstantin Kolinko 2017-01-21 09:22:34 UTC
A workaround for this Oracle JRE bug was added to memory leaks protection code in Tomcat 7.0.74 (r1778068), 8.5.11 (r1778065), 9.0.0.M17 (r1778061)

The fix has not been applied to Tomcat 8.0 yet.

Note that compilation of SafeForkJoinWorkerThreadFactory requires Java 7 and later. People who use two separate Eclipse projects for Tomcat 7 (separating code that requires java 6 and java 7 into different projects) need to update their include / exclude patterns.

The sample projects were updated in r1779707, to be in 7.0.76.
Comment 2 Konstantin Kolinko 2017-01-21 09:26:33 UTC
Moving the issue to Tomcat 8.0, as the fix has not been applied there yet.

As a variant, we can add the helper class but keep the protection feature off by default. This may wait a while, to get more feedback.
Comment 3 Mark Thomas 2017-01-25 20:45:30 UTC
Fixed in r1780268 for 8.0.42 onwards.