NissimShiman commented on code in PR #5878:
URL: https://github.com/apache/nifi/pull/5878#discussion_r901830003


##########
nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/SampleRecord.java:
##########
@@ -208,6 +237,25 @@ protected Collection<ValidationResult> 
customValidate(ValidationContext validati
                         .explanation(SAMPLING_INTERVAL.getDisplayName() + " 
property must be set to use " + INTERVAL_SAMPLING.getDisplayName() + " 
strategy")
                         .build());
             }
+        } else if (RANGE_SAMPLING_KEY.equals(samplingStrategyValue)) {
+            final PropertyValue samplingRangeProperty = 
validationContext.getProperty(SAMPLING_RANGE);
+            if (!samplingRangeProperty.isSet()) {
+                results.add(new 
ValidationResult.Builder().subject(RANGE_SAMPLING.getDisplayName()).valid(false)
+                        .explanation(SAMPLING_RANGE.getDisplayName() + " 
property must be set to use " + RANGE_SAMPLING.getDisplayName() + " strategy")
+                        .build());
+            }

Review Comment:
   I'm not sure if we need this as SAMPLING_RANGE is now a required property.



-- 
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