[ 
https://issues.apache.org/jira/browse/ARTEMIS-5588?focusedWorklogId=985301&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-985301
 ]

ASF GitHub Bot logged work on ARTEMIS-5588:
-------------------------------------------

                Author: ASF GitHub Bot
            Created on: 01/Oct/25 09:52
            Start Date: 01/Oct/25 09:52
    Worklog Time Spent: 10m 
      Work Description: gemmellr commented on code in PR #5942:
URL: https://github.com/apache/activemq-artemis/pull/5942#discussion_r2394023768


##########
artemis-server/src/main/java/org/apache/activemq/artemis/core/server/impl/ActiveMQServerImpl.java:
##########
@@ -4624,9 +4625,14 @@ public void reloadConfigurationFile() throws Exception {
    }
 
    private void reloadConfigurationFile(URL uri) throws Exception {
-      Configuration config = new 
FileConfigurationParser().parseMainConfig(uri.openStream());
-      LegacyJMSConfiguration legacyJMSConfiguration = new 
LegacyJMSConfiguration(config);
-      legacyJMSConfiguration.parseConfiguration(uri.openStream());
+      Configuration config = null;

Review Comment:
   I agree with what Tim said, this seems like it just overwrites various 
settings in an originally-present Configuration[Impl] in the 
_\[this.\]configuration_ field, using the values from a freshly created 
_config_ ConfigurationImpl which may be different.
   
   There is no comparison done, it just gets the values from the new _config_ 
and sets them on the existing _configuration_. Anything that is 'actually 
reloadable' amongst these updated bits can then be reloaded, potentially with 
the default / wrong value, in the deployReloadableConfigFromConfiguration 
method that uses these now-overwritten settings.
   
   It feels to me like it should do more like it did originally, if there is no 
xml config uri (the 'uri' parameter should probably be renamed to make clear 
thats what it is) then its the case that the properties are the only thing 
reloadable and it should just no-op the XML-config related section and use the 
original _configuration_ object settings. Essentially the same as it did before 
now, because it didnt try to reload _anything_ when there was no XML config.





Issue Time Tracking
-------------------

    Worklog Id:     (was: 985301)
    Time Spent: 1h 10m  (was: 1h)

> config reload of properties requires an xml config
> --------------------------------------------------
>
>                 Key: ARTEMIS-5588
>                 URL: https://issues.apache.org/jira/browse/ARTEMIS-5588
>             Project: ActiveMQ Artemis
>          Issue Type: Improvement
>          Components: Configuration
>    Affects Versions: 2.42.0
>            Reporter: Gary Tully
>            Assignee: Gary Tully
>            Priority: Major
>              Labels: pull-request-available
>          Time Spent: 1h 10m
>  Remaining Estimate: 0h
>
> An embedded broker can work without any xml config and will load broker 
> properties to configure as needed, however the config reload for properties 
> paths feature is gated on the presence of a config url provided by the xml 
> parser.
> reload should be able to work with a null config url. 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information, visit: https://activemq.apache.org/contact


Reply via email to