ChrisSamo632 commented on code in PR #7195:
URL: https://github.com/apache/nifi/pull/7195#discussion_r1178127215


##########
nifi-nar-bundles/nifi-elasticsearch-bundle/nifi-elasticsearch-restapi-processors/src/main/java/org/apache/nifi/processors/elasticsearch/AbstractJsonQueryElasticsearch.java:
##########
@@ -65,7 +65,7 @@
             .name("el-rest-split-up-hits")
             .displayName("Search Results Split")
             .description("Output a flowfile containing all hits or one 
flowfile for each individual hit.")
-            .allowableValues(ResultOutputStrategy.PER_RESPONSE.getValue(), 
ResultOutputStrategy.PER_HIT.getValue())
+            
.allowableValues(ResultOutputStrategy.getNonPaginatedResponseOutputStrategies())

Review Comment:
   Disagree - we don't want all three options here, just the 2, which is why 
I've put these in a `non-paginated` method to provide the filtered `EnumSet`
   
   The full set of options is needed for the properties of the 
`PaginatedJsonQueryElasticsearch` processor where the `COMBINED` option makes 
sense, but not for the non-paginated processors



##########
nifi-nar-bundles/nifi-elasticsearch-bundle/nifi-elasticsearch-restapi-processors/src/main/java/org/apache/nifi/processors/elasticsearch/api/ResultOutputStrategy.java:
##########
@@ -52,6 +53,10 @@ public String getDescription() {
         return description;
     }
 
+    public static EnumSet<ResultOutputStrategy> 
getNonPaginatedResponseOutputStrategies() {
+        return EnumSet.of(PER_RESPONSE, PER_HIT);
+    }

Review Comment:
   See https://github.com/apache/nifi/pull/7195#discussion_r1178127215



-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to