Java Concurrency In Practice
Buy it now
One Minute Bottom Line
|This book is a must read for all Java developers, particularly if you are working with multi-threading and java.concurrent package.|
ReviewThis book is very well organized and divided into four sections, starting from fundamentals like thread safety, atomicity, race conditions, locking, liveliness and goes on to concurrent collections like ConcurrentHaskMap, CopyOnWriteArrayList, BlcokingQueues, ConcurtrentLinkedQueue and other collections.
The second and third sections cover structuring concurrent applications, liveliness, performance and testing which includes Executor framework, boundedbuffers, thread life cycles overheads, context switches, different types of thread pools, thread factories, policies among some very useful techniques for reducing lock contention, lock stripping, avoiding dead locks etc.
I find chapter twelve ‘Testing Concurrent Programs’ particularly interesting and very useful considering how tricky and hard to test concurrent programs in real life. And the last section covers advanced topics such Explicit locks and advantages and disadvantages of using intrinsic locks vs. explicit locks and read-write locks, performance considerations of using various types of locks, building custom synchronizers, atomic variables and non-blocking synchronization, Java memory model and annotations.
(Note: Opinions expressed in this article and its replies are the opinions of their respective authors and not those of DZone, Inc.)