Skip to content

uniform error handling #610

Description

@dariok

(rewritten):

  • REST functions need to return errors in their response, usually with a status code
    • functions that are called directly have to return the error if it is encountered and must not continues
    • functions that are called by other functions must return a map with the error, ideally with an HTTP response code and a more detailed description.
    • internal error codes should match wdbErr:rest0000
  • when views are concerned, we only throw errors upwards and only catch them in view.xql

If we catch them early and create an output, re-catching and re-processing may happen and thus the error gets hidden and users will only receive an incomplete HTML with no way of really knowing what went wrong.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    Status
    In review

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions