【发布时间】:2018-08-03 08:04:05
【问题描述】:
我想在一天中的特定时间使用 Quartz 触发流程。问题是流程不是使用 mule 3.4 独立服务器触发的,而是在 mule 3.7 上运行,并且每 2 秒打印一次“hello”。
<?xml version="1.0" encoding="UTF-8"?>
<mule xmlns:quartz="http://www.mulesoft.org/schema/mule/quartz"
xmlns="http://www.mulesoft.org/schema/mule/core"
xmlns:doc="http://www.mulesoft.org/schema/mule/documentation"
xmlns:spring="http://www.springframework.org/schema/beans"
xmlns:task="http://www.springframework.org/schema/task"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.mulesoft.org/schema/mule/quartz http://www.mulesoft.org/schema/mule/quartz/current/mule-quartz.xsd http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-current.xsd http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/current/mule.xsd http://www.springframework.org/schema/task http://www.springframework.org/schema/task/spring-task-3.1.xsd">
<quartz:connector name="quartz_connector" validateConnections="true" doc:name="Quartz"/>
<quartz:endpoint name="QUARTZ_ENDPOINT_NAME" jobName="name"
cronExpression="*/2 * * * * ?" repeatInterval="0"
responseTimeout="10000" connector-ref="quartz_connector"
doc:name="Scheduler">
<quartz:event-generator-job/>
</quartz:endpoint>
<flow name="some_flow" doc:name="some_flow">
<inbound-endpoint ref="QUARTZ_ENDPOINT_NAME" doc:name="QUARTZ_ENDPOINT_NAME_DOC"/>
<flow-ref name="test-flow"/>
</flow>
<flow name="test-flow">
<logger message="hello" level="INFO" doc:name="logger"/>
</flow>
</mule>
mule 3.4 是否存在 Quartz 问题?有什么替代方法可以实现相同的目标吗?
【问题讨论】:
标签: java quartz-scheduler mule-esb