Uploaded image for project: 'OpenICF'
  1. OpenICF
  2. OPENICF-832

ServiceNow: Deleting a non existing user return code 500


    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: servicenow-connector-
    • Component/s: ServiceNow Connector
    • Labels:
    • Environment:


      Deleting a non existing user return status code 500 and displayed exception in openidm console/logs.

      Steps to reproduce:

      1. Download, unzip openidm, start openidm and set up ServiceNow connector according documentation
      2. Send delete request for deleting non-existing user
        curl -X DELETE \
          http://localhost:8080/openidm/system/ServiceNow/user/NONEXISTING_USER_ID \
          -H 'if-match: *' \
          -H 'x-openidm-password: openidm-admin' \
          -H 'x-openidm-username: openidm-admin'

      Actual result:
      OpenIDM console displayed exception and returned code status 500.

          "code": 500,
          "reason": "Internal Server Error",
          "message": "Operation DELETE failed with ConnectorException on system object"
      ar 06, 2018 12:59:45 PM org.apache.http.impl.client.CloseableHttpClient execute
      WARNING: HTTP response status is 404
      Mar 06, 2018 12:59:45 PM org.forgerock.openicf.connectors.servicenow.client.ServiceNowClient getRecord
      WARNING: API exception occurred. The response body is: {"error":{"detail":"Record doesn't exist or ACL restricts the record retrieval","message":"No Record found"},"status":"failure"}
      Mar 06, 2018 12:59:45 PM org.forgerock.openicf.connectors.servicenow.ServiceNowConnector executeQuery
      SEVERE: Failed to get record
      Mar 06, 2018 12:59:45 PM org.forgerock.openidm.servlet.internal.ServletConnectionFactory$3 lambda$handleRequestWithLogging$8
      WARNING: Resource exception: 500 Internal Server Error: "Operation DELETE failed with ConnectorException on system object"
      org.forgerock.json.resource.InternalServerErrorException: Operation DELETE failed with ConnectorException on system object
      	at org.forgerock.openidm.provisioner.openicf.impl.ExceptionHelper.adaptConnectorException(ExceptionHelper.java:159)
      	at org.forgerock.openidm.provisioner.openicf.impl.ObjectClassResourceProvider.handleDelete(ObjectClassResourceProvider.java:334)
      	at org.forgerock.openidm.provisioner.openicf.impl.ObjectClassRequestHandler.handleDelete(ObjectClassRequestHandler.java:111)
      	at org.forgerock.json.resource.Router.handleDelete(Router.java:278)...

      More at openidm0.log.0 openidm0.log.1 openidm0.log.2 openidm0.log.3

      Expected result:
      The delete request should be returned 404 status code and OpenIDM console should not displayed exception.

          "code": 404,
          "reason": "Not Found",
          "message": "Operation DELETE could not find resource on system object"

      Note: For example the sample for sync-with-csv > When deleting non-existing user so then return 404 status code.


        1. openidm0.log.0
          115 kB
        2. openidm0.log.1
          3 kB
        3. openidm0.log.2
          92 kB
        4. openidm0.log.3
          4 kB

          Issue Links



              • Assignee:
                petr.jurica Petr Jurica [X] (Inactive)
                miroslav.meca Miroslav Meca
                QA Assignee:
                Miroslav Meca
              • Votes:
                0 Vote for this issue
                1 Start watching this issue


                • Created: