scheduling jobs未起来

项目启动时报错信息:

#### 20220512 09:33:35,324 | org.quartz.plugins.xml.XMLSchedulingDataProcessorPlugin.processFile(XMLSchedulingDataProcessorPlugin.java:324) | ERROR |  Error scheduling jobs: Encountered 2 validation exceptions. 
org.quartz.xml.ValidationException: Encountered 2 validation exceptions.
	at org.quartz.xml.XMLSchedulingDataProcessor.maybeThrowValidationException(XMLSchedulingDataProcessor.java:1230) ~[quartz-2.3.2.jar:?]
	at org.quartz.xml.XMLSchedulingDataProcessor.processFile(XMLSchedulingDataProcessor.java:466) ~[quartz-2.3.2.jar:?]
	at org.quartz.xml.XMLSchedulingDataProcessor.processFileAndScheduleJobs(XMLSchedulingDataProcessor.java:848) ~[quartz-2.3.2.jar:?]
	at org.quartz.plugins.xml.XMLSchedulingDataProcessorPlugin.processFile(XMLSchedulingDataProcessorPlugin.java:319) ~[quartz-2.3.2.jar:?]
	at org.quartz.plugins.xml.XMLSchedulingDataProcessorPlugin.start(XMLSchedulingDataProcessorPlugin.java:246) ~[quartz-2.3.2.jar:?]
	at org.quartz.plugins.SchedulerPluginWithUserTransactionSupport.start(SchedulerPluginWithUserTransactionSupport.java:144) ~[quartz-2.3.2.jar:?]
	at org.quartz.core.QuartzScheduler.startPlugins(QuartzScheduler.java:2389) ~[quartz-2.3.2.jar:?]
	at org.quartz.core.QuartzScheduler.start(QuartzScheduler.java:540) ~[quartz-2.3.2.jar:?]
	at org.quartz.impl.StdScheduler.start(StdScheduler.java:142) ~[quartz-2.3.2.jar:?]
	at com.epoint.basic.timetask.EpointTaskSchedule9.<clinit>(n:497) ~[epoint-common-9.3.4-sp2.jar:?]
	at com.epoint.common.service.AuditCommonStartInit.commonStartInit(AuditCommonStartInit.java:77) ~[epoint-zwfw-common-7.4-SNAPSHOT.jar:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_311]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_311]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_311]
	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_311]
	at com.epoint.core.utils.reflect.ReflectUtil.invokeMethodWithObjHasParame(ReflectUtil.java:909) ~[epoint-utils-9.3.4-sp2.jar:?]
	at com.epoint.core.utils.reflect.ReflectUtil.invokeMethodWithObjHasParame(ReflectUtil.java:419) ~[epoint-utils-9.3.4-sp2.jar:?]
	at com.epoint.core.utils.reflect.ReflectUtil.invokeMethodWithObjHasParame(ReflectUtil.java:365) ~[epoint-utils-9.3.4-sp2.jar:?]
	at com.epoint.core.utils.reflect.ReflectUtil.invokeMethod(ReflectUtil.java:322) ~[epoint-utils-9.3.4-sp2.jar:?]
	at com.epoint.basic.timetask.EpointStartInit.startInit(v:4) ~[epoint-common-9.3.4-sp2.jar:?]
	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_311]
	at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_311]
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_311]
	at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_311]
	at com.epoint.core.utils.reflect.ReflectUtil.invokeMethodWithObjHasParame(ReflectUtil.java:909) ~[epoint-utils-9.3.4-sp2.jar:?]
	at com.epoint.core.utils.reflect.ReflectUtil.invokeMethodWithObjHasParame(ReflectUtil.java:419) ~[epoint-utils-9.3.4-sp2.jar:?]
	at com.epoint.core.utils.reflect.ReflectUtil.invokeMethodWithObjHasParame(ReflectUtil.java:365) ~[epoint-utils-9.3.4-sp2.jar:?]
	at com.epoint.core.utils.reflect.ReflectUtil.invokeMethod(ReflectUtil.java:322) ~[epoint-utils-9.3.4-sp2.jar:?]
	at com.epoint.core.dto.EpointDispatcherServlet.initFrameworkServlet(t:24) ~[epoint-core-4.3.5.jar:?]
	at org.springframework.web.servlet.FrameworkServlet.initServletBean(FrameworkServlet.java:495) ~[spring-webmvc-4.3.25.RELEASE.jar:?]
	at org.springframework.web.servlet.HttpServletBean.init(HttpServletBean.java:171) ~[spring-webmvc-4.3.25.RELEASE.jar:?]
	at javax.servlet.GenericServlet.init(GenericServlet.java:160) ~[tomcat-embed-core-7.0.47.jar:7.0.47]
	at org.apache.catalina.core.StandardWrapper.initServlet(StandardWrapper.java:1280) ~[tomcat-embed-core-7.0.47.jar:7.0.47]
	at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1193) ~[tomcat-embed-core-7.0.47.jar:7.0.47]
	at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:1088) ~[tomcat-embed-core-7.0.47.jar:7.0.47]
	at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:5176) ~[tomcat-embed-core-7.0.47.jar:7.0.47]
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5460) ~[tomcat-embed-core-7.0.47.jar:7.0.47]
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ~[tomcat-embed-core-7.0.47.jar:7.0.47]
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1559) ~[tomcat-embed-core-7.0.47.jar:7.0.47]
	at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1549) ~[tomcat-embed-core-7.0.47.jar:7.0.47]
	at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[?:1.8.0_311]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) ~[?:1.8.0_311]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) ~[?:1.8.0_311]
	at java.lang.Thread.run(Thread.java:748) [?:1.8.0_311]
