mirror of
http://github.com/valkey-io/valkey
synced 2024-11-22 00:52:38 +00:00
Merge pull request #58 from hampus/fix-autorewrite
Fix automatic rewrite starting too early
This commit is contained in:
commit
4abd096f51
@ -699,7 +699,7 @@ int serverCron(struct aeEventLoop *eventLoop, long long id, void *clientData) {
|
||||
{
|
||||
int base = server.auto_aofrewrite_base_size ?
|
||||
server.auto_aofrewrite_base_size : 1;
|
||||
long long growth = (server.appendonly_current_size*100/base);
|
||||
long long growth = (server.appendonly_current_size*100/base) - 100;
|
||||
if (growth >= server.auto_aofrewrite_perc) {
|
||||
redisLog(REDIS_NOTICE,"Starting automatic rewriting of AOF on %lld%% growth",growth);
|
||||
rewriteAppendOnlyFileBackground();
|
||||
|
Loading…
Reference in New Issue
Block a user