Skip to content

Commit 3e61da3

Browse files
committed
mmaprototype: add Status to cluster state test
This allows TestClusterState to update the store status. It continues to be true that no semantics are attached to the store status at this point.
1 parent ffec3ab commit 3e61da3

File tree

6 files changed

+122
-39
lines changed

6 files changed

+122
-39
lines changed

pkg/kv/kvserver/allocator/mmaprototype/cluster_state_test.go

Lines changed: 64 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,53 @@ func parseSecondaryLoadVector(t *testing.T, in string) SecondaryLoadVector {
6363
return vec
6464
}
6565

66+
func parseStatusFromArgs(t *testing.T, d *datadriven.TestData) Status {
67+
var status Status
68+
if d.HasArg("health") {
69+
healthStr := dd.ScanArg[string](t, d, "health")
70+
found := false
71+
for i := Health(0); i < healthCount; i++ {
72+
if i.String() == healthStr {
73+
status.Health = i
74+
found = true
75+
break
76+
}
77+
}
78+
if !found {
79+
t.Fatalf("unknown health: %s", healthStr)
80+
}
81+
}
82+
if d.HasArg("leases") {
83+
leaseStr := dd.ScanArg[string](t, d, "leases")
84+
found := false
85+
for i := LeaseDisposition(0); i < leaseDispositionCount; i++ {
86+
if i.String() == leaseStr {
87+
status.Disposition.Lease = i
88+
found = true
89+
break
90+
}
91+
}
92+
if !found {
93+
t.Fatalf("unknown lease disposition: %s", leaseStr)
94+
}
95+
}
96+
if d.HasArg("replicas") {
97+
replicaStr := dd.ScanArg[string](t, d, "replicas")
98+
found := false
99+
for i := ReplicaDisposition(0); i < replicaDispositionCount; i++ {
100+
if i.String() == replicaStr {
101+
status.Disposition.Replica = i
102+
found = true
103+
break
104+
}
105+
}
106+
if !found {
107+
t.Fatalf("unknown replica disposition: %s", replicaStr)
108+
}
109+
}
110+
return status
111+
}
112+
66113
func parseStoreLoadMsg(t *testing.T, in string) StoreLoadMsg {
67114
var msg StoreLoadMsg
68115
for _, v := range strings.Fields(in) {
@@ -333,8 +380,10 @@ func TestClusterState(t *testing.T) {
333380
ss := cs.stores[storeID]
334381
ns := cs.nodes[ss.NodeID]
335382
fmt.Fprintf(&buf,
336-
"store-id=%v node-id=%v reported=%v adjusted=%v node-reported-cpu=%v node-adjusted-cpu=%v seq=%d\n",
337-
ss.StoreID, ss.NodeID, ss.reportedLoad, ss.adjusted.load, ns.ReportedCPU, ns.adjustedCPU, ss.loadSeqNum,
383+
"store-id=%v node-id=%v status=%s reported=%v adjusted=%v node-reported-cpu=%v node-adjusted-cpu=%v seq"+
384+
"=%d\n",
385+
ss.StoreID, ss.NodeID, ss.status, ss.reportedLoad, ss.adjusted.load, ns.ReportedCPU, ns.adjustedCPU,
386+
ss.loadSeqNum,
338387
)
339388
for ls, topk := range ss.adjusted.topKRanges {
340389
n := topk.len()
@@ -354,9 +403,22 @@ func TestClusterState(t *testing.T) {
354403
for _, next := range strings.Split(d.Input, "\n") {
355404
sal := parseStoreAttributedAndLocality(t, next)
356405
cs.setStore(sal)
406+
// For convenience, in these tests, stores start out
407+
// healthy.
408+
cs.stores[sal.StoreID].status = Status{Health: HealthOK}
357409
}
358410
return printNodeListMeta()
359411

412+
case "set-store-status":
413+
storeID := dd.ScanArg[roachpb.StoreID](t, d, "store-id")
414+
ss, ok := cs.stores[storeID]
415+
if !ok {
416+
t.Fatalf("store %d not found", storeID)
417+
}
418+
status := parseStatusFromArgs(t, d)
419+
ss.status = MakeStatus(status.Health, status.Disposition.Lease, status.Disposition.Replica)
420+
return ss.status.String()
421+
360422
case "store-load-msg":
361423
msg := parseStoreLoadMsg(t, d.Input)
362424
cs.processStoreLoadMsg(context.Background(), &msg)

pkg/kv/kvserver/allocator/mmaprototype/testdata/cluster_state/multiple_ranges

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -36,9 +36,9 @@ store-id=1
3636
# The top-k uses CPURate.
3737
get-load-info
3838
----
39-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:100, write-bandwidth:40, byte-size:50] adjusted=[cpu:100, write-bandwidth:40, byte-size:50] node-reported-cpu=100 node-adjusted-cpu=100 seq=1
39+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:100, write-bandwidth:40, byte-size:50] adjusted=[cpu:100, write-bandwidth:40, byte-size:50] node-reported-cpu=100 node-adjusted-cpu=100 seq=1
4040
top-k-ranges (local-store-id=1) dim=CPURate: r4 r3
41-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:45, write-bandwidth:40, byte-size:50] adjusted=[cpu:45, write-bandwidth:40, byte-size:50] node-reported-cpu=45 node-adjusted-cpu=45 seq=1
41+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:45, write-bandwidth:40, byte-size:50] adjusted=[cpu:45, write-bandwidth:40, byte-size:50] node-reported-cpu=45 node-adjusted-cpu=45 seq=1
4242
top-k-ranges (local-store-id=1) dim=CPURate: r3 r2
4343

4444

@@ -67,9 +67,9 @@ store-id=1
6767
# The top-2 ranges for store 2 are based on ByteSize.
6868
get-load-info
6969
----
70-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:100, write-bandwidth:40, byte-size:50] adjusted=[cpu:100, write-bandwidth:40, byte-size:50] node-reported-cpu=100 node-adjusted-cpu=100 seq=1
70+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:100, write-bandwidth:40, byte-size:50] adjusted=[cpu:100, write-bandwidth:40, byte-size:50] node-reported-cpu=100 node-adjusted-cpu=100 seq=1
7171
top-k-ranges (local-store-id=1) dim=CPURate: r4 r3
72-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:45, write-bandwidth:40, byte-size:50] adjusted=[cpu:45, write-bandwidth:40, byte-size:50] node-reported-cpu=45 node-adjusted-cpu=45 seq=2
72+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:45, write-bandwidth:40, byte-size:50] adjusted=[cpu:45, write-bandwidth:40, byte-size:50] node-reported-cpu=45 node-adjusted-cpu=45 seq=2
7373
top-k-ranges (local-store-id=1) dim=ByteSize: r1 r2
7474

7575
# StoreLeaseholderMsg not containing r1 and r4 since no longer the leaseholder.
@@ -86,7 +86,7 @@ store-id=1
8686
# r1 and r4 no longer mentioned in the top-k.
8787
get-load-info
8888
----
89-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:100, write-bandwidth:40, byte-size:50] adjusted=[cpu:100, write-bandwidth:40, byte-size:50] node-reported-cpu=100 node-adjusted-cpu=100 seq=1
89+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:100, write-bandwidth:40, byte-size:50] adjusted=[cpu:100, write-bandwidth:40, byte-size:50] node-reported-cpu=100 node-adjusted-cpu=100 seq=1
9090
top-k-ranges (local-store-id=1) dim=CPURate: r3 r2
91-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:45, write-bandwidth:40, byte-size:50] adjusted=[cpu:45, write-bandwidth:40, byte-size:50] node-reported-cpu=45 node-adjusted-cpu=45 seq=2
91+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:45, write-bandwidth:40, byte-size:50] adjusted=[cpu:45, write-bandwidth:40, byte-size:50] node-reported-cpu=45 node-adjusted-cpu=45 seq=2
9292
top-k-ranges (local-store-id=1) dim=ByteSize: r2 r3

pkg/kv/kvserver/allocator/mmaprototype/testdata/cluster_state/rebalance_replica

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ store-load-msg
1313

1414
get-load-info
1515
----
16-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:80, write-bandwidth:80, byte-size:80] node-reported-cpu=80 node-adjusted-cpu=80 seq=1
17-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
16+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:80, write-bandwidth:80, byte-size:80] node-reported-cpu=80 node-adjusted-cpu=80 seq=1
17+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
1818

19-
store-leaseholder-msg
19+
store-leaseholder-msg
2020
store-id=1
2121
range-id=1 load=[80,80,80] raft-cpu=20 config=(num_replicas=3 constraints={'+region=us-west-1:1'} voter_constraints={'+region=us-west-1:1'})
2222
store-id=1 replica-id=1 type=VOTER_FULL leaseholder=true
@@ -30,9 +30,9 @@ range-id=1 load=[cpu:80, write-bandwidth:80, byte-size:80] raft-cpu=20
3030

3131
get-load-info
3232
----
33-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:80, write-bandwidth:80, byte-size:80] node-reported-cpu=80 node-adjusted-cpu=80 seq=1
33+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:80, write-bandwidth:80, byte-size:80] node-reported-cpu=80 node-adjusted-cpu=80 seq=1
3434
top-k-ranges (local-store-id=1) dim=CPURate: r1
35-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
35+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
3636

3737
make-pending-changes range-id=1
3838
rebalance-replica: remove-store-id=1 add-store-id=2
@@ -52,9 +52,9 @@ range-id=1 load=[cpu:80, write-bandwidth:80, byte-size:80] raft-cpu=20
5252

5353
get-load-info
5454
----
55-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=80 node-adjusted-cpu=0 seq=2
55+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=80 node-adjusted-cpu=0 seq=2
5656
top-k-ranges (local-store-id=1) dim=CPURate: r1
57-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:88, write-bandwidth:88, byte-size:88] node-reported-cpu=0 node-adjusted-cpu=88 seq=1
57+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:88, write-bandwidth:88, byte-size:88] node-reported-cpu=0 node-adjusted-cpu=88 seq=1
5858

5959
# TODO: this test is confusing since it is sending StoreLeaseholderMsgs from
6060
# s1 and s2 to the same clusterState, but s1 and s2 are not on the same node.
@@ -66,9 +66,9 @@ store-id=2
6666

6767
get-load-info
6868
----
69-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=80 node-adjusted-cpu=0 seq=2
69+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=80 node-adjusted-cpu=0 seq=2
7070
top-k-ranges (local-store-id=1) dim=CPURate: r1
71-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:88, write-bandwidth:88, byte-size:88] node-reported-cpu=0 node-adjusted-cpu=88 seq=1
71+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:88, write-bandwidth:88, byte-size:88] node-reported-cpu=0 node-adjusted-cpu=88 seq=1
7272
top-k-ranges (local-store-id=2) dim=ByteSize: r1
7373

7474
get-pending-changes
@@ -94,9 +94,9 @@ change-id=2 store-id=1 node-id=1 range-id=1 load-delta=[cpu:-80, write-bandwidth
9494

9595
get-load-info
9696
----
97-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=80 node-adjusted-cpu=0 seq=2
97+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=80 node-adjusted-cpu=0 seq=2
9898
top-k-ranges (local-store-id=1) dim=CPURate: r1
99-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:80, write-bandwidth:80, byte-size:80] node-reported-cpu=80 node-adjusted-cpu=80 seq=2
99+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:80, write-bandwidth:80, byte-size:80] node-reported-cpu=80 node-adjusted-cpu=80 seq=2
100100
top-k-ranges (local-store-id=2) dim=ByteSize: r1
101101

102102

@@ -110,7 +110,7 @@ pending(0)
110110

111111
get-load-info
112112
----
113-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=3
113+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=3
114114
top-k-ranges (local-store-id=1) dim=CPURate: r1
115-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:80, write-bandwidth:80, byte-size:80] node-reported-cpu=80 node-adjusted-cpu=80 seq=2
115+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:80, write-bandwidth:80, byte-size:80] adjusted=[cpu:80, write-bandwidth:80, byte-size:80] node-reported-cpu=80 node-adjusted-cpu=80 seq=2
116116
top-k-ranges (local-store-id=2) dim=ByteSize: r1

