Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type APIGateway ¶
type APIGateway struct {
// contains filtered or unexported fields
}
APIGateway provides a REST API interface to the Control Plane services
func NewAPIGateway ¶
func NewAPIGateway(cfg *config.ControlPlaneConfig, cpConn, authConn *grpc.ClientConn) (*APIGateway, error)
NewAPIGateway creates a new API gateway
type RateLimiter ¶
type RateLimiter struct {
// contains filtered or unexported fields
}
RateLimiter implements a token bucket rate limiter
func NewRateLimiter ¶
func NewRateLimiter(limit int, intervalStr string) (*RateLimiter, error)
NewRateLimiter creates a new rate limiter with the specified limit and interval
func (*RateLimiter) Allow ¶
func (r *RateLimiter) Allow(key string) bool
Allow checks if a request is allowed under the rate limit
Click to show internal directories.
Click to hide internal directories.