milamberspace commented on code in PR #6462:
URL: https://github.com/apache/jmeter/pull/6462#discussion_r2152614556
##########
bin/jmeter:
##########
@@ -169,20 +170,26 @@ esac
# Default to en_EN
: "${JMETER_LANGUAGE:="-Duser.language=en -Duser.region=EN"}"
-# Uncomment this to generate GC verbose file with Java prior to 9
-# VERBOSE_GC="-verbose:gc -Xloggc:gc_jmeter_%p.log -XX:+PrintGCDetails
-XX:+PrintGCCause -XX:+PrintTenuringDistribution -XX:+PrintHeapAtGC
-XX:+PrintGCApplicationConcurrentTime -XX:+PrintAdaptiveSizePolicy
-XX:+PrintGCApplicationStoppedTime -XX:+PrintGCDateStamps"
+# Legacy GC verbose options removed (Java 8/9 support discontinued)
+
+# Optimized GC logging for Java 17 with structured output and performance
analysis
+# Uncomment to enable comprehensive GC logging with rotation and detailed
metrics
+#
VERBOSE_GC="-Xlog:gc,gc+heap,gc+regions,gc+refine,gc+phases:gc_jmeter_%p_%t.log:time,level,tags:filecount=5,filesize=50M"
+
+# Alternative: Minimal GC logging for production (uncomment if needed)
+# VERBOSE_GC="-Xlog:gc:gc_jmeter_%p.log:time"
-# Uncomment this to generate GC verbose file with Java 9 and above
-# VERBOSE_GC="-Xlog:gc*,gc+age=trace,gc+heap=debug:file=gc_jmeter_%p.log"
+# Docker support for Java 17+
+# Modern container memory detection is automatic in Java 17+
+# RUN_IN_DOCKER="-XX:+UseContainerSupport"
-# Uncomment this if you run JMeter in DOCKER (need Java SE 8u131 or JDK 9)
-# see
https://blogs.oracle.com/java-platform-group/java-se-support-for-docker-cpu-and-memory-limits
-# RUN_IN_DOCKER="-XX:+UnlockExperimentalVMOptions
-XX:+UseCGroupMemoryLimitForHeap"
+# Java 17 specific performance optimizations
+# Modern JVM performance flags for better throughput and reduced latency
+JAVA17_PERFORMANCE="-XX:+AlwaysPreTouch -XX:+UseLargePages
-XX:+OptimizeStringConcat"
-# Finally, some tracing to help in case things go astray:
-# You may want to add those settings:
-# -XX:+ParallelRefProcEnabled -XX:+PerfDisableSharedMem
-: "${GC_ALGO:="-XX:+UseG1GC -XX:MaxGCPauseMillis=100 -XX:G1ReservePercent=20"}"
+# Enhanced G1GC tuning for Java 17
+# Improved G1 performance with better defaults and new features
+: "${GC_ALGO:="-XX:+UseG1GC -XX:MaxGCPauseMillis=100 -XX:G1ReservePercent=20
-XX:+ParallelRefProcEnabled -XX:+UseStringDeduplication
-XX:G1HeapRegionSize=16m"}"
Review Comment:
Right. Changed
##########
bin/jmeter.bat:
##########
@@ -151,25 +149,21 @@ if not defined HEAP (
set HEAP=-Xms1g -Xmx1g -XX:MaxMetaspaceSize=256m
)
-rem Uncomment this to generate GC verbose file with Java prior to 9
-rem set VERBOSE_GC=-verbose:gc -Xloggc:gc_jmeter_%%p.log -XX:+PrintGCDetails
-XX:+PrintGCCause -XX:+PrintTenuringDistribution -XX:+PrintHeapAtGC
-XX:+PrintGCApplicationConcurrentTime -XX:+PrintGCApplicationStoppedTime
-XX:+PrintGCDateStamps -XX:+PrintAdaptiveSizePolicy
-
-rem Uncomment this to generate GC verbose file with Java 9 and above
-rem set VERBOSE_GC=-Xlog:gc*,gc+age=trace,gc+heap=debug:file=gc_jmeter_%%p.log
-rem You may want to add those settings
-rem -XX:+ParallelRefProcEnabled -XX:+PerfDisableSharedMem
+rem Legacy GC verbose options removed (Java 8/9 support discontinued)
+rem Enhanced G1GC tuning for Java 17
+rem Improved G1 performance with better defaults and new features
if not defined GC_ALGO (
- set GC_ALGO=-XX:+UseG1GC -XX:MaxGCPauseMillis=100 -XX:G1ReservePercent=20
+ set GC_ALGO=-XX:+UseG1GC -XX:MaxGCPauseMillis=100 -XX:G1ReservePercent=20
-XX:+ParallelRefProcEnabled -XX:+UseStringDeduplication -XX:G1HeapRegionSize=16m
Review Comment:
Thanks for comment, change in last PR version
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]