Error Handling and Validations

Note the following issues when designing an integration with the Oracle Utilities Adapter.

  • The Basic Authentication, OAuth Resource Owner Password Credentials, and OAuth Client Credentials security policies are currently supported by REST-based connections.
  • The Username Password Token and Basic Authentication security policies are currently supported by SOAP-based connections.
  • Dragging the Oracle Utilities Adapter connection to the trigger area of the integration canvas prompts you to enter the relative resource URI on the Basic Info page. The standard resource URI format starts with a /, followed by letters. If you enter any other URI format, an error message is displayed.
  • Handling the cross-combination connection catalog error:
    If you create an integration using a SOAP-based connection, changing the connection to use a REST-based catalog has the following impact on that integration:
    • If the integration was already activated, there is no impact on the integration.
    • If the integration was not activated and you now attempt to activate the integration, it fails with the following error message:
      Activation Error:- This Integration was created using SOAP based connection
      but now connection changed to REST. Configure your connection to SOAP again or edit
      the integration for REST.
  • If you create an integration using a REST-based connection, changing the connection to use a SOAP-based catalog has the same impact on that integration. The following error message is displayed:
    Activation Error:- This Integration was created using REST based connection but 
    now connection changed to SOAP. Configure your connection to REST again or edit the 
    integration for SOAP.
The Oracle Utilities Adapter uses the following strategy to handle errors in the invoke (outbound) and trigger (inbound) directions for REST endpoints.
  • Error Handling in the Invoke (Outbound) Direction:

    The Oracle Utilities Adapter in the invoke (outbound) direction returns a standard APIInvocationError for any HTTP response that it receives with an error code. In addition, it also produces an APIInvocationError if a processing error occurs within the Oracle Utilities Adapter while preparing the request, calling the endpoint, or handling the response.

    The format of the APIInvocationError in the mapper is as follows.


    The APIInvocationError element is expanded to show the errorDetails element, which includes selections for type, instance, title, errorPath, and errorCode.

    The errorDetails section contains the actual cause.

    You can handle the APIInvocationError with a fault handler in the orchestrated integration.

  • Error Handling in the Trigger (Inbound) Direction:

    The Oracle Utilities Adapter in the trigger (inbound) direction exposes an HTTP endpoint that HTTP clients can request for using an HTTP request, and returns an HTTP response.

    If successful, the Oracle Utilities Adapter returns a success response. The Oracle Utilities Adapter returns an error response with an HTTP status belonging to the error family of codes depending on the situation.

    The Oracle Utilities Adapter also returns an error response with additional details about the error and possible steps for troubleshooting. The standard error response format is returned according to the configured response media type. The following is a sample JSON response structure:
    {
      "type" : "http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.5.1",
      "title" : "Internal Server Error",
      "detail" : "An internal error occurred while processing the request. Please see the fault details for the nested error details.",
      "o:errorCode" : "500",
      "o:errorDetails" : [ {
        "type" : "http://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html#sec10.4.1",
        "instance" : "{\n   \"error_message\" : \"Invalid request. Missing the 'origin' parameter.\",\n   \"routes\" : [],\n   
        \"status\" : \"INVALID_REQUEST\"\n}\n",
        "title" : "Bad Request",
        "o:errorPath" : "GET http://maps.googleapis.com/maps/api/directions/json?destination=Montreal returned a response status of 
          400 Bad Request",
        "o:errorCode" : "APIInvocationError"
      } ]
    }

    The o:errorDetails section is reserved for the actual cause. The included prefix o: is based on Oracle standards.

    Unmapped faults are propagated as system faults by Oracle Integration to the inbound Oracle Utilities Adapter. They may not communicate the appropriate details. Therefore, it is recommended that you define the fault pipelines.