我想有条件地开始m子石英。
例如:在mule peroperties文件中,我放了一个flag = on。如果该标志为on,则只有Scheduler会启动;如果该标志为off,则不会调用schedule。

如何在in子中做到这一点?
请帮忙

最佳答案

Mule与Spring相连,因此the tricks/features you can use to make some beans conditional也应适用于Mule。

我会尝试以下方法:


将启动Quartz端点的流定义提取到quartz-config-on.xml
创建一个名为quartz-config-off.xml的空Mule XML配置
在您的主要Mule XML配置中,使用:<import resource="quartz-config-${quartz.flag}.xml"/>其中,quartz.flagonoff的属性。

关于mule - 有条件地运行M子 quartz ,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/35100683/

10-11 02:56
查看更多