Quartz configuration time (duty cycle class)

 No. Explanation
 Required  Which allowed the value of Allow wildcard
 1  second  Yes  0-59    , - * /
 2  Minute  Yes  0-59
  , - * /
 3 hour  Yes  0-23   , - * /
 4  day  Yes  1-31   , - * ? / L W
 5  month  Yes  1-12 or JAN-DEC   , - * /
 6  week  Yes  1-7 or SUN-SAT   , - * ? / L #
 7  year  no  empty or 1970-2099  , - * /


Wildcard Note:
* indicates all values, for example: a field provided on the partition, "*" indicates a trigger every minute.
? Said they did not specify the value. Scene used to not care about the value of the current setting of this field. For example: To trigger on the 10th of each month of operation, but is not concerned about a few weeks, so it is necessary that the field is set for the specific peripheral position is set to 00010 "?" *?
- representing the interval. For example, set up "10-12" on the hour, 10, 11, represents the point will be triggered.
, It represents specify multiple values, such as setting "MON, WED, FRI" in the week field said on Monday, Wednesday and Friday trigger
/ for incrementing trigger. As set "5/15" above represents the second for 5 seconds, every 15 seconds by a trigger (5,20,35,50). Set in the month field '1/3' Start No. 1 a month, once every three days triggered shown.
L represents the final meaning. On the field, set the day, represents the last day (based on the current month, if February is also based on whether it is a leap year [leap]) the month, expressed Saturday, the equivalent of "7" or "SAT" in the week field. If the "L" digitally before, indicates the last of the data. For example, to format this "6L" in the week field, it means "the last Friday of the month"
WRepresents, for example setting "15W" on the daily field closest to the date specified weekday (Monday to Friday), represents the 15th of each month from recent days that trigger. If the 15th happens to be Saturday and then find the nearest Friday (14) is triggered, if the number 15 is the weekend, then look for the nearest next Monday (16) is triggered. If the number in just 15 working days (Monday to Sunday e), then triggered in the day. If you specify the format of "1W", it said 1 month later recent days triggered. If No. 1 is the Saturday will be No. 3 on Monday triggered. (Note, "W" can only be set before the specific numbers are not allowed interval "-").

hint

'L' and 'W' may be a combination. If set to "LW" in the Japanese field, then triggered the last business day of the month

# Serial number (the first few weeks of every month a few), for example on the field Week "6 # 3". Note that if you specify "# 5", not just the fifth week in the week the third Saturday of each month Sixth, the configuration is not triggered (with mother's Day and father's Day a perfect fit)

hint

Set circumferential field, the use of letters is insensitive MON the same mon .


       
Common examples:
 

 

0 0 12 * * ? 12:00 every day trigger
0 15 10 ? * * Daily 10:15 Trigger
0 15 10 * * ? Daily 10:15 Trigger
0 15 10 * * ? * Daily 10:15 Trigger
0 15 10 * * ? 2005 2005 day 10:15 Trigger
0 * 14 * * ? Every afternoon 2:00 to 2:59 each trigger points
0 0/5 14 * * ? 2:00 every afternoon to 2:59 (the whole point of the start trigger every 5 minutes)
0 0/5 14,18 * * ? 2:00 every afternoon to 2:59 (the whole point of the start trigger every 5 minutes)
every afternoon 18:00 to 18:59 (the whole point of the start trigger every 5 minutes)
0 0-5 14 * * ? 每天下午的 2点到2点05分每分触发
0 10,44 14 ? 3 WED 3月分每周三下午的 2点10分和2点44分触发
0 15 10 ? * MON-FRI 从周一到周五每天上午的10点15分触发
0 15 10 15 * ? 每月15号上午10点15分触发
0 15 10 L * ? 每月最后一天的10点15分触发
0 15 10 ? * 6L 每月最后一周的星期五的10点15分触发
0 15 10 ? * 6L 2002-2005 从2002年到2005年每月最后一周的星期五的10点15分触发
0 15 10 ? * 6#3 每月的第三周的星期五开始触发
0 0 12 1/5 * ? 每月的第一个中午开始每隔5天触发一次
0 11 11 11 11 ? 每年的11月11号 11点11分触发(光棍节)

Guess you like

Origin www.cnblogs.com/weibanggang/p/11278173.html