mirror of
https://github.com/cubefs/cubefs.git
synced 2026-08-02 02:00:56 +00:00
fix(flashnode): reset test limiter#23061931
Signed-off-by: clinx <chenlin1@oppo.com>
This commit is contained in:
parent
f3b98b69b1
commit
9df10b2063
@ -72,7 +72,7 @@ func testTCPCachePrepare(t *testing.T) {
|
||||
|
||||
flashServer.readLimiter.SetBurst(200)
|
||||
flashServer.readLimiter.SetLimit(20)
|
||||
|
||||
time.Sleep(time.Second)
|
||||
p.Opcode = proto.OpFlashNodeCachePrepare
|
||||
require.NoError(t, p.WriteToConn(conn))
|
||||
require.NoError(t, r.ReadFromConn(conn, 3))
|
||||
@ -122,7 +122,9 @@ func testTCPCacheRead(t *testing.T) {
|
||||
defer conn.Close()
|
||||
p := proto.NewPacketReqID()
|
||||
r := proto.NewPacket()
|
||||
|
||||
flashServer.readLimiter.SetBurst(0)
|
||||
flashServer.readLimiter.SetLimit(0)
|
||||
time.Sleep(time.Second)
|
||||
p.Opcode = proto.OpFlashNodeCacheRead
|
||||
require.NoError(t, p.WriteToConn(conn))
|
||||
require.NoError(t, r.ReadFromConn(conn, 3))
|
||||
|
||||
Loading…
Reference in New Issue
Block a user