Uploaded image for project: 'Qpid Dispatch'
  1. Qpid Dispatch
  2. DISPATCH-641

Make containerId attribute work with clients

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Won't Fix
    • 0.7.0
    • 0.8.0
    • Router Node
    • None

    Description

      During verification of issue https://issues.apache.org/jira/browse/DISPATCH-628
      I found out that when I set this containerId in the clients, router can see it but it can not route it.

      E.g. I have sender with the containerId "xxx" and autoLink entity with the containerId "xxx" ->
      this autoLink does not activate in this scenario.

      Simply said when I have sender/receiver with the containerId set and matching the containerId attribute in the configuration file, it does
      not accept the connection. e.g. linkRoute usage ends with the "Link error: No route to the destination node".

      Possible configuration to use(same applies for autoLink entities)

      router {
          mode: standalone
          id: Router.A
      }
      
      listener {
          host: 0.0.0.0
          port: amqp
          authenticatePeer: no
          saslMechanisms: ANONYMOUS
      }
      
      connector {
          name: broker
          host: MY-HOST
          role: route-container
          port: amqp
      }
      
      address {
          prefix: jms.queue
          waypoint: yes
          distribution: balanced
      }
      
      linkRoute {
          name: myqueueIn
          dir: in
          prefix: jms.queue.myqueue
          connection: broker
          containerId: dtest
      }
      
      linkRoute {
          name: myqueueOut
          dir: out
          prefix: jms.queue.myqueue
          connection: broker
          containerId: dtest
      }
      
      log {
          module: MESSAGE
          enable: debug
          timestamp: yes
      }
      

      Right now, router works only as described e.g. here https://issues.apache.org/jira/browse/DISPATCH-640

      In such a case, it is important to set a name (aka container_id) for the broker, matching the value of containerId attribute of the chosen linkRoute/autoLink entity. Then all messages are routed to this broker, ignoring the value of container_id of the actual client itself.

      Request is that this value would be used to "specify" which clients would actually be allowed to make a connection to the broker.

      Usages:
      Scenario A:
      1. Client has containerId=xxx, address="myqueue"
      2. linkRoute has containerId=yyy, prefix="myqueue"
      resolution: connection won't be established, not matching containerId

      Scenario B:
      1. Client has containerId=xxx, address="myqueue"
      2. linkRoute has containerId=xxx, prefix="myqueue"
      resolution: connection will be established, client sends messages to the broker

      As described in https://issues.apache.org/jira/browse/DISPATCH-639 ->
      "if there is a container field, use it otherwise use the connection_field to specify the connection to use."

      This could be elevated to the use case, where an condition as:
      "if there is container field and also connection_field specified, demand matching containerId from the client"

      Attachments

        Issue Links

          Activity

            People

              gmurthy Ganesh Murthy
              DarkEye Matej Lesko
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: