Interface: HttpRateLimiterConfig
Defined in: shared/utils/httpRateLimiter.ts:70
Configuration for HttpRateLimiter.
Propertiesโ
maxConcurrentโ
readonly maxConcurrent: number;
Defined in: shared/utils/httpRateLimiter.ts:72
Max number of concurrent operations globally.
maxWaitMs?โ
readonly optional maxWaitMs?: number;
Defined in: shared/utils/httpRateLimiter.ts:79
Maximum time to wait for a slot before failing (ms).
Default Valueโ
30_000;
minIntervalMsโ
readonly minIntervalMs: number;
Defined in: shared/utils/httpRateLimiter.ts:82
Minimum interval between requests to the same key (ms).
onMaxWaitExceeded?โ
readonly optional onMaxWaitExceeded?: (context: {
key: string;
waitedMs: number;
}) => void;
Defined in: shared/utils/httpRateLimiter.ts:90
Optional callback invoked when a caller waited longer than maxWaitMs.
Parametersโ
contextโ
keyโ
string
waitedMsโ
number
Returnsโ
void
Remarksโ
This is useful for logging/telemetry in environment-specific wrappers.
toKey?โ
readonly optional toKey?: (url: string) => string;
Defined in: shared/utils/httpRateLimiter.ts:100
Optional key derivation function.
Parametersโ
urlโ
string
Returnsโ
string
Default Valueโ
(URL) =\> new URL(URL)