Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

Are there any better options for handling concurrency outside of the core Java classes?

0
10 Posted

Are there any better options for handling concurrency outside of the core Java classes?

0
10

Alex Miller: Well first I’d like to say that I wish more people made better use of what is already offered by java.util.concurrent! I would highly recommend using Locks, the various thread coordination classes like CyclicBarrier and CountdownLatch, and Executors to clean up a lot of old code. In general, any time you are explicitly creating Threads, using Thread.join() or wait()/notify(), there are probably better alternatives in the concurrency library. For concurrency geeks like me, this is a wonderful time as there is a cornucopia of work occurring on alternative languages and concurrency paradigms. In Java, JDK 7 will contain a new library from Doug Lea called fork / join that is designed to support fine-grained parallelism of divide-and-conquer sorts of problems. That will be a great addition to the executors and other tools we have currently for coarse-grained parallelism in the JDK. There has been a lot of buzz recently about the “actor” model of concurrency which is a form of m

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123