#400 ✓closed
Ben Hood

Invalid cron spec gets persisted

Reported by Ben Hood | October 31st, 2011 @ 01:33 PM | in 1.0 (closed)

Specifying an invalid cron specification (in a XML post) appears to get saved to the database and hence causes a ground hog day scenario whereby Diffa cannot restart itself cleanly because the config has become corrupted (see attached stack trace as a symptom).

Furthermore, the agent does not appear to be impervious to bogus XMLs being updated - what seems to happen is that the agent becomes unresponsive to subsequent XML re-uploads.

Caused by: java.text.ParseException: Support for specifying both a day-of-week AND a day-of-month parameter is not implemented.
        at org.quartz.CronExpression.buildExpression(CronExpression.java:490) ~[quartz-2.1.0.jar:na]
        at org.quartz.CronExpression.<init>(CronExpression.java:276) ~[quartz-2.1.0.jar:na]
        at org.quartz.CronExpression.validateExpression(CronExpression.java:403) ~[quartz-2.1.0.jar:na]
        at org.quartz.CronScheduleBuilder.cronSchedule(CronScheduleBuilder.java:105) ~[quartz-2.1.0.jar:na]
        at net.lshift.diffa.kernel.scheduler.QuartzScanScheduler.assertSchedule$1(QuartzScanScheduler.scala:105) ~[diffa-kernel-0.9-SNAPSHOT.jar:na]
        at net.lshift.diffa.kernel.scheduler.QuartzScanScheduler$$anonfun$onUpdatePair$1.apply(QuartzScanScheduler.scala:134) ~[diffa-kernel-0.9-SNAPSHOT.jar:na]
        at net.lshift.diffa.kernel.scheduler.QuartzScanScheduler$$anonfun$onUpdatePair$1.apply(QuartzScanScheduler.scala:132) ~[diffa-kernel-0.9-SNAPSHOT.jar:na]
        at scala.collection.immutable.Map$Map2.foreach(Map.scala:139) ~[scala-library-2.9.0-1.jar:na]
        at net.lshift.diffa.kernel.scheduler.QuartzScanScheduler.onUpdatePair(QuartzScanScheduler.scala:132) ~[diffa-kernel-0.9-SNAPSHOT.jar:na]
        at net.lshift.diffa.kernel.scheduler.QuartzScanScheduler$$anonfun$1.apply(QuartzScanScheduler.scala:85) ~[diffa-kernel-0.9-SNAPSHOT.jar:na]
        at net.lshift.diffa.kernel.scheduler.QuartzScanScheduler$$anonfun$1.apply(QuartzScanScheduler.scala:85) ~[diffa-kernel-0.9-SNAPSHOT.jar:na]
        at scala.collection.mutable.ResizableArray$class.foreach(ResizableArray.scala:60) ~[scala-library-2.9.0-1.jar:na]
        at scala.collection.mutable.ArrayBuffer.foreach(ArrayBuffer.scala:44) ~[scala-library-2.9.0-1.jar:na]
        at net.lshift.diffa.kernel.scheduler.QuartzScanScheduler.<init>(QuartzScanScheduler.scala:85) ~[diffa-kernel-0.9-SNAPSHOT.jar:na]
        at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[na:1.6.0_16]
        at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39) ~[na:1.6.0_16]
        at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27) ~[na:1.6.0_16]
        at java.lang.reflect.Constructor.newInstance(Constructor.java:513) ~[na:1.6.0_16]
        at org.springframework.beans.BeanUtils.instantiateClass(BeanUtils.java:126) ~[spring-beans-3.0.6.RELEASE.jar:3.0.6.RELEASE]
        ... 24 common frames omitted

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

A Real Time Differencing Tool.

Shared Ticket Bins

People watching this ticket

Referenced by

Pages