You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Timo Walther (JIRA)" <ji...@apache.org> on 2019/06/28 08:23:00 UTC
[jira] [Comment Edited] (FLINK-12979) Sending data to kafka with
CsvRowSerializationSchema always adding a "\n", "\r","\r\n" at the end of
the message
[ https://issues.apache.org/jira/browse/FLINK-12979?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16874769#comment-16874769 ]
Timo Walther edited comment on FLINK-12979 at 6/28/19 8:22 AM:
---------------------------------------------------------------
The implementation is according to the RFC standard. But we could allow setting a custom property to disable the new line at the end.
was (Author: twalthr):
The implementation should be according to the RFC standard. But we could allow setting a custom property to disable the new line at the end.
> Sending data to kafka with CsvRowSerializationSchema always adding a "\n", "\r","\r\n" at the end of the message
> ----------------------------------------------------------------------------------------------------------------
>
> Key: FLINK-12979
> URL: https://issues.apache.org/jira/browse/FLINK-12979
> Project: Flink
> Issue Type: Bug
> Components: API / Type Serialization System
> Affects Versions: 1.8.0, 1.8.1, 1.8.2, 1.9.0, 2.0.0
> Reporter: chaiyongqiang
> Assignee: Hugo Louro
> Priority: Major
>
> When sending data to kafka using CsvRowSerializationSchema, the CsvRowSerializationSchema#serialize method helps generating value for KafkaRecord, which will call CsvEncoder#endRow and in which a _cfgLineSeparator will be added at the end of KafkaRecord.value.
> But For CsvRowSerializationSchema#Builder , when you calling the mothod setLineDelimiter only "\n","\r","\r\n" could be used as the parameter.
> It's not friendly when you want to send a message "123,pingpong,21:00" to kafka but kafka receives a message "123,pingpong,21:00\r\n".
> I'm not sure about the reason for limitting the lineDelimiter to "\n","\r","\r\n" ? In previous version and jackson-databind, there's no limits on lineDelimiter.
> But at least it should let the application developer to set LineDelimiter with "".
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)