Should _ensureRoom in ProtobufGenerator.writeString()?
See original GitHub issueWith version 2.9.0.pr3, we encounter a ArrayIndexOutOfBoundsException
Caused by: java.lang.ArrayIndexOutOfBoundsException: 8000
at com.fasterxml.jackson.dataformat.protobuf.ProtobufUtil.appendLengthLength(ProtobufUtil.java:73)
at com.fasterxml.jackson.dataformat.protobuf.ProtobufGenerator._writeLengthPrefixed(ProtobufGenerator.java:1293)
at com.fasterxml.jackson.dataformat.protobuf.ProtobufGenerator._encodeLongerString(ProtobufGenerator.java:1286)
at com.fasterxml.jackson.dataformat.protobuf.ProtobufGenerator.writeString(ProtobufGenerator.java:729)
at com.fasterxml.jackson.databind.ser.std.StringSerializer.serialize(StringSerializer.java:41)
at com.fasterxml.jackson.databind.ser.BeanPropertyWriter.serializeAsField(BeanPropertyWriter.java:727)
at com.fasterxml.jackson.databind.ser.std.BeanSerializerBase.serializeFields(BeanSerializerBase.java:716)
... 104 more
Occurs once every few hours, so not easily reproduced. Shall we call _ensureRoom when _encodeLongerString?
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:8 (7 by maintainers)
Top Results From Across the Web
jackson-dataformat-protobuf/ProtobufGenerator.java at master
Flag that indicates whether values should be written with tag or not; ... public ProtobufGenerator useDefaultPrettyPrinter() {. return this;. }.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Yup, I’ll try to get it fixed soon. Just need to re-familiarize with specific part – unlike with many other jackson codecs, solution here is not to simplify flush contents (since due to nesting, not everything can actually be flushed)
Can be reproduced by the following code: