JDK-8039378 : CompletableFuture: Avoid StackOverflowError for long linear chains
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.util.concurrent
  • Affected Version: 8,9
  • Priority: P3
  • Status: Closed
  • Resolution: Duplicate
  • Submitted: 2014-04-07
  • Updated: 2015-11-09
  • Resolved: 2015-09-21
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 9
9 b88Resolved
Related Reports
Duplicate :  
Description
Rework propagation in the case of linear dependency chains, which are the only cases in which these kinds of StackOverflowErrors occur. By re-packing actions while processing dependent completions, we can isolate tail-recursive cases and loopify them. This generally works out better than moving them across lists, because doing so can reduce opportunities for other threads to help process them.

Already checked into the 166 CVS:
  http://gee.cs.oswego.edu/cgi-bin/viewcvs.cgi/jsr166/src/main/java/util/concurrent/CompletableFuture.java?view=log

For further information, see the discussion on concurrency-interest mailing list:
  http://cs.oswego.edu/pipermail/concurrency-interest/2014-April/012501.html
Comments
part of the Great jsr166 jdk9 integration
21-09-2015