Github user gtully commented on a diff in the pull request:

    https://github.com/apache/activemq-artemis/pull/1820#discussion_r164162902
  
    --- Diff: 
artemis-jms-client/src/main/java/org/apache/activemq/artemis/jms/client/ActiveMQSession.java
 ---
    @@ -698,8 +699,17 @@ private ActiveMQMessageConsumer createConsumer(final 
ActiveMQDestination dest,
                  */
                 if (!response.isExists() || 
!response.getQueueNames().contains(dest.getSimpleAddress())) {
                    if (response.isAutoCreateQueues()) {
    +                  SimpleString queueNameToUse = dest.getSimpleAddress();
    +                  SimpleString addressToUse = queueNameToUse;
    +                  RoutingType routingTypeToUse = RoutingType.ANYCAST;
    +                  if 
(CompositeAddress.isFullyQualified(queueNameToUse.toString())) {
    +                     CompositeAddress compositeAddress = 
CompositeAddress.getQueueName(queueNameToUse.toString());
    +                     addressToUse = new 
SimpleString(compositeAddress.getAddress());
    +                     queueNameToUse = new 
SimpleString(compositeAddress.getQueueName());
    +                     routingTypeToUse = RoutingType.MULTICAST;
    --- End diff --
    
    The original test case that I added to, had both artemis and openwire jms 
clients in the mix, a parameterised test. It may be that the vt use case needs 
to be constrained to openwire because I think your expectation is correct. I 
guess in the case that the address already existed I may be able to find the 
routing type there. 
    But when both address and queue need to be created core would be out of 
luck.



---

Reply via email to