Immutant
  1. Immutant
  2. IMMUTANT-198

Replace queue listeners and append topic listeners by default

    Details

    • Type: Feature Request Feature Request
    • Status: Closed Closed (View Workflow)
    • Priority: Major Major
    • Resolution: Done
    • Affects Version/s: 0.7.0
    • Fix Version/s: 0.8.0
    • Labels:
      None
    • Similar Issues:
      Show 10 results 

      Description

      Multiple listen calls should replace listeners for queues, and they should append listeners for topics.

      Once this default behavior is implemented, we need to determine how best to override it, if at all.

        Activity

        Hide
        Jim Crossley
        added a comment -

        With the latest commit (see Source tab) behavior is as suggested by this issue with no way to override. Multiple invocations of listen for any destination (queue or topic) with the exact same arguments should be idempotent, i.e. "replace" the existing handler.

        This is all based on the name we create for the listener's jboss "service". Since the handler function is not a part of that name for queues, multiple calls with the same dest and selector will replace the handler.

        The handler function is a part of the listener's name for topics, however. So multiple calls with the same dest and selector but different handlers will not replace any existing handler: both will be active.

        Hopefully, this matches default user expectations for queues and topics, but it's probably best to call unlisten before re-invoking listen and not rely on it.

        Show
        Jim Crossley
        added a comment - With the latest commit (see Source tab) behavior is as suggested by this issue with no way to override. Multiple invocations of listen for any destination (queue or topic) with the exact same arguments should be idempotent, i.e. "replace" the existing handler. This is all based on the name we create for the listener's jboss "service". Since the handler function is not a part of that name for queues, multiple calls with the same dest and selector will replace the handler. The handler function is a part of the listener's name for topics, however. So multiple calls with the same dest and selector but different handlers will not replace any existing handler: both will be active. Hopefully, this matches default user expectations for queues and topics, but it's probably best to call unlisten before re-invoking listen and not rely on it.

          People

          • Assignee:
            Jim Crossley
            Reporter:
            Jim Crossley
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: