Uploaded image for project: 'OpenNMS'
  1. OpenNMS
  2. NMS-7975

Rest API v2 returns http-404 (not found) for http-204 (no content) cases

    XMLWordPrintable

Details

    • Bug
    • Status: Resolved (View Workflow)
    • Major
    • Resolution: Fixed
    • 17.0.0
    • 18.0.0
    • REST
    • Security Level: Default (Default Security Scheme)
    • None
    • BSM - Sprint 2

    Description

      Rest calls against the api/v2 rest api return wrong http-404 status codes.
      If the result sets are empty the api always returns http-404 instead of http-204 for no content.
      For example a call against the nodes returns a 404 if no nodes exist.
      Calls using a criteria that causes an empty result also returns an 404 instead of http-204.

      relevant class:
      org.opennms.web.rest.v2.AbstractDaoRestService

      Attachments

        Activity

          People

            mvr Markus von RĂ¼den
            tak Markus Neumann (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: