You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Arjen PoutsmaRossen Stoyanchev I have created an updated JsonObjectDecoder based on our DataBuffer instead of using Netty ByteBuf, see this branch for the code. This is the first working version, and the implementation still needs some polish and managing properly buffer release/retain, but I think this is a good basis for discussing various points.
Please notice that I fixed a bug in NettyDataBuffer#lastIndexOf() to make it works.
This JsonObjectDecoder implementation aggregates the multiple buffers thanks to DataBuffer#write(DataBuffer), creates a slice in order to identify the JSON objects start and end index without changing the original buffer read position, and then return each JSON object as a slice that will be processed by Jackson2JsonDecoder.
I think I need Arjen Poutsma feedback to understand how to manage release/retain in that use cases, where we use slices and where 2 decoders are processing the data together.
Jackson 2.9 (initial release or a patch release coming shortly after) should provide asynchronous Jackson JSON parsing capabilities that will allow to avoid requiring io.netty.buffer dependency.
Arjen Poutsma Since you mention during last meeting that you want to have a look to this feature + you have the experience of implementing Aalto XML support, I assign you this issue. Feel free to assign back to me after your initial look if you don't have the time to handle it for RC3.
Activity
spring-projects-issues commentedon Aug 10, 2016
Sébastien Deleuze commented
Arjen Poutsma Rossen Stoyanchev I have created an updated
JsonObjectDecoderbased on ourDataBufferinstead of using NettyByteBuf, see this branch for the code. This is the first working version, and the implementation still needs some polish and managing properly buffer release/retain, but I think this is a good basis for discussing various points.Please notice that I fixed a bug in
NettyDataBuffer#lastIndexOf()to make it works.This
JsonObjectDecoderimplementation aggregates the multiple buffers thanks toDataBuffer#write(DataBuffer), creates a slice in order to identify the JSON objects start and end index without changing the original buffer read position, and then return each JSON object as a slice that will be processed byJackson2JsonDecoder.I think I need Arjen Poutsma feedback to understand how to manage release/retain in that use cases, where we use slices and where 2 decoders are processing the data together.
spring-projects-issues commentedon Mar 30, 2017
Sébastien Deleuze commented
Jackson 2.9 (initial release or a patch release coming shortly after) should provide asynchronous Jackson JSON parsing capabilities that will allow to avoid requiring
io.netty.bufferdependency.spring-projects-issues commentedon Jun 5, 2017
Sébastien Deleuze commented
This feature should be available in the upcoming Jackson 2.9.0.pr4.
spring-projects-issues commentedon Jun 17, 2017
Sébastien Deleuze commented
We now use Jackson 2.9.0.pr4 which contains this non-blocking JSON feature.
Arjen Poutsma Since you mention during last meeting that you want to have a look to this feature + you have the experience of implementing Aalto XML support, I assign you this issue. Feel free to assign back to me after your initial look if you don't have the time to handle it for RC3.
spring-projects-issues commentedon Jun 28, 2017
Arjen Poutsma commented
Completed in 31e0e53
spring-projects-issues commentedon Jun 29, 2017
Stéphane Nicoll commented
That commit added an import on
org.eclipse.jetty.io.RuntimeIOExceptionspring-projects-issues commentedon Jun 29, 2017
Stéphane Nicoll commented
Polished in b1f06fd