nifi-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ASF subversion and git services (Jira)" <>
Subject [jira] [Commented] (NIFI-7404) Scripted processors become invalid when thread terminated
Date Fri, 01 May 2020 14:48:00 GMT


ASF subversion and git services commented on NIFI-7404:

Commit aa986e0bfb6b787fd16de82e4708def42ea0f6af in nifi's branch refs/heads/master from Matt
[;h=aa986e0 ]

NIFI-7404: Fixed invalid script processors upon thread termination

Signed-off-by: Pierre Villard <>

This closes #4238.

> Scripted processors become invalid when thread terminated
> ---------------------------------------------------------
>                 Key: NIFI-7404
>                 URL:
>             Project: Apache NiFi
>          Issue Type: Bug
>          Components: Extensions
>            Reporter: Matt Burgess
>            Assignee: Matt Burgess
>            Priority: Major
>          Time Spent: 10m
>  Remaining Estimate: 0h
> As reported on the NiFi users mailing list, when a processor thread is terminated for
ExecuteScript or InvokeScriptedProcessor, the processor becomes invalid with the message "‘Script
engine’ validated against ‘<script engine name>’ is invalid because Given value
not found in allowed set ‘ECMA Script’".
> This is caused by the scriptingComponentHelper not being re-initialized correctly. When
createResources() is called, it is called from a thread whose context classloader is not the
processor's instance classloader, and thus none of the additional script engines are found.
> This could be fixed by NIFI-6386, but specifically for these processors there is another
solution, namely to add an OnAdded method that calls createResources() whether some other
thread has already called it. The OnAdded method is guaranteed to be called with the thread's
context class loader set to the processor's instance classloader, and will set the initialized
flag to true, preventing any future calls (of other methods) of createResources() if not initialized.

This message was sent by Atlassian Jira

View raw message