https://issues.apache.org/bugzilla/show_bug.cgi?id=55233
Bug ID: 55233 Summary: [websocket] Problem reading many subsequent binary messages Product: Tomcat 8 Version: trunk Hardware: PC OS: Linux Status: NEW Severity: major Priority: P2 Component: Catalina Assignee: dev@tomcat.apache.org Reporter: s.bos...@gmail.com I have a test client that receives many binary messages. The server sends thousands of binary messages with size 1024 with no delay between them. At some point of time, the client fails to read the message and the connection is closed. See some close reasons below. I am wondering whether there is some issue with the read buffers being modified from other threads. Seeing all close reasons below, there are two issues here: - why there is buffer overflow when there is plenty of space to store the incoming data (e.g. "unwrapping [1,130] bytes into a [8,192]") - why there are attempts to unwrap bigger buffer into smaller one. I thought this should not be possible (e.g. "unwrapping [12,466] bytes into a [8,192]") Here are some close reasons occurred during the test: Ending test thread as websocket session is closed Connection closed: Buffer overflow unwrapping [6,466] bytes into a [8,192] byte buffer that already contained [0] bytes. Ending test thread as websocket session is closed Connection closed: Buffer overflow unwrapping [1,130] bytes into a [8,192] byte buffer that already contained [0] bytes. Ending test thread as websocket session is closed Connection closed: Buffer overflow unwrapping [2,240] bytes into a [8,192] byte buffer that already contained [0] bytes. Ending test thread as websocket session is closed Connection closed: Buffer overflow unwrapping [12,466] bytes into a [8,192] byte buffer that already contained [0] bytes. Ending test thread as websocket session is closed Connection closed: Buffer overflow unwrapping [2,071] bytes into a [8,192] byte buffer that already contained [0] bytes. Ending test thread as websocket session is closed Connection closed: Buffer overflow unwrapping [12,466] bytes into a [8,192] byte buffer that already contained [0] bytes. Ending test thread as websocket session is closed Connection closed: Buffer overflow unwrapping [4,356] bytes into a [8,192] byte buffer that already contained [0] bytes. Ending test thread as websocket session is closed Connection closed: Buffer overflow unwrapping [14,059] bytes into a [8,192] byte buffer that already contained [0] bytes. Ending test thread as websocket session is closed Connection closed: Buffer overflow unwrapping [4,707] bytes into a [8,192] byte buffer that already contained [0] bytes. Ending test thread as websocket session is closed Connection closed: Buffer overflow unwrapping [10,041] bytes into a [8,192] byte buffer that already contained [0] bytes. Ending test thread as websocket session is closed Connection closed: Buffer overflow unwrapping [2,478] bytes into a [8,192] byte buffer that already contained [0] bytes. -- You are receiving this mail because: You are the assignee for the bug. --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@tomcat.apache.org For additional commands, e-mail: dev-h...@tomcat.apache.org