[
https://issues.apache.org/jira/browse/NIFI-15686?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Pierre Villard reassigned NIFI-15686:
-------------------------------------
Assignee: Pierre Villard
> NullPointerException when accessing /nifi-api/flow/listen-ports
> ---------------------------------------------------------------
>
> Key: NIFI-15686
> URL: https://issues.apache.org/jira/browse/NIFI-15686
> Project: Apache NiFi
> Issue Type: Bug
> Affects Versions: 2.8.0
> Reporter: Mathias Krueger
> Assignee: Pierre Villard
> Priority: Major
>
> If a user adds a ListenSyslog processor to the canvas and doesnt configure a
> port, accessing nifi-api/flow/listen-ports results in the message:
> An unexpected error has occurred. Please check the logs for additional
> details.
> in nifi-user.log the following NPE is thrown
> {code:java}
> java.lang.NullPointerException: Cannot invoke "java.lang.Integer.intValue()"
> because "tcpPortNumber" is null
> at
> org.apache.nifi.processors.standard.ListenSyslog.getListenPorts(ListenSyslog.java:357)
> {code}
> In ListenSyslog in method getListenPorts should a null value check for TCP
> and UDP port be added.
> Also if the users enters an invalid value (e.g. empty text) this method
> should not fail.
> This problem exists for every components that inherits the method
> getListenPorts() form the interface ListenComponent
--
This message was sent by Atlassian Jira
(v8.20.10#820010)