I'm playing with web sockets on WebSphere Liberty 16.0.0.3 and seeing something odd. If I send a number of messages back to back using the getAsyncRemote.sendText
method (say 4 in a row), there are times when 2 of the messages don't make it to the client application. It feels like I'm doing something wrong, but I can't see what the issue is.
Note, if I switch to the serialized approach, getBasicRemote
, things work as expected and all messages are received.
Asked
Active
Viewed 278 times
2

RamenChef
- 5,557
- 11
- 31
- 43

RyanColorado
- 31
- 3
1 Answers
0
Ok, did some more debugging and finally found the error. Very hidden was the following error: "java.lang.IllegalStateException: write not allowed. Most likely cause is that another Write or Close is in progress" which led to this: https://developer.ibm.com/answers/questions/253442/is-the-was-liberty-websocket-implementation-not-th.html
For now, I'm just going to switch to the getBasicRemote approach and move on.
thanks! -r

RyanColorado
- 31
- 3