pkg/kv/kvserver/allocator/mmaprototype/testdata/cluster_state/remove_replica

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@ store-load-msg
1313

1414
get-load-info
1515
----
16-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
17-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:20, write-bandwidth:80, byte-size:80] adjusted=[cpu:20, write-bandwidth:80, byte-size:80] node-reported-cpu=20 node-adjusted-cpu=20 seq=1
16+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
17+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:20, write-bandwidth:80, byte-size:80] adjusted=[cpu:20, write-bandwidth:80, byte-size:80] node-reported-cpu=20 node-adjusted-cpu=20 seq=1
1818

1919
store-leaseholder-msg
2020
store-id=1
@@ -25,9 +25,9 @@ store-id=1
2525

2626
get-load-info
2727
----
28-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
28+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
2929
top-k-ranges (local-store-id=1) dim=CPURate: r1
30-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:20, write-bandwidth:80, byte-size:80] adjusted=[cpu:20, write-bandwidth:80, byte-size:80] node-reported-cpu=20 node-adjusted-cpu=20 seq=1
30+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:20, write-bandwidth:80, byte-size:80] adjusted=[cpu:20, write-bandwidth:80, byte-size:80] node-reported-cpu=20 node-adjusted-cpu=20 seq=1
3131
top-k-ranges (local-store-id=1) dim=CPURate: r1
3232

3333
ranges
@@ -55,9 +55,9 @@ range-id=1 load=[cpu:80, write-bandwidth:80, byte-size:80] raft-cpu=20
5555
# applied.
5656
get-load-info
5757
----
58-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
58+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
5959
top-k-ranges (local-store-id=1) dim=CPURate: r1
60-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:20, write-bandwidth:80, byte-size:80] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=20 node-adjusted-cpu=0 seq=2
60+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:20, write-bandwidth:80, byte-size:80] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=20 node-adjusted-cpu=0 seq=2
6161
top-k-ranges (local-store-id=1) dim=CPURate: r1
6262

6363
store-leaseholder-msg
@@ -68,9 +68,9 @@ store-id=1
6868

6969
get-load-info
7070
----
71-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
71+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
7272
top-k-ranges (local-store-id=1) dim=CPURate: r1
73-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:20, write-bandwidth:80, byte-size:80] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=20 node-adjusted-cpu=0 seq=2
73+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:20, write-bandwidth:80, byte-size:80] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=20 node-adjusted-cpu=0 seq=2
7474

7575
get-pending-changes
7676
----
@@ -85,9 +85,9 @@ store-load-msg
8585

8686
get-load-info
8787
----
88-
store-id=1 node-id=1 status=unknown, refusing=leases,replicas reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
88+
store-id=1 node-id=1 status=ok accepting all reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
8989
top-k-ranges (local-store-id=1) dim=CPURate: r1
90-
store-id=2 node-id=2 status=unknown, refusing=leases,replicas reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=3
90+
store-id=2 node-id=2 status=ok accepting all reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=3
9191

9292
get-pending-changes
9393
----
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
set-store
2+
store-id=1 node-id=1 attrs=purple locality-tiers=region=foo
3+
----
4+
node-id=1 locality-tiers=region=foo,node=1
5+
store-id=1 attrs=purple locality-code=1:2:
6+
7+
set-store-status store-id=1 health=unhealthy replicas=refusing leases=shedding
8+
----
9+
unhealthy refusing=replicas shedding=leases
10+
11+
set-store-status store-id=1 health=unhealthy replicas=shedding leases=shedding
12+
----
13+
unhealthy shedding=leases,replicas
14+
15+
get-load-info
16+
----
17+
store-id=1 node-id=1 status=unhealthy shedding=leases,replicas reported=[cpu:0, write-bandwidth:0, byte-size:0] adjusted=[cpu:0, write-bandwidth:0, byte-size:0] node-reported-cpu=0 node-adjusted-cpu=0 seq=0
18+
19+
set-store-status store-id=1 health=ok
20+
----
21+
ok accepting all

0 commit comments

Comments
 (0)