Я получаю NPE из приведенных ниже фрагментов кода.Не уверен, какой объект является нулевым.
List<ProvisioningBrokerRequest> filteredPbRequests = allPbRequests.parallelStream().filter(
pbRequest -> pbRequest.getProvisioningRequest().getConfig().stream().anyMatch(
config -> StringUtils.equals(uid, config.getUid()) && config.getTemplate() != null && !config
.getTemplate().isEmpty())).collect(Collectors.toList());
Stacktrace
java.lang.NullPointerException
at com.provisioningbroker.impl.ProvisioningRequestServiceImpl.lambda$handleDeleteConnectorConfigCtlrEvent$1(ProvisioningRequestServiceImpl.java:336)[388:com..provisioning-broker-impl:18.1.1.417]
at java.util.stream.ReferencePipeline$2$1.accept(ReferencePipeline.java:174)[:1.8.0_151]
at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1380)[:1.8.0_151]
at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481)[:1.8.0_151]
at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)[:1.8.0_151]
at java.util.stream.ReduceOps$ReduceTask.doLeaf(ReduceOps.java:747)[:1.8.0_151]
at java.util.stream.ReduceOps$ReduceTask.doLeaf(ReduceOps.java:721)[:1.8.0_151]
at java.util.stream.AbstractTask.compute(AbstractTask.java:316)[:1.8.0_151]
at java.util.concurrent.CountedCompleter.exec(CountedCompleter.java:731)[:1.8.0_151]
at java.util.concurrent.ForkJoinTask.doExec(ForkJoinTask.java:289)[:1.8.0_151]
at java.util.concurrent.ForkJoinTask.doInvoke(ForkJoinTask.java:401)[:1.8.0_151]
at java.util.concurrent.ForkJoinTask.invoke(ForkJoinTask.java:734)[:1.8.0_151]
at java.util.stream.ReduceOps$ReduceOp.evaluateParallel(ReduceOps.java:714)[:1.8.0_151]
at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:233)[:1.8.0_151]
at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499)[:1.8.0_151]
at com.provisioningbroker.impl.ProvisioningRequestServiceImpl.handleDeleteConnectorConfigCtlrEvent(ProvisioningRequestServiceImpl.java:338)[388:com.provisioning-broker-impl:18.1.1.417]