You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by "slambrose (via GitHub)" <gi...@apache.org> on 2023/03/07 19:48:31 UTC

[GitHub] [nifi] slambrose commented on a diff in pull request #6993: NIFI-11231 Stateless NiFi sensitive parameter context support

slambrose commented on code in PR #6993:
URL: https://github.com/apache/nifi/pull/6993#discussion_r1128479495


##########
nifi-stateless/nifi-stateless-bundle/nifi-stateless-engine/src/main/java/org/apache/nifi/stateless/engine/StatelessFlowManager.java:
##########
@@ -270,10 +271,9 @@ public FlowFileQueue createFlowFileQueue(final LoadBalanceStrategy loadBalanceSt
     public ReportingTaskNode createReportingTask(final String type, final String id, final BundleCoordinate bundleCoordinate, final Set<URL> additionalUrls, final boolean firstTimeAdded,
                                                  final boolean register, final String classloaderIsolationKey) {
 
-        if (type == null || id == null || bundleCoordinate == null) {

Review Comment:
   Valid point. I used this implementation because it was cleaner as well. The requireNonNull throws a generic NullPointerException, but doesn't have the full details like the current code:
   throw new NullPointerException("Must supply type, id, and bundle coordinate in order to create Reporting Task. Provided arguments were type=" + type + ", id=" + id + ", bundle coordinate = " + bundleCoordinate);
                   
   I can change this back if desired, just let me know.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@nifi.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org