On Wed, Feb 10, 2016 at 7:47 AM, Konstantin Kolinko
<knst.koli...@gmail.com> wrote:
> 2016-02-10 5:40 GMT+03:00 Jason Ricles <jgr...@alum.lehigh.edu>:
>> Is there any formal forum to make a feature request for tomcat?
>
> http://tomcat.apache.org/bugreport.html#How_to_submit_patches_and_enhancement_requests
>
> but usually better either to provide a patch or to discuss it (on the
> mailing list) to prove that there is an interest in the feature.
>
>> I noticed I was having a silent failure with a binary websocket with tomcat
>> since I didn't flip the bytebuffer from write to read and the send kept
>> failing down at the low level of the code without any error being thrown.
>> With that in mind, I was thinking it would be useful to explicitly throw
>> that an error happened since I spent 1.5 days to debug that when I changed
>> the code I just forgot to flip the bytebuffer and had no excpetion being
>> thrown, it would thus be very helpful for debugging purposes.
>
> 1. I think that a buffer that has not been flipped is not
> distinguishable from an empty buffer.
>
> Sending empty data is an empty operation, not an error.
>
> 2. Tomcat implements Java API for WebSocket 1.1 (JSR356).
>
> Error handling is defined by specification.
>
> Best regards,
> Konstantin Kolinko


That is very true Konstantin,

Maybe then adding as part of the java doc for the write binary to say
"remember to flip the buffer if was written to" or something of that
nature. I am just trying to think of a good way other users can avoid
this pit fall in the future but still follow the websocket spec as
stated.

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

Reply via email to