Skip to content

Commit

Permalink
Merge pull request #28 from barshaul/config_get
Browse files Browse the repository at this point in the history
Changed CONFIG GET to be sent to a random node
  • Loading branch information
nihohit authored Aug 30, 2023
2 parents d7d96a7 + daeb92c commit 6fee44c
Showing 1 changed file with 5 additions and 7 deletions.
12 changes: 5 additions & 7 deletions redis/src/cluster_routing.rs
Original file line number Diff line number Diff line change
Expand Up @@ -243,12 +243,10 @@ impl RoutingInfo {

b"WAIT" => Some(Aggregate(AggregateOp::Min)),

b"CONFIG SET" | b"CONFIG GET" | b"CONFIG RESETSTAT" | b"CONFIG REWRITE"
| b"FLUSHALL" | b"FLUSHDB" | b"FUNCTION DELETE" | b"FUNCTION FLUSH"
| b"FUNCTION LOAD" | b"FUNCTION RESTORE" | b"LATENCY RESET" | b"MEMORY PURGE"
| b"MSET" | b"PING" | b"SCRIPT FLUSH" | b"SCRIPT LOAD" | b"SLOWLOG RESET" => {
Some(AllSucceeded)
}
b"CONFIG SET" | b"CONFIG RESETSTAT" | b"CONFIG REWRITE" | b"FLUSHALL" | b"FLUSHDB"
| b"FUNCTION DELETE" | b"FUNCTION FLUSH" | b"FUNCTION LOAD" | b"FUNCTION RESTORE"
| b"LATENCY RESET" | b"MEMORY PURGE" | b"MSET" | b"PING" | b"SCRIPT FLUSH"
| b"SCRIPT LOAD" | b"SLOWLOG RESET" => Some(AllSucceeded),

b"KEYS" | b"MGET" | b"SLOWLOG GET" => Some(CombineArrays),

Expand Down Expand Up @@ -298,7 +296,7 @@ impl RoutingInfo {
| b"MEMORY STATS"
| b"INFO" => Some(RoutingInfo::MultiNode(MultipleNodeRoutingInfo::AllMasters)),

b"SLOWLOG GET" | b"SLOWLOG LEN" | b"SLOWLOG RESET" | b"CONFIG SET" | b"CONFIG GET"
b"SLOWLOG GET" | b"SLOWLOG LEN" | b"SLOWLOG RESET" | b"CONFIG SET"
| b"CONFIG RESETSTAT" | b"CONFIG REWRITE" | b"SCRIPT FLUSH" | b"SCRIPT LOAD"
| b"LATENCY RESET" | b"LATENCY GRAPH" | b"LATENCY HISTOGRAM" | b"LATENCY HISTORY"
| b"LATENCY DOCTOR" | b"LATENCY LATEST" => {
Expand Down

0 comments on commit 6fee44c

Please sign in to comment.