rstudio / websocket

WebSocket client for R
https://rstudio.github.io/websocket/
Other
92 stars 19 forks source link

Using several websockets with high incoming data rate and queues #102

Open yimyom opened 1 year ago

yimyom commented 1 year ago

Hi,

I'm looking for an efficient pattern to do the following:

Now here is my problem: in an ideal world, I would like to have one thread for each websocket and its queue and the main thread will read from the queue at its own rate. Now, I don't want to have slow IPC like in most of the R packages (futures, ipc, promises, etc...) which rely on local files. I need very fast communications (like shared memory for example).

How would you approach this problem?

(I know it's not an "issue" with websocket per se but it's still related to it, because I'd like to have not only the internal websocket in a thread but also the $onMessage method too)