Skip to content

CID Software Solutions LTD

Home » Overcome Groovy Execution Limits by Submitting OIC Integration Through ESS Job

Overcome Groovy Execution Limits by Submitting OIC Integration Through ESS Job

Business Challenge

Oracle Fusion Application Composer provides a way to define user-initiated actions using Groovy scripts. These scripts often support buttons on UI pages to trigger integration or business logic.

However, a key limitation is that Groovy scripts invoked this way are capped to 60 seconds execution time. This becomes a problem when:

  • The logic performs long-running data operations or integration with external systems
  • The process must be asynchronous (non-blocking) to avoid keeping users waiting

Although Object Workflows can be used for asynchronous Groovy execution, they are harder to monitor, debug, and maintain.

Solution: Trigger OIC Integration via ESS Job and BI Publisher

To address the timeout limitation and provide an asynchronous pattern that is stable across environments, we use the following strategy:

  • Define a Fusion Web Service connection to call ESS from Groovy using an internal REST endpoint
  • Submit an ESS job from Groovy that runs a BI Publisher (BIP) report
  • The BIP report uses an HTTP connection to invoke the OIC integration

This approach is robust, P2T-safe, and gives visibility into the job execution via standard ESS monitoring tools.

Implementation Steps

Here’s how to implement this pattern step by step:

in Oracle Fusion Application Composer by offloading long-running or external processes to an asynchronous OIC integration using an ESS Job and BIP HTTP connection.

This solution is fully P2T-safe and supports robust integration logic without affecting user experience or UI performance. We’ll walk through all steps—from Groovy code to setup screens—in a single post.


1. Define Internal Web Service Connection in Application Composer

To keep the solution safe across P2T refreshes, we define a REST web service connection in Application Composer that points to an internal Fusion endpoint using SAML authentication. This avoids external web service references in Groovy and makes the connection stable post-clone.

Sample Configuration:

  • Name: LocalFscmREST
  • URL: https://fa-internal.oracleoutsourcing.com:10663/fscmRestApi/resources/latest/##REL_URL##
  • Authentication Scheme: Propagate user identity using SAML

Screenshot – Application Composer Web Service Setup:
Application Composer Web Service Setup


2. Submit ESS Job from Groovy Using the Web Service

Instead of calling the OIC integration directly from Groovy, we submit an ESS job using the internal web service defined above. The ESS job is configured to run a BIP report, which in turn triggers the OIC call.

Below is a working Groovy example used inside a custom object function:


def conn = adf.webServices.LocalFscmREST
def httpHeaders = ['Content-Type': 'application/json']
conn.requestHTTPHeaders = httpHeaders

def payload = [
  "OperationName": "submitESSJobRequest",
  "JobPackageName": "/oracle/apps/ess/custom",
  "JobDefName": "PalletPrint",
  "ESSParameters": RecordName
]

def response = conn.POST("erpintegrations", payload)
return response.toString()

Screenshot – Groovy Function Submitting ESS Job:
Groovy code for submitting ESS job


3. Define BIP HTTP Connection to Trigger OIC Integration

On the BIP (BI Publisher) side, define an HTTP Data Source that will invoke your OIC integration URL. This BIP connection is used in the report template called by the ESS job.

Configuration:

  • Data Source Name: OIC
  • Server Protocol: https
  • Server: your-oic-instance.oraclecloud.com
  • Port: 443
  • Username / Password: OIC integration credentials

Screenshot – BIP HTTP Connection Setup:
BI Publisher HTTP connection to OIC

Once the report is executed by the ESS job, it will invoke the configured OIC endpoint with any required payload, enabling seamless orchestration of downstream logic.


Summary

This integration architecture allows you to:

  • Bypass the 60s Groovy timeout
  • Keep Fusion sandbox logic lightweight
  • Monitor jobs via ESS Scheduled Processes
  • Isolate post-clone maintenance to a single BIP HTTP connection

At CID Software Solutions, we have implemented this pattern for global clients looking to scale their custom logic without compromising maintainability or upgrade safety.

If you’re facing similar limitations in your Oracle Fusion implementation, contact our team to find out how we can help.


Tags: Oracle Fusion, Groovy, ESS Job, BIP, OIC Integration, Application Composer, Custom Object, Web Services, Asynchronous

Leave a Reply

Your email address will not be published. Required fields are marked *