Stacktrace for the ComponentNotFoundException. What I assume is that Quartz can't find the SampleJob.
at Castle.MicroKernel.DefaultKernel.Castle.MicroKernel.IKernelInternal.Resolve(Type service, IDictionary arguments, IReleasePolicy policy) at Castle.MicroKernel.DefaultKernel.Resolve(Type service) at Castle.Facilities.QuartzIntegration.WindsorJobFactory.NewJob(TriggerFiredBundle bundle, IScheduler scheduler) in g:\prg\QuartzNetIntegration.gitsvn\QuartzNetIntegration\QuartzNetIntegration\WindsorJobFactory.cs:line 51 https://github.com/castleprojectcontrib/QuartzNetIntegration/blob/master/QuartzNetIntegration/WindsorJobFactory.cs In my eyes the job-type is correct. First the FullName and then the Assembly: <job-type>HelpLine.Application.WebAPI.Quartz.SampleJob, HelpLine.Application.WebAPI</job-type> I get the exception at the first component I want to register in my container. Even when I put : container.Register(Component.For<IJob>().ImplementedBy<SampleJob >().LifestyleTransient()); When I initialize the Windsor container I use the XmlInterpreter. Then when it is initialized, the container contains the following items: -QuartzNetScheduler -QuartzNetSimpleScheduler -WindsorJobFactory -SampleJobListener -SampleTriggerListener -SampleSchedulerListener -FileScanJob But when I try to register something to the container, it throws this exception. So it never get's to the point where I am able to register the SampleJob. Op woensdag 14 mei 2014 12:36:19 UTC+2 schreef Jonathon Rossi: > I assume you have registered the SampleJob in your Windsor container. If > so, it might be a transitive component injected via the constructor that it > cannot find. > > Can you try turning on catch all CLR exceptions in VS and run it again so > you can get the message text from the ComponentNotFoundException. > > On Wed, May 14, 2014 at 8:28 PM, Edwin Vliet > <[email protected]<javascript:> > > wrote: > > I thought it wouldn't be much trouble configuring the job correctly. > > But it simply does not execute. > In my output I see the following lines which concern me: > > A first chance exception of type > 'Castle.MicroKernel.ComponentNotFoundException' occurred in > Castle.Windsor.dll > > A first chance exception of type 'Quartz.SchedulerException' occurred in > Quartz.dll > But I can't figure out what component is not found... > I got my JobType in my quartz_jobs.xml by using the GetType() function. > > <?xml version="1.0" encoding="utf-8" ?> > <job-scheduling-data xmlns=" > http://quartznet.sourceforge.net/JobSchedulingData" > > xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"version="2.0"> > > <processing-directives> > <overwrite-existing-data>true</overwrite-existing-data> > </processing-directives> > <schedule> > <job> > > > > > > <name>defaultJob</name> > <description>test job</description> > <job-type>HelpLine.Application.WebAPI.Quartz.SampleJob, > HelpLine.Application.WebAPI</job-type> > <durable>true</durable> > <recover>true</recover> > </job> > <trigger> > <cron> > <name>defaultTrigger</name> > <job-name>defaultJob</job-name> > <cron-expression>0 0/1 * * * ?</cron-expression> > </cron> > </trigger> > </schedule> > </job-scheduling-data> > > > Op woensdag 14 mei 2014 10:18:02 UTC+2 schreef Jonathon Rossi: > > I'm pretty sure it is because some of those items you've got in your > configuration have a empty XML element value, the facility uses the XML > element's value not a "value" attribute. If you look at the example > configuration on the page I linked to in my previous reply you'll see the > items it defines as an example. > > https://github.com/castleprojectcontrib/QuartzNetIntegration/blob/ > master/QuartzNetIntegration/QuartzFacility.cs#L90 > > On Wed, May 14, 2014 at 6:04 PM, Edwin Vliet <[email protected]>wrote: > > Stacktrace: > > at Quartz.Impl.StdSchedulerFactory.Instantiate() in > c:\Work\OpenSource\Quartz.NET\quartznet\src\Quartz\Impl\StdSchedulerFactory.cs:line > > 748 > at Quartz.Impl.StdSchedulerFactory.GetScheduler() in > c:\Work\OpenSource\Quartz.NET\quartznet\src\Quartz\Impl\StdSchedulerFactory.cs:line > > 1118 > at > Castle.Facilities.QuartzIntegration.QuartzNetScheduler..ctor(IDictionary`2 > props, IJobFactory jobFactory, IKernel kernel) in > g:\prg\QuartzNetIntegration.gitsvn\QuartzNetIntegration\ > QuartzNetIntegration\QuartzNetScheduler.cs:line 38 > > > > This is the full configuration for Castle. > > <castle> > <facilities> > <facility id="startable.facility" > type="Castle.Facilities.Startable.StartableFacility, > Castle.Windsor" /> > <facility id="quartznet" > type="Castle.Facilities.QuartzIntegration.QuartzFacility, > Castle.Facilities.QuartzIntegration"> > <schedulerListeners> > <listener>${schedulerListener}</listener> > </schedulerListeners> > <jobListeners> > <job name="defaultJob"> > <listener>${jobListener}</listener> > </job> > </jobListeners> > <triggerListeners> > <trigger name="defaultTrigger"> > <listener>${triggerListener}</listener> > </trigger> > </triggerListeners> > <quartz> > <add key="quartz.scheduler.instanceName" value="QuartzScheduler" /> > <add key="quartz.threadPool.type" value="Quartz.Simpl.SimpleThreadPool, > Quartz"> > <add key="quartz.threadPool.threadCount">5<font co > > ... -- You received this message because you are subscribed to the Google Groups "Castle Project Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. Visit this group at http://groups.google.com/group/castle-project-users. For more options, visit https://groups.google.com/d/optout.
