Skip to content

Commit 6e4f542

Browse files
authored
Merge pull request #227 from jmtd/OPENJDK-111-diagnostic-output
[OPENJDK-111] Adjust JVM parameters when JAVA_DIAGNOSTICS is set
2 parents d147d76 + 3eeb9fc commit 6e4f542

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

modules/jdk/11/artifacts/opt/jboss/container/openjdk/jdk/jvm-options

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@
66
# ==============================================================================
77

88
function jvm_specific_diagnostics() {
9-
echo "-Xlog:gc::utctime -XX:NativeMemoryTracking=summary"
9+
echo "-Xlog:gc::utctime -XX:NativeMemoryTracking=summary -XX:+UnlockDiagnosticVMOptions -XX:+PrintNMTStatistics -verbose:gc"
1010
}

modules/jdk/8/artifacts/opt/jboss/container/openjdk/jdk/jvm-options

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@
66
# ==============================================================================
77

88
function jvm_specific_diagnostics() {
9-
echo "-XX:NativeMemoryTracking=summary -XX:+PrintGC -XX:+PrintGCDateStamps -XX:+PrintGCTimeStamps -XX:+UnlockDiagnosticVMOptions"
9+
echo "-XX:NativeMemoryTracking=summary -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+PrintGCTimeStamps -XX:+UnlockDiagnosticVMOptions -XX:+PrintNMTStatistics -verbose:gc"
1010
}

modules/jvm/api/module.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ envs:
2222
description: Is used when no `-Xms` option is given in **JAVA_OPTS**. This is used to calculate the maximum value of the initial heap memory. If used in a container without any memory constraints for the container then this option has no effect. If there is a memory constraint then `-Xms` is limited to the value set here. The default is 4096MB which means the calculated value of `-Xms` never will be greater than 4096MB. The value of this variable is expressed in MB.
2323
example: "4096"
2424
- name: JAVA_DIAGNOSTICS
25-
description: Set this to get some diagnostics information to standard output when things are happening. **Disabled by default.**
25+
description: Set this to get some diagnostics information to standard output when things are happening. **Note:** This option, if set to true, will set `-XX:+UnlockDiagnosticVMOptions`. **Disabled by default.**
2626
example: "true"
2727
- name: JAVA_DEBUG
2828
description: If set remote debugging will be switched on. **Disabled by default.**

0 commit comments

Comments
 (0)