OutOfMemoryError / Java heap space

The JVM hit its heap ceiling — which is set on the JVM, not on the tool

why

Java tools default to a heap far smaller than the machine's RAM, so a 300 GB server still runs the tool in a couple of gigabytes unless told otherwise. Passing a memory flag to the tool often does nothing; the ceiling belongs to the JVM.

what to do

Set it on the JVM: java -Xmx8g -jar tool.jar …. If the tool starts from its own launcher, the flag goes in that launcher's config file — and see the .vmoptions entry above, which silently fails to parse on Windows when saved with CRLF endings.

JVM behaviour, canonical
This is one entry from BioErrors, a catalogue of bioinformatics error messages that point at the wrong thing. Every entry was traced to its real cause before it was written down.
If your error is not in it, paste it there and it gets traced and added.