Skip to content

Commit

Permalink
Merge pull request #358 from zemian/issue-220-dailytimeint-trigger-en…
Browse files Browse the repository at this point in the history
…dtime

 DailyTimeIntervalTrigger failed to set endingDailyAfterCount = 1 #220
  • Loading branch information
zemian authored Feb 15, 2019
2 parents 4978029 + b938143 commit 487d748
Show file tree
Hide file tree
Showing 3 changed files with 278 additions and 262 deletions.
1 change: 1 addition & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ THIS RELEASE REQUIRES JDK7
* #212 bugfix: QuartzInitializerListener: fix a typo
* #193 bugfix: Job execution context impl returns incorrect recovering job key
* #172 bugfix: Miss notify SchedulerListeners in QuartzScheduler.java
* #220 bugifx: DailyTimeIntervalTrigger failed to set endingDailyAfterCount = 1
* #160 improv: Add drop table if exists check in sql script for postgres
* #214 improv: Reuse JobBuilder.storeDurably(boolean) in JobBuilder
* #281 improv: Fix no setter for dataSource property validateOnCheckout
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -854,8 +854,13 @@ public void validate() throws SchedulerException {
}

// Ensure timeOfDay is in order.
if (getEndTimeOfDay() != null && !getStartTimeOfDay().before(getEndTimeOfDay())) {
throw new SchedulerException("StartTimeOfDay " + startTimeOfDay + " should not come after endTimeOfDay " + endTimeOfDay);
// NOTE: We allow startTimeOfDay to be set equal to endTimeOfDay so the repeatCount can be
// set to 1.
if (getEndTimeOfDay() != null
&& !getStartTimeOfDay().equals(getEndTimeOfDay())
&& !getStartTimeOfDay().before(getEndTimeOfDay())) {
throw new SchedulerException("StartTimeOfDay " + startTimeOfDay
+ " should not come after endTimeOfDay " + endTimeOfDay);
}
}

Expand Down
Loading

0 comments on commit 487d748

Please sign in to comment.