Mule flow para leer los mensajes de la cola en Quartz Scheduler y reenviarlos a un componente de Java

How do I write a Mule flow to use a Quartz Scheduler to read messages from Queue on regular interval (cron)?

My first flow includes a CXF->Queue. I need this in my second flow: Queue->Quartz->Component

  <quartz:inbound-endpoint jobName="ReadQIN" cronExpression="* * * * * ?" repeatInterval="0" doc:name="Quartz">
        <quartz:endpoint-polling-job groupName="ReadQINGroup" jobGroupName="ReadQINJobGroup">
            <quartz:job-endpoint address="jms://QIN"/>
        </quartz:endpoint-polling-job>
    </quartz:inbound-endpoint>

It ended in org.quartz.SchedulerException: Trigger does not reference given job!

preguntado el 09 de marzo de 12 a las 15:03

1 Respuestas

If you provide a "cronExpression" don't provide a "repeatInterval". Also just do not provide values for "groupName" and "jobGroupName" (they are for advanced usage of the underlying Quartz infrastructure).

With these changes applied, the following works fine for me:

    <quartz:inbound-endpoint jobName="ReadQIN"
        cronExpression="* * * * * ?"  doc:name="Quartz">
        <quartz:endpoint-polling-job>
            <quartz:job-endpoint address="jms://QIN" />
        </quartz:endpoint-polling-job>
    </quartz:inbound-endpoint>

respondido 09 mar '12, 18:03

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.