-
Notifications
You must be signed in to change notification settings - Fork 687
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
Update redis keyword to valkey in some sentinel functions (Redis Legacy) #706
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## unstable #706 +/- ##
============================================
- Coverage 70.28% 70.08% -0.20%
============================================
Files 111 111
Lines 60299 60299
============================================
- Hits 42381 42262 -119
- Misses 17918 18037 +119
|
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.
Nice! LGTM
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.
LGTM
I see some more occurrences of redis that can be changed, but that can be done in another PR if you want.
src/sentinel.c
Outdated
int quorum, | ||
sentinelRedisInstance *primary) { | ||
sentinelRedisInstance *ri; | ||
sentinelValkeyInstance *createSentinelRedisInstance(char *name, |
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.
Function name is still createSentinelRedisInstance. Change this too?
src/sentinel.c
Outdated
@@ -1350,7 +1349,7 @@ sentinelRedisInstance *createSentinelRedisInstance(char *name, | |||
* This function does not take care of unlinking the instance from the main | |||
* primaries table (if it is a primary) or from its primary sentinels/replicas table | |||
* if it is a replica or sentinel. */ | |||
void releaseSentinelRedisInstance(sentinelRedisInstance *ri) { | |||
void releaseSentinelRedisInstance(sentinelValkeyInstance *ri) { |
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.
Function name still contains redis.
src/sentinel.c
Outdated
@@ -1448,10 +1447,10 @@ int removeMatchingSentinelFromPrimary(sentinelRedisInstance *primary, char *runi | |||
* | |||
* runid or addr can be NULL. In such a case the search is performed only | |||
* by the non-NULL field. */ | |||
sentinelRedisInstance *getSentinelRedisInstanceByAddrAndRunID(dict *instances, char *addr, int port, char *runid) { | |||
sentinelValkeyInstance *getSentinelRedisInstanceByAddrAndRunID(dict *instances, char *addr, int port, char *runid) { |
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.
Function name contains redis.
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.
https://github.com/valkey-io/valkey/blob/5925cc7c4fdd89e9547fa2602d5e46213c70f891/src/sentinel.c
i see there are still some places are using the Redis word, can you do a search and also fix it? like addReplySentinelRedisInstance
b9ae8bb
to
f9b9713
Compare
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.
Thanks! Just one issue I wonder if clang-format doesn't understand.
Signed-off-by: hwware <[email protected]>
Signed-off-by: hwware <[email protected]>
Signed-off-by: hwware <[email protected]>
f9b9713
to
d1e9cc2
Compare
This PR updates all Redis/redis keywords to Valkey/valkey, including variable names, comments, function names.
All sentinel test cases passed.