Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: webadmin
    • Labels:

      Description

      The idea would be to ensure we :

      • Return 400 status code for invalid JSON data
      • That we use our JSON error format for:
      • 500 Internal (uncatched) server errors
      • 404 Not Found (calls on non routes endpoints)

      Currently HTML is returned...

      We need to register specific error handlers in the WebAdmin server.

      • we need upon init to load the `service::internalServerError`, `service::notFound` and a `service::exception targetting JsonExtractException` in WebAdminServer :: configure.
      • We should rely on the common `ErrorResponder` to have consistant error messages
      • In these routes we should avoid throwing an exception. We should have an ErrorResponder::toResponse(Response response) method setting the body and the response code to be used.

      If you need more details to implement this feature, we are willing to provide support. Don't hesitate to ask on https://gitter.im/apache/james-project. We are willing to provide guidance.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              BTellier Tellier Benoit
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: