[
https://issues.apache.org/jira/browse/OOZIE-1319?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13966921#comment-13966921
]
Robert Kanter commented on OOZIE-1319:
--------------------------------------
{quote}I think the concurrency also need to be 2 if you get two actions in
waiting.{quote}
That just made both actions do RUNNING at the same time instead of in sequence
I think the problem is that the query used to get the Jobs is this (for FIFO;
FILO is just this with the order as "desc"):
{noformat}
select a.id, a.jobId, a.statusStr, a.pending, a.nominalTimestamp,
a.createdTimestamp from CoordinatorActionBean a where a.jobId = :jobId AND
a.statusStr = 'READY' order by a.nominalTimestamp
{noformat}
Even though I made the data available for both actions at the same time, Oozie
didn't transition them to READY at the same time, so when this query was
executed, there was only ever 1 action in READY -- that's why it didn't seem to
do anything. I was thinking that this may depend partly on the timing of the
actions transitioning from WAITING to READY, which doesn't happen
simultaneously for all actions.
I tried modifying the example to have 4 actions; I then waited for all of them
to be WAITING and put up the data; the \@4 went to RUNNING and the rest
eventually went to READY. I was then expecting those to go to SKIPPED because
the query should be looking for them; however, they stayed READY and just went
in sequence to RUNNING and SUCCEEDED.
tldr; the patch isn't working :(
{quote}Overall, this execution control is not really a well-defined
property.{quote}
My understanding of LAST_ONLY is that if multiple actions are WAITING or READY,
only one of them should actually run while the rest are skipped. What's not
clear to me is if the "LAST" means the oldest action (i.e. the _last_ one in
the list) or the newest action (i.e. the _last_ one to be added); though this
isn't too hard to switch around once we get the rest of this working. It may
make sense to add a "FIRST_ONLY" for the opposite or something.
[~bowenzhangusa], are you planning on still doing this? Or do you mind if I
take a stab at it?
> "LAST_ONLY" in execution control for coordinator job still runs all the
> actions
> -------------------------------------------------------------------------------
>
> Key: OOZIE-1319
> URL: https://issues.apache.org/jira/browse/OOZIE-1319
> Project: Oozie
> Issue Type: Bug
> Reporter: Bowen Zhang
> Assignee: Bowen Zhang
> Attachments: oozie-1319.patch
>
>
> In execute() of CoordJobGetReadyActionsJPAExecutor.java, once we retrieve the
> top item from a "LIFO" query result, we do not discard or delete the
> remaining items from the result list. As a result, the next time execute() is
> invoked, we will be retrieving the next item in line. Consequently, LAST_ONLY
> strategy will also execute all ready actions for a given coordinator job,
> making it no different than LIFO.
--
This message was sent by Atlassian JIRA
(v6.2#6252)