6 Generating and Deploying Data Services

This chapter describes how to generate and deploy data services with Oracle Data Integrator.

This chapter includes the following section:

6.1 Generating and Deploying Data Services

Once the model, data sources and container have been configured, it is possible to generate and deploy the data services. Generating data services for a model generates model-level data services as well as the data services for the selected datastores in this model.

To generate Data Services for a model:

  1. In the Models tree in the Designer Navigator, select the model.
  2. Right-click, and select Generate Service. The Generating Data Service window opens.
  3. In the Generating Data Service window, fill in the following fields:
    • Store generated Data Services in: Oracle Data Integrator places the generated source code and the compiled Web Service here. This directory is a temporary location that can be deleted after generation. You can review the generated source code for the data services here.

    • Context: Context into which the data services are generated and deployed. This context choice has three effects:

      • Determining the JDBC/Java datatype bindings at generation time.

      • Determining which physical schemas are used to serve the data.

      • Determining which physical Web Services container is deployed to

    • Generation Phases: Choose one or more generation phases. For normal deployment, all three phases should be selected. However, it may be useful to only perform the generation phase when testing new SKMs, for instance. See below for the meaning of these phases.

  4. Click OK to start data service generation and deployment.

Phase Description

Generate code

This phase performs the following operation.

  • Deletes the content of the generation directory.

  • Generates the Java source code for the data services using the code template from the SKM.

Compilation

This phase performs the following operations:

  • Extracts web service framework.

  • Compiles the Java source code.

Deployment

This phase performs the following operations:

  • Packages the compiled code.

  • Deploys the package to the deployment target, using the deployment method selected for the container.


6.2 Overview of Generated Services

The data services generated by Oracle Data Integrator include model-level services and datastore level services. These services are described below.

Model-level services

Data services are generated at model-level when the model is enabled for consistent set CDC.

The following services are available at model-level:

  • extend Window (no parameters): Carries out an extend window operation.

  • lock (Subscriber Name): Locks the consistent set for the named subscriber. To lock the consistent set for several subscribers, call the service several times, using several OdiInvokeWebService steps for example.

  • unlock (Subscriber Name): Unlocks the consistent set for the named subscriber.

  • purge (no parameters): Purges consumed changes.

See the "Using Journalizing" chapter in Developing Integration Projects with Oracle Data Integrator for more information on these operations.

Datastore-level services

The range of operations offered by each generated data service depends on the SKM used to generate it. There are several common properties shared by the SKMs available with Oracle Data Integrator. In almost every case the name of the published entity forms part of the name of each operation. In the following examples, the published entity "Customer" is used.

The following operations are available at datastore-level:

  • Operations on a single entity. These operations allow a single record to be manipulated, by specifying a value for its primary key. Other fields may have to be supplied to describe the new row, if any. Examples: addcustomer, getcustomer, deletecustomer, updatecustomer.

  • Operations on a group of entities specified by filter. These operations involve specifying values for one or several fields to define a filter, then optionally supplying other values for the changes to made to those rows. In general, a maximum number of rows to return can also be specified. Examples: getcustomerfilter, deletecustomerfilter, updatecustomerfilter.

  • Operations on a list of entities. This list is constructed by supplying several individual entities, as described in the "single entity" case above. Examples: addcustomerlist, deletecustomerlist, getcustomerlist, updatecustomerlist.

6.3 Testing Data Services

The easiest way to test generated data services is to use the graphical interface for the OdiInvokeWebService Oracle Data Integrator tool. See the "Using Web Services" chapter in Developing Integration Projects with Oracle Data Integrator for more information on this subject.