Blog

A new way to test multi-threaded and concurrent Java

Testing multi-threaded, concurrent Java is hard since we can only test one thread interleaving at a time. An obvious solution is to repeat the test multiple times, hoping that we execute all possible interleavings. The problem with this solution is that every field access leads to a potential new interleaving. So the solution only works for small unit tests. This led me to develop the open-source tool VMLens.

Read more →

June 5, 2025