mirror of
https://github.com/jasonxu114514/opencode2api.git
synced 2026-12-05 08:02:53 +00:00
Registrations were paced by a fixed 12-second gap, which made a cold pool and a 429 replacement wait minutes for capacity. Remove the gap: the registrar now issues registrations back to back in the background, serialized by the pool's create mutex, and only a rejected attempt backs off (doJSON still honours Retry-After). Keep half of warp.pool_size (at least one) hot as a preload: the first exit still gates readiness, the rest register in the background, and desiredLocked/scaleDown treat the preload as a floor so idle surplus is still retired after 60 seconds but the warm bench survives. A 429 or 403 removes the exit from the ring and the next request uses a preloaded exit immediately. /healthz reports warp.preload, and the WebUI and all four READMEs describe the behaviour.