Uploaded image for project: 'AMQ Broker'
  1. AMQ Broker
  2. ENTMQBR-424

jms.topic producer autocreation fails using qpid-jms client

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Major Major
    • A-MQ 7.0.0.ER14
    • A-MQ 7.0.0.ER13
    • None
    • None

      I have an Artemis broker instance with default configuration.

      bin/artemis create --user admin --password admin --role admin --allow-anonymous amq7i0

      I am running the following Java program which uses qpid-jms to connect to broker and call session.createProducer with a topic. Since jms topic autocreation is on by default, I expect the topic to be created. But this does not happen.

           ConnectionFactory connectionFactory = new JmsConnectionFactory("amqp://127.0.0.1:61616");
            Connection connection = connectionFactory.createConnection();
            connection.start();
            Session session = connection.createSession(false, Session.DUPS_OK_ACKNOWLEDGE);
      
               String name = "jms.topic.mytopic"
               Destination destination = new JmsTopic(name);
               producer = session.createProducer(destination);
               assertNotNull(consumer);
      
            producer.close();
            session.close();
            connection.close();
      

      The code above fails with exception javax.jms.InvalidDestinationException: AMQ219002: target address does not exist [condition = amqp:not-found]

      See the GitHub link above for a full reproducer.

              rh-ee-ataylor Andy Taylor
              jdanek@redhat.com Jiri Daněk
              Jiri Daněk Jiri Daněk
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved: