ravendb / quartznet-RavenDB

RavenDB JobStore support for Quartz.NET scheduler.
Apache License 2.0
27 stars 19 forks source link

Exception when creating a new trigger #9

Closed alexeyzimarev closed 2 years ago

alexeyzimarev commented 8 years ago

When new trigger is getting created, I get this exception:

[13:54:05 ERR] quartzSchedulerThreadLoop: RuntimeException Unable to cast object of type 'Quartz.Impl.RavenDB.Trigger' to type 'Quartz.Impl.RavenDB.Job'. System.InvalidCastException: Unable to cast object of type 'Quartz.Impl.RavenDB. Trigger' to type 'Quartz.Impl.RavenDB.Job'. at Raven.Client.Document.DocumentSession.Load[T](String id) in c:\Builds\Rave nDB-Stable-3.0\Raven.Client.Lightweight\Document\DocumentSession.cs:line 263 at Quartz.Impl.RavenDB.RavenJobStore.AcquireNextTriggers(DateTimeOffset noLat erThan, Int32 maxCount, TimeSpan timeWindow) at Quartz.Core.QuartzSchedulerThread.Run() in c:\Program Files (x86)\Jenkins\ workspace\Quartz.NET\src\Quartz\Core\QuartzSchedulerThread.cs:line 253

iftahbe commented 8 years ago

Hi Alexey, First of all, thanks for the feedback. I am not getting this exception when creating triggers in the demo. Can you please explain what kind of trigger you're creating and how? Or even better, supply a short failing test?

alexeyzimarev commented 8 years ago

I will try to create a reproduction, I am on holidays now.