Just for laziness:
PUBLISH: O(N+M) where N is the number of clients subscribed to the
receiving channel and M is the total number of subscribed patterns (by
any client).
SUBSCRIBE: O(N) where N is the number of channels to subscribe to.
UNSUBSCRIBE: O(N) where N is the number of clients already subscribed to
a channel.
PUNSUBSCRIBE: O(N+M) where N is the number of patterns the client is
already subscribed and M is the number of total patterns subscribed in
the system (by any client).
PSUBSCRIBE: O(N) where N is the number of patterns the client is already
subscribed to.
> --
> You received this message because you are subscribed to the Google
> Groups "Redis DB" group.
> To post to this group, send email to redi...@googlegroups.com.
> To unsubscribe from this group, send email to
> redis-db+u...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/redis-db?hl=en.
To unsubscribe from this group, send email to redis-db+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/redis-db?hl=en.
--
You received this message because you are subscribed to the Google Groups "Redis DB" group.
To post to this group, send email to redi...@googlegroups.com.
To unsubscribe from this group, send email to redis-db+unsubscribe@googlegroups.com.
I would instead recommend inserting messages into lists (having a
limit wouldn't be unreasonable), adding an expiration time far enough
in the future so that reasonable clients would get the messages, and
having your clients poll those lists every few seconds.
That minimizes the number of concurrent connections, minimizes the
likelihood of memory exploding in the case of a slow client, and means
that you don't need to learn how awful ulimit is to actually use.
This Github Gist implements a poll-based chat server that uses some of
these ideas in order to offer shared chat channels (think IRC without
/msg nick message): https://gist.github.com/1045789
Regards,
- Josiah
>>> redis-db+u...@googlegroups.com.
>>> For more options, visit this group at
>>> http://groups.google.com/group/redis-db?hl=en.
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Redis DB" group.
>> To post to this group, send email to redi...@googlegroups.com.
>> To unsubscribe from this group, send email to
>> redis-db+u...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/redis-db?hl=en.
>>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Redis DB" group.
> To post to this group, send email to redi...@googlegroups.com.
> To unsubscribe from this group, send email to
> redis-db+u...@googlegroups.com.