zen0n
zen0n

Reputation: 347

Create Quartz 2.x xml job without triggers

I have quartz job Quartz UpdateContentMetaData.class, and I have Quartz 2.x job xml:

<?xml version='1.0' encoding='utf-8'?>
<job-scheduling-data version="2.0" 
    xmlns="http://www.quartz-scheduler.org/xml/JobSchedulingData" 
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://www.quartz-scheduler.org/xml/JobSchedulingData 
    http://www.quartz-scheduler.org/xml/job_scheduling_data_2_0.xsd">
    <schedule>    
        <job>
            <name>UpdateContentJob</name>
            <job-class>ru.icb.cms.schedule.job.UpdateContentMetaData</job-class>
            <job-data-map>
                <entry>
                    <key>provider</key>
                    <value>2</value>
                </entry>
            </job-data-map>
        </job>
        <trigger>
            <simple>
                <name>minute_job</name>
                <group>DEFAULT</group>
                <job-name>minute_job</job-name>
                <job-group>DEFAULT</job-group>
                <repeat-count>-1</repeat-count>
                <repeat-interval>60000</repeat-interval>
            </simple>
        </trigger>    
    </schedule>
</job-scheduling-data>

How to create xml job without triggers?

Upvotes: 1

Views: 2027

Answers (1)

Anthony Dahanne
Anthony Dahanne

Reputation: 5053

did you try just :

<schedule>
        <job>
            <name>TestJob1</name>
            <job-class>org.quartz.examples.example10.SimpleJob</job-class>
        <durability>true</durability>
        <recover>true</recover>
    </job>
</schedule>   

Upvotes: 1

Related Questions