Skip to content
This repository has been archived by the owner on Mar 8, 2023. It is now read-only.

Commit

Permalink
Merge pull request #53 from sanoma-technology/master
Browse files Browse the repository at this point in the history
Support for extra configuration directives.
  • Loading branch information
dwerder committed Nov 11, 2015
2 parents 75cffe8 + 5cdad0f commit e1c2011
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 4 deletions.
6 changes: 6 additions & 0 deletions manifests/server.pp
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,10 @@
# Configure Redis replication ping slave period
# [*save*]
# Configure Redis save snapshotting. Example: [[900, 1], [300, 10]]. Default: []
# [*hash_max_ziplist_entries*]
# Threshold for ziplist entries. Default: 512
# [*hash_max_ziplist_value*]
# Threshold for ziplist value. Default: 64
#
# [*force_rewrite*]
#
Expand Down Expand Up @@ -117,6 +121,8 @@
$repl_timeout = 60,
$repl_ping_slave_period = 10,
$save = [],
$hash_max_ziplist_entries = 512,
$hash_max_ziplist_value = 64,
$force_rewrite = false,
) {
$redis_user = $::redis::install::redis_user
Expand Down
8 changes: 4 additions & 4 deletions templates/etc/redis.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -429,11 +429,11 @@ slowlog-max-len 1024
# small number of entries, and the biggest entry does not exceed a given
# threshold. These thresholds can be configured using the following directives.
<% if @redis_2_6_or_greater -%>
hash-max-ziplist-entries 512
hash-max-ziplist-value 64
hash-max-ziplist-entries <%= @hash_max_ziplist_entries %>
hash-max-ziplist-value <%= @hash_max_ziplist_value %>
<% else -%>
hash-max-zipmap-entries 512
hash-max-zipmap-value 64
hash-max-zipmap-entries <%= @hash_max_ziplist_entries %>
hash-max-zipmap-value <%= @hash_max_ziplist_value %>
<% end -%>

# Similarly to hashes, small lists are also encoded in a special way in order
Expand Down

0 comments on commit e1c2011

Please sign in to comment.