19 lines
313 B
Go
Raw Normal View History

2020-04-28 22:48:09 +08:00
package ratelimit
import (
"testing"
)
/*
Rate limiting is an very important mechanism
With limiting you can controll resource utilization and maintain quality of service.
Go supports rate limiting by using goroutines, channels, and tickers.
*/
func TestRateLimiting(t *testing.T) {
2020-05-08 18:54:32 +08:00
rateLimiting(5, 3)
2020-04-28 22:48:09 +08:00
}