[
https://issues.apache.org/jira/browse/NIFI-10767?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17629195#comment-17629195
]
ASF subversion and git services commented on NIFI-10767:
--------------------------------------------------------
Commit 381e0f84e122a7ff357ad08b7b8fe2c08fee0c24 in nifi's branch
refs/heads/main from Mark Payne
[ https://gitbox.apache.org/repos/asf?p=nifi.git;h=381e0f84e1 ]
NIFI-10767: When an empty line is encountered with Syslog Readers, just skip
over the empty line instead of throwing an Exception
This closes #6623
Signed-off-by: David Handermann <[email protected]>
> SyslogReader should not throw Exceptions on empty/blank lines
> -------------------------------------------------------------
>
> Key: NIFI-10767
> URL: https://issues.apache.org/jira/browse/NIFI-10767
> Project: Apache NiFi
> Issue Type: Bug
> Components: Extensions
> Reporter: Mark Payne
> Assignee: Mark Payne
> Priority: Major
> Fix For: 1.19.0
>
> Time Spent: 20m
> Remaining Estimate: 0h
>
> If the SyslogReader encounters an empty line, it throws an Exception:
> {code:java}
> if (StringUtils.isBlank(line)) {
> // while an empty string is an error
> throw new MalformedRecordException("Encountered a blank message!");
> } {code}
> Often flows are built that use MergeContent or split data apart, etc. that
> can result in inadvertently including an empty line between messages. There's
> no need to throw an Exception in this case. Instead, we should simply skip
> over the empty line. Perhaps a debug log should be emitted but not an
> Exception.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)