“Sometimes abstraction and encapsulation are at odds with performance — although not nearly as often as many developers believe — but it is always a good practice first to make your code right, and then make it fast.”
― Java Concurrency in Practice
― Java Concurrency in Practice
“The possibility of incorrect results in the presence of unlucky timing is so important in concurrent programming that it has a name: a race condition. A race condition occurs when the correctness of a computation depends on the relative timing or interleaving of multiple threads by the runtime; in other words, when getting the right answer relies on lucky timing.”
― Java Concurrency in Practice
― Java Concurrency in Practice
“When a field is declared volatile, the compiler and runtime are put on notice that this variable is shared and that operations on it should not be reordered with other memory operations. Volatile variables are not cached in registers or in caches where they are hidden from other processors, so a read of a volatile variable always returns the most recent write by any thread.”
― Java Concurrency in Practice
― Java Concurrency in Practice
“Whenever more than one thread accesses a given state variable, and one of them might write to it, they all must coordinate their access to it using synchronization.”
― Java Concurrency in Practice
― Java Concurrency in Practice
“Once an object escapes, you have to assume that another class or thread may, maliciously or carelessly, misuse it. This is a compelling reason to use encapsulation: it makes it practical to analyze programs for correctness and harder to violate design constraints accidentally.”
― Java Concurrency in Practice
― Java Concurrency in Practice
Puneeth’s 2025 Year in Books
Take a look at Puneeth’s Year in Books, including some fun facts about their reading.
Favorite Genres
Polls voted on by Puneeth
Lists liked by Puneeth





