diff --git a/dynamic-mapping-service/src/main/java/dynamic/mapping/rest/MappingRestController.java b/dynamic-mapping-service/src/main/java/dynamic/mapping/rest/MappingRestController.java index 9340f3bd..f9977156 100644 --- a/dynamic-mapping-service/src/main/java/dynamic/mapping/rest/MappingRestController.java +++ b/dynamic-mapping-service/src/main/java/dynamic/mapping/rest/MappingRestController.java @@ -212,8 +212,8 @@ public ResponseEntity deleteConnectionConfiguration(@PathVariable String return ResponseEntity.status(HttpStatus.BAD_REQUEST) .body("Can't delete an enabled connector! Disable connector first."); // make sure the connector is disconnected before it is deleted. - if (connectorRegistry.getClientForTenant(tenant, ident).isConnected()) - bootstrapService.disableConnector(tenant, ident); + //if (connectorRegistry.getClientForTenant(tenant, ident) != null && connectorRegistry.getClientForTenant(tenant, ident).isConnected()) + bootstrapService.disableConnector(tenant, ident); connectorConfigurationComponent.deleteConnectorConfiguration(ident); mappingComponent.removeConnectorFromDeploymentMap(tenant, ident); bootstrapService.shutdownAndRemoveConnector(tenant, ident);