You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@nifi.apache.org by GitBox <gi...@apache.org> on 2020/05/27 03:44:00 UTC

[GitHub] [nifi] adarmiento commented on a change in pull request #4297: NIFI-7488 Listening Port property on HandleHttpRequest is not validated when Variable registry is used

adarmiento commented on a change in pull request #4297:
URL: https://github.com/apache/nifi/pull/4297#discussion_r430201564



##########
File path: nifi-nar-bundles/nifi-standard-bundle/nifi-standard-processors/src/main/java/org/apache/nifi/processors/standard/HandleHttpRequest.java
##########
@@ -321,6 +326,24 @@
         return Collections.singleton(REL_SUCCESS);
     }
 
+    @Override
+    protected Collection<ValidationResult> customValidate(final ValidationContext validationContext) {
+        final List<ValidationResult> results = new ArrayList<>();
+
+        final Long port = validationContext.getProperty(PORT).evaluateAttributeExpressions().asLong();

Review comment:
       I made a unit test using invalid values (passing from the registry), calling the `.assertValid()` was not marking the processor as invalid
   




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

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