[
https://issues.apache.org/jira/browse/ARTEMIS-4147?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17682051#comment-17682051
]
arne anka commented on ARTEMIS-4147:
------------------------------------
Oh, and everywhere else as well.
Just stumbled over
`bin/artemis`
where variables are used
`ARTEMIS_INSTANCE`
but also re-defined for no plausible reason:
`ARTEMIS_INSTANCE_ETC`
Not sure if it is feasible with XML like
`bootstrap.xml`
where the same path is set again.
> artemis.profile: use variables consistently
> -------------------------------------------
>
> Key: ARTEMIS-4147
> URL: https://issues.apache.org/jira/browse/ARTEMIS-4147
> Project: ActiveMQ Artemis
> Issue Type: Bug
> Components: Configuration
> Reporter: arne anka
> Priority: Minor
>
> Generated
> `artemis.profile`
> starts with a section of variables
> ```
> ARTEMIS_HOME='/tmp/apache-artemis-2.27.1'
> ARTEMIS_INSTANCE='/tmp/apache-artemis-2.27.1/artemis'
> ARTEMIS_DATA_DIR='/tmp/apache-artemis-2.27.1/artemis/data'
> ARTEMIS_ETC_DIR='/tmp/apache-artemis-2.27.1/artemis/etc'
> ARTEMIS_OOME_DUMP='/tmp/apache-artemis-2.27.1/artemis/log/oom_dump.hprof
> ARTEMIS_INSTANCE_URI='file:/tmp/apache-artemis-2.27.1/artemis/'
> ARTEMIS_INSTANCE_ETC_URI='file:/tmp/apache-artemis-2.27.1/artemis/etc/'
> ```
> basically none of these variables is being reused.
> So, whenever I need to change either
> `ARTEMIS_HOME`
> or
> `ARTEMIS_INSTANCE`
> I need to change each and every variable.
> Instead, I propose to re-use
> `ARTEMIS_HOME`
> `ARTEMIS_INSTANCE`
> so one needs to change only in one place:
> ```
> ARTEMIS_HOME='/tmp/apache-artemis-2.27.1'
> ARTEMIS_INSTANCE='$ARTEMIS_HOME/artemis'
> ARTEMIS_DATA_DIR='$ARTEMIS_INSTANCE/data'
> ARTEMIS_ETC_DIR='$ARTEMIS_INSTANCE/etc'
> ARTEMIS_OOME_DUMP='$ARTEMIS_INSTANCE/log/oom_dump.hprof
> ARTEMIS_INSTANCE_URI='file:$ARTEMIS_INSTANCE/'
> ARTEMIS_INSTANCE_ETC_URI='file:$ARTEMIS_INSTANCE/etc/'
> ```
--
This message was sent by Atlassian Jira
(v8.20.10#820010)