blob: a3dbbe4c6b73156a6d051b923fa6a1e68b02e41d [file] [log] [blame]
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"></meta><title>ScriptedReportingTask</title><link rel="stylesheet" href="../../../../../css/component-usage.css" type="text/css"></link></head><script type="text/javascript">window.onload = function(){if(self==top) { document.getElementById('nameHeader').style.display = "inherit"; } }</script><body><h1 id="nameHeader" style="display: none;">ScriptedReportingTask</h1><h2>Description: </h2><p>Provides reporting and status information to a script. ReportingContext, ComponentLog, and VirtualMachineMetrics objects are made available as variables (context, log, and vmMetrics, respectively) to the script for further processing. The context makes various information available such as events, provenance, bulletins, controller services, process groups, Java Virtual Machine metrics, etc.</p><h3>Tags: </h3><p>reporting, script, execute, groovy, python, jython, jruby, ruby, javascript, js, lua, luaj</p><h3>Properties: </h3><p>In the list below, the names of required properties appear in <strong>bold</strong>. Any other properties (not in bold) are considered optional. The table also indicates any default values, and whether a property supports the <a href="../../../../../html/expression-language-guide.html">NiFi Expression Language</a>.</p><table id="properties"><tr><th>Display Name</th><th>API Name</th><th>Default Value</th><th>Allowable Values</th><th>Description</th></tr><tr><td id="name"><strong>Script Engine</strong></td><td>Script Engine</td><td id="default-value">ECMAScript</td><td id="allowable-values"><ul><li>ECMAScript <img src="../../../../../html/images/iconInfo.png" alt="ECMAScript ECMA - 262 Edition 5.1 [Oracle Nashorn 1.8.0_322-b06]" title="ECMAScript ECMA - 262 Edition 5.1 [Oracle Nashorn 1.8.0_322-b06]"></img></li></ul></td><td id="description">The engine to execute scripts</td></tr><tr><td id="name">Script File</td><td>Script File</td><td></td><td id="allowable-values"></td><td id="description">Path to script file to execute. Only one of Script File or Script Body may be used<br/><br/><strong>This property requires exactly one file to be provided..</strong><br/><br/><strong>Supports Expression Language: true (will be evaluated using variable registry only)</strong></td></tr><tr><td id="name">Script Body</td><td>Script Body</td><td></td><td id="allowable-values"></td><td id="description">Body of script to execute. Only one of Script File or Script Body may be used</td></tr><tr><td id="name">Module Directory</td><td>Module Directory</td><td></td><td id="allowable-values"></td><td id="description">Comma-separated list of paths to files and/or directories which contain modules required by the script.<br/><br/><strong>This property expects a comma-separated list of resources. Each of the resources may be of any of the following types: directory, file.</strong><br/><br/><strong>Supports Expression Language: true (will be evaluated using variable registry only)</strong></td></tr></table><h3>Dynamic Properties: </h3><p>Supports Sensitive Dynamic Properties: <strong>Yes</strong></p><p>Dynamic Properties allow the user to specify both the name and value of a property.<table id="dynamic-properties"><tr><th>Name</th><th>Value</th><th>Description</th></tr><tr><td id="name">A script engine property to update</td><td id="value">The value to set it to</td><td>Updates a script engine property specified by the Dynamic Property's key with the value specified by the Dynamic Property's value<br/><strong>Supports Expression Language: true (will be evaluated using variable registry only)</strong></td></tr></table></p><h3>State management: </h3>This component does not store state.<h3>Restricted: </h3><table id="restrictions"><tr><th>Required Permission</th><th>Explanation</th></tr><tr><td>execute code</td><td>Provides operator the ability to execute arbitrary code assuming all permissions that NiFi has.</td></tr></table><h3>System Resource Considerations:</h3>None specified.</body></html>