IBM BPM, V8.0.1, All platforms > Migrating and upgrading your IBM BPM environment > Migrating from other products > Migrating from WebSphere Studio Application Developer Integration Edition > Additional migration information > Create SCA Components and SCA Imports for the services in the application for rewiring

The consumption scenario for service migration

If there is no direct counterpart for a WebSphere Studio Application Developer Integration Edition service type, a consumption scenario is needed to consume the old WebSphere Studio Application Developer Integration Edition service as-is when redesigning the application in IBM Integration Designer.

Follow these the steps to perform in WebSphere Studio Application Developer Integration Edition before invoking the Migration wizard:

  1. Create a new Java project to hold this client proxy code. Do not put this client proxy code in the service project, because the 5.1-style generated messages and JavaBeans classes will be skipped by the automatic Migration wizard that migrates service projects.
  2. Open WebSphere Studio Application Developer Integration Edition and right-click the WSDL file containing the transformer binding and service. Select Enterprise Services > Generate Service Proxy. You will be asked what type of proxy to create, but only Web Services Invocation Framework (WSIF) will be available. Click Next.

  3. Specify the package and name of the service proxy Java class to create (you will create the proxy in the current service project). Click Next.

  4. Specify the proxy style, choose Client Stub, select the operations to include in the proxy, and click Finish. This creates a Java class that exposes the same methods as the WebSphere Studio Application Developer Integration Edition service, where the arguments to the Java methods are the parts of the source WSDL message.

Migrate to IBM Integration Designer:

  1. Ensure that the Java project is in the old workspace (the Java project will be migrated automatically by the Migration wizard).
  2. Import the service project using the Migration wizard. This will result in the creation of a Business Integration module with the WSDL Messages, PortTypes, Bindings, and Services generated in WebSphere Studio Application Developer Integration Edition.

  3. In the Business Integration perspective, expand the module so that you can see its contents. Open the Assembly Editor by double-clicking the first item under the module project (it will have the same name as the project).

  4. To create the custom Java component, under the module project, expand Interfaces and select the WSDL interface that was generated for this transformer service in WebSphere Studio Application Developer Integration Edition.

  5. Drag this interface onto the Assembly Editor. A window will open asking you to select the type of component to create. Select Component with No Implementation Type and click OK.

  6. A generic component will appear on the Assembly diagram. Select it and go to the Properties view.

  7. On the Description tab, you can change the name and display name of the component to something more descriptive. (Name it something like your EJB's name but append a postfix such as “JavaMed,” as this is going to be a Java component that mediates between the WSDL interface generated for the transformer service in WebSphere Studio Application Developer Integration Edition and the Java interface of the transformer client proxy.)

  8. On the Details tab you will see that this component has one interface - the one that you dragged onto the Assembly Editor.
  9. Return to the Assembly Editor, right-click the component that you just created, and select Generate Implementation… > Java. Select the package where the Java implementation will be generated. This creates a skeleton Java service that adheres to the WSDL interface according to the SCA programming model, where complex types are represented by an object that is a commonj.sdo.DataObject and simple types are represented by their Java Object equivalents.

Enter code where you see the “//TODO” tags in the generated Java implementation class. There are two options:

  1. Move the logic from the original Java class to this class, adapting it to the new data structure.

  2. Create a private instance of the old Java class inside this generated Java class and write code to:
    1. Convert all parameters of the generated Java implementation class into parameters that the old Java class expects

    2. Invoke the private instance of the old Java class with the converted parameters
    3. Convert the return value of the old Java class into the return value type declared by the generated Java implementation method

Once you have completed the previous options, rewire the client proxy. There should not be any "references", therefore you just need to rewire the Java component's interface:

: Create SCA Components and SCA Imports for the services in the application for rewiring