in reply to Re^2: WebSocket idle
in thread WebSocket idle
That sample code is where my code changes came from. I'm relying on the websocket module to notify me when data is available, right? I can't read 1 byte at a time like they did because the websocket messages are read with $ept->get_next_message(); Before I made the change, it would get caught in a loop without reading any new data, I'm guessing because SSL needed to be renegotiated like I read in the doc I did find, preventing the websocket module from seeing more data. My change with the select seems to have resolved it.
I also added a 100ms sleep if there is no message received since the last iteration based on sequence numbers in the messages, but that may never happen because I don't think it goes more than a second without a message.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: WebSocket idle
by noxxi (Pilgrim) on Jan 21, 2018 at 07:29 UTC | |
by chris212 (Scribe) on Jan 22, 2018 at 15:48 UTC |