Search in sources :

Example 6 with StandardValidationContextFactory

use of org.apache.nifi.processor.StandardValidationContextFactory in project nifi by apache.

the class StandardControllerServiceProvider method createControllerService.

@Override
public ControllerServiceNode createControllerService(final String type, final String id, final BundleCoordinate bundleCoordinate, final Set<URL> additionalUrls, final boolean firstTimeAdded) {
    if (type == null || id == null || bundleCoordinate == null) {
        throw new NullPointerException();
    }
    ClassLoader cl = null;
    final ClassLoader currentContextClassLoader = Thread.currentThread().getContextClassLoader();
    try {
        final Class<?> rawClass;
        try {
            final Bundle csBundle = ExtensionManager.getBundle(bundleCoordinate);
            if (csBundle == null) {
                throw new ControllerServiceInstantiationException("Unable to find bundle for coordinate " + bundleCoordinate.getCoordinate());
            }
            cl = ExtensionManager.createInstanceClassLoader(type, id, csBundle, additionalUrls);
            Thread.currentThread().setContextClassLoader(cl);
            rawClass = Class.forName(type, false, cl);
        } catch (final Exception e) {
            logger.error("Could not create Controller Service of type " + type + " for ID " + id + "; creating \"Ghost\" implementation", e);
            Thread.currentThread().setContextClassLoader(currentContextClassLoader);
            return createGhostControllerService(type, id, bundleCoordinate);
        }
        final Class<? extends ControllerService> controllerServiceClass = rawClass.asSubclass(ControllerService.class);
        final ControllerService originalService = controllerServiceClass.newInstance();
        final StandardControllerServiceInvocationHandler invocationHandler = new StandardControllerServiceInvocationHandler(originalService);
        // extract all interfaces... controllerServiceClass is non null so getAllInterfaces is non null
        final List<Class<?>> interfaceList = ClassUtils.getAllInterfaces(controllerServiceClass);
        final Class<?>[] interfaces = interfaceList.toArray(new Class<?>[interfaceList.size()]);
        final ControllerService proxiedService;
        if (cl == null) {
            proxiedService = (ControllerService) Proxy.newProxyInstance(getClass().getClassLoader(), interfaces, invocationHandler);
        } else {
            proxiedService = (ControllerService) Proxy.newProxyInstance(cl, interfaces, invocationHandler);
        }
        logger.info("Created Controller Service of type {} with identifier {}", type, id);
        final ComponentLog serviceLogger = new SimpleProcessLogger(id, originalService);
        final TerminationAwareLogger terminationAwareLogger = new TerminationAwareLogger(serviceLogger);
        originalService.initialize(new StandardControllerServiceInitializationContext(id, terminationAwareLogger, this, getStateManager(id), nifiProperties));
        final ValidationContextFactory validationContextFactory = new StandardValidationContextFactory(this, variableRegistry);
        final LoggableComponent<ControllerService> originalLoggableComponent = new LoggableComponent<>(originalService, bundleCoordinate, terminationAwareLogger);
        final LoggableComponent<ControllerService> proxiedLoggableComponent = new LoggableComponent<>(proxiedService, bundleCoordinate, terminationAwareLogger);
        final ComponentVariableRegistry componentVarRegistry = new StandardComponentVariableRegistry(this.variableRegistry);
        final ControllerServiceNode serviceNode = new StandardControllerServiceNode(originalLoggableComponent, proxiedLoggableComponent, invocationHandler, id, validationContextFactory, this, componentVarRegistry, flowController);
        serviceNode.setName(rawClass.getSimpleName());
        invocationHandler.setServiceNode(serviceNode);
        if (firstTimeAdded) {
            try (final NarCloseable x = NarCloseable.withComponentNarLoader(originalService.getClass(), originalService.getIdentifier())) {
                ReflectionUtils.invokeMethodsWithAnnotation(OnAdded.class, originalService);
            } catch (final Exception e) {
                throw new ComponentLifeCycleException("Failed to invoke On-Added Lifecycle methods of " + originalService, e);
            }
        }
        serviceCache.putIfAbsent(id, serviceNode);
        return serviceNode;
    } catch (final Throwable t) {
        throw new ControllerServiceInstantiationException(t);
    } finally {
        if (currentContextClassLoader != null) {
            Thread.currentThread().setContextClassLoader(currentContextClassLoader);
        }
    }
}
Also used : ControllerServiceInstantiationException(org.apache.nifi.controller.exception.ControllerServiceInstantiationException) ValidationContextFactory(org.apache.nifi.controller.ValidationContextFactory) StandardValidationContextFactory(org.apache.nifi.processor.StandardValidationContextFactory) ControllerService(org.apache.nifi.controller.ControllerService) StandardValidationContextFactory(org.apache.nifi.processor.StandardValidationContextFactory) SimpleProcessLogger(org.apache.nifi.processor.SimpleProcessLogger) NarCloseable(org.apache.nifi.nar.NarCloseable) StandardComponentVariableRegistry(org.apache.nifi.registry.variable.StandardComponentVariableRegistry) Bundle(org.apache.nifi.bundle.Bundle) ComponentLifeCycleException(org.apache.nifi.controller.exception.ComponentLifeCycleException) ComponentLog(org.apache.nifi.logging.ComponentLog) TimeoutException(java.util.concurrent.TimeoutException) ComponentLifeCycleException(org.apache.nifi.controller.exception.ComponentLifeCycleException) ControllerServiceInstantiationException(org.apache.nifi.controller.exception.ControllerServiceInstantiationException) LoggableComponent(org.apache.nifi.controller.LoggableComponent) StandardComponentVariableRegistry(org.apache.nifi.registry.variable.StandardComponentVariableRegistry) ComponentVariableRegistry(org.apache.nifi.registry.ComponentVariableRegistry) TerminationAwareLogger(org.apache.nifi.controller.TerminationAwareLogger)

Example 7 with StandardValidationContextFactory

use of org.apache.nifi.processor.StandardValidationContextFactory in project nifi by apache.

the class StandardControllerServiceProvider method createGhostControllerService.

private ControllerServiceNode createGhostControllerService(final String type, final String id, final BundleCoordinate bundleCoordinate) {
    final ControllerServiceInvocationHandler invocationHandler = new ControllerServiceInvocationHandler() {

        @Override
        public Object invoke(final Object proxy, final Method method, final Object[] args) throws Throwable {
            final String methodName = method.getName();
            if ("validate".equals(methodName)) {
                final ValidationResult result = new ValidationResult.Builder().input("Any Property").subject("Missing Controller Service").valid(false).explanation("Controller Service could not be created because the Controller Service Type (" + type + ") could not be found").build();
                return Collections.singleton(result);
            } else if ("getPropertyDescriptor".equals(methodName)) {
                final String propertyName = (String) args[0];
                return new PropertyDescriptor.Builder().name(propertyName).description(propertyName).sensitive(true).required(true).build();
            } else if ("getPropertyDescriptors".equals(methodName)) {
                return Collections.emptyList();
            } else if ("onPropertyModified".equals(methodName)) {
                return null;
            } else if ("getIdentifier".equals(methodName)) {
                return id;
            } else if ("toString".equals(methodName)) {
                return "GhostControllerService[id=" + id + ", type=" + type + "]";
            } else if ("hashCode".equals(methodName)) {
                return 91 * type.hashCode() + 41 * id.hashCode();
            } else if ("equals".equals(methodName)) {
                return proxy == args[0];
            } else {
                throw new IllegalStateException("Controller Service could not be created because the Controller Service Type (" + type + ") could not be found");
            }
        }

        @Override
        public void setServiceNode(ControllerServiceNode serviceNode) {
        // nothing to do
        }
    };
    final ControllerService proxiedService = (ControllerService) Proxy.newProxyInstance(getClass().getClassLoader(), new Class[] { ControllerService.class }, invocationHandler);
    final String simpleClassName = type.contains(".") ? StringUtils.substringAfterLast(type, ".") : type;
    final String componentType = "(Missing) " + simpleClassName;
    final LoggableComponent<ControllerService> proxiedLoggableComponent = new LoggableComponent<>(proxiedService, bundleCoordinate, null);
    final ComponentVariableRegistry componentVarRegistry = new StandardComponentVariableRegistry(this.variableRegistry);
    final ControllerServiceNode serviceNode = new StandardControllerServiceNode(proxiedLoggableComponent, proxiedLoggableComponent, invocationHandler, id, new StandardValidationContextFactory(this, variableRegistry), this, componentType, type, componentVarRegistry, flowController, true);
    serviceCache.putIfAbsent(id, serviceNode);
    return serviceNode;
}
Also used : StandardComponentVariableRegistry(org.apache.nifi.registry.variable.StandardComponentVariableRegistry) Method(java.lang.reflect.Method) ValidationResult(org.apache.nifi.components.ValidationResult) ControllerService(org.apache.nifi.controller.ControllerService) StandardValidationContextFactory(org.apache.nifi.processor.StandardValidationContextFactory) LoggableComponent(org.apache.nifi.controller.LoggableComponent) StandardComponentVariableRegistry(org.apache.nifi.registry.variable.StandardComponentVariableRegistry) ComponentVariableRegistry(org.apache.nifi.registry.ComponentVariableRegistry)

Example 8 with StandardValidationContextFactory

use of org.apache.nifi.processor.StandardValidationContextFactory in project nifi by apache.

the class FlowController method createProcessor.

/**
 * <p>
 * Creates a new ProcessorNode with the given type and identifier and
 * optionally initializes it.
 * </p>
 *
 * @param type the fully qualified Processor class name
 * @param id the unique ID of the Processor
 * @param coordinate the bundle coordinate for this processor
 * @param firstTimeAdded whether or not this is the first time this
 * Processor is added to the graph. If {@code true}, will invoke methods
 * annotated with the {@link OnAdded} annotation.
 * @return new processor node
 * @throws NullPointerException if either arg is null
 * @throws ProcessorInstantiationException if the processor cannot be
 * instantiated for any reason
 */
public ProcessorNode createProcessor(final String type, String id, final BundleCoordinate coordinate, final Set<URL> additionalUrls, final boolean firstTimeAdded, final boolean registerLogObserver) throws ProcessorInstantiationException {
    id = id.intern();
    boolean creationSuccessful;
    LoggableComponent<Processor> processor;
    try {
        processor = instantiateProcessor(type, id, coordinate, additionalUrls);
        creationSuccessful = true;
    } catch (final ProcessorInstantiationException pie) {
        LOG.error("Could not create Processor of type " + type + " for ID " + id + "; creating \"Ghost\" implementation", pie);
        final GhostProcessor ghostProc = new GhostProcessor();
        ghostProc.setIdentifier(id);
        ghostProc.setCanonicalClassName(type);
        processor = new LoggableComponent<>(ghostProc, coordinate, null);
        creationSuccessful = false;
    }
    final ComponentVariableRegistry componentVarRegistry = new StandardComponentVariableRegistry(this.variableRegistry);
    final ValidationContextFactory validationContextFactory = new StandardValidationContextFactory(controllerServiceProvider, componentVarRegistry);
    final ProcessorNode procNode;
    if (creationSuccessful) {
        procNode = new StandardProcessorNode(processor, id, validationContextFactory, processScheduler, controllerServiceProvider, nifiProperties, componentVarRegistry, this);
    } else {
        final String simpleClassName = type.contains(".") ? StringUtils.substringAfterLast(type, ".") : type;
        final String componentType = "(Missing) " + simpleClassName;
        procNode = new StandardProcessorNode(processor, id, validationContextFactory, processScheduler, controllerServiceProvider, componentType, type, nifiProperties, componentVarRegistry, this, true);
    }
    final LogRepository logRepository = LogRepositoryFactory.getRepository(id);
    if (registerLogObserver) {
        logRepository.addObserver(StandardProcessorNode.BULLETIN_OBSERVER_ID, LogLevel.WARN, new ProcessorLogObserver(getBulletinRepository(), procNode));
    }
    try {
        final Class<?> procClass = procNode.getProcessor().getClass();
        if (procClass.isAnnotationPresent(DefaultSettings.class)) {
            DefaultSettings ds = procClass.getAnnotation(DefaultSettings.class);
            try {
                procNode.setYieldPeriod(ds.yieldDuration());
            } catch (Throwable ex) {
                LOG.error(String.format("Error while setting yield period from DefaultSettings annotation:%s", ex.getMessage()), ex);
            }
            try {
                procNode.setPenalizationPeriod(ds.penaltyDuration());
            } catch (Throwable ex) {
                LOG.error(String.format("Error while setting penalty duration from DefaultSettings annotation:%s", ex.getMessage()), ex);
            }
            // the caller said to register the log observer, otherwise we could be changing the level when we didn't mean to
            if (registerLogObserver) {
                try {
                    procNode.setBulletinLevel(ds.bulletinLevel());
                } catch (Throwable ex) {
                    LOG.error(String.format("Error while setting bulletin level from DefaultSettings annotation:%s", ex.getMessage()), ex);
                }
            }
        }
    } catch (Throwable ex) {
        LOG.error(String.format("Error while setting default settings from DefaultSettings annotation: %s", ex.getMessage()), ex);
    }
    if (firstTimeAdded) {
        try (final NarCloseable x = NarCloseable.withComponentNarLoader(procNode.getProcessor().getClass(), procNode.getProcessor().getIdentifier())) {
            ReflectionUtils.invokeMethodsWithAnnotation(OnAdded.class, procNode.getProcessor());
        } catch (final Exception e) {
            if (registerLogObserver) {
                logRepository.removeObserver(StandardProcessorNode.BULLETIN_OBSERVER_ID);
            }
            throw new ComponentLifeCycleException("Failed to invoke @OnAdded methods of " + procNode.getProcessor(), e);
        }
        if (firstTimeAdded) {
            try (final NarCloseable nc = NarCloseable.withComponentNarLoader(procNode.getProcessor().getClass(), procNode.getProcessor().getIdentifier())) {
                ReflectionUtils.quietlyInvokeMethodsWithAnnotation(OnConfigurationRestored.class, procNode.getProcessor());
            }
        }
    }
    return procNode;
}
Also used : NarCloseable(org.apache.nifi.nar.NarCloseable) GhostProcessor(org.apache.nifi.processor.GhostProcessor) Processor(org.apache.nifi.processor.Processor) StandardComponentVariableRegistry(org.apache.nifi.registry.variable.StandardComponentVariableRegistry) LogRepository(org.apache.nifi.logging.LogRepository) DefaultSettings(org.apache.nifi.annotation.configuration.DefaultSettings) StandardValidationContextFactory(org.apache.nifi.processor.StandardValidationContextFactory) ComponentLifeCycleException(org.apache.nifi.controller.exception.ComponentLifeCycleException) StandardValidationContextFactory(org.apache.nifi.processor.StandardValidationContextFactory) ConfigException(org.apache.zookeeper.server.quorum.QuorumPeerConfig.ConfigException) IOException(java.io.IOException) ProcessorInstantiationException(org.apache.nifi.controller.exception.ProcessorInstantiationException) ComponentLifeCycleException(org.apache.nifi.controller.exception.ComponentLifeCycleException) UnknownServiceAddressException(org.apache.nifi.cluster.protocol.UnknownServiceAddressException) FlowSerializationException(org.apache.nifi.controller.serialization.FlowSerializationException) ResourceNotFoundException(org.apache.nifi.web.ResourceNotFoundException) InitializationException(org.apache.nifi.reporting.InitializationException) ReportingTaskInstantiationException(org.apache.nifi.controller.reporting.ReportingTaskInstantiationException) CommunicationsException(org.apache.nifi.controller.exception.CommunicationsException) FlowSynchronizationException(org.apache.nifi.controller.serialization.FlowSynchronizationException) ControllerServiceInstantiationException(org.apache.nifi.controller.exception.ControllerServiceInstantiationException) StandardComponentVariableRegistry(org.apache.nifi.registry.variable.StandardComponentVariableRegistry) ComponentVariableRegistry(org.apache.nifi.registry.ComponentVariableRegistry) ProcessorInstantiationException(org.apache.nifi.controller.exception.ProcessorInstantiationException) GhostProcessor(org.apache.nifi.processor.GhostProcessor) ProcessorLogObserver(org.apache.nifi.logging.ProcessorLogObserver)

Example 9 with StandardValidationContextFactory

use of org.apache.nifi.processor.StandardValidationContextFactory in project nifi by apache.

the class TestStandardControllerServiceProvider method createProcessor.

private ProcessorNode createProcessor(final StandardProcessScheduler scheduler, final ControllerServiceProvider serviceProvider) {
    final ReloadComponent reloadComponent = Mockito.mock(ReloadComponent.class);
    final LoggableComponent<Processor> dummyProcessor = new LoggableComponent<>(new DummyProcessor(), systemBundle.getBundleDetails().getCoordinate(), null);
    final ProcessorNode procNode = new StandardProcessorNode(dummyProcessor, UUID.randomUUID().toString(), new StandardValidationContextFactory(serviceProvider, null), scheduler, serviceProvider, niFiProperties, new StandardComponentVariableRegistry(VariableRegistry.EMPTY_REGISTRY), reloadComponent);
    final ProcessGroup group = new StandardProcessGroup(UUID.randomUUID().toString(), serviceProvider, scheduler, null, null, Mockito.mock(FlowController.class), new MutableVariableRegistry(variableRegistry));
    group.addProcessor(procNode);
    procNode.setProcessGroup(group);
    return procNode;
}
Also used : Processor(org.apache.nifi.processor.Processor) DummyProcessor(org.apache.nifi.controller.service.mock.DummyProcessor) StandardComponentVariableRegistry(org.apache.nifi.registry.variable.StandardComponentVariableRegistry) StandardProcessGroup(org.apache.nifi.groups.StandardProcessGroup) ReloadComponent(org.apache.nifi.controller.ReloadComponent) StandardValidationContextFactory(org.apache.nifi.processor.StandardValidationContextFactory) LoggableComponent(org.apache.nifi.controller.LoggableComponent) ProcessorNode(org.apache.nifi.controller.ProcessorNode) StandardProcessorNode(org.apache.nifi.controller.StandardProcessorNode) ProcessGroup(org.apache.nifi.groups.ProcessGroup) MockProcessGroup(org.apache.nifi.controller.service.mock.MockProcessGroup) StandardProcessGroup(org.apache.nifi.groups.StandardProcessGroup) MutableVariableRegistry(org.apache.nifi.registry.variable.MutableVariableRegistry) FlowController(org.apache.nifi.controller.FlowController) DummyProcessor(org.apache.nifi.controller.service.mock.DummyProcessor) StandardProcessorNode(org.apache.nifi.controller.StandardProcessorNode)

