-XX:[+|-]HitachiOutOfMemoryHandling (OutOfMemory handling option)
Format
Description
Specify whether to enable the OutOfMemory handling functionality. This option is valid only when the J2EE server is executed in J2EE server mode.
Use the OutOfMemory handling functionality in combination with the forced termination functionality for OutOfMemory (-XX:+HitachiOutOfMemoryAbort). If the forced termination functionality for OutOfMemory (-XX:-HitachiOutOfMemoryAbort) is disabled, the OutOfMemory handling functionality will be disabled.
If the OutOfMemory handling functionality is enabled, the OutOfMemoryError throwing condition is determined when OutOfMemory occurs. Specifically, if OutOfMemory occurs due to Java heap or Perm heap shortage during the following processing, the functionality determines whether to continue executing the J2EE server:
After determining, if the J2EE server continues execution, the java.lang.OutOfMemoryError is thrown and only the request processing where OutOfMemory occurred is cancelled.
JavaVM performs the following operations based on the determined results. However, if java.lang.OutOfMemoryError is caught by a Web application, that processing is followed.
The OutOfMemoryError throwing condition is as follows. Note that when JavaVM does not conform to the OutOfMemoryError throwing conditions, JavaVM is terminated forcibly by the forced termination functionality for OutOfMemory.
The following table describes the operations for the cause of OutOfMemory occurrence for the forced termination functionality for OutOfMemory and OutOfMemory handling functionality. The enabling of the OutOfMemory handling functionality impacts the operations to be performed when the cause of OutOfMemory is a Java heap or Perm heap shortage.
Table 16-8 Operations for the cause of OutOfMemory occurrence of the forced termination functionality for OutOfMemory and OutOfMemory handling functionality
Causes of OutOfMemory occurrence | Is an operation performed for the forced termination functionality for OutOfMemory (Operations to be performed during OutOfMemory #1) | Is an operation performed for the OutOfMemory handling functionality (Operations to be performed during OutOfMemory) |
---|---|---|
Java heap shortage | An operation is performed (JavaVM is terminated forcibly). | An operation is performed (an operation is performed according to the determined results#2). |
Perm heap shortage | An operation is performed (JavaVM is terminated forcibly). | An operation is performed (an operation is performed according to the determined results#2). |
C heap shortage | An operation is performed (JavaVM is terminated forcibly). | An operation is not performed (JavaVM is terminated forcibly#3). |
Unkown | An operation is not performed (java.lang.OutOfMemoryError is thrown). | An operation is not performed (java.lang.OutOfMemoryError is thrown). |
Thread Limit | An operation is not performed (java.lang.OutOfMemoryError is thrown). | An operation is not performed (java.lang.OutOfMemoryError is thrown). |
Also, if the OutOfMemory handling functionality is enabled, the information related to the frequency of OutOfMemory occurrence is output to the JavaVM log file when the OutOfMemory error occurs due to a Java heap and Perm heap shortage.
Output format
[id][Thread: thread_id]<date>[Handling: oom_count(max_oom_count)] |
The following is a description of the output contents:
Examples of output
[OMH][Thread: 0x00927f48]<Tue Aug 24 19:02:19 2010>[Handling: 1(60)] |
Precautions