public abstract class AbstractScriptedControllerService extends AbstractControllerService
| Modifier and Type | Field and Description |
|---|---|
protected ConfigurationContext |
configurationContext |
protected ScriptEngine |
scriptEngine |
protected ScriptingComponentHelper |
scriptingComponentHelper |
protected AtomicBoolean |
scriptNeedsReload |
protected AtomicReference<Collection<ValidationResult>> |
validationResults |
| Constructor and Description |
|---|
AbstractScriptedControllerService() |
| Modifier and Type | Method and Description |
|---|---|
protected Collection<ValidationResult> |
customValidate(ValidationContext validationContext) |
protected PropertyDescriptor |
getSupportedDynamicPropertyDescriptor(String propertyDescriptorName)
Returns a PropertyDescriptor for the given name.
|
protected List<PropertyDescriptor> |
getSupportedPropertyDescriptors()
Returns a list of property descriptors supported by this record reader.
|
void |
onEnabled(ConfigurationContext context) |
void |
onPropertyModified(PropertyDescriptor descriptor,
String oldValue,
String newValue)
Handles changes to this processor's properties.
|
protected abstract boolean |
reloadScript(String scriptBody) |
protected boolean |
reloadScriptBody(String scriptBody)
Reloads the script defined by the given string
|
protected boolean |
reloadScriptFile(String scriptPath)
Reloads the script located at the given path
|
abstract void |
setup() |
abstractClearConfigContext, abstractStoreConfigContext, disabled, enabled, getConfigurationContext, getControllerServiceLookup, getIdentifier, getLogger, getNodeTypeProvider, getProperty, getStateManager, init, initialize, isEnabledequals, getPropertyDescriptor, getPropertyDescriptors, hashCode, toString, validateclone, finalize, getClass, notify, notifyAll, wait, wait, waitgetPropertyDescriptor, getPropertyDescriptors, validateprotected final AtomicReference<Collection<ValidationResult>> validationResults
protected final AtomicBoolean scriptNeedsReload
protected volatile ScriptEngine scriptEngine
protected volatile ScriptingComponentHelper scriptingComponentHelper
protected volatile ConfigurationContext configurationContext
protected List<PropertyDescriptor> getSupportedPropertyDescriptors()
getSupportedPropertyDescriptors in class AbstractConfigurableComponentprotected PropertyDescriptor getSupportedDynamicPropertyDescriptor(String propertyDescriptorName)
getSupportedDynamicPropertyDescriptor in class AbstractConfigurableComponentpropertyDescriptorName - used to lookup if any property descriptors
exist for that namepublic void onPropertyModified(PropertyDescriptor descriptor, String oldValue, String newValue)
onPropertyModified in interface ConfigurableComponentonPropertyModified in class AbstractConfigurableComponentdescriptor - of the modified propertyoldValue - non-null property value (previous)newValue - the new property value or if null indicates the propertyprotected Collection<ValidationResult> customValidate(ValidationContext validationContext)
customValidate in class AbstractConfigurableComponentpublic void onEnabled(ConfigurationContext context)
public abstract void setup()
protected boolean reloadScriptFile(String scriptPath)
scriptPath - the path to the script file to be loadedprotected boolean reloadScriptBody(String scriptBody)
scriptBody - the contents of the script to be loadedprotected abstract boolean reloadScript(String scriptBody)
Copyright © 2021 Apache NiFi Project. All rights reserved.