diff options
author | antirez <antirez@gmail.com> | 2014-06-16 10:43:05 +0200 |
---|---|---|
committer | antirez <antirez@gmail.com> | 2014-06-21 15:27:12 +0200 |
commit | b6a26b52bf7887839957e4f1afb1cab7e5fc2d1a (patch) | |
tree | 441a71438db7dadfff214eb3daa0cce4dce1d16a /src/redis.c | |
parent | 8060de98f89e4114af2aed90650e397292ada937 (diff) | |
download | redis-b6a26b52bf7887839957e4f1afb1cab7e5fc2d1a.tar.gz |
Client types generalized.
Because of output buffer limits Redis internals had this idea of type of
clients: normal, pubsub, slave. It is possible to set different output
buffer limits for the three kinds of clients.
However all the macros and API were named after output buffer limit
classes, while the idea of a client type is a generic one that can be
reused.
This commit does two things:
1) Rename the API and defines with more general names.
2) Change the class of clients executing the MONITOR command from "slave"
to "normal".
"2" is a good idea because you want to have very special settings for
slaves, that are not a good idea for MONITOR clients that are instead
normal clients even if they are conceptually slave-alike (since it is a
push protocol).
The backward-compatibility breakage resulting from "2" is considered to
be minimal to care, since MONITOR is a debugging command, and because
anyway this change is not going to break the format or the behavior, but
just when a connection is closed on big output buffer issues.
Diffstat (limited to 'src/redis.c')
-rw-r--r-- | src/redis.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/redis.c b/src/redis.c index 8c675b3bd..9558938b8 100644 --- a/src/redis.c +++ b/src/redis.c @@ -1400,7 +1400,7 @@ void initServerConfig() { server.repl_no_slaves_since = time(NULL); /* Client output buffer limits */ - for (j = 0; j < REDIS_CLIENT_LIMIT_NUM_CLASSES; j++) + for (j = 0; j < REDIS_CLIENT_TYPE_COUNT; j++) server.client_obuf_limits[j] = clientBufferLimitsDefaults[j]; /* Double constants initialization */ |