Execution Process

The execution process includes:

  1. The user submits a Load Set, Program, or Data Mart for execution.

    • The system calls the Oracle LSH operator specified for the technology type that drives the execution of the executable.

    • The system generates a job ID and assigns a service instance to the job.

  2. The system calls the pre-execution function specified in the technology type, if any, and then calls the execution function.

  3. You must write an execution function to do the following; see "Execution_Function" for details.

    1. Build a collection of files, if required

    2. Output an XML message with information about the job (the XML payload)

    3. Call the Send Job public API

  4. The Oracle LSH listener detects the XML message produced by the Execution_Function, dequeues the message, and sends the XML message to the DP Server to run the job in the external processing engine using the assigned service instance.

    The service instance is the account that the job uses to connect back to the Oracle LSH database to read from sources and write to targets, if any.

    The DP Server creates a subdirectory with he job ID as a name in the work directory defined under the DP Server directory for jobs of this type and puts all the files required for the job in this subdirectory.

    The DP Server makes two UNIX shell variables available to the processing engine:

    • $CDRJOBSCHEMA holds the value of the service instance account, which is extracted from the XML message; for example, <SCHEMA>ZZ_CDR_SI_250001</SCHEMA>

    • $CDREXEPASS holds a random password assigned to the account for that job. The password can never be reused.

  5. The service instance runs the execution command. There is a single execution command, which you must write, for all jobs of this type; see "Execution Command".

  6. The DP Server job processor uses the information in the XML message to connect back to the Oracle LSH database. Once connected, it downloads all the necessary data, including the execution function(s), into a target directory identified in the XML message.

  7. The job processor then executes the job-specific script by spawning a new operating system-level process.

  8. This spawned process runs the processing engine, which in turn carries out the actual job execution using the downloaded job input data.

  9. After the spawned external process completes, the job processor connects back to Oracle LSH and uploads any output results into Oracle LSH. The service instance is released.

  10. Meanwhile, the execution function waits for the job to complete, using the Wait for Final Status public API as soon as it calls the Send Job API.

    If the job produces one or more outputs, the DP Server loads the BLOB or CLOB file(s) into a temporary table. Your postexecution function should retrieve these files; see "Post_Execution_Function".

  11. The system calls the postexecution function.

  12. The system reports the final job status. See the Oracle Life Sciences Data Hub User's Guide for a description of job and execution statuses.