Uploaded image for project: 'ActiveMQ Artemis'
  1. ActiveMQ Artemis
  2. ARTEMIS-2100

address routing-type overridden on attaching AMQP sender

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.6.2
    • Fix Version/s: 2.6.4, 2.7.0
    • Component/s: None
    • Labels:
      None

      Description

      If the default-address-routing-type is set to ANYCAST and an address is created with routing-type MULTICAST, then when an AMQP sender attaches to that address the address is recreated with routing-type=[MULTICAST,ANYCAST] and a queue with the same name as the address is created. It is expected that the address routing-type should be honoured.

      E.g. on broker with:

               <address-setting match="#">
                  <dead-letter-address>DLQ</dead-letter-address>
                  <expiry-address>ExpiryQueue</expiry-address>
                  <redelivery-delay>0</redelivery-delay>
                  <!-- with -1 only the global-max-size is in use for limiting -->
                  <max-size-bytes>-1</max-size-bytes>
                  <message-counter-history-day-limit>10</message-counter-history-day-limit>
                  <address-full-policy>PAGE</address-full-policy>
                  <auto-create-queues>true</auto-create-queues>
                  <auto-create-addresses>true</auto-create-addresses>
                  <auto-create-jms-queues>true</auto-create-jms-queues>
                  <auto-create-jms-topics>true</auto-create-jms-topics>
                  <default-address-routing-type>ANYCAST</default-address-routing-type>
               </address-setting>
      

      Create a MULTICAST address:

      artemis address create --multicast --no-anycast --name mytopic
      

      Check the address and any queues (feilds ommitted for clarity):

      $ artemis address show --name mytopic
      Address [name=mytopic, routingTypes={MULTICAST}, autoCreated=false]
      $ artemis queue stat
      |NAME                     |ADDRESS                  
      |DLQ                      |DLQ     
      |ExpiryQueue              |ExpiryQueue   
      |activemq.management.612e33f1-1c5f-4bde-99bb-9e9188efa508|activemq.management.612e33f1-1c5f-4bde-99bb-9e9188efa508|1              
      

      Now attach an AMQP sender to the address, e.g. using Qpid Proton python example

      simple_send.py -a localhost/mytopic -m 1
      

      Now the address has been altered and a queue called mytopic exists:

      $ artemis address show --name mytopic
      Address [name=mytopic, routingTypes={MULTICAST,ANYCAST}, autoCreated=false]
      $ artemis queue stat
      |NAME                     |ADDRESS   
      |DLQ                      |DLQ 
      |ExpiryQueue              |ExpiryQueue 
      |activemq.management.5a393c3e-746d-404b-9afb-36849886aaa5|activemq.management.5a393c3e-746d-404b-9afb-36849886aaa5
      |mytopic                  |mytopic               
      

        Attachments

          Activity

            People

            • Assignee:
              nigro.fra@gmail.com Francesco Nigro
              Reporter:
              gsim Gordon Sim
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: