HyperSwitch/errors/server error
HTTP Status
[edit]500
Description
[edit]General internal server error. The title
and detail
field might suggest the reason for a failure, but in most cases the error is unexpected, so no useful information would be provided. This error generally represents a bug in the server code. In case it's encountered please file a bug on Phabricator
Error response contains JSON body in the form of application/problem+json
Body Schema
[edit]Field | Type | Description | Example |
---|---|---|---|
type | string | Link to the error description page | https://mediawiki.org/wiki/HyperSwitch/errors/server_error |
method | string | HTTP request method | get |
uri | string | Requested URI that produced this problem | https://en.wikipedia.org/api/rest_v1/page/html/Failing_Page |
title | string | High-level explanation of the error | Server Error |
detail | string | More detailed explanation of the error reason. Optional, most likely this would no be provided | Empty response received from a bacon service |
stack | string | A stack trace of the exception which lead to the error. | /sys/parsoid.js:100
/sys/parsoid.js:200 ... |
Specific error types
[edit]empty_response
[edit]Indicates that a backend service returned empty or no response.
request_recursion_depth_exceeded
[edit]Applications built using HyperSwitch framework heavily rely on modularisation. So, to get the requested content sometimes several modules needs to be called. Each module call is represented by an internal request. In case of a bug, there could be a cycle of internal requests, resulting in infinite recursion. HyperSwitch is protected from such situations by limiting the recursion depth. The default limit is 10. To help in debugging errors like this the following extra fields are added to the response:
Field | Type | Description | Example |
---|---|---|---|
depth | integer | Current recursion depth | 10 |
parents | array | HyperSwitch context objects hold a reference to caller contexts. So, for debugging the whole chain of contexts is returned, that allows the user to follow the chain of requests which lead to infinite recursion.. |