Closed rajasimon closed 7 years ago
If I am not wrong WS are peer to peer by definition. Meaning you can open as many connections as you want and your server can support, but it is not exactly "broadcasting".
If you can expand the question with examples maybe it becomes more clear.
Will it be OK for you to keep a pool of open connections and to send messages to clients kept in it?
@oblalex yes I'm thinking the same.
In the mean time I found this very helpful. I have modified lot of code to adapt my need. I wish flask-sockets will have these feature inbuilt.
Ref: https://github.com/heroku-examples/python-websockets-chat
All web sockets connected to the same endpoint but
ws.send(message)
will receive by only one client which is initiatedsocket.send('message')