Hi Ashish, You're right, to decode fragmented packet I need to keep track of the data before the message is complete.
With MINA 2.0, I'm using a CumulativeProtocolDecoder to handle these issues. I'll fix this using a context in my decoders, I agree with you that MINA 3.0 might need something like a CumulativeProtocolDecoder. Thanks you, Raphaël On Sun, May 5, 2013 at 7:05 AM, Ashish <[email protected]> wrote: > Thanks Raphael ! > > Had a quick look at the code. One quick question, for fragmented packets, > you need to store the data till the message is complete. I couldn't find > where you are doing this. May be I am missing something. > > I am currently playing around with an Avro decoder. Approach is similar, > but with slight semantic changes. I am currently trying to get a fixed > length prefix decoder implementation. It works very similar to your > approach, but instead of a SizeDecoder, it passes the size of length > prefix. It will then accumulate bytes till message size is complete and > then pass onto Avro decoder to decode the messages. My implementation is > still in initial stage. > > > On Sun, May 5, 2013 at 5:01 AM, Raphaël Barazzutti < > [email protected]> wrote: > > > Hi MINA-developers! > > > > Using extensively MINA 2.0 at my work, I’d like to contribute to the next > > MINA version. > > > > IMHO, MINA 3.0 could provide serialization facilities like Apache Thrift > > and Google Protobuf transport. > > > > According to that I decide to propose the following code to be merged > with > > the main repository of MINA 3.0. > > > > Please have a look to my repo : https://github.com/rbarazzutti/mina > > > > Suggestions are welcome, > > > > Kind regards, > > > > Raphaël > > > > > > -- > thanks > ashish > > Blog: http://www.ashishpaliwal.com/blog > My Photo Galleries: http://www.pbase.com/ashishpaliwal >