Example 10 with StandardValidationContextFactory

use of org.apache.nifi.processor.StandardValidationContextFactory in project nifi by apache.

the class FlowController method createReportingTask.

public ReportingTaskNode createReportingTask(final String type, final String id, final BundleCoordinate bundleCoordinate, final Set<URL> additionalUrls, final boolean firstTimeAdded, final boolean register) throws ReportingTaskInstantiationException {
    if (type == null || id == null || bundleCoordinate == null) {
        throw new NullPointerException();
    }
    LoggableComponent<ReportingTask> task = null;
    boolean creationSuccessful = true;
    try {
        task = instantiateReportingTask(type, id, bundleCoordinate, additionalUrls);
    } catch (final Exception e) {
        LOG.error("Could not create Reporting Task of type " + type + " for ID " + id + "; creating \"Ghost\" implementation", e);
        final GhostReportingTask ghostTask = new GhostReportingTask();
        ghostTask.setIdentifier(id);
        ghostTask.setCanonicalClassName(type);
        task = new LoggableComponent<>(ghostTask, bundleCoordinate, null);
        creationSuccessful = false;
    }
    final ComponentVariableRegistry componentVarRegistry = new StandardComponentVariableRegistry(this.variableRegistry);
    final ValidationContextFactory validationContextFactory = new StandardValidationContextFactory(controllerServiceProvider, componentVarRegistry);
    final ReportingTaskNode taskNode;
    if (creationSuccessful) {
        taskNode = new StandardReportingTaskNode(task, id, this, processScheduler, validationContextFactory, componentVarRegistry, this);
    } else {
        final String simpleClassName = type.contains(".") ? StringUtils.substringAfterLast(type, ".") : type;
        final String componentType = "(Missing) " + simpleClassName;
        taskNode = new StandardReportingTaskNode(task, id, this, processScheduler, validationContextFactory, componentType, type, componentVarRegistry, this, true);
    }
    taskNode.setName(taskNode.getReportingTask().getClass().getSimpleName());
    if (firstTimeAdded) {
        final ReportingInitializationContext config = new StandardReportingInitializationContext(id, taskNode.getName(), SchedulingStrategy.TIMER_DRIVEN, "1 min", taskNode.getLogger(), this, nifiProperties, this);
        try {
            taskNode.getReportingTask().initialize(config);
        } catch (final InitializationException ie) {
            throw new ReportingTaskInstantiationException("Failed to initialize reporting task of type " + type, ie);
        }
        try (final NarCloseable x = NarCloseable.withComponentNarLoader(taskNode.getReportingTask().getClass(), taskNode.getReportingTask().getIdentifier())) {
            ReflectionUtils.invokeMethodsWithAnnotation(OnAdded.class, taskNode.getReportingTask());
            ReflectionUtils.quietlyInvokeMethodsWithAnnotation(OnConfigurationRestored.class, taskNode.getReportingTask());
        } catch (final Exception e) {
            throw new ComponentLifeCycleException("Failed to invoke On-Added Lifecycle methods of " + taskNode.getReportingTask(), e);
        }
    }
    if (register) {
        reportingTasks.put(id, taskNode);
        // Register log observer to provide bulletins when reporting task logs anything at WARN level or above
        final LogRepository logRepository = LogRepositoryFactory.getRepository(id);
        logRepository.addObserver(StandardProcessorNode.BULLETIN_OBSERVER_ID, LogLevel.WARN, new ReportingTaskLogObserver(getBulletinRepository(), taskNode));
    }
    return taskNode;
}
Also used : NarCloseable(org.apache.nifi.nar.NarCloseable) StandardComponentVariableRegistry(org.apache.nifi.registry.variable.StandardComponentVariableRegistry) LogRepository(org.apache.nifi.logging.LogRepository) StandardValidationContextFactory(org.apache.nifi.processor.StandardValidationContextFactory) StandardReportingInitializationContext(org.apache.nifi.controller.reporting.StandardReportingInitializationContext) InitializationException(org.apache.nifi.reporting.InitializationException) ComponentLifeCycleException(org.apache.nifi.controller.exception.ComponentLifeCycleException) StandardValidationContextFactory(org.apache.nifi.processor.StandardValidationContextFactory) ConfigException(org.apache.zookeeper.server.quorum.QuorumPeerConfig.ConfigException) IOException(java.io.IOException) ProcessorInstantiationException(org.apache.nifi.controller.exception.ProcessorInstantiationException) ComponentLifeCycleException(org.apache.nifi.controller.exception.ComponentLifeCycleException) UnknownServiceAddressException(org.apache.nifi.cluster.protocol.UnknownServiceAddressException) FlowSerializationException(org.apache.nifi.controller.serialization.FlowSerializationException) ResourceNotFoundException(org.apache.nifi.web.ResourceNotFoundException) InitializationException(org.apache.nifi.reporting.InitializationException) ReportingTaskInstantiationException(org.apache.nifi.controller.reporting.ReportingTaskInstantiationException) CommunicationsException(org.apache.nifi.controller.exception.CommunicationsException) FlowSynchronizationException(org.apache.nifi.controller.serialization.FlowSynchronizationException) ControllerServiceInstantiationException(org.apache.nifi.controller.exception.ControllerServiceInstantiationException) GhostReportingTask(org.apache.nifi.reporting.GhostReportingTask) ReportingTaskInstantiationException(org.apache.nifi.controller.reporting.ReportingTaskInstantiationException) ReportingInitializationContext(org.apache.nifi.reporting.ReportingInitializationContext) StandardReportingInitializationContext(org.apache.nifi.controller.reporting.StandardReportingInitializationContext) StandardReportingTaskNode(org.apache.nifi.controller.reporting.StandardReportingTaskNode) StandardReportingTaskNode(org.apache.nifi.controller.reporting.StandardReportingTaskNode) StandardComponentVariableRegistry(org.apache.nifi.registry.variable.StandardComponentVariableRegistry) ComponentVariableRegistry(org.apache.nifi.registry.ComponentVariableRegistry) ReportingTaskLogObserver(org.apache.nifi.logging.ReportingTaskLogObserver) ReportingTask(org.apache.nifi.reporting.ReportingTask) GhostReportingTask(org.apache.nifi.reporting.GhostReportingTask)

