openptk
  1. openptk
  2. OPENPTK-330

Limit use of WebApplicationException

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0, 2.1
    • Fix Version/s: 2.1
    • Component/s: Server
    • Labels:
      None

      Description

      Enhance the Resource code to handle exceptions with appropriate HTTP 400/500 Response instead of throwing WebApplicationException, where possible.

        Activity

        Hide
        Scott Fehrman added a comment -

        Implemented solution. The use of WebApplicationException is limited to the constructor method for Resource.java. All other "run time" exceptions (EngineException) are caught and an Internal Server Error (500) is sent back to the client.

        Show
        Scott Fehrman added a comment - Implemented solution. The use of WebApplicationException is limited to the constructor method for Resource.java . All other "run time" exceptions (EngineException) are caught and an Internal Server Error (500) is sent back to the client.
        Hide
        Terry Sigle added a comment -

        Confirmed with a code review of the org.openptk.jaxrs.Resource.java and child classes to confirm that the WebApplicationException is being thrown properly and/or an INTERNAL_SERVER_ERROR is being used properly.

        Show
        Terry Sigle added a comment - Confirmed with a code review of the org.openptk.jaxrs.Resource.java and child classes to confirm that the WebApplicationException is being thrown properly and/or an INTERNAL_SERVER_ERROR is being used properly.

          People

          • Assignee:
            Scott Fehrman
            Reporter:
            Scott Fehrman
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: