Class CommonsConfigurationLookupService<T extends org.apache.commons.configuration2.FileBasedConfiguration>
java.lang.Object
org.apache.nifi.components.AbstractConfigurableComponent
org.apache.nifi.controller.AbstractControllerService
org.apache.nifi.lookup.configuration2.CommonsConfigurationLookupService<T>
- All Implemented Interfaces:
org.apache.nifi.components.ConfigurableComponent,org.apache.nifi.controller.ControllerService,LookupService<String>,StringLookupService
- Direct Known Subclasses:
PropertiesFileLookupService,XMLFileLookupService
public abstract class CommonsConfigurationLookupService<T extends org.apache.commons.configuration2.FileBasedConfiguration>
extends org.apache.nifi.controller.AbstractControllerService
implements StringLookupService
This abstract class defines a generic
LookupService backed by an
Apache Commons Configuration FileBasedConfiguration.-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate org.apache.commons.configuration2.Configurationprotected List<org.apache.nifi.components.PropertyDescriptor> protected voidinit(org.apache.nifi.controller.ControllerServiceInitializationContext context) voidonEnabled(org.apache.nifi.controller.ConfigurationContext context) Methods inherited from class org.apache.nifi.controller.AbstractControllerService
abstractClearConfigContext, abstractStoreConfigContext, disabled, enabled, getConfigurationContext, getControllerServiceLookup, getIdentifier, getLogger, getNodeTypeProvider, getProperty, getStateManager, initialize, isEnabledMethods inherited from class org.apache.nifi.components.AbstractConfigurableComponent
customValidate, equals, getPropertyDescriptor, getPropertyDescriptors, getSupportedDynamicPropertyDescriptor, hashCode, onPropertyModified, toString, validateMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.nifi.components.ConfigurableComponent
getIdentifier, getPropertyDescriptor, getPropertyDescriptors, onPropertyModified, validateMethods inherited from interface org.apache.nifi.controller.ControllerService
initialize, isStateful, migratePropertiesMethods inherited from interface org.apache.nifi.lookup.LookupService
lookupMethods inherited from interface org.apache.nifi.lookup.StringLookupService
getValueType
-
Field Details
-
KEY
- See Also:
-
REQUIRED_KEYS
-
CONFIGURATION_FILE
public static final org.apache.nifi.components.PropertyDescriptor CONFIGURATION_FILE -
resultClass
-
properties
-
builder
private volatile org.apache.commons.configuration2.builder.ReloadingFileBasedConfigurationBuilder<T extends org.apache.commons.configuration2.FileBasedConfiguration> builder
-
-
Constructor Details
-
CommonsConfigurationLookupService
public CommonsConfigurationLookupService()
-
-
Method Details
-
getConfiguration
private org.apache.commons.configuration2.Configuration getConfiguration() throws LookupFailureException- Throws:
LookupFailureException
-
getSupportedPropertyDescriptors
- Overrides:
getSupportedPropertyDescriptorsin classorg.apache.nifi.components.AbstractConfigurableComponent
-
init
protected void init(org.apache.nifi.controller.ControllerServiceInitializationContext context) throws InitializationException - Overrides:
initin classorg.apache.nifi.controller.AbstractControllerService- Throws:
InitializationException
-
onEnabled
@OnEnabled public void onEnabled(org.apache.nifi.controller.ConfigurationContext context) throws InitializationException - Throws:
InitializationException
-
lookup
- Specified by:
lookupin interfaceLookupService<T extends org.apache.commons.configuration2.FileBasedConfiguration>- Throws:
LookupFailureException
-
getRequiredKeys
- Specified by:
getRequiredKeysin interfaceLookupService<T extends org.apache.commons.configuration2.FileBasedConfiguration>
-