List/Grid Author Archives Subscribe to the RSS feed of Peter Lawrey

java-logo

Compounding double error

Overview In a previous article, I outlined why BigDecimal is not the answer most of the time. While it is possible to construct situations where double produces an error, it is also ...
java-logo

If BigDecimal is the answer, it must have been a strange question

Overview Many developers have determined that BigDecimal is the only way to deal with money.  Often they site that by replacing double with BigDecimal, they fixed a bug or ten.  What ...
java-logo

Making operations on volatile fields atomic

Overview The expected behaviour for volatile fields is that they should behave in a multi-threaded application the same as they do in a single threaded application.  They are not forbidden ...
java-logo

Adding @atomic operations to Java

Overview How might atomic operations work in Java, and is there a current alternative in OpenJDK/Hotspot it could translate to. Feedback In my previous article on Making operations ...
java-logo

MineCraft and off heap memory

Overview MineCraft is a really good example of when off heap memory can really help.The key requirements are:The bulk of the retained data is a simple data structure (in minecraft’s ...
java-logo

Making Unsafe safer

Overview If you use Unsafe directly, you risk crashing the JVM.  This happens when you access a page of memory which hasn’t been mapped and the result on Unix is a SIGSEG (if ...
redis-logo

SharedHashMap vs Redis

Overview This is a comparison between OpenHFT’s SharedHashMap and a popular key-value store Redis. Any vendor will tell you how great their product is, so I will start by outlining ...
java-logo

Chronicle and low latency in Java

Overview I was watching this excellent presentation by Rolan Kuhn of Typesafe on Introducing Reactive Streams At first glance it appears that it has some similar goals to Chronicle, ...
java-logo

Common Java Myths

These are questions which are likely to be too advanced to ask in any interview as they may just put candidates off.  Never the less, they may be work practising in your own time.                 Myth ...
java-logo

Java arrays, Wat!?

There is a few things you can do with arrays which are surprising.                     Is it an array or not? Serializable array = ...
Java Code Geeks and all content copyright © 2010-2014, Exelixis Media Ltd | Terms of Use | Privacy Policy
All trademarks and registered trademarks appearing on Java Code Geeks are the property of their respective owners.
Java is a trademark or registered trademark of Oracle Corporation in the United States and other countries.
Java Code Geeks is not connected to Oracle Corporation and is not sponsored by Oracle Corporation.

Sign up for our Newsletter

20,709 insiders are already enjoying weekly updates and complimentary whitepapers! Join them now to gain exclusive access to the latest news in the Java world, as well as insights about Android, Scala, Groovy and other related technologies.

As an extra bonus, by joining you will get our brand new e-books, published by Java Code Geeks and their JCG partners for your reading pleasure! Enter your info and stay on top of things,

  • Fresh trends
  • Cases and examples
  • Research and insights
  • Two complimentary e-books