* Jonathan Gibbons: > Florian, > > I looked at the code: this is definitely a design bug. > > There appears to be no reason for it to be static, and removing the > `static` modifier > does not cause any compilation issues. > > There's some minor cleanup we could do in this area as well, to use > Map::computeIfAbsent, > > Filed: https://bugs.openjdk.java.net/browse/JDK-8231587
Thanks. I removed the static keyword and the leak is gone if I do not reuse the DocumentationTool object. However, there is still a leak if I recycle the tool object. (This does not happen with the javac tool object, I think.) So it's an improvement in the sense that there is now an easy workaround, but the fix isn't quite complete yet.