Internal Server Errors in the orderableFulfills endpoint

Description

While testing OLMIS-4052: API: StockCardSummaries v2Done (while executing step#1 of the test case for the ticket, OLMIS-4124: API: StockCardSummaries v2Canceled), I noticed issues with the orderableFulfills endpoint.

I noticed that when one enters null or an incorrect value in the "id" parameter (e.g. with a space before, after or within the parameter; or a too long or a too short ID), the Internal Server Error is returned. Please find the attached screenshots.

Reproduction steps:

  1. Log into the application as administrator and obtain the user's access token.

  2. Make e.g. the following query: https://uat.openlmis.org/api/orderableFulfills?id=5437bd1c-d582-4d3f-a7ce-888 5c6d785b.

  3. The java.lang.NumberFormatException with the Internal Server Error is returned.

  4. Make e.g. the following query: https://uat.openlmis.org/api/orderableFulfills?id=.

  5. The java.lang.IllegalArgumentException with the Internal Server Error is returned.

Expected Behavior:
If the API receives a null or invalid ID parameter, it should respond with a translatable error message and error status code.

Environment

None

Attachments

2

QAlity Plus - Test Management

Checklists

Activity

Show:
Joanna Bebak
November 20, 2019 at 8:44 AM

The issue is no longer valid - moving to Dead.

Joanna Bebak
November 19, 2019 at 12:51 PM

I will verify if it still occurs.

Joanna Bebak
July 9, 2019 at 12:09 PM

The issues are still valid.

Joanna Bebak
November 15, 2018 at 10:23 AM

I checked, and the issue still occurs, although only the Illegal argument exception is raised; I wasn't able to reproduce the Number format exception but still, the Internal Server error was returned.

Won't Fix
Pinned fields
Click on the next to a field label to start pinning.

Details

Assignee

Reporter

Labels

Components

Priority

Time Assistant

Created February 16, 2018 at 12:32 PM
Updated February 8, 2023 at 1:29 PM
Resolved November 20, 2019 at 8:44 AM