Apache Camel Quartz2 теперь не работает
Я использую Quartz2 "Firenow", который входит в Apache Camel 2.23.2, он не работает согласованно.
Иногда он срабатывает через долгое время, а иногда не срабатывает.
Проблема возникает не очень часто. Я попытался включить журналы, чтобы выяснить, что происходит. я не видел ни одного сообщения об ошибке. единственное различие, которое я нашел между рабочей и нерабочей работой, - это порядок, в котором вызывается потребитель
Рабочие журналы
org.apache.camel.component.quartz2.QuartzComponent##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Setting org.quartz.scheduler.jmx.export=true to ensure QuartzScheduler(s) will be enlisted in JMX.|
org.apache.camel.component.quartz2.QuartzComponent##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Creating SchedulerFactory: 1557418314584-Timer_Issue with properties: {org.quartz.scheduler.jmx.export=true, org.quartz.scheduler.skipUpdateCheck=true, org.quartz.scheduler.instanceName=1557418314584-Timer_Issue, org.terracotta.quartz.skipUpdateCheck=true, org.quartz.threadPool.threadCount=1}|
org.apache.camel.component.quartz2.QuartzComponent##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Create and initializing scheduler.|
org.apache.camel.component.quartz2.QuartzComponent##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Storing camelContextName=Timer_Issue into Quartz Context space.|
org.apache.camel.component.quartz2.QuartzEndpoint##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Creating new CamelJob.|
org.apache.camel.component.quartz2.QuartzEndpoint##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Created jobDetail=JobDetail 'Camel_Timer_Issue.TimerIssueTimerEventDefinition3719721': jobClass: 'org.apache.camel.component.quartz2.CamelJob concurrentExectionDisallowed: false persistJobDataAfterExecution: false isDurable: false requestsRecovers: false|
org.apache.camel.component.quartz2.QuartzEndpoint##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Creating SimpleTrigger.|
org.apache.camel.component.quartz2.QuartzEndpoint##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Setting user extra triggerParameters {repeatCount=0, repeatInterval=0}|
org.apache.camel.component.quartz2.QuartzEndpoint##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Created trigger=Trigger 'Camel_Timer_Issue.TimerIssueTimerEventDefinition3719721': triggerClass: 'org.quartz.impl.triggers.SimpleTriggerImpl calendar: 'null' misfireInstruction: 1 nextFireTime: null|
org.apache.camel.component.quartz2.QuartzHelper##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Adding camelContextName=Timer_Issue, endpointUri=quartz2://TimerIssueTimerEventDefinition3719721?fireNow=true&trigger.repeatCount=0&trigger.repeatInterval=0 into job data map.|
org.apache.camel.component.quartz2.QuartzEndpoint##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Job Camel_Timer_Issue.TimerIssueTimerEventDefinition3719721 (triggerType=SimpleTriggerImpl, jobClass=CamelJob) is scheduled. Next fire date is Thu May 09 16:11:56 UTC 2019|
org.apache.camel.component.quartz2.QuartzComponent##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Storing camelContextName=Timer_Issue into Quartz Context space.|
**org.apache.camel.component.quartz2.QuartzComponent##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Starting scheduler.|
org.apache.camel.component.quartz2.QuartzConsumer##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Starting consumer: Consumer[quartz2://TimerIssueTimerEventDefinition3719721?fireNow=true&trigger.repeatCount=0&trigger.repeatInterval=0]|
org.apache.camel.component.quartz2.CamelJob##anonymous#1557418314584-Timer_Issue_Worker-1####na#na#na#na#Running CamelJob jobExecutionContext=JobExecutionContext: trigger: 'Camel_Timer_Issue.TimerIssueTimerEventDefinition3719721 job: Camel_Timer_Issue.TimerIssueTimerEventDefinition3719721 fireTime: 'Thu May 09 16:11:56 UTC 2019 scheduledFireTime: Thu May 09 16:11:56 UTC 2019 previousFireTime: 'null nextFireTime: null isRecovering: false refireCount: 0|
org.apache.camel.component.quartz2.CamelJob##anonymous#1557418314584-Timer_Issue_Worker-1####na#na#na#na#Looking up existing QuartzEndpoint with triggerKey=Camel_Timer_Issue.TimerIssueTimerEventDefinition3719721|**
Не работает
INFO#org.apache.camel.component.quartz2.QuartzComponent##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Setting org.quartz.scheduler.jmx.export=true to ensure QuartzScheduler(s) will be enlisted in JMX.|
DEBUG#org.apache.camel.component.quartz2.QuartzComponent##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Creating SchedulerFactory: 1557418506499-Timer_Issue with properties: {org.quartz.scheduler.jmx.export=true, org.quartz.scheduler.skipUpdateCheck=true, org.quartz.scheduler.instanceName=1557418506499-Timer_Issue, org.terracotta.quartz.skipUpdateCheck=true, org.quartz.threadPool.threadCount=1}|
INFO#org.apache.camel.component.quartz2.QuartzComponent##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Create and initializing scheduler.|
org.apache.camel.component.quartz2.QuartzComponent##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Storing camelContextName=Timer_Issue into Quartz Context space.|
org.apache.camel.component.quartz2.QuartzEndpoint##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Creating new CamelJob.|
org.apache.camel.component.quartz2.QuartzEndpoint##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Created jobDetail=JobDetail 'Camel_Timer_Issue.TimerIssueTimerEventDefinition3719721': jobClass: 'org.apache.camel.component.quartz2.CamelJob concurrentExectionDisallowed: false persistJobDataAfterExecution: false isDurable: false requestsRecovers: false|
org.apache.camel.component.quartz2.QuartzEndpoint##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Creating SimpleTrigger.|
org.apache.camel.component.quartz2.QuartzEndpoint##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Setting user extra triggerParameters {repeatCount=0, repeatInterval=0}|
org.apache.camel.component.quartz2.QuartzEndpoint##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Created trigger=Trigger 'Camel_Timer_Issue.TimerIssueTimerEventDefinition3719721': triggerClass: 'org.quartz.impl.triggers.SimpleTriggerImpl calendar: 'null' misfireInstruction: 1 nextFireTime: null|
org.apache.camel.component.quartz2.QuartzHelper##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Adding camelContextName=Timer_Issue, endpointUri=quartz2://TimerIssueTimerEventDefinition3719721?fireNow=true&trigger.repeatCount=0&trigger.repeatInterval=0 into job data map.|
org.apache.camel.component.quartz2.QuartzEndpoint##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Job Camel_Timer_Issue.TimerIssueTimerEventDefinition3719721 (triggerType=SimpleTriggerImpl, jobClass=CamelJob) is scheduled. Next fire date is Thu May 09 16:15:07 UTC 2019|
org.apache.camel.component.quartz2.QuartzComponent##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Storing camelContextName=Timer_Issue into Quartz Context space.|
Я выделил разницу в следующем блоке. Похоже, что CamelJob запускается еще до того, как потребитель начнет.
org.apache.camel.component.quartz2.QuartzComponent##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Starting scheduler.|
org.apache.camel.component.quartz2.CamelJob##anonymous#1557418506499-Timer_Issue_Worker-1####na#na#na#na#Running CamelJob jobExecutionContext=JobExecutionContext: trigger: 'Camel_Timer_Issue.TimerIssueTimerEventDefinition3719721 job: Camel_Timer_Issue.TimerIssueTimerEventDefinition3719721 fireTime: 'Thu May 09 16:15:07 UTC 2019 scheduledFireTime: Thu May 09 16:15:07 UTC 2019 previousFireTime: 'null nextFireTime: null isRecovering: false refireCount: 0|
org.apache.camel.component.quartz2.CamelJob##anonymous#1557418506499-Timer_Issue_Worker-1####na#na#na#na#Looking up existing QuartzEndpoint with triggerKey=Camel_Timer_Issue.TimerIssueTimerEventDefinition3719721|
org.apache.camel.component.quartz2.QuartzConsumer##anonymous#Blueprint Event Dispatcher: 1####na#na#na#na#Starting consumer: Consumer[quartz2://TimerIssueTimerEventDefinition3719721?fireNow=true&trigger.repeatCount=0&trigger.repeatInterval=0]|
Как я могу это исправить?