This is an automated email from the ASF dual-hosted git repository.

clebertsuconic pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/activemq-artemis.git


The following commit(s) were added to refs/heads/main by this push:
     new 92964e4f00 ARTEMIS-3934 restore settings equivalent to 
-XX:+AggressiveOpts
92964e4f00 is described below

commit 92964e4f001da64b1cf373e65ed0b9728d596c09
Author: Justin Bertram <[email protected]>
AuthorDate: Mon Sep 19 22:07:25 2022 -0500

    ARTEMIS-3934 restore settings equivalent to -XX:+AggressiveOpts
    
    Before we moved to Java 11 we recommended using the -XX:+AggressiveOpts
    JVM tuning option. In Java 8 this was essentially equivalent to setting
    these two main parameters:
    
     - -XX:BiasedLockingStartupDelay=500 (4000 by default)
     - -XX:AutoBoxCacheMax=20000 (128 by default)
    
    BiasedLockingStartupDelay defaults to 0 in Java 11, but AutoBoxCacheMax
    still defaults to 128. Therefore, we should add
    -XX:AutoBoxCacheMax=20000 to restore this optimization that's been lost
    since removing -XX:+AggressiveOpts.
---
 .../org/apache/activemq/artemis/cli/commands/etc/artemis.profile        | 2 +-
 .../org/apache/activemq/artemis/cli/commands/etc/artemis.profile.cmd    | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git 
a/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/etc/artemis.profile
 
b/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/etc/artemis.profile
index 42358eb8ab..56d8adf83e 100644
--- 
a/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/etc/artemis.profile
+++ 
b/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/etc/artemis.profile
@@ -37,7 +37,7 @@ HAWTIO_ROLE='${role}'
 
 # Java Opts
 if [ -z "$JAVA_ARGS" ]; then
-    JAVA_ARGS="-XX:+PrintClassHistogram -XX:+UseG1GC 
-XX:+UseStringDeduplication -Xms512M -Xmx${java-memory} 
-Dhawtio.disableProxy=true -Dhawtio.realm=activemq -Dhawtio.offline=true 
-Dhawtio.rolePrincipalClasses=org.apache.activemq.artemis.spi.core.security.jaas.RolePrincipal
 -Djolokia.policyLocation=${ARTEMIS_INSTANCE_ETC_URI}jolokia-access.xml 
${java-opts}"
+    JAVA_ARGS="-XX:AutoBoxCacheMax=20000 -XX:+PrintClassHistogram -XX:+UseG1GC 
-XX:+UseStringDeduplication -Xms512M -Xmx${java-memory} 
-Dhawtio.disableProxy=true -Dhawtio.realm=activemq -Dhawtio.offline=true 
-Dhawtio.rolePrincipalClasses=org.apache.activemq.artemis.spi.core.security.jaas.RolePrincipal
 -Djolokia.policyLocation=${ARTEMIS_INSTANCE_ETC_URI}jolokia-access.xml 
${java-opts}"
 fi
 
 # Uncomment to enable logging for Safepoint JVM pauses
diff --git 
a/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/etc/artemis.profile.cmd
 
b/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/etc/artemis.profile.cmd
index 729365716c..5367e34fe4 100644
--- 
a/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/etc/artemis.profile.cmd
+++ 
b/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/etc/artemis.profile.cmd
@@ -33,7 +33,7 @@ rem Cluster Properties: Used to pass arguments to ActiveMQ 
Artemis which can be
 rem set ARTEMIS_CLUSTER_PROPS=-Dactivemq.remoting.default.port=61617 
-Dactivemq.remoting.amqp.port=5673 -Dactivemq.remoting.stomp.port=61614 
-Dactivemq.remoting.hornetq.port=5446
 
 rem Java Opts
-IF "%JAVA_ARGS%"=="" (set JAVA_ARGS=${java-opts} -XX:+PrintClassHistogram  
-XX:+UseG1GC -XX:+UseStringDeduplication -Xms512M -Xmx${java-memory} 
-Xbootclasspath/a:%ARTEMIS_HOME%\lib\${logmanager};%ARTEMIS_HOME%\lib\${wildfly-common}
 -Djava.security.auth.login.config=%ARTEMIS_ETC_DIR%\login.config 
-Dhawtio.disableProxy=true -Dhawtio.offline=true -Dhawtio.realm=activemq 
-Dhawtio.role=${role} 
-Dhawtio.rolePrincipalClasses=org.apache.activemq.artemis.spi.core.security.jaas.RolePrincipal
 -Djol [...]
+IF "%JAVA_ARGS%"=="" (set JAVA_ARGS=${java-opts} -XX:AutoBoxCacheMax=20000 
-XX:+PrintClassHistogram  -XX:+UseG1GC -XX:+UseStringDeduplication -Xms512M 
-Xmx${java-memory} 
-Xbootclasspath/a:%ARTEMIS_HOME%\lib\${logmanager};%ARTEMIS_HOME%\lib\${wildfly-common}
 -Djava.security.auth.login.config=%ARTEMIS_ETC_DIR%\login.config 
-Dhawtio.disableProxy=true -Dhawtio.offline=true -Dhawtio.realm=activemq 
-Dhawtio.role=${role} 
-Dhawtio.rolePrincipalClasses=org.apache.activemq.artemis.spi.core.securit [...]
 
 rem Logs Safepoints JVM pauses: Uncomment to enable them
 rem In addition to the traditional GC logs you could enable some JVM flags to 
know any meaningful and "hidden" pause that could

Reply via email to