Skip to content

Return status code 500 (instead of 200) when there's a run time error#781

Open
amandasaurus wants to merge 1 commit intodrolbr:masterfrom
amandasaurus:http500-on-runtime-error
Open

Return status code 500 (instead of 200) when there's a run time error#781
amandasaurus wants to merge 1 commit intodrolbr:masterfrom
amandasaurus:http500-on-runtime-error

Conversation

@amandasaurus
Copy link
Contributor

HTTP 200 is for when there is no problem.

In my experience, if something happens to an overpass server, you can get runtime error: open64: 2 No such file or directory /ssd/overpass-database//osm3s_v0.7.58_osm_base Unix_Socket::7. However when this happens the HTTP status code is 200. With this patch, the HTTP status code will be 500.

This allows the existance, or occurance, of this error to be detected, logged, with potential automatic failover happening.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant