[concurrency-interest] ForkJoin updates

Doug Lea dl at cs.oswego.edu
Tue Jan 31 11:47:38 EST 2012


On 01/31/12 10:23, √iktor Ҡlang wrote:
> a surprising behavior is that AdaptedRunnable doesn't escalate uncaught
> exception to the WorkerThreads UncaughtExceptionHandler,
> I'm trying to align the behavior with ThreadPoolExecutor.
>
> What the strategy to handle potentially fatal errors?

All exceptions are associated with the tasks encountering them.
The only exceptions propagated to UncaughtExceptionHandlers
are resource exhaustion, internal errors, and setup errors mode by
people extending class ForkJoinWorkerThread.

If you'd like certain kinds of exceptions to instead trigger
some sort of coordinated error response, you could create
your own variant of AdaptedRunnable that probes via getException.

While I'm at it: the current CVS commit almost completes this
round of updates. (I still plan a few non-essential changes
to fit internals together better under new submission scheme
etc but these won't happen immediately.)

-Doug









More information about the Concurrency-interest mailing list