-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/18302/
-----------------------------------------------------------

Review request for oozie.


Bugs: OOZIE-1699
    https://issues.apache.org/jira/browse/OOZIE-1699


Repository: oozie-git


Description
-------

The core issue is before XCommand is added to the workerQueue within 
BlockingQueue of the ThreadPoolExecutor, it is added to the uniqueCallables in 
CallableQueueService. If however while XCommand isn't added to the 
BlockingQueue due to any exception (as below), the item remains in 
uniqueCallables preventing further execution of the command.

{code}
        if (queueElement == null) {
            throw new NullPointerException("queueElement is NULL");
        }
        if (queueElement.getPriority() < 0 || queueElement.getPriority() >= 
priorities) {
            throw new IllegalArgumentException("priority out of range: " + 
queueElement);
        }
        if (queueElement.inQueue) {
            throw new IllegalStateException("queueElement already in a queue: " 
+ queueElement);
        }
{code}


Diffs
-----

  core/src/main/java/org/apache/oozie/service/CallableQueueService.java ab81b09 
  core/src/main/java/org/apache/oozie/util/PollablePriorityDelayQueue.java 
6645544 
  core/src/main/java/org/apache/oozie/util/PriorityDelayQueue.java 8b4e0ff 
  core/src/test/java/org/apache/oozie/service/TestCallableQueueService.java 
903866d 

Diff: https://reviews.apache.org/r/18302/diff/


Testing
-------

New tests added to TestCallableQueueService to validate if the fix indeed fixes 
this issue.


Thanks,

Srikanth Sundarrajan

Reply via email to