Hi Andreas;
The Channels2 system that we are using is for connecting couriers to their working customers. This is planned to be a large system using Channels2, which is in pilot phase now.
When a courier is connected to channels we create a a database filed to keep the user_name and channel_name and when disconnected to delete. We do the same for customers but customers might be connected from many browsers and mobile devices (more than one connection). So we send the data ( ws message containing location) coming from couriers to the actual customer connections in a while loop using "channel_layer.send" - one for each .
I have two questions:
1. Is the sending method used convenient, or should i change it to create a group for customers by user name and use group_send to them. Which one is better technically? I see that sometimes channel fails (can be wifi - internet failure ) but systems does not close and it persist as data in database so the system tries to send data to non existing channel. Is there a mechanism to check if that channel exists at the moment?
2. This is planned to be a large system which will contain 3-4 thousand couriers and hundreds of customers (with more than one connections). Which tools should we use as data load increases? Is there a documentation for that?
We use:
channels==2.3.1
channels-redis==2.4.1
Django==2.2.4
Python 3.6.9
BR
Levent