Reputation: 263
I am developing a node.js application using express & mongodb also I am using socket.io to be able to handle the realtime events.
what is the max number of listeners on an event:
io.on('posts' , (data) => {
io.emit('posts' , data);
})
I mean how many users can I emit to them.
also I many channels can I use like the posts channel?
can I use tens of thousands of channels that can emit data changes to thousands of users?
is this make sense or there is a better way.
thank you all.
Upvotes: 0
Views: 194
Reputation: 14530
can I use tens of thousands of channels that can emit data changes to thousands of users?
Yes. In principle.
In actual applications, at this scale, a good amount of thought, planning, architecturing and solid implementation has to go into a solution that would practically work.
Upvotes: 2