Deploying and configuring inbound operations for scenario 2

Scenario 2 of the sample application requires you to use the enterprise service discovery wizard to deploy the application package, configure the adapter, and generate the SCA artifacts for inbound processing.

Why and when to perform this task

Before you begin to deploy and configure, import the CWYFF_FlatFile.RAR file into the project. For this task, you must run the enterprise service discovery within WebSphere® Integration Developer to set adapter configuration properties. To change the property values later, use the WebSphere Process Server administrative console.

Steps for this task

  1. From the WebSphere Integration Developer window, switch to the Business Integration perspective by selecting Window > Open Perspective > Other from the menu bar. All perspectives are displayed. Select Business Integration perspective in WebSphere Integration Developer.
  2. In the Business Integration Perspective of WebSphere Integration Developer, right-click the frame and from the pop-up menu, select New > Enterprise Service Discovery. The Select an Enterprise Service Resource Adapter window is displayed.
  3. Select the IBM WebSphere Adapter for Flat Files (version 6.0.0) from the ’CWYFF_FlatFile’ Connector Project and click Next. The Configure Settings for Discovery Agent window is displayed.
  4. In the Configure Settings for Discovery Agent window, set the connection properties by selecting Inbound for the ServiceType.
  5. Optional. At the bottom of the Configure Settings for Discovery Agent window, click the Show Advanced button. You can set logging and tracing levels here. Click Next.
  6. In the Find and Discover Enterprise Services window, click the Run Query button to display the meta-data tree of the Flat Files adapter.
  7. Under Objects discovered by query, for inbound operations, select the Inbound root node of the meta-data tree. The objects that can be selected for import are displayed in the Objects discovered by query box. Highlight the object you would like to import, then click the Add Selected button to add the objects to the Objects to be imported box. Click Next.
    Note: To remove objects from the Objects Discovered by query text box, highlight the object that you would like to remove and click the Remove Selected button.
  8. In the Configure Objects window, specify the properties for the objects that will be imported by the discovery agent. For the BO Location property, specify the folder name within the Business Integration module where the .xsd file should be generated. Click Next.

    The supported operations for Inbound include:

    • Read
  9. In the Generate Artifacts window, do the following:
    1. Click New to create a new business integration module.
    2. In the New Module window, enter the Module name, FlatFileInboundModule, and click Finish.
    3. In the Generate Artifacts window, enter the folder name, FlatFileInboundFolder.
    4. Under "Specify the connection properties which will be used to connect to the Enterprise Information System at runtime", select Use discovered connection properties.
    5. Enter the Event Distribution Database properties.
      Note: Required properties are indicated with a * next to the property box.
    6. Enter the Flat Files adapter ActivationSpecification properties.
      Note: Properties marked with an asterisk (*) are required.
    7. Enter the logging and tracing values.
      Note: Required properties are indicated with a * next to the property box.
  10. When you are finished entering property values, click Finish. The new module is added to the Business Integration Perspective, along with all its artifacts.

    Now, you can use WebSphere Integration Developer to generate reference bindings for the SCA component that the enterprise service discovery tool creates. Reference bindings are used by other WebSphere Business Integration SCA components to access the adapter. You create a reference to the adapter from the project module so as to link the adapter to the other server processes.

  11. In the Business Integration Perspective of WebSphere Integration Developer, right-click the module, and select Open With > Assembly Editor. The Assembly Diagram window appears with the modules Import component in view.
  12. To create a new component, click the top-most icon in the left-side (vertical) frame of the Assembly Diagram Window. A new menu of icons appears.
  13. Create a Component with no implementation. Drag the Create a Component icon into the Assembly Diagram window.
  14. Create wiring from the FlatFileInboundInterface to this new component. Click and drag the module‘s Import component to the new component. This draws a wire from the Import component to the new component. The Add Wire dialog box is displayed.
  15. Click OK. The new Standalone Reference component displays in the Assembly Diagram window with a wire that connects it to the modules Import component.
  16. Create a Java™ component that will acts like an endpoint listener. During event delivery of the inbound operation, the adapter invokes the READ method of the component implementation and passes the inbound business object as a parameter.
    1. Right click the component and select Generate implementation > Java.
    2. Select the package where the Java code should be created and click OK.
    3. Enter the Package name, listener, when prompted and click OK.
    4. Click OK in the Generate Implementation window.
    5. In the generated Java implementation, scroll to the READ method. You can add custom code inside the READ method to process the delivered business object according to your specific business needs. For example, you can add print statements to detect event delivery.
    6. Save the file, File > Save.
  17. Edit the ActivationSpecificaiton properties. In WebSphere Integration Developer, double click the first element under FlatFileInboundModule to open the Assembly Editor.
    1. Select Properties > Binding > Connection > ActivationSpec Properties
    2. Edit the ActivationSpecification properties according to your specific system requirements.
    3. Click Save when you are finished editing the ActivationSpecification properties.
  18. In the Business Integration perspective, right click FlatFileInboundModule.
  19. Select Test > Test Module from the pop-up menu. The Events window is displayed.
  20. In the Events window, place a sample event file in the event directory.
    1. Verify the event file has an ".in" extension.
    2. To start the WebSphere Process Server and install the inbound application, click Continue.

What to do next

The adapter application package, including all its SCA artifacts, is now configured and deployed. You can now run the sample application.
Related tasks
Deploying and configuring inbound operations for scenario 1
Deploying and configuring outbound operations for scenario 1
Deploying and configuring outbound operations for scenario 2
Running the sample application for inbound operations
Running the sample application for outbound operations
Enabling logging
Enabling tracing
Related reference
Structure of the application package
Business object structure
Custom properties
J2C activation specification properties
Resource adapter properties

Terms of use |

Last updated: Sun Mar 12 11:47:11 2006

(c) Copyright IBM Corporation 2005.
This information center is powered by Eclipse technology (http://www.eclipse.org)