module

Web::Routes::Episodes

Constants

LIMITER_AUDIO = ProxyHelpers::ProxyLimiter.new(global_cap: 64, per_host_cap: 16)

Global semaphore: bound concurrent in-flight audio_proxy fibers so a stalled upstream CDN can't accumulate fibers without limit. Caps: 64 globally (~21 MB worst-case RAM at 128 KB chunk + ~200 KB conn state per fiber); 16 per upstream host so one bad CDN can't monopolise the pool. Note: audio_proxy is ONLY used for the service worker's background "save for offline" flow — actual listening streams direct from the CDN and never traverses our pod. Crystal requires constants at module/class body scope (not inside method bodies).

Class methods

register
Source