Aggregations

StandardValidationContextFactory (org.apache.nifi.processor.StandardValidationContextFactory)10 StandardComponentVariableRegistry (org.apache.nifi.registry.variable.StandardComponentVariableRegistry)10 LoggableComponent (org.apache.nifi.controller.LoggableComponent)8 ProcessorNode (org.apache.nifi.controller.ProcessorNode)6 ReloadComponent (org.apache.nifi.controller.ReloadComponent)6 StandardProcessorNode (org.apache.nifi.controller.StandardProcessorNode)6 Processor (org.apache.nifi.processor.Processor)6 FailOnScheduledProcessor (org.apache.nifi.controller.scheduling.processors.FailOnScheduledProcessor)4 AbstractProcessor (org.apache.nifi.processor.AbstractProcessor)4 StandardProcessorInitializationContext (org.apache.nifi.processor.StandardProcessorInitializationContext)4 ComponentVariableRegistry (org.apache.nifi.registry.ComponentVariableRegistry)4 Test (org.junit.Test)4 ComponentLifeCycleException (org.apache.nifi.controller.exception.ComponentLifeCycleException)3 ControllerServiceInstantiationException (org.apache.nifi.controller.exception.ControllerServiceInstantiationException)3 NarCloseable (org.apache.nifi.nar.NarCloseable)3 IOException (java.io.IOException)2 HashMap (java.util.HashMap)2 ConcurrentHashMap (java.util.concurrent.ConcurrentHashMap)2 UnknownServiceAddressException (org.apache.nifi.cluster.protocol.UnknownServiceAddressException)2 ControllerService (org.apache.nifi.controller.ControllerService)2