New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rename redis in aof logs and proc title redis-aof-rewrite to valkey-aof-rewrite. #393
Changes from 1 commit
79ca612
54ac594
64095cf
c27cb4c
9af3bb2
ed99e67
00d7cb5
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||
---|---|---|---|---|
|
@@ -996,7 +996,7 @@ int startAppendOnly(void) { | |||
|
||||
if (rewriteAppendOnlyFileBackground() == C_ERR) { | ||||
server.aof_state = AOF_OFF; | ||||
serverLog(LL_WARNING,"Redis needs to enable the AOF but can't trigger a background AOF rewrite operation. Check the above logs for more info about the error."); | ||||
serverLog(LL_WARNING,"Server needs to enable the AOF but can't trigger a background AOF rewrite operation. Check the above logs for more info about the error."); | ||||
return C_ERR; | ||||
} | ||||
} | ||||
|
@@ -1121,7 +1121,7 @@ void flushAppendOnlyFile(int force) { | |||
/* Otherwise fall through, and go write since we can't wait | ||||
* over two seconds. */ | ||||
server.aof_delayed_fsync++; | ||||
serverLog(LL_NOTICE,"Asynchronous AOF fsync is taking too long (disk is busy?). Writing the AOF buffer without waiting for fsync to complete, this may slow down Redis."); | ||||
serverLog(LL_NOTICE,"Asynchronous AOF fsync is taking too long (disk is busy?). Writing the AOF buffer without waiting for fsync to complete, this may slow down the server."); | ||||
} | ||||
} | ||||
/* We want to perform a single write. This should be guaranteed atomic | ||||
|
@@ -1183,7 +1183,7 @@ void flushAppendOnlyFile(int force) { | |||
if (ftruncate(server.aof_fd, server.aof_last_incr_size) == -1) { | ||||
if (can_log) { | ||||
serverLog(LL_WARNING, "Could not remove short write " | ||||
"from the append-only file. Redis may refuse " | ||||
"from the append-only file. Server may refuse " | ||||
"to load the AOF the next time it starts. " | ||||
"ftruncate: %s", strerror(errno)); | ||||
} | ||||
|
@@ -1224,7 +1224,7 @@ void flushAppendOnlyFile(int force) { | |||
* OK state and log the event. */ | ||||
if (server.aof_last_write_status == C_ERR) { | ||||
serverLog(LL_NOTICE, | ||||
"AOF write error looks solved, Redis can write again."); | ||||
"AOF write error looks solved, Server can write again."); | ||||
server.aof_last_write_status = C_OK; | ||||
} | ||||
} | ||||
|
@@ -1634,14 +1634,14 @@ int loadSingleAppendOnlyFile(char *filename) { | |||
} | ||||
} | ||||
serverLog(LL_WARNING, "Unexpected end of file reading the append only file %s. You can: " | ||||
"1) Make a backup of your AOF file, then use ./redis-check-aof --fix <filename.manifest>. " | ||||
"1) Make a backup of your AOF file, then use ./valkey-check-aof --fix <filename.manifest>. " | ||||
"2) Alternatively you can set the 'aof-load-truncated' configuration option to yes and restart the server.", filename); | ||||
ret = AOF_FAILED; | ||||
goto cleanup; | ||||
|
||||
fmterr: /* Format error. */ | ||||
serverLog(LL_WARNING, "Bad file format reading the append only file %s: " | ||||
"make a backup of your AOF file, then use ./redis-check-aof --fix <filename.manifest>", filename); | ||||
"make a backup of your AOF file, then use ./valkey-check-aof --fix <filename.manifest>", filename); | ||||
ret = AOF_FAILED; | ||||
/* fall through to cleanup. */ | ||||
|
||||
|
@@ -2471,7 +2471,7 @@ int rewriteAppendOnlyFileBackground(void) { | |||
char tmpfile[256]; | ||||
|
||||
/* Child */ | ||||
serverSetProcTitle("redis-aof-rewrite"); | ||||
serverSetProcTitle("valkey-aof-rewrite"); | ||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @PingXie You're right that proc title is not logging. For the most reasonable result we could check if Valkey was started using a Line 7019 in a5a1377
Maybe it's too complex and not important. I'm not sure. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
+1 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I have tried to add a flag similar to server.sentinel_mode, I am still not sure whether it is appropriate and best way. |
||||
serverSetCpuAffinity(server.aof_rewrite_cpulist); | ||||
snprintf(tmpfile,256,"temp-rewriteaof-bg-%d.aof", (int) getpid()); | ||||
if (rewriteAppendOnlyFile(tmpfile) == C_OK) { | ||||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is part of #207 so I will tag @0del because he is assigned to it. @0del are you still working on the remaining logging?
In #207 we discussed this style:
... because then it would be easy patch the SERVER_TITLE macro to be "Redis" to get the old logging. But then we discussed it a bit more and decided that most of the logging isn't a problem about redis compatibility, so I think we don't need this complexity.
I'm OK with "Server", but probably better grammar is "The server" in this case.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for the review, Changed the string "Server" to "The server" and updated the diff.