[ 
https://issues.apache.org/jira/browse/NIFI-2944?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15788074#comment-15788074
 ] 

ASF GitHub Bot commented on NIFI-2944:
--------------------------------------

GitHub user pvillard31 opened a pull request:

    https://github.com/apache/nifi/pull/1379

    NIFI-2944 check remote input hostname at startup

    Thank you for submitting a contribution to Apache NiFi.
    
    In order to streamline the review of the contribution we ask you
    to ensure the following steps have been taken:
    
    ### For all changes:
    - [X] Is there a JIRA ticket associated with this PR? Is it referenced 
         in the commit message?
    
    - [X] Does your PR title start with NIFI-XXXX where XXXX is the JIRA number 
you are trying to resolve? Pay particular attention to the hyphen "-" character.
    
    - [X] Has your PR been rebased against the latest commit within the target 
branch (typically master)?
    
    - [X] Is your initial contribution a single, squashed commit?
    
    ### For code changes:
    - [X] Have you ensured that the full suite of tests is executed via mvn 
-Pcontrib-check clean install at the root nifi folder?
    - [X] Have you written or updated unit tests to verify your changes?
    - [ ] If adding new dependencies to the code, are these dependencies 
licensed in a way that is compatible for inclusion under [ASF 
2.0](http://www.apache.org/legal/resolved.html#category-a)? 
    - [ ] If applicable, have you updated the LICENSE file, including the main 
LICENSE file under nifi-assembly?
    - [ ] If applicable, have you updated the NOTICE file, including the main 
NOTICE file found under nifi-assembly?
    - [ ] If adding new Properties, have you added .displayName in addition to 
.name (programmatic access) for each of the new properties?
    
    ### For documentation related changes:
    - [ ] Have you ensured that format looks appropriate for the output in 
which it is rendered?
    
    ### Note:
    Please ensure that once the PR is submitted, you check travis-ci for build 
issues and submit an update to your PR as soon as possible.


You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/pvillard31/nifi NIFI-2944

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/nifi/pull/1379.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #1379
    
----
commit 2008a984775407bb0acd0b5c90aae6e58e2c625f
Author: Pierre Villard <pierre.villard...@gmail.com>
Date:   2016-12-30T17:32:44Z

    NIFI-2944 check remote input hostname at startup

----


> Validate the configured remote input hostname
> ---------------------------------------------
>
>                 Key: NIFI-2944
>                 URL: https://issues.apache.org/jira/browse/NIFI-2944
>             Project: Apache NiFi
>          Issue Type: Improvement
>    Affects Versions: 1.0.0
>            Reporter: Joseph Percivall
>            Priority: Minor
>
> Currently NiFi doesn't do any validation on what is set for 
> "nifi.remote.input.host". For example, I ran across 1 node cluster configured 
> with a remote input hostname that started with a "http:// ...". This cluster 
> started up and everything seemed fine on it's end but on the client side it 
> failed.
> After the initial connection it received "http:// ..." as the hostname for it 
> to connect to causing UnknownHostExceptions.
> NiFi should validate that the value set for the remote input host is valid in 
> order to avoid this issue.
> Example:
> 2016-10-25 11:18:29,132 ERROR [Timer-Driven Process Thread-6] 
> o.a.nifi.remote.StandardRemoteGroupPort RemoteGroupPort[name=From 
> MiNiFi,target=http://<HOSTNAME>:9090/nifi/] failed to communicate with 
> http://<HOSTNAME>:9090/nifi/ due to java.net.UnknownHostException
> 2016-10-25 11:18:29,136 ERROR [Timer-Driven Process Thread-6] 
> o.a.nifi.remote.StandardRemoteGroupPort 
> java.net.UnknownHostException: null
>   at sun.nio.ch.Net.translateException(Net.java:155) ~[na:1.8.0_74]
>   at sun.nio.ch.SocketAdaptor.connect(SocketAdaptor.java:127) ~[na:1.8.0_74]
>   at 
> org.apache.nifi.remote.client.socket.EndpointConnectionPool.establishSiteToSiteConnection(EndpointConnectionPool.java:712)
>  ~[nifi-site-to-site-client-0.6.1.jar:0.6.1]
>   at 
> org.apache.nifi.remote.client.socket.EndpointConnectionPool.establishSiteToSiteConnection(EndpointConnectionPool.java:685)
>  ~[nifi-site-to-site-client-0.6.1.jar:0.6.1]
>   at 
> org.apache.nifi.remote.client.socket.EndpointConnectionPool.getEndpointConnection(EndpointConnectionPool.java:301)
>  ~[nifi-site-to-site-client-0.6.1.jar:0.6.1]
>   at 
> org.apache.nifi.remote.client.socket.SocketClient.createTransaction(SocketClient.java:129)
>  ~[nifi-site-to-site-client-0.6.1.jar:0.6.1]
>   at 
> org.apache.nifi.remote.StandardRemoteGroupPort.onTrigger(StandardRemoteGroupPort.java:171)
>  ~[nifi-site-to-site-0.6.1.jar:0.6.1]
>   at org.apache.nifi.controller.AbstractPort.onTrigger(AbstractPort.java:227) 
> [nifi-framework-core-api-0.6.1.jar:0.6.1]
>   at 
> org.apache.nifi.controller.tasks.ContinuallyRunConnectableTask.call(ContinuallyRunConnectableTask.java:81)
>  [nifi-framework-core-0.6.1.jar:0.6.1]
>   at 
> org.apache.nifi.controller.tasks.ContinuallyRunConnectableTask.call(ContinuallyRunConnectableTask.java:40)
>  [nifi-framework-core-0.6.1.jar:0.6.1]
>   at 
> org.apache.nifi.controller.scheduling.TimerDrivenSchedulingAgent$1.run(TimerDrivenSchedulingAgent.java:123)
>  [nifi-framework-core-0.6.1.jar:0.6.1]
>   at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) 
> [na:1.8.0_74]
>   at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) 
> [na:1.8.0_74]
>   at 
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180)
>  [na:1.8.0_74]
>   at 
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294)
>  [na:1.8.0_74]
>   at 
> java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
>  [na:1.8.0_74]
>   at 
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
>  [na:1.8.0_74]
>   at java.lang.Thread.run(Thread.java:745) [na:1.8.0_74]



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to