Joseph Percivall created NIFI-5703: -------------------------------------- Summary: SyslogParser regex fails to handle messages that end with Windows style new line Key: NIFI-5703 URL: https://issues.apache.org/jira/browse/NIFI-5703 Project: Apache NiFi Issue Type: Bug Reporter: Joseph Percivall
The common SyslogParser class, which is used by ListenSyslog and ParseSyslog, has two different regexes to match the RFCs for syslog. Both of which end in a "(.*)$"[1]. There is also special handling if the last character is "\n"[2]. Note that "." does not match any of the newline characters[3]. The endline handling should be expanded to handle "\r\n". [1]https://github.com/apache/nifi/blob/master/nifi-nar-bundles/nifi-extension-utils/nifi-syslog-utils/src/main/java/org/apache/nifi/syslog/parsers/SyslogParser.java#L49 [2] https://github.com/apache/nifi/blob/master/nifi-nar-bundles/nifi-extension-utils/nifi-syslog-utils/src/main/java/org/apache/nifi/syslog/parsers/SyslogParser.java#L128 [3] https://stackoverflow.com/questions/3445326/regex-in-java-how-to-deal-with-newline -- This message was sent by Atlassian JIRA (v7.6.3#76005)