mirror of
https://github.com/fluencelabs/redis
synced 2025-06-23 14:01:34 +00:00
DEBUG set-active-expire added.
We need the ability to disable the activeExpireCycle() (active expired key collection) call for testing purposes.
This commit is contained in:
@ -854,7 +854,8 @@ void clientsCron(void) {
|
||||
void databasesCron(void) {
|
||||
/* Expire keys by random sampling. Not required for slaves
|
||||
* as master will synthesize DELs for us. */
|
||||
if (server.masterhost == NULL) activeExpireCycle();
|
||||
if (server.active_expire_enabled && server.masterhost == NULL)
|
||||
activeExpireCycle();
|
||||
|
||||
/* Perform hash tables rehashing if needed, but only if there are no
|
||||
* other processes saving the DB on disk. Otherwise rehashing is bad
|
||||
@ -1203,6 +1204,7 @@ void initServerConfig() {
|
||||
server.verbosity = REDIS_NOTICE;
|
||||
server.maxidletime = REDIS_MAXIDLETIME;
|
||||
server.tcpkeepalive = 0;
|
||||
server.active_expire_enabled = 1;
|
||||
server.client_max_querybuf_len = REDIS_MAX_QUERYBUF_LEN;
|
||||
server.saveparams = NULL;
|
||||
server.loading = 0;
|
||||
|
Reference in New Issue
Block a user