A DESCRIPTION OF THE PROBLEM :
Java Platform, Standard Edition Tools Reference (for both Unix and Windows: https://docs.oracle.com/javase/8/docs/technotes/tools/windows/java.html and http://docs.oracle.com/javase/8/docs/technotes/tools/unix/java.html) contains incorrect name of the HeapDumpOnOutOfMemoryError JVM option:
"-XX:+HeapDumpOnOutOfMemory
Enables the dumping of the Java heap to a file in the current directory by using the heap profiler (HPROF) when a java.lang.OutOfMemoryError exception is thrown."
During attempt to launch JVM with the specified option and error is thrown:
> java -XX:+HeapDumpOnOutOfMemory -jar MyJar.jar
Unrecognized VM option 'HeapDumpOnOutOfMemory'
Did you mean '(+/-)HeapDumpOnOutOfMemoryError'?
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
The same also holds true for least 1.8.0u51 on Linux.
SE 7 troubleshooting guide, for instance, contained correct option name: https://docs.oracle.com/javase/7/docs/webnotes/tsg/TSG-VM/html/memleaks.html#gdyrr
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
-XX:+HeapDumpOnOutOfMemoryError
ACTUAL -
-XX:+HeapDumpOnOutOfMemory
URL OF FAULTY DOCUMENTATION :
https://docs.oracle.com/javase/8/docs/technotes/tools/windows/java.html
Java Platform, Standard Edition Tools Reference (for both Unix and Windows: https://docs.oracle.com/javase/8/docs/technotes/tools/windows/java.html and http://docs.oracle.com/javase/8/docs/technotes/tools/unix/java.html) contains incorrect name of the HeapDumpOnOutOfMemoryError JVM option:
"-XX:+HeapDumpOnOutOfMemory
Enables the dumping of the Java heap to a file in the current directory by using the heap profiler (HPROF) when a java.lang.OutOfMemoryError exception is thrown."
During attempt to launch JVM with the specified option and error is thrown:
> java -XX:+HeapDumpOnOutOfMemory -jar MyJar.jar
Unrecognized VM option 'HeapDumpOnOutOfMemory'
Did you mean '(+/-)HeapDumpOnOutOfMemoryError'?
Error: Could not create the Java Virtual Machine.
Error: A fatal exception has occurred. Program will exit.
The same also holds true for least 1.8.0u51 on Linux.
SE 7 troubleshooting guide, for instance, contained correct option name: https://docs.oracle.com/javase/7/docs/webnotes/tsg/TSG-VM/html/memleaks.html#gdyrr
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
-XX:+HeapDumpOnOutOfMemoryError
ACTUAL -
-XX:+HeapDumpOnOutOfMemory
URL OF FAULTY DOCUMENTATION :
https://docs.oracle.com/javase/8/docs/technotes/tools/windows/java.html