You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@@ -58,6 +61,23 @@ var consumerCmd = &cobra.Command{
58
61
}()
59
62
fmt.Printf("Using random seed: %d\n", seed)
60
63
64
+
varrequestRate=Inf
65
+
varrequestBurst=rps
66
+
useRateLimiter:=false
67
+
ifrps!=0 {
68
+
requestRate=rate.Limit(rps)
69
+
useRateLimiter=true
70
+
ifrpsBurst!=0 {
71
+
requestBurst=rpsBurst
72
+
}
73
+
} else {
74
+
ifreadBlockMs<0 {
75
+
fmt.Printf("Given you haven't specified a rate of messages/sec and the \"--stream-read-block-ms\" value is also < 0 this means you'll be stressing the server to the highest capacity. Be aware that this will influence the producer side as well!\n")
rootCmd.PersistentFlags().Int("rps", 0, "Max rps. If 0 no limit is applied and the DB is stressed up to maximum.")
60
-
rootCmd.PersistentFlags().Int("rps-burst", 0, "Max rps burst. If 0 the allowed burst will be the ammount of clients.")
60
+
rootCmd.PersistentFlags().Int("rps-burst", 0, "Max rps burst. If 0 the allowed burst will be the amount of clients.")
61
61
rootCmd.PersistentFlags().String("a", "", "Password for Redis Auth.")
62
62
rootCmd.PersistentFlags().Int64("random-seed", 12345, "random seed to be used.")
63
63
rootCmd.PersistentFlags().Uint64("c", 50, "number of clients.")
64
64
rootCmd.PersistentFlags().Int64("keyspace-len", 100, "number of streams.")
65
-
rootCmd.PersistentFlags().Int64("stream-maxlen", 1000000, "stream max length.")
65
+
rootCmd.PersistentFlags().Int64("stream-maxlen", 250000, "stream max length.")
66
66
rootCmd.PersistentFlags().Int64("stream-maxlen-expire-secs", 60, "If a stream reached the max length, we expire it after the provided amount of seconds. If 0 will use DEL instead of expire.")
0 commit comments