Package org.apache.nifi.controller
Class AbstractControllerService
java.lang.Object
org.apache.nifi.components.AbstractConfigurableComponent
org.apache.nifi.controller.AbstractControllerService
- All Implemented Interfaces:
ConfigurableComponent
,ControllerService
public abstract class AbstractControllerService
extends AbstractConfigurableComponent
implements ControllerService
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate ConfigurationContext
private boolean
private String
private ComponentLog
private NodeTypeProvider
private ControllerServiceLookup
private StateManager
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfinal void
final void
abstractStoreConfigContext
(ConfigurationContext configContext) final void
disabled()
final void
enabled()
protected ConfigurationContext
protected final ControllerServiceLookup
protected ComponentLog
protected final NodeTypeProvider
protected PropertyValue
getProperty
(PropertyDescriptor descriptor) protected StateManager
protected void
Provides a mechanism by which subclasses can perform initialization of the Controller Service before it is scheduled to be runfinal void
Provides the Controller Service with access to objects that may be of use throughout the life of the service.boolean
Methods inherited from class org.apache.nifi.components.AbstractConfigurableComponent
customValidate, equals, getPropertyDescriptor, getPropertyDescriptors, getSupportedDynamicPropertyDescriptor, getSupportedPropertyDescriptors, hashCode, onPropertyModified, toString, validate
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.apache.nifi.components.ConfigurableComponent
getPropertyDescriptor, getPropertyDescriptors, onPropertyModified, validate
Methods inherited from interface org.apache.nifi.controller.ControllerService
isStateful, migrateProperties
-
Field Details
-
identifier
-
serviceLookup
-
logger
-
stateManager
-
configurationContext
-
enabled
private volatile boolean enabled -
nodeTypeProvider
-
-
Constructor Details
-
AbstractControllerService
public AbstractControllerService()
-
-
Method Details
-
initialize
public final void initialize(ControllerServiceInitializationContext context) throws InitializationException Description copied from interface:ControllerService
Provides the Controller Service with access to objects that may be of use throughout the life of the service. This method will be called before any properties are set- Specified by:
initialize
in interfaceControllerService
- Parameters:
context
- of initialization- Throws:
InitializationException
- if unable to init
-
getIdentifier
- Specified by:
getIdentifier
in interfaceConfigurableComponent
- Returns:
- the unique identifier that the framework assigned to this component
-
getControllerServiceLookup
- Returns:
- the
ControllerServiceLookup
that was passed to theinit(ControllerServiceInitializationContext)
method
-
getNodeTypeProvider
- Returns:
- the
NodeTypeProvider
that was passed to theinit(ControllerServiceInitializationContext)
method
-
init
Provides a mechanism by which subclasses can perform initialization of the Controller Service before it is scheduled to be run- Parameters:
config
- of initialization context- Throws:
InitializationException
- if unable to init
-
enabled
-
disabled
-
isEnabled
public boolean isEnabled() -
getLogger
- Returns:
- the logger that has been provided to the component by the framework in its initialize method
-
getStateManager
- Returns:
- the StateManager that can be used to store and retrieve state for this Controller Service
-
abstractStoreConfigContext
-
abstractClearConfigContext
-
getConfigurationContext
-
getProperty
-