Performance tuning is an experimental science, but that doesn't mean engineers should resort to guesswork and folklore to get the job done. Yet that's often the case. With this practical book, intermediate to advanced Java technologists working with complex technology stacks will learn how to tune Java applications for performance using a quantitative, verifiable approach.
Most resources on performance tend to discuss the theory and internals of Java virtual machines, but this book focuses on the practicalities of performance tuning by examining a wide range of aspects. There are no simple recipes, tips and tricks, or algorithms to learn. Performance tuning is a process of defining and determining desired outcomes. And it requires diligence.
Learn how Java principles and technology make the best use of modern hardware and operating systems Explore several performance tests and common anti-patterns that can vex your team Understand the pitfalls of measuring Java performance numbers and the drawbacks of microbenchmarking Dive into JVM garbage collection logging, monitoring, tuning, and tools Explore JIT compilation and Java language performance techniques Learn performance aspects of the Java Collections API and get an overview of Java concurrency
I hadn't read the subtitle of “Optimizing Java” so I didn't know it was about JVM performance vs application level tricks. That turned out to be a pleasant surprise as I learned more.
I learned a good number of things. From the fun (CAFEDADA bytecode for modules) to the practical (tools for looking at JVM resources)
I've heard a talk about garbage collection a few times now. G1GC isn't easy to understand. Between reading this book and hearing one more talk on it, the concepts finally clicked.
I also learned a lot about modern hardware vs what I learned in school. And what book isn't made better by a ninja quote?
There were some API level concepts like why toUpperCase() is so complicated to implement. Along with warnings about premature optimization.
This is the first O'Reilly book that I've read that is in color. It definitely made the graphs better.
Disclosure: I received a copy of this book from the publisher in exchange for writing this review on behalf of CodeRanch.
Very good book to understand more deeply how JVM works internally, not only GC. Many books focus mainly on GC, but this one describes many more aspects of JVM internals (such as threading, JVM internal memory representation, bytecode, JIT compilers etc). Moreover, the book contains overview of many tools which can help you on a daily basis work with JVM. If you have read "Java Performance: The Definitive Guide" by Scott Oaks you won't regret reading this one as well.
A worthwhile dive into the low-level aspects of how the JVm works, with focus on garbage collection (GC) and how the virtual machine actually does stuff. A very interesting set of stuff although maybe a little too low-level for most Java programmers — I found it good for deeper understanding but lacking for how to write performance programs.
The closing sentences of the book provide a good summary:
"...this book is nowhere near complete, as there is simply so much to comprehend as a performance engineer. Nevertheless we hope that it has been a useful troduction to the world of Java performance and has provided some signposts dor readers on their own performance journey."
The author has brought up some many aspects of improving jvm app. However, it is too much in terms of getting them into practice. Though, it's good to grasp some knowledge about GCC, all different kinds of flags, and some know-how on improving the performance of the system.
Solid book on jvm mechanics, that every java programmer should be familiar with. It will take you months of watching infoq videos to collect same amount of information.