jlinn / quartz-redis-jobstore

A Quartz Scheduler JobStore using Redis.
Apache License 2.0
136 stars 67 forks source link

Trigger wont be removed if JobConcurrentExecutionDisallowed is true and no nextFireTime set (Version 1.1.9) #30

Open roeder82 opened 6 years ago

roeder82 commented 6 years ago

Given the following scenario:

In this case in RedisStorage.triggersFired the else case in line 744 ( jedis.hset(triggerHashKey, TRIGGER_NEXT_FIRE_TIME, "")) is not executed, as there is an else if else from "if (isJobConcurrentExecutionDisallowed(job.getJobClass()))", therefor the trigger wont be removed in RedisStorage.triggeredJobComplete line 818 (if(isNullOrEmpty(jedis.hget(triggerHashKey, TRIGGER_NEXT_FIRE_TIME)))) as the expression evaluates to false.

This leads to jobs running and running again even though the shall be deleted.