cocoon-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Borut ┼Żagar [Email.si] <zag...@email.si>
Subject CocoonQuartzJobScheduler
Date Fri, 02 Dec 2005 15:57:47 GMT
Hi.
 
I have enabled org.apache.cocoon.components.cron.CocoonQuartzJobScheduler
component in cocoon.xconf and it seems to be working fine. But I do not know
how to schedule tasks programatically with this scheduler as I could do it
with Quartz Scheduler.
 
For example, how would I create a scheduled task like the one below which I
made with Quartz:
 
	SchedulerFactory sf = new StdSchedulerFactory();
	Scheduler sched = sf.getScheduler();
	sched.start();
	JobDetail jd = new JobDetail("Income report", "Report generation",
Quartz.class);
	jd.getJobDataMap().put("type", "FULL");
	CronTrigger trigger = new CronTrigger("Income report", "Report
generation");
	trigger.setCronExpression("*/10 * * * * ? *");
	sched.scheduleJob(jd, trigger);

Since Cocoon Scheduler is based on Quartz scheduler I would expect it to be
easy but I havent been able to do it and I did not found any examples.

Examples would be appreciated.

Thanks!
Borut


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org


Mime
View raw message