exceptionfactory commented on code in PR #9620:
URL: https://github.com/apache/nifi/pull/9620#discussion_r1910945741
##########
nifi-extension-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/GenerateFlowFile.java:
##########
@@ -76,7 +76,8 @@ public class GenerateFlowFile extends AbstractProcessor {
.description("The size of the file that will be used")
.required(true)
.defaultValue("0B")
- .addValidator(StandardValidators.DATA_SIZE_VALIDATOR)
+ .addValidator(StandardValidators.NON_EMPTY_VALIDATOR)
Review Comment:
@markobean Reverting this change and running the unit test worked as
expected. See `StandardValidators` line 370 where the validator handles the
presence of expression language. Do you still see the validation error?
##########
nifi-extension-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/GenerateFlowFile.java:
##########
@@ -187,11 +188,13 @@ protected Collection<ValidationResult>
customValidate(ValidationContext validati
+ "text and Unique FlowFiles must be false.").build());
}
+ results.add(StandardValidators.DATA_SIZE_VALIDATOR.validate("File
Size",
validationContext.getProperty(FILE_SIZE).evaluateAttributeExpressions().getValue(),
validationContext));
Review Comment:
This line should also be removed after reverting the validator change.
--
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]