Job failed step status not mapped to the correct processor (ExecuteScript)

Description

The failed flow from a ExecuteScript processor does not appear correctly in the Job status.
I'm processing and routing to failure in a Groovy script (executed by an ExecuteScript), and in most cases, the failed status in the Job Step status appears in the next processor step (post-failure/success action)

The only case when the Step status appears as Failed to the ExecuteScript processor is when the failure relationship is auto-terminated.

Attached is a feed example & template, script used and screenshot. The feed generates flowFiles and simply discards them at the end.

Not investigated too much, but the failed status appears to be picked-up mostly when the return is !=0, in eg:

Please advise about how to properly generate failed statuses.

Environment

NiFi 1.3
CDH 5.10

Assignee

Scott Reisdorf

Reporter

Claudiu Stanciu

Labels

Reviewer

None

Story point estimate

None

Story Points

20

Components

Sprint

None

Affects versions

Priority

Medium
Configure