[concurrency-interest] ForkJoinPool for async http calls?
dl at cs.oswego.edu
Thu May 10 08:57:50 EDT 2012
On 05/10/12 08:12, Christian Essl wrote:
> As said I like the akka-framework, still it would be very nice if
> anybody could answer my original question whether ForkJoinTasks can
> give a sort of non-blocking future also suitable for async IO, because
> I am stil not sure.
The jsr166y/jdk8 CountedCompleter and related updates are specifically
aimed to better support IO-bound and other non-computationally-bound
tasks. The javadocs and examples probably don't yet do a good enough
job in showing how. (Partly because IO examples are always too bulky
to make for simple understandable examples; suggestions would be welcome.)
The syntax and constructions for using them are not as nice as in akka/Scala.
On the other hand the ability to effectively AND completion triggers
via counts (not found yet in Scala versions) is handy.
More information about the Concurrency-interest