Skip to content

Commit 47bd258

Browse files
committed
tests: use high burst value in limiter.
Use the highest MaximalQPS of all traffic profiles as burst otherwise actual traffic may be accidentally limited. For example, if burst is set to 200 it is unlikely traffic can achieve higher than 200. Signed-off-by: Jiayin Mao <[email protected]>
1 parent 75f2ae1 commit 47bd258

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

tests/robustness/traffic/traffic.go

+2-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,8 @@ func SimulateTraffic(ctx context.Context, t *testing.T, lg *zap.Logger, clus *e2
5959

6060
lm := identity.NewLeaseIDStorage()
6161
reports := []report.ClientReport{}
62-
limiter := rate.NewLimiter(rate.Limit(profile.MaximalQPS), 200)
62+
// Use the highest MaximalQPS of all traffic profiles as burst otherwise actual traffic may be accidentally limited
63+
limiter := rate.NewLimiter(rate.Limit(profile.MaximalQPS), 1000)
6364

6465
cc, err := client.NewRecordingClient(endpoints, ids, baseTime)
6566
require.NoError(t, err)

0 commit comments

Comments
 (0)