4 Replies Latest reply on Dec 2, 2009 6:45 AM by Tom Eicher


    Tom Eicher Newbie


      can someone please drop me a note about the idea behind the
      ScheduledEventListener interface...?

      If I'm a ScheduledEventMessageComposer as a listener in a service, I'll
      create a message, that is then processed in the action pipeline, ok.

      But if I'm a ScheduledEventListener, I can not produce a message for the
      pipeline, processing takes place in the ScheduledEventListener.onSchedule().
      However, I'm still forced to put some action in the action pipeline, since the
      XSD enforces it. But I have no message to process.

      What is the idea (good or bad) behind that ? Shall I just put a "NOOPAction" ?

      My use case: I want to periodically do stuff, like, log queue statistics, so
      an action pipeline is not really involved...

      Thanks, Cheers, Tom.

        • 1. Re: ScheduledEventListener
          Kevin Conner Master

          You shouldn't need to specify the actions, can you show us your jboss-esb.xml?

          • 2. Re: ScheduledEventListener
            Tom Eicher Newbie

            Hi Kevin,

            well, looking at the jbossesb-1.1.0.xsd (also 1.0.1), everything in
            is "minOccurs 1", so I think a listener that does not produce a message
            doesn't make sense, does it ?

            <service category="XXJmsDefault"
             description="Monitor error queues"
             invmScope="GLOBAL" name="XXErrorMonitor">
             <scheduled-listener name="altertingListenerPosLog" schedule-frequency="60"
             <property name="queueName" value="queue/XX_POS_LOG_ERROR"/>
             <!-- action is minOccurs=1 ... need to put a NOOP action here... -->
             <action class="xxx.NOOPAction" name="alertingNOOPAction"/>

            Cheers, Tom.

            • 3. Re: ScheduledEventListener
              Kevin Conner Master

              Yes, but actions is minOccurs="0"

              <xsd:element maxOccurs="1" minOccurs="0" ref="jesb:actions" />

              The pipeline should only be instantiated if using ScheduledEventMessageComposer, in which case it will need actions.


              • 4. Re: ScheduledEventListener
                Tom Eicher Newbie

                Ah, funny how one can check, and still not see the obvious...
                Sorry about that.
                Cheers, Tom.