Uploaded image for project: 'Apache Fineract'
  1. Apache Fineract
  2. FINERACT-1921

BatchAPI - status code mismatch in case of exception

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Critical
    • Resolution: Fixed
    • None
    • 1.9.0
    • None

    Description

      Steps to reproduce

      Have a batch API request that encapsulates multiple requests, and one of them gives a business-exception. E.g.:

      1. Have a savings account, with balance 1000
      2. Have a batch request with at least 2 requests included. Have 2 withdraws:
        1. Withdraw 1000,
        2. Withdraw 1000
      3. Send it in to Fineract.

      Expected result

      • The batchAPI request has "200" as http status code
      • in the response body the request-related details contain:
        • "statusCode": 403
           
        • "body": "{\n \"developerMessage\": \"Request was understood but caused a domain rule violation.\",\n \"httpStatusCode\": \"403\", ....
           

      Actual result

      • The batchAPI request has "200" as http status code
      • in the response body the request-related details contain:
        • "statusCode": 500
           
        • "body": "{\n \"developerMessage\": \"Request was understood but caused a domain rule violation.\",\n \"httpStatusCode\": \"403\", ....
           

       

      Attachments

        Issue Links

          Activity

            People

              jmarta Marta Jankovics
              peter.santa Peter Santa
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: