Uploaded image for project: 'OpenIDM'
  1. OpenIDM
  2. OPENIDM-15201

Workflow 'processinstance' query unable to sort with '+' as ascending sort order.

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Not a defect
    • Affects Version/s: 7.0.0
    • Fix Version/s: 7.0.0
    • Component/s: Module - Workflow
    • Labels:
      None

      Description

      I request such as the following - note the "" in the sort key to indicate ascending order.  While leaving the "" off of the sortkey will sort ascending by default, the query parameter sortKeys also supports the "+" in the syntax.

       

      curl --location --request GET 'http://localhost:8080/openidm/workflow/processinstance?_queryFilter=true&_sortKeys=+_id' \
      --header 'X-OpenIDM-Username: openidm-admin' \
      --header 'X-OpenIDM-Password: openidm-admin' \
      --header 'X-OpenIDM-nosession: true'
      

      Will return as a 400 error as it is attempting to parse the sortKeys parameters.

      {
          "code": 400,
          "reason": "Bad Request",
          "message": "A value could not be parsed as a comma separated list of sort keys"
      }
      

       Link to query documentation: https://ea.forgerock.com/docs/idm/rest-api-reference/sec-about-crest.html#about-crest-query

       

      Note: I found this on the processinstance endpoint, but the issue likely lies in the shared sort key parsing for all workflow endpoints that permit sorting.

       

      Setup:  Start the contractor onboarding workflow sample, and begin a few processes. the example api call should succeed, with the results sorted in asc order.

        

        Attachments

          Activity

            People

            • Assignee:
              travis.haagen Travis Haagen
              Reporter:
              jason.vincent jason vincent
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: