DanielCarter-stack commented on PR #11575:
URL: https://github.com/apache/seatunnel/pull/11575#issuecomment-5213343682
Thanks @DanielLeens for the careful review. I've addressed Issue 1 in commit
`fa3bda3b`.
The Socket sink description no longer claims line framing. I verified the
implementation first:
- `SocketSinkWriter` uses `JsonSerializationSchema`, whose `serialize()`
returns `mapper.writeValueAsString(node).getBytes(charset)` — no trailing
newline.
- `SocketClient.write()` only does `outputStream.write(msg);
outputStream.flush()` — no delimiter is appended.
So multiple records are written as one continuous TCP byte stream of
concatenated JSON objects, exactly as you described.
Both `docs/en/connectors/sink/Socket.md` and
`docs/zh/connectors/sink/Socket.md` now:
- State that each row is serialized to a JSON object and that the connector
does **not** append a newline or any delimiter between records.
- Explain that multiple records arrive as concatenated JSON objects (e.g.
`{"a":1}{"a":2}{"a":3}`).
- Note that the peer must handle framing itself with a streaming JSON parser
(e.g. Jackson's `MappingIterator`), not a line-oriented parser, and that `nc
-l` only echoes the raw concatenated bytes.
- The task example output was updated to show concatenated records rather
than a single line.
The `Build` check is re-running on the new head; `Notify test workflow` and
`labeler` already pass. Happy to tweak the wording further if needed.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]