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

ASF subversion and git services commented on NIFI-5877:
-------------------------------------------------------

Commit f1e03b5ed5b53dd909f0e20d8684113120cd73e5 in nifi's branch 
refs/heads/master from [~bbende]
[ https://git-wip-us.apache.org/repos/asf?p=nifi.git;h=f1e03b5 ]

NIFI-5877 Protecting against null values when obtaining master address

Signed-off-by: Pierre Villard <pierre.villard...@gmail.com>

This closes #3206.


> Protect against null ClusterStatus in HBase Client Service
> ----------------------------------------------------------
>
>                 Key: NIFI-5877
>                 URL: https://issues.apache.org/jira/browse/NIFI-5877
>             Project: Apache NiFi
>          Issue Type: Improvement
>    Affects Versions: 1.5.0, 1.6.0, 1.7.1
>            Reporter: Bryan Bende
>            Assignee: Bryan Bende
>            Priority: Minor
>
> We currently get the masterAddress with this line of code:
> {code:java}
> masterAddress = admin.getClusterStatus().getMaster().getHostAndPort();{code}
> If getClusterStatus() returns null, or getMaster() returns null, then this 
> code will throw a NPE and the service will fail to enable.
> We only user the masterAddress for the transit URI of provenance events, and 
> we already protect against a blank/null masterAddress when generating the 
> URI, so we should protect against the possible nulls in the line above.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to