-
Notifications
You must be signed in to change notification settings - Fork 38.8k
Description
Abhijit Sarkar opened SPR-16337 and commented
Given a stream "abc\n", "abc", "def\n", "abc", "def\nxyz\n", "abc", "def", "xyz\n" StringDecoder simply chops them off at newlines. This is hardly desired, since most applications expect to deal with complete records that end on line boundaries. In other words, the expected output for the above would be "abc", "abcdef", "abcdef", "xyz", "abcdefxyz".
I've an alternate implementation that produces the expected output but before making a PR, I would like to check that the existing behavior is not based on some use case I'm not thinking about.
https://github.com/asarkar/spring/blob/master/buffer-learning/src/main/java/org/abhijitsarkar/java/StringDecoder.java
Affects: 5.0.2
Referenced from: commits spring-projects/spring-integration@11240be
0 votes, 7 watchers