mirror of
https://codeberg.org/redict/redict.git
synced 2025-01-23 00:28:26 -05:00
Cluster tests now using redis-cli instead of redis-trib
This commit is contained in:
parent
be94e89031
commit
af4584d608
@ -73,12 +73,12 @@ test "Cluster consistency during live resharding" {
|
|||||||
flush stdout
|
flush stdout
|
||||||
set target [dict get [get_myself [randomInt 5]] id]
|
set target [dict get [get_myself [randomInt 5]] id]
|
||||||
set tribpid [lindex [exec \
|
set tribpid [lindex [exec \
|
||||||
../../../src/redis-trib.rb reshard \
|
../../../src/redis-cli --cluster reshard \
|
||||||
--from all \
|
|
||||||
--to $target \
|
|
||||||
--slots 100 \
|
|
||||||
--yes \
|
|
||||||
127.0.0.1:[get_instance_attrib redis 0 port] \
|
127.0.0.1:[get_instance_attrib redis 0 port] \
|
||||||
|
--cluster-from all \
|
||||||
|
--cluster-to $target \
|
||||||
|
--cluster-slots 100 \
|
||||||
|
--cluster-yes \
|
||||||
| [info nameofexecutable] \
|
| [info nameofexecutable] \
|
||||||
../tests/helpers/onlydots.tcl \
|
../tests/helpers/onlydots.tcl \
|
||||||
&] 0]
|
&] 0]
|
||||||
|
@ -31,9 +31,9 @@ test "Each master should have at least two replicas attached" {
|
|||||||
set master0_id [dict get [get_myself 0] id]
|
set master0_id [dict get [get_myself 0] id]
|
||||||
test "Resharding all the master #0 slots away from it" {
|
test "Resharding all the master #0 slots away from it" {
|
||||||
set output [exec \
|
set output [exec \
|
||||||
../../../src/redis-trib.rb rebalance \
|
../../../src/redis-cli --cluster rebalance \
|
||||||
--weight ${master0_id}=0 \
|
127.0.0.1:[get_instance_attrib redis 0 port] \
|
||||||
127.0.0.1:[get_instance_attrib redis 0 port] >@ stdout]
|
--cluster-weight ${master0_id}=0 >@ stdout ]
|
||||||
}
|
}
|
||||||
|
|
||||||
test "Master #0 should lose its replicas" {
|
test "Master #0 should lose its replicas" {
|
||||||
@ -49,10 +49,10 @@ test "Resharding back some slot to master #0" {
|
|||||||
# new resharding.
|
# new resharding.
|
||||||
after 10000
|
after 10000
|
||||||
set output [exec \
|
set output [exec \
|
||||||
../../../src/redis-trib.rb rebalance \
|
../../../src/redis-cli --cluster rebalance \
|
||||||
--weight ${master0_id}=.01 \
|
127.0.0.1:[get_instance_attrib redis 0 port] \
|
||||||
--use-empty-masters \
|
--cluster-weight ${master0_id}=.01 \
|
||||||
127.0.0.1:[get_instance_attrib redis 0 port] >@ stdout]
|
--cluster-use-empty-masters >@ stdout]
|
||||||
}
|
}
|
||||||
|
|
||||||
test "Master #0 should re-acquire one or more replicas" {
|
test "Master #0 should re-acquire one or more replicas" {
|
||||||
|
Loading…
Reference in New Issue
Block a user