-
Notifications
You must be signed in to change notification settings - Fork 339
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Mark Workflow as FAILED if the action inside the workflow fails instead of marking it as COMPLETE. #7546
Conversation
Build is green here - http://builds.cask.co/browse/CDAP-DUT5245-17 |
|
||
@Override | ||
public void completed() { | ||
LOG.debug("Program {} completed successfully.", program.getId()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we log the runid also
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed.
|
||
@Override | ||
public void killed() { | ||
LOG.debug("Program {} killed.", program.getId()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we log the runid also
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fixed.
runtimeStore.setStart(program.getId(), runId.getId(), startTimeInSeconds, twillRunId, | ||
options.getUserArguments().asMap(), options.getArguments().asMap()); | ||
|
||
switch (state) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what about KILLED
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
actually no need to have KILLED state here, since when actions such as SUSPEND/KILLED would happen init listener would have executed at that time. This is similar to the https://github.com/caskdata/cdap/blob/develop/cdap-app-fabric/src/main/java/co/cask/cdap/internal/app/services/ProgramLifecycleService.java#L341
LGTM |
Build running here - https://builds.cask.co/browse/CDAP-DUT5389-1 |
78374c5
to
9e8edc4
Compare
Thank you @anwar6953 for the review. Build is green. Squashing and merging. |
JIRA: https://issues.cask.co/browse/CDAP-6008
Build: http://builds.cask.co/browse/CDAP-DUT5245-15
Fix contains -
WorkflowProgramRunner
ProgramManager
interface -waitForRun
, andwaitForRuns
which are used in the unit tests instead ofwaitForFinish
to make sure that the Workflow program is reached to the specified state.