Apache Wicket 6.19.0 PermGen OutOfMemoryException

Phew…. This one came as a surprise. The application I am busy with at one of my clients uses Apache Wicket 6. So some fine day in the winter of 2015. We did a lib upgrade on this project. And so we moved from Apache Wicket 6.19 to 6.20.

During the tests I noticed that somehow those OutOfMemoryException in the PermGen started to creep up occasionally.It happened twice during the 2month long tests, so I just hoped. That it may not occur at all in Production as these servers there have more heap and more PermGen space. 

No two weeks later, the production  management started calling me on those OutOfMemoryExceptions on their production machines. As a remedy the servers got restarted every morning. However this still kind of sucked. So I did some load tests and with the jvisualvm I could see that the PermGen usage kept on increasing. I switched back to the old code and repeated the test. Here the PermGen was stable! Now I started to go through my standard suspects and in the end I was surprised to see, that the error was in the upgrade from Apache Wicket 6.19 to 6.20.

Luckily this issue was found by the Apache Wicket team too and they have it fixed in the 6.21 release (Wicket-5978: LazyInitProxyFactory fills permgen space). 

Leave a comment