Skip to content

Commit

Permalink
special encoding limits redefined, and all the config options for spe…
Browse files Browse the repository at this point in the history
…cial encodings added in the example redis.conf file
  • Loading branch information
antirez committed Dec 14, 2010
1 parent cc7c415 commit 6a246b1
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 3 deletions.
13 changes: 13 additions & 0 deletions redis.conf
Original file line number Diff line number Diff line change
Expand Up @@ -377,6 +377,19 @@ glueoutputbuf yes
hash-max-zipmap-entries 64
hash-max-zipmap-value 512

# Similarly to hashes, small lists are also encoded in a special way in order
# to save a lot of space. The special representation is only used when
# you are under the following limits:
list-max-ziplist-entries 512
list-max-ziplist-value 64

# Sets have a special encoding in just one case: when a set is composed
# of just strings that happens to be integers in radix 10 in the range
# of 64 bit signed integers.
# The following configuration setting sets the limit in the size of the
# set in order to use this special memory saving encoding.
set-max-intset-entries 512

# Active rehashing uses 1 millisecond every 100 milliseconds of CPU time in
# order to help rehashing the main Redis hash table (the one mapping top-level
# keys to values). The hash table implementation redis uses (see dict.c)
Expand Down
6 changes: 3 additions & 3 deletions src/redis.h
Original file line number Diff line number Diff line change
Expand Up @@ -196,9 +196,9 @@
/* Zip structure related defaults */
#define REDIS_HASH_MAX_ZIPMAP_ENTRIES 64
#define REDIS_HASH_MAX_ZIPMAP_VALUE 512
#define REDIS_LIST_MAX_ZIPLIST_ENTRIES 1024
#define REDIS_LIST_MAX_ZIPLIST_VALUE 32
#define REDIS_SET_MAX_INTSET_ENTRIES 4096
#define REDIS_LIST_MAX_ZIPLIST_ENTRIES 512
#define REDIS_LIST_MAX_ZIPLIST_VALUE 64
#define REDIS_SET_MAX_INTSET_ENTRIES 512

/* Sets operations codes */
#define REDIS_OP_UNION 0
Expand Down

0 comments on commit 6a246b1

Please sign in to comment.