Microreview: Most Excellent!
I bought this book because I was working on some gnarly multithreading problems. I was hoping to get up to speed on the wonderful new concurrency classes added in Java 1.5 to replace the boring old Thread class. What I got was so much more. It goes into great depth in:
- Preventing thread data escaping (what happens in thread, stays in thread)
- How to divide work among threads
- Exactly why the New Hotness is better than the Old Stuff
- The difference between the various implementations of the New Hotness
But wait! There’s more! The aspect if this book I found the most helpful was the many examples of how to use this stuff (and which to use) in real-world examples. In other words, the In Practice part was just as valuable as the Java Concurrency part. For instance, he doesn’t just show the One True Way. Many times, Goetz shows the wrong way (and explains in sufficient detail why), shows a better solution (and why), then shows the One True Way (and why). The contrast amplifies the lessons.
The reason this books resonates so strongly with me is that I suck at memorization, but I excel at understanding. If a book doesn’t tell me why I should drink it’s flavor of Kool-Aid, I’ve wasted my time. This book gives me that. But even if that isn’t as important for you, there’s another reason to focus on the “why”: You have to know which of the many ways of skinning your cat are going to work best for you. Without knowing how each option will bite you or kiss you later, you can’t know you’ve made the right decision (or at least for the right reasons). Or which choice is causing your software to go all FUBAR.
Let me know what you think.