Camel
  1. Camel
  2. CAMEL-1698

Break out the smack listeners implemented by XmppConsumer out to separate classes, and add a ConnectionListener.

    Details

    • Type: Improvement Improvement
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0-M1
    • Fix Version/s: Future
    • Component/s: camel-xmpp
    • Labels:
      None

      Description

      According to the smack documentation if you register the same listener multiple times, only the most recent filter is used.
      Since the XmppConsumer is being used for all listeners in this case only the last add<Message|Packet>Listener call is honored.
      It would be wiser to have the listeners as separate classes, then the handling of each packet/message type can be addressed separately.
      A ConnectionListener can be added as well to handle connections that go down and can be retried later.
      Proposed listeners:
      ConnectionListener (to listen to and respond to connection and disconnection events)
      MessageListener (to listen to and process messages)
      RosterListener (to listen to and process roster events)
      PresenceListeners (should be one for most types of listener defined in org.jivesoftware.smack.packet)

      Each listener type should be able to pass messages up through the camel exchange. All except the MessageListener should be disabled by default, but enabled via an option in the uri passed to camel. MessageListener should always pass the message up through the camel exchange.

        Issue Links

          Activity

          Transition Time In Source Status Execution Times Last Executer Last Execution Date
          Open Open Resolved Resolved
          1120d 14h 12m 1 Claus Ibsen 06/Jul/12 08:02
          Claus Ibsen made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Assignee Claus Ibsen [ davsclaus ]
          Resolution Fixed [ 1 ]
          Hide
          Claus Ibsen added a comment -

          Lets close old ticket that are not in demand.

          Show
          Claus Ibsen added a comment - Lets close old ticket that are not in demand.
          Claus Ibsen made changes -
          Assignee Stan Lewis [ slewis ]
          Jeff Turner made changes -
          Project Import Sat Nov 27 00:14:50 EST 2010 [ 1290834890113 ]
          Claus Ibsen made changes -
          Fix Version/s 2.3.0 [ 12184 ]
          Fix Version/s Future [ 11977 ]
          Hide
          Claus Ibsen added a comment -

          Okay I am putting this out of the 2.3 roadmap as AMQ 5.4 is most likely not around the corner

          Show
          Claus Ibsen added a comment - Okay I am putting this out of the 2.3 roadmap as AMQ 5.4 is most likely not around the corner
          Hide
          Stan Lewis added a comment -

          Have gotten some patches to ActiveMQ committed that allows me to use a broker as a mock XMPP server, just waiting for 5.4 to be released to then commit these changes to the camel-xmpp tests, then I can look into doing this, I think it'll require some refactoring so I wanted to have an easier way to test.

          Show
          Stan Lewis added a comment - Have gotten some patches to ActiveMQ committed that allows me to use a broker as a mock XMPP server, just waiting for 5.4 to be released to then commit these changes to the camel-xmpp tests, then I can look into doing this, I think it'll require some refactoring so I wanted to have an easier way to test.
          Hide
          Claus Ibsen added a comment -

          Stan what is the status of this one?

          Show
          Claus Ibsen added a comment - Stan what is the status of this one?
          Stan Lewis made changes -
          Link This issue depends upon CAMEL-2480 [ CAMEL-2480 ]
          Claus Ibsen made changes -
          Fix Version/s 2.2.0 [ 12170 ]
          Fix Version/s 2.3.0 [ 12184 ]
          Claus Ibsen made changes -
          Fix Version/s 2.2.0 [ 12170 ]
          Hide
          Stan Lewis added a comment -

          Yeah, this is definitely a good idea, will look into it.

          Show
          Stan Lewis added a comment - Yeah, this is definitely a good idea, will look into it.
          Claus Ibsen made changes -
          Field Original Value New Value
          Assignee Stan Lewis [ slewis ]
          Hide
          Claus Ibsen added a comment -

          Stan, a XMPP related ticket, do you mind take a look?

          Show
          Claus Ibsen added a comment - Stan, a XMPP related ticket, do you mind take a look?
          Edward Campbell created issue -

            People

            • Assignee:
              Claus Ibsen
              Reporter:
              Edward Campbell
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development