Ralph
Ralph

Reputation: 120811

Does -XX:+HeapDumpOnOutOfMemoryError create any security or performance issues?

Does the instruction to create an Heap Dump on out of memory error (-XX:+HeapDumpOnOutOfMemoryError) result in any security or noteworthy performance issues for Tomcat 7 in a production environment?

(Of curse the server has to write the file when it "crashes" and this take some amout of time/space - but I am more interested in performance issues while the server is still in business.)

Upvotes: 4

Views: 558

Answers (1)

apangin
apangin

Reputation: 98330

-XX:+HeapDumpOnOutOfMemoryError flag does not introduce performance or security problems in run time. The flag is checked only after OOME has happened.

However the heap dump itself may contain sensitive data. Make sure it is written to a secure place by providing appropriate -XX:HeapDumpPath= option.

Upvotes: 3

Related Questions