diff options
| author | Matthias Radestock <matthias@lshift.net> | 2009-06-10 23:39:52 +0100 |
|---|---|---|
| committer | Matthias Radestock <matthias@lshift.net> | 2009-06-10 23:39:52 +0100 |
| commit | 096e6d4324034290f20bcad5f86c70189130616c (patch) | |
| tree | 9c5c6bad28fa6658186386d9a18c6b762ac6cde2 /src/rabbit.erl | |
| parent | 4948fcbb601f4828410eff13e46fac2341a3e488 (diff) | |
| download | rabbitmq-server-git-096e6d4324034290f20bcad5f86c70189130616c.tar.gz | |
proper round-robining even when blocking
This involved some substantial changes to the queue internal data
structures - mostly by choice; the new design is cleaner:
- We no longer keep a list of consumers in the channel
records. Now the channel records just contain a consumer count
instead, and that's only there for efficiency so we can more
easily tell when we need to register/unregister with the limiter.
- We now keep *two* consumer queues - one of active consumers
(that's the one we've always had) and one of blocked consumers.
We round-robin on the first one as before, and move things between the
two queues when blocking/unblocking channels. When doing so the
relative order of a channel's consumers is preserved, so the effects
of any round-robining the active consumers get carried
through to the blocked consumers when they get blocked and then back
to the active consumers when they get unblocked.
Diffstat (limited to 'src/rabbit.erl')
0 files changed, 0 insertions, 0 deletions
