diff --git a/nifi-nar-bundles/nifi-kudu-bundle/nifi-kudu-controller-service/src/main/java/org/apache/nifi/controller/kudu/KuduLookupService.java b/nifi-nar-bundles/nifi-kudu-bundle/nifi-kudu-controller-service/src/main/java/org/apache/nifi/controller/kudu/KuduLookupService.java index 93b0ce61aa..5656fdb9e5 100644 --- a/nifi-nar-bundles/nifi-kudu-bundle/nifi-kudu-controller-service/src/main/java/org/apache/nifi/controller/kudu/KuduLookupService.java +++ b/nifi-nar-bundles/nifi-kudu-bundle/nifi-kudu-controller-service/src/main/java/org/apache/nifi/controller/kudu/KuduLookupService.java @@ -246,7 +246,19 @@ public class KuduLookupService extends AbstractControllerService implements Reco @Override public Optional lookup(Map coordinates) { + Optional record; + if (kerberosUser != null) { + final KerberosAction> kerberosAction = new KerberosAction<>(kerberosUser, () -> getRecord(coordinates), getLogger()); + record = kerberosAction.execute(); + } else { + record = getRecord(coordinates); + } + + return record; + } + + private Optional getRecord(Map coordinates) { //Scanner KuduScanner.KuduScannerBuilder builder = kuduClient.newScannerBuilder(table);