Quartz Description of the table required to save the job in the database

Source: Internet
Author: User

Http://blog.iqbon.com/doc/364.html (the practice of persisting quartz to a database)

Qrtz_calendars storing Quartz Calendar information in Blob type

Qrtz_cron_triggers stores cron Trigger, including cron expressions and time zone information Qrtz_fired_triggers stores state information related to the triggered Trigger, and execution information for the associated job qrtz_paused _trigger_grps stores information about a paused TRIGGER group Qrtz_scheduler_state stores a small amount of state information about the SCHEDULER, and other SCHEDULER instances (if used in a cluster) qrtz_locks Information about the pessimistic lock of the stored program (if pessimistic lock is used) Qrtz_job_details stores the details of each configured JOB Qrtz_job_listeners stores information about the configured Joblistener Qrtz_simple_ TRIGGERS stores simple Trigger, including the number of repetitions, intervals, and number of touches qrtz_blog_triggers Trigger as Blob type storage for Quartz users to create their own custom Trigger type with JDBC, Jo Bstore does not know how to store the instance) Qrtz_trigger_listeners stores the configured Triggerlistener information Qrtz_triggers stores the configured TRIGGER information--------------- ----------------------------------------------------------------------------------- Quartz Persistent Database table field interpretation of the table, SQL statements in the Quartz-1.6.6\docs\dbtables folder can be found, introduced the following main tables:
Table Qrtz_job_details: Save job Details, this table requires the user to initialize according to the actual situation
Job_name: The name of the job in the cluster, the name of the user can be arbitrarily customized, no forced requirements
Job_group: The name of the group to which the job belongs in the cluster, the name of the user is freely customizable, no forced request
Job_class_name: The full package name of the note job implementation class in the cluster, quartz the job class based on the path to Classpath
Is_durable: If persisted, setting this property to 1,quartz will persist the job to the database
Job_data: A BLOB field that holds persisted job objects

Table Qrtz_triggers: Saving trigger information
Trigger_name:trigger name, the name of the user can be arbitrarily customized, no forced requirements
Trigger_group:trigger name of the group, the name of the user's own customization, no forced requirements
Job_name:qrtz_job_details foreign keys for table job_name
Job_group:qrtz_job_details foreign keys for table Job_group
Trigger_state: The current trigger state, set to acquired, and if set to waiting, the job does not trigger
Trigger_cron: Trigger type, using cron expression

Table qrtz_cron_triggers: Storing cron expression tables
Trigger_name:qrtz_triggers foreign keys for table trigger_name
Trigger_group:qrtz_triggers foreign keys for table Trigger_group
Cron_expression:cron-expression

Table Qrtz_scheduler_state: Store Note Instance information in the cluster, quartz periodically reads the table information to determine the current state of each instance in the cluster
Instance_name: The name of the Org.quartz.scheduler.instanceId configuration in the previous configuration file will be written to this field, if set to Auto,quartz will produce a name based on the physical machine name and the current time
Last_checkin_time: Last Check time
Checkin_interval: Check interval time

Step 4:
To configure the Quartz.properties file:
Each instance of a #调度标识名 cluster must use the same name org.quartz.scheduler.instanceName = Scheduler#id set to automatically get each one must be different Org.quartz.scheduler.instanceId = auto# data is persisted org.quartz.jobStore.class = org.quartz.impl.jdbcjobstore.jobstoretx# Database Platform Org.quartz.jobStore.driverDelegateClass = Org.quartz.impl.jdbcjobstore.oracle.weblogic.WebLogicOracleDelegate #数据库别名 casually take Org.quartz.jobStore.dataSource = myxads# table Prefix Org.quartz.jobStore.tablePrefix = qrtz_# set to True does not occur when serializing a non-string class to a BLOB when generating a class version problem Org.quartz.jobStore.useProperties = true# Join cluster org.quartz.jobStore.isClustered = true# check interval for scheduled instance invalidation Org.quartz.jobStore.clusterCheckinInterval = 20000  #容许的最大作业延长时间 org.quartz.jobStore.misfireThreshold = 60000# ThreadPool implemented class name Org.quartz.threadPool.class = org.quartz.simpl.simplethreadpool# number of threads Org.quartz.threadPool.threadCount = 10# Thread Priority org.quartz.threadPool.threadPriority = AA Self-created parent thread Org.quartz.threadPool.threadsInheritContextClassLoaderOfInitializingThread = true # Set data Source Org.quartz.dataSource.myXADS.jndiURL = Ct#jbdi class name Org.quartz.dataSource.myXADS.java.naming.factory.initial = weblogic.jndi.WLInitialContextFactory # URLorg.quartz.dataSource.myXADS.java.naming.provider.url = t3://localhost:7001  "Note" : In the Java EE project, if you want to use database management quartz information, you must configure the data source, this is the quartz requirements.   This article turns from: http://blog.sina.com.cn/s/blog_4f925fc30102e3zr.html

Quartz A description of the table required for the job to be saved in the database

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.