Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [jetty-dev] Websocket buffers and async modes




On 10 January 2014 11:17, Bruno D. Rodrigues <bruno.rodrigues@xxxxxxxxx> wrote:

I’m sorry for jumping in, but this is not 100% true ;)

We want you to jump in! that's why we posted here!
 
The aggregation does indeed happen for write(byte[]) but not for write(ByteBuffer). I’ve sent an email to the list some time in the past and I was almost sure I had opened a bug on bugs.eclipse, but now I can’t find it. It’s late now, and I’ll search again tomorrow, but basically a write(ByteBuffer) will never aggregate, and hence why my local copy has this patch: https://gist.github.com/davipt/7155109 Please advice how to provide a better feedback on this kind of situation. I’ll search my archives again and reopen a new issue on bugzilla if indeed it never went through :( 

I believe I have already addressed this issue in 9.1.1 I think and passed buffers may be aggregated, sliced and written or just written.

Eitherway, the point remains valid that if we choose to copy passed buffers, then we have to deal with very large buffers.    Copying these in chunks is not helpful, so I think we should write them directly and not call their callbacks until written - ie momentarily revert to non batching mode if a very large frame is to be sent.

cheers



 

_______________________________________________
jetty-dev mailing list
jetty-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/jetty-dev




--
Greg Wilkins <gregw@xxxxxxxxxxx>
http://www.webtide.com
Developer advice and support from the Jetty & CometD experts.
Intalio, the modern way to build business applications.

Back to the top