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

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

                Author: ASF GitHub Bot
            Created on: 15/Jun/21 21:32
            Start Date: 15/Jun/21 21:32
    Worklog Time Spent: 10m 
      Work Description: erwindon commented on a change in pull request #3620:
URL: https://github.com/apache/activemq-artemis/pull/3620#discussion_r652167879



##########
File path: 
artemis-server/src/test/java/org/apache/activemq/artemis/core/config/impl/FileConfigurationParserTest.java
##########
@@ -95,6 +95,22 @@ public void testDuplicateQueue() throws Exception {
       assertEquals(0, 
server.locateQueue(SimpleString.toSimpleString("q")).getMaxConsumers());
    }
 
+   @Test
+   public void testDuplicateAddressSettings() throws Exception {
+      String filename = "FileConfigurationParser-duplicateAddressSettings.xml";
+      FileConfiguration fc = new FileConfiguration();
+      FileDeploymentManager deploymentManager = new 
FileDeploymentManager(filename);
+      deploymentManager.addDeployable(fc);
+      try {
+         deploymentManager.readConfiguration();

Review comment:
       My list of address-settings is a bit more modest. The main reason why I 
fell into this trap is that I did not even realise that the name patterns 
should be unique.
   The startup of Artemis does not produce that much output that one should 
fear that a warning would be missed.
   I would not create a separate warning style for this.
   When there is doubt between warning or error, just go for warning. It is the 
safest choice and still helps to solve the problem much more than the old 
situation (where I needed git-bisect to find the root cause, as I was clueless)




-- 
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.

For queries about this service, please contact Infrastructure at:
[email protected]


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

    Worklog Id:     (was: 611612)
    Time Spent: 2h  (was: 1h 50m)

> duplicate address-setting gets lost
> -----------------------------------
>
>                 Key: ARTEMIS-3343
>                 URL: https://issues.apache.org/jira/browse/ARTEMIS-3343
>             Project: ActiveMQ Artemis
>          Issue Type: Improvement
>          Components: Configuration
>    Affects Versions: 2.17.0
>            Reporter: Erwin Dondorp
>            Priority: Major
>          Time Spent: 2h
>  Remaining Estimate: 0h
>
> In setting file `broker.xml`, it is possible to register multiple 
> `address-setting` blocks for the same `match`. But because these blocks are 
> put in a `Map` (in 
> `org.apache.activemq.artemis.core.deployers.impl.parseAddressSettings()`), 
> any previous block with the same `match` will be effectively ignored.
> This may also happen for some of the other named blocks.
> My suggestion is to raise an error when configuration information is lost.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to