HTTP/2 connection drops after 60s despite keep-alive - configurable?

jetsonearth
FREE

3 days ago

Hey Railway team! 👋

Quick question about HTTP/2 connection persistence limits on Railway.

Context:
I have a Swift client that sends keep-alive requests every 40s to maintain HTTP/2 connections to my Railway-hosted proxy (which forwards to Groq API). This works great for eliminating cold start penalties.

Issue:
Connection reuse works perfectly for ~60 seconds, then Railway seems to drop the connection despite active keep-alives every 40s. This causes 800ms+ TCP/TLS handshake penalties.

Question:
Is there a way to extend HTTP/2 connection persistence beyond 60 seconds on Railway? Or is 60s a hard limit?

My keep-alive setup:

  • Connection: keep-alive + Keep-Alive: timeout=55 headers

  • URLSession with persistent config (httpMaximumConnectionsPerHost = 1)

0 Replies

jetsonearth
FREE

3 days ago

77c31c97-2ba9-4511-b060-7ff5fa441682


HTTP/2 connection drops after 60s despite keep-alive - configurable? - Railway Help Station