vajapravin
vajapravin

Reputation: 1383

Error H13 (Connection Closed without response) Heroku

I am working on Ruby on Rails. A project which works fine on local server and when I deploy it on heroku it gives following error. Thanks!

2012-06-12T14:19:23+00:00 heroku[router]: Error H13 (Connection closed without response) -> GET sheets-vip.heroku.com/ dyno=web.1 queue= wait= service= status=503 bytes=
2012-06-12T14:19:23+00:00 heroku[nginx]: 122.179.134.45 - - [12/Jun/2012:14:19:23 +0000] "GET / HTTP/1.1" 503 601 "-" "Mozilla/5.0 (Windows NT 6.1; rv:12.0) Gecko/20100101 Firefox/12.0" myapp1101.heroku.com
2012-06-12T14:27:35+00:00 app[web.1]: !! Unexpected error while processing request: can't modify frozen array
2012-06-12T14:27:35+00:00 heroku[router]: Error H13 (Connection closed without response) -> GET sheets-vip.heroku.com/ dyno=web.1 queue= wait= service= status=503 bytes=
2012-06-12T14:27:35+00:00 heroku[nginx]: 122.179.134.45 - - [12/Jun/2012:14:27:35 +0000] "GET / HTTP/1.1" 503 601 "-" "Mozilla/5.0 (Windows NT 6.1; rv:12.0) Gecko/20100101 Firefox/12.0" myapp1101.heroku.com

Upvotes: 5

Views: 5601

Answers (2)

Petr Dlouhý
Petr Dlouhý

Reputation: 927

Might not be the OP's case, but if these errors occurs during scaledown events, they are caused by the app inproperly handling SIGTERM signals given by Heroku.

Read more at H13 (Connection closed without response) errors on Heroku scale down and https://www.schneems.com/2019/07/12/puma-4-hammering-out-h13sa-debugging-story/

Upvotes: 0

Andy Glover
Andy Glover

Reputation: 437

This error occurs when something deep down in a dependency of your app blows up. For instance, we saw this error when an incoming request was enormous (i.e. it was a JSON document at +100K). We were able to fix this by setting:

Rack::Utils.key_space_limit = some appropriate value

That is, the H13 was b/c of a Rack error. Try increasing logging in your application as that might point to the error (that's how we ultimately zeroed in on the Rack key space limit).

Upvotes: 2

Related Questions