summaryrefslogtreecommitdiff
path: root/src/aof.c
diff options
context:
space:
mode:
authoryoav-steinberg <yoav@monfort.co.il>2022-02-17 14:32:48 +0200
committerGitHub <noreply@github.com>2022-02-17 14:32:48 +0200
commit56fa48ffc136b7540f8144562d8aa2a13b8a3fa7 (patch)
treeb30165191ea229046a61a62778bfb6ff7c2bead4 /src/aof.c
parenta50aa29bde33f22dabc307c4a28bc2321f8acdfe (diff)
downloadredis-56fa48ffc136b7540f8144562d8aa2a13b8a3fa7.tar.gz
aof rewrite and rdb save counters in info (#10178)
Add aof_rewrites and rdb_snapshots counters to info. This is useful to figure our if a rewrite or snapshot happened since last check. This was part of the (ongoing) effort to provide a safe backup solution for multipart-aof backups.
Diffstat (limited to 'src/aof.c')
-rw-r--r--src/aof.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/aof.c b/src/aof.c
index d7ba6b318..affe74441 100644
--- a/src/aof.c
+++ b/src/aof.c
@@ -2348,7 +2348,7 @@ int rewriteAppendOnlyFileBackground(void) {
server.aof_selected_db = -1;
flushAppendOnlyFile(1);
if (openNewIncrAofForAppend() != C_OK) return C_ERR;
-
+ server.stat_aof_rewrites++;
if ((childpid = redisFork(CHILD_TYPE_AOF)) == 0) {
char tmpfile[256];