Caused by: org.xml.sax.SAXParseException: cvc-pattern-valid: Value '*/10 * * * * ? * ' is not facet-valid with respect to pattern '(((([0-9]|[0-5][0-9])(-([0-9]|[0-5][0-9]))?,)*([0-9]|[0-5][0-9])(-([0-9]|[0-5][0-9]))?)|(([\*]|[0-9]|[0-5][0-9])/([0-9]|[0-5][0-9]))|([\?])|([\*]))[\s](((([0-9]|[0-5][0-9])(-([0-9]|[0-5][0-9]))?,)*([0-9]|[0-5][0-9])(-([0-9]|[0-5][0-9]))?)|(([\*]|[0-9]|[0-5][0-9])/([0-9]|[0-5][0-9]))|([\?])|([\*]))[\s](((([0-9]|[0-1][0-9]|[2][0-3])(-([0-9]|[0-1][0-9]|[2][0-3]))?,)*([0-9]|[0-1][0-9]|[2][0-3])(-([0-9]|[0-1][0-9]|[2][0-3]))?)|(([\*]|[0-9]|[0-1][0-9]|[2][0-3])/([0-9]|[0-1][0-9]|[2][0-3]))|([\?])|([\*]))[\s](((([1-9]|[0][1-9]|[1-2][0-9]|[3][0-1])(-([1-9]|[0][1-9]|[1-2][0-9]|[3][0-1]))?,)*([1-9]|[0][1-9]|[1-2][0-9]|[3][0-1])(-([1-9]|[0][1-9]|[1-2][0-9]|[3][0-1]))?(C)?)|(([1-9]|[0][1-9]|[1-2][0-9]|[3][0-1])/([1-9]|[0][1-9]|[1-2][0-9]|[3][0-1])(C)?)|(L(-[0-9])?)|(L(-[1-2][0-9])?)|(L(-[3][0-1])?)|(LW)|([1-9]W)|([1-3][0-9]W)|([\?])|([\*]))[\s](((([1-9]|0[1-9]|1[0-2])(-([1-9]|0[1-9]|1[0-2]))?,)*([1-9]|0[1-9]|1[0-2])(-([1-9]|0[1-9]|1[0-2]))?)|(([1-9]|0[1-9]|1[0-2])/([1-9]|0[1-9]|1[0-2]))|(((JAN|FEB|MAR|APR|MAY|JUN|JUL|AUG|SEP|OCT|NOV|DEC)(-(JAN|FEB|MAR|APR|MAY|JUN|JUL|AUG|SEP|OCT|NOV|DEC))?,)*(JAN|FEB|MAR|APR|MAY|JUN|JUL|AUG|SEP|OCT|NOV|DEC)(-(JAN|FEB|MAR|APR|MAY|JUN|JUL|AUG|SEP|OCT|NOV|DEC))?)|((JAN|FEB|MAR|APR|MAY|JUN|JUL|AUG|SEP|OCT|NOV|DEC)/(JAN|FEB|MAR|APR|MAY|JUN|JUL|AUG|SEP|OCT|NOV|DEC))|([\?])|([\*]))[\s]((([1-7](-([1-7]))?,)*([1-7])(-([1-7]))?)|([1-7]/([1-7]))|(((MON|TUE|WED|THU|FRI|SAT|SUN)(-(MON|TUE|WED|THU|FRI|SAT|SUN))?,)*(MON|TUE|WED|THU|FRI|SAT|SUN)(-(MON|TUE|WED|THU|FRI|SAT|SUN))?(C)?)|((MON|TUE|WED|THU|FRI|SAT|SUN)/(MON|TUE|WED|THU|FRI|SAT|SUN)(C)?)|(([1-7]|(MON|TUE|WED|THU|FRI|SAT|SUN))?(L|LW)?)|(([1-7]|MON|TUE|WED|THU|FRI|SAT|SUN)#([1-7])?)|([\?])|([\*]))([\s]?(([\*])?|(19[7-9][0-9])|(20[0-9][0-9]))?| (((19[7-9][0-9])|(20[0-9][0-9]))/((19[7-9][0-9])|(20[0-9][0-9])))?| ((((19[7-9][0-9])|(20[0-9][0-9]))(-((19[7-9][0-9])|(20[0-9][0-9])))?,)*((19[7-9][0-9])|(20[0-9][0-9]))(-((19[7-9][0-9])|(20[0-9][0-9])))?)?)' for type 'cron-expressionType'.
	at org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.util.ErrorHandlerWrapper.error(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.impl.xs.XMLSchemaValidator$XSIErrorReporter.reportError(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.impl.xs.XMLSchemaValidator.reportSchemaError(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.impl.xs.XMLSchemaValidator.elementLocallyValidType(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.impl.xs.XMLSchemaValidator.processElementContent(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.impl.xs.XMLSchemaValidator.handleEndElement(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.impl.xs.XMLSchemaValidator.endElement(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanEndElement(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.parsers.XMLParser.parse(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.parsers.DOMParser.parse(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source) ~[xercesImpl-2.11.0.jar:?]
	at org.quartz.xml.XMLSchedulingDataProcessor.process(XMLSchedulingDataProcessor.java:501) ~[quartz-2.3.2.jar:?]
	at org.quartz.xml.XMLSchedulingDataProcessor.processFile(XMLSchedulingDataProcessor.java:464) ~[quartz-2.3.2.jar:?]
	... 42 more

根据错误信息,可以很明显地发现是配置错误:

Caused by: org.xml.sax.SAXParseException: cvc-pattern-valid: Value '*/10 * * * * ? * ' is not facet-valid with respect to pattern

 解决方法:表达式前后不能有空格

 总结:

        问题虽小,但却极容易忽视,生产环境下需要特别注意这些配置方面的小细节!!

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值