SimpleBinaryBufferedReaderFactory misses line endings #811
Labels
for: backport-to-5.0.x
Issues that will be back-ported to the 5.0.x line
for: backport-to-5.1.x
Issues that will be back-ported to the 5.1.x line
in: infrastructure
type: bug
Milestone
cosban opened BATCH-2792 and commented
If a line contains the first character of the line delimiter within N characters of the actual beginning of the line ending delimiter, where N is the length of the line ending delimiter, then the SimpleBinaryBufferedReaderFactory will incorrectly miss the actual line ending and continue reading.
The '#' character is within 5 characters of the actual line ending for this example. This causes the candidateEnding to contain
#3#@#
before determining that it is not the correct line ending, appending all of these characters to the line buffer, and continuing.I suspect it would be better for the method to fail fast the moment that current candidate doesn't match the provided template. i.e. once
#3
is determined to not be a possible match of the template going forward.I have provided a full example of a situation which causes this to fail below:
No further details from BATCH-2792
The text was updated successfully, but these errors were encountered: