Uploaded image for project: 'ActiveMQ C++ Client'
  1. ActiveMQ C++ Client
  2. AMQCPP-386

Run-time Setting of Destination Prefix

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 3.3.0, 3.4.0, 3.4.1
    • 3.5.0
    • Stomp
    • All

    • Patch Available

    Description

      Some STOMP-aware message brokers (such as HornetQ) want their destinations prefixed in a manner different from "/queue/" or "/topic/". HornetQ, for example, wants it to be "jms.queue." or "jms.topic.".

      To address this, I've made some changes to StompHelper, adding the following URI parameters:

      • wireFormat.queuePrefix - defaults to "/queue/"
      • wireFormat.topicPrefix - defaults to "/topic/"
      • wireFormat.tempQueuePrefix - defaults to "/temp-queue/"
      • wireFormat.tempTopicPrefix - defaults to "/temp-topic/"

      My patch, however, fails to utilize the framework laid out by the StompWireformatProperties class, as the current code structure makes it very hard. Regardless, I've tested it with the SimpleProducer example (make sure you provide guest/guest as auth params if you're running a vanilla HornetQ) and it seems to work fine.

      The patch is against the activemq-cpp-3.4.1 tag as trunk wouldn't compile; some formatting issues may be present as well.

      Attachments

        1. stomp-prefixes.patch
          8 kB
          Mark Rappoport

        Activity

          People

            tabish Timothy A. Bish
            marklar Mark Rappoport
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: