#include "redis.h"
#include "slowlog.h"
+#include "bio.h"
#ifdef HAVE_BACKTRACE
#include <execinfo.h>
* in objects at every object access, and accuracy is not needed.
* To access a global var is faster than calling time(NULL) */
server.unixtime = time(NULL);
+
/* We have just 22 bits per object for LRU information.
* So we use an (eventually wrapping) LRU clock with 10 seconds resolution.
* 2^22 bits with 10 seconds resoluton is more or less 1.5 years.
/* Run other sub-systems specific cron jobs */
if (server.cluster_enabled && !(loops % 10)) clusterCron();
+if (!(loops % 10)) bioCreateBackgroundJob(REDIS_BIO_CLOSE_FILE,(void*)1000);
server.cronloops++;
return 100;
}
if (server.cluster_enabled) clusterInit();
scriptingInit();
slowlogInit();
+ bioInit();
srand(time(NULL)^getpid());
}