func (rl *RateLimiterImpl) WaitN(ctx context.Context, numToken int) error {
	return rl.goRateLimiter.WaitN(ctx, numToken)
}
WaitN waits up till deadline for n rate limit token
package quotas
import (
	"context"
	"sync"
	"time"
	"golang.org/x/time/rate"
)
type (
	RateLimiterImpl struct {
		sync.RWMutex
		rate          float64
		burst         int
		goRateLimiter *rate.Limiter
	}
)
var _ RateLimiter = (*RateLimiterImpl)(nil)
func NewRateLimiter(newRate float64, newBurst int) *RateLimiterImpl {
	rl := &RateLimiterImpl{
		rate:          newRate,
		burst:         newBurst,
		goRateLimiter: rate.NewLimiter(rate.Limit(newRate), newBurst),
	}
	return rl
}
func (rl *RateLimiterImpl) SetRate(rate float64) {
	rl.refreshInternalRateLimiterImpl(&rate, nil)
}
func (rl *RateLimiterImpl) SetBurst(burst int) {
	rl.refreshInternalRateLimiterImpl(nil, &burst)
}
func (rl *RateLimiterImpl) SetRateBurst(rate float64, burst int) {
	rl.refreshInternalRateLimiterImpl(&rate, &burst)
}
func (rl *RateLimiterImpl) Allow() bool {
	return rl.goRateLimiter.Allow()
}
func (rl *RateLimiterImpl) AllowN(now time.Time, numToken int) bool {
	return rl.goRateLimiter.AllowN(now, numToken)
}
func (rl *RateLimiterImpl) Reserve() Reservation {
	return rl.goRateLimiter.Reserve()
}
func (rl *RateLimiterImpl) ReserveN(now time.Time, numToken int) Reservation {
	return rl.goRateLimiter.ReserveN(now, numToken)
}
func (rl *RateLimiterImpl) Wait(ctx context.Context) error {
	return rl.goRateLimiter.Wait(ctx)
}