src/main/java/com/redislabs/quartz/RedisJobStore.java
/**
	 * Unsets a state of a given trigger key by removing the trigger from the trigger state zsets. <br>
	 * The caller should handle synchronization.
	 *
	 * @param triggerHashKey the trigger hash key
	 * @param jedis the redis client
	 * @return 1- if removed, 0- if the trigger was stateless, -1- if unset state failed  
	 * @throws JobPersistenceException 
	 */
Unsets a state of a given trigger key by removing the trigger from the trigger state zsets. 
The caller should handle synchronization.

@param triggerHashKey the trigger hash key
@param jedis the redis client
@return 1- if removed, 0- if the trigger was stateless, -1- if unset state failed
@throws JobPersistenceException
Unsets a state of a given trigger key by removing the trigger from the trigger state zsets . The caller should handle synchronization . @param triggerHashKey the trigger hash key @param jedis the redis client @return 1 - if removed 0 - if the trigger was stateless - 1 - if unset state failed @throws JobPersistenceException
private long unsetTriggerState(String triggerHashKey) throws JobPersistenceException {
		Long removed = -1L;
      try (Jedis jedis = pool.getResource()) {
			Pipeline p = jedis.pipelined();
			p.zrem(RedisTriggerState.WAITING.getKey(), triggerHashKey);
			p.zrem(RedisTriggerState.PAUSED.getKey(), triggerHashKey);
			p.zrem(RedisTriggerState.BLOCKED.getKey(), triggerHashKey);
			p.zrem(RedisTriggerState.PAUSED_BLOCKED.getKey(), triggerHashKey);
			p.zrem(RedisTriggerState.ACQUIRED.getKey(), triggerHashKey);
			p.zrem(RedisTriggerState.COMPLETED.getKey(), triggerHashKey);
			p.zrem(RedisTriggerState.ERROR.getKey(), triggerHashKey);
			List<Object> results = p.syncAndReturnAll();
			for (Object result : results) {
				removed = (Long)result;
				if (removed == 1) {
					jedis.hset(triggerHashKey, LOCKED_BY, "");
					jedis.hset(triggerHashKey, LOCK_TIME, "");
					break;
				}
			}
		} catch (Exception ex) {
			removed = -1L;
			log.error("could not unset state for trigger: " + triggerHashKey);
			throw new JobPersistenceException(ex.getMessage(), ex.getCause());
      }
		return removed;
	}
private long unsetTriggerState ( String triggerHashKey ) throws JobPersistenceException { Long removed = - 1L ; try ( Jedis jedis = pool . getResource ( ) ) { Pipeline p = jedis . pipelined ( ) ; p . zrem ( RedisTriggerState . WAITING . getKey ( ) , triggerHashKey ) ; p . zrem ( RedisTriggerState . PAUSED . getKey ( ) , triggerHashKey ) ; p . zrem ( RedisTriggerState . BLOCKED . getKey ( ) , triggerHashKey ) ; p . zrem ( RedisTriggerState . PAUSED_BLOCKED . getKey ( ) , triggerHashKey ) ; p . zrem ( RedisTriggerState . ACQUIRED . getKey ( ) , triggerHashKey ) ; p . zrem ( RedisTriggerState . COMPLETED . getKey ( ) , triggerHashKey ) ; p . zrem ( RedisTriggerState . ERROR . getKey ( ) , triggerHashKey ) ; List < Object > results = p . syncAndReturnAll ( ) ; for ( Object result : results ) { removed = ( Long ) result ; if ( removed == 1 ) { jedis . hset ( triggerHashKey , LOCKED_BY , "" ) ; jedis . hset ( triggerHashKey , LOCK_TIME , "" ) ; break ; } } } catch ( Exception ex ) { removed = - 1L ; log . error ( "could not unset state for trigger: " + triggerHashKey ) ; throw new JobPersistenceException ( ex . getMessage ( ) , ex . getCause ( ) ) ; } return removed ; }
Unsets a state of a given trigger key by removing the trigger from the trigger state zsets.
Unsets a state of a given trigger key by removing the trigger from the trigger state zsets .