On 21/11/2013 12:55, Johan Compagner wrote:
> Hi Mark,
> 
> 
> 
>>
>>> So tomcat should handle the concatting for me, why do i need to do that
>> my
>>> self?
>>
>> You don't.
>>
>> If you want the container to provide the received message in a single
>> call then all you need to do is tell the container what the maximum
>> message size you wish it to support is. The Java WebSocket 1.0 (JSR356)
>> API provides a mechanism for doing this via
>> Session.setMaxTextMessageBufferSize() and
>> Session.setMaxBinaryMessageBufferSize()
>>
> 
> ok
> but if i set that to 1MB
> 
> then the messageBufferText of WsFrameBase is suddenly always that big, so
> every client takes 1MB of text buffer (and if i also want to support binary
> that big then it would be 2MB per client)
> That's not really what i want to happen.
> 
> i am fine with 8K buffers as long as tomcat does give me the complete/whole
> message until a maxSize (of 1MB)
> 
> We are mixing performance settings (buffers) and a security setting (max
> size) together. That should be a separate thing.
> I do agree that there should be a sensible max size of a message that
> tomcat defines by default. But that shouldn't be the buffer size thats
> always kept in memory per client

Patches welcome.

Mark


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to