AiRateLimiter

constructor(name: String, maxRequests: Int = DEFAULT_MAX_REQUESTS, windowMs: Long = DEFAULT_WINDOW_MS, clock: () -> Long = System::currentTimeMillis)(source)

Parameters

name

Human-readable label used in log messages

maxRequests

Maximum number of requests allowed per window

windowMs

Window duration in milliseconds