[ovirt-devel] Certain questions about Quartz based scheduling in oVirt
Yair Zaslavsky
yzaslavs at redhat.com
Wed Nov 26 05:32:32 UTC 2014
----- Original Message -----
> From: "Sahina Bose" <sabose at redhat.com>
> To: "Moti Asayag" <masayag at redhat.com>, "Shubhendu Tripathi" <shtripat at redhat.com>
> Cc: devel at ovirt.org
> Sent: Tuesday, November 25, 2014 1:13:06 PM
> Subject: Re: [ovirt-devel] Certain questions about Quartz based scheduling in oVirt
>
>
> On 11/24/2014 06:27 PM, Moti Asayag wrote:
> > Hi Shubhendu,
> >
> > ----- Original Message -----
> >> From: "Shubhendu Tripathi" <shtripat at redhat.com>
> >> To: devel at ovirt.org
> >> Sent: Monday, November 24, 2014 8:58:34 AM
> >> Subject: [ovirt-devel] Certain questions about Quartz based scheduling in
> >> oVirt
> >>
> >> Hi All,
> >>
> >> We are in a requirement where we need to schedule jobs at certain time
> >> interval, hourly, daily, weekly and monthly (i.e. repetitive and cron
> >> kind of scheduling).
> >> I was trying to understand quartz based scheduling mechanism in oVirt to
> >> achieve the scenarios.
> >>
> >> Have some basic questions regarding the same -
> >> 1. Is there is mechanism to persist the scheduling data in oVirt ?
> > In ovirt we do not persist the jobs. The application reschedule the jobs
> > when it starts
> > and programmatically triggers jobs when required.
> >
> > On packaging/services/ovirt-engine/ovirt-engine.xml.in we specify the job
> > store configuration
> > as RAMJobStore, which is a volatile:
> >
> > <property name="org.quartz.jobStore.class"
> > value="org.quartz.simpl.RAMJobStore"/>
> >
> > You may select other implementation. See:
> > http://quartz-scheduler.org/api/2.2.0/org/quartz/spi/JobStore.html
>
> Would the correct approach then be to have multiple scheduler instances?
Please bare in mind that quartz has the ability to perform
Cron like scheduling (with cron expressions).
http://www.quartz-scheduler.org/documentation/quartz-1.x/tutorials/crontrigger
>
> 1. - that uses the in memory job store
>
> 2. that uses DB to persist the jobs.
>
> The second instance would be used to schedule and manage any dynamic
> jobs, for instance like the ones required for gluster volume snapshot
> scheduling
>
> Using a separate instance also would mean there's no change to existing
> jobs that are scheduled in Backend bean.
>
>
> >
> >> 2. How to tackle edit and rescheduling of jobs ?
> >>
> > You can have a look at org.ovirt.engine.core.utils.timer.SchedulerUtil
> > interface in
> > the 'scheduler' project which provides that functionality, and the related
> > classes.
> >
> > But if not special requirements, i guess the shipped quartz implementation
> > should be
> > enough:
> >
> > http://quartz-scheduler.org/documentation/quartz-2.x/tutorials/tutorial-lesson-05
> >
> >> Kindly guide on how to achieve these.
> >>
> >> Thanks and Regards,
> >> Shubhendu
> >> _______________________________________________
> >> Devel mailing list
> >> Devel at ovirt.org
> >> http://lists.ovirt.org/mailman/listinfo/devel
> >>
> > _______________________________________________
> > Devel mailing list
> > Devel at ovirt.org
> > http://lists.ovirt.org/mailman/listinfo/devel
>
> _______________________________________________
> Devel mailing list
> Devel at ovirt.org
> http://lists.ovirt.org/mailman/listinfo/devel
>
More information about the Devel
mailing list