NIFI-11978 Fix: NPE when trying to disable Management Controller Service

This closes #7637

Signed-off-by: David Handermann <exceptionfactory@apache.org>
This commit is contained in:
Tamas Palfy 2023-08-22 20:27:25 +02:00 committed by exceptionfactory
parent c08560447f
commit 1e12800912
No known key found for this signature in database
GPG Key ID: 29B6A52D2AAE8DBA
1 changed files with 4 additions and 1 deletions

View File

@ -284,7 +284,10 @@ public class StandardControllerServiceDAO extends ComponentDAO implements Contro
public void verifyUpdateReferencingComponents(final String controllerServiceId, final ScheduledState scheduledState, final ControllerServiceState controllerServiceState) {
final ControllerServiceNode controllerService = locateControllerService(controllerServiceId);
controllerService.getProcessGroup().verifyCanScheduleComponentsIndividually();
final ProcessGroup processGroup = controllerService.getProcessGroup();
if (processGroup != null) {
processGroup.verifyCanScheduleComponentsIndividually();
}
if (controllerServiceState != null) {
if (ControllerServiceState.ENABLED.equals(controllerServiceState)) {