This is an automated email from the ASF dual-hosted git repository. gtully 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 45ffea9ef8 ARTEMIS-4002 - support JAVA_ARGS_APPEND env var to easily modify the jdk comand line, JDK_JAVA_OPTIONS is prepend only 45ffea9ef8 is described below commit 45ffea9ef824bd009bc47c94e6c9e6285cd83e3a Author: Gary Tully <gary.tu...@gmail.com> AuthorDate: Fri Oct 28 12:05:57 2022 +0100 ARTEMIS-4002 - support JAVA_ARGS_APPEND env var to easily modify the jdk comand line, JDK_JAVA_OPTIONS is prepend only --- .../main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis | 1 + .../resources/org/apache/activemq/artemis/cli/commands/bin/artemis.cmd | 1 + artemis-distribution/src/main/resources/bin/artemis | 1 + artemis-distribution/src/main/resources/bin/artemis.cmd | 1 + docs/user-manual/en/using-server.md | 2 ++ tests/e2e-tests/src/main/resources/containerService/artemis | 1 + 6 files changed, 7 insertions(+) diff --git a/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis b/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis index 5ee4f1e3a0..0baaf170bc 100755 --- a/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis +++ b/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis @@ -114,4 +114,5 @@ exec "$JAVACMD" \ -Dartemis.instance.etc="$ARTEMIS_INSTANCE_ETC" \ -Dartemis.default.sensitive.string.codec.key="$ARTEMIS_DEFAULT_SENSITIVE_STRING_CODEC_KEY" \ $DEBUG_ARGS \ + $JAVA_ARGS_APPEND \ org.apache.activemq.artemis.boot.Artemis "$@" diff --git a/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis.cmd b/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis.cmd index 5c86cb583c..2ae3e3ee6f 100644 --- a/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis.cmd +++ b/artemis-cli/src/main/resources/org/apache/activemq/artemis/cli/commands/bin/artemis.cmd @@ -65,6 +65,7 @@ set JVM_ARGS=%JVM_ARGS% -Dartemis.instance.etc=%ARTEMIS_INSTANCE_ETC% set JVM_ARGS=%JVM_ARGS% -Dartemis.default.sensitive.string.codec.key=%ARTEMIS_DEFAULT_SENSITIVE_STRING_CODEC_KEY% if not "%DEBUG_ARGS%"=="" set JVM_ARGS=%JVM_ARGS% %DEBUG_ARGS% +if not "%$JAVA_ARGS_APPEND%"=="" set JVM_ARGS=%JVM_ARGS% %$JAVA_ARGS_APPEND% "%_JAVACMD%" %JVM_ARGS% org.apache.activemq.artemis.boot.Artemis %* diff --git a/artemis-distribution/src/main/resources/bin/artemis b/artemis-distribution/src/main/resources/bin/artemis index c7076c64a2..29dce4abc7 100755 --- a/artemis-distribution/src/main/resources/bin/artemis +++ b/artemis-distribution/src/main/resources/bin/artemis @@ -95,4 +95,5 @@ exec "$JAVACMD" $JAVA_ARGS $ARTEMIS_CLUSTER_PROPS \ -Dartemis.home="$ARTEMIS_HOME" \ -Djava.library.path="$ARTEMIS_HOME/bin/lib/linux-$(uname -m)" \ $DEBUG_ARGS \ + $JAVA_ARGS_APPEND \ org.apache.activemq.artemis.boot.Artemis "$@" diff --git a/artemis-distribution/src/main/resources/bin/artemis.cmd b/artemis-distribution/src/main/resources/bin/artemis.cmd index fd8bb93118..273bf851e2 100755 --- a/artemis-distribution/src/main/resources/bin/artemis.cmd +++ b/artemis-distribution/src/main/resources/bin/artemis.cmd @@ -53,6 +53,7 @@ if not "%ARTEMIS_CLUSTER_PROPS%"=="" set JVM_ARGS=%JVM_ARGS% %ARTEMIS_CLUSTER_PR set JVM_ARGS=%JVM_ARGS% -classpath %ARTEMIS_HOME%\lib\artemis-boot.jar set JVM_ARGS=%JVM_ARGS% -Dartemis.home=%ARTEMIS_HOME% if not "%DEBUG_ARGS%"=="" set JVM_ARGS=%JVM_ARGS% %DEBUG_ARGS% +if not "%JAVA_ARGS_APPEND%"=="" set JVM_ARGS=%JVM_ARGS% %JAVA_ARGS_APPEND% "%_JAVACMD%" %JVM_ARGS% org.apache.activemq.artemis.boot.Artemis %* diff --git a/docs/user-manual/en/using-server.md b/docs/user-manual/en/using-server.md index 08306054cc..06c7586b95 100644 --- a/docs/user-manual/en/using-server.md +++ b/docs/user-manual/en/using-server.md @@ -527,6 +527,8 @@ manager at boot time. Package the dependency in a jar and put it on the boot classpath before of log manager jar. This can be done appending the jar at the variable `JAVA_ARGS`, defined in `artemis.profile`, with the option `-Xbootclasspath/a`. +Note: the environment variable `JAVA_ARGS_APPEND` can be used to append or override options. + ## Adding Runtime Dependencies Runtime dependencies like diverts, transformers, broker plugins, JDBC drivers, diff --git a/tests/e2e-tests/src/main/resources/containerService/artemis b/tests/e2e-tests/src/main/resources/containerService/artemis index 4ab71c12f6..c48fc130e6 100755 --- a/tests/e2e-tests/src/main/resources/containerService/artemis +++ b/tests/e2e-tests/src/main/resources/containerService/artemis @@ -114,4 +114,5 @@ exec "$JAVACMD" \ -Dartemis.instance.etc="$ARTEMIS_INSTANCE_ETC" \ -Dartemis.default.sensitive.string.codec.key="$ARTEMIS_DEFAULT_SENSITIVE_STRING_CODEC_KEY" \ $DEBUG_ARGS \ + $JAVA_ARGS_APPEND \ org.apache.activemq.artemis.boot.Artemis "$@"