mirror of https://github.com/zulip/zulip.git
puppet: Allow enabling "stats sizes" in memcached.
This commit is contained in:
parent
dfdaddea38
commit
8673f87907
|
@ -306,6 +306,12 @@ Override the maximum size that an item in memcached can store. This defaults to
|
||||||
1m; adjusting it should only be necessary if your Zulip server has organizations
|
1m; adjusting it should only be necessary if your Zulip server has organizations
|
||||||
which have more than 20k users.
|
which have more than 20k users.
|
||||||
|
|
||||||
|
#### `size_reporting`
|
||||||
|
|
||||||
|
Set to a true value to enable object size reporting in memcached. This incurs a
|
||||||
|
small overhead for every store or delete operation, but allows a
|
||||||
|
memcached_exporter to report precise item size distribution.
|
||||||
|
|
||||||
### `[loadbalancer]`
|
### `[loadbalancer]`
|
||||||
|
|
||||||
#### `ips`
|
#### `ips`
|
||||||
|
|
|
@ -18,6 +18,7 @@ class zulip::profile::memcached {
|
||||||
package { $memcached_packages: ensure => installed }
|
package { $memcached_packages: ensure => installed }
|
||||||
|
|
||||||
$memcached_max_item_size = zulipconf('memcached', 'max_item_size', '1m')
|
$memcached_max_item_size = zulipconf('memcached', 'max_item_size', '1m')
|
||||||
|
$memcached_size_reporting = zulipconf('memcached', 'size_reporting', false)
|
||||||
$memcached_memory = zulipconf('memcached', 'memory', $zulip::common::total_memory_mb / 8)
|
$memcached_memory = zulipconf('memcached', 'memory', $zulip::common::total_memory_mb / 8)
|
||||||
file { '/etc/sasl2':
|
file { '/etc/sasl2':
|
||||||
ensure => directory,
|
ensure => directory,
|
||||||
|
|
|
@ -55,3 +55,7 @@ logfile /var/log/memcached.log
|
||||||
# Larger max-item-size
|
# Larger max-item-size
|
||||||
-I <%= @memcached_max_item_size %>
|
-I <%= @memcached_max_item_size %>
|
||||||
<% end -%>
|
<% end -%>
|
||||||
|
<%- if @memcached_size_reporting %>
|
||||||
|
# Enable `stats sizes` (see https://github.com/memcached/memcached/blob/master/doc/protocol.txt)
|
||||||
|
-o track_sizes
|
||||||
|
<% end -%>
|
||||||
|
|
Loading…
Reference in New Issue