The IMS™ TM Resource
Adapter v. 10.20 RAR contains the convID, useConvID and convEnded properties in the
interactionSpec, and these properties can be used to support conversational
applications.
Before you begin
When you expose conversation properties in the interactionSpec,
you need to expose these three properties altogether:
- isConvEnded: the conversation ID to identify
the conversation
- convID: a flag to indicate a conversation ID
is being used
- UseConvID: to mark if conversation has ended
Procedure
- Select , and click Next.
- On the Resource Adapter Selection page, select IMS TM Resource Adapter (10.5.0).
- On the Connector Import page, select WebSphere® Application Server v7.0, and
click Next.
- On the Adapter Style page, select Outbound, and click Next.
- On the Scenario Selection page, select IMS MFS-based
applications, and click Next.
- On the Discovery Configuration page, click Add
- Browse to locate your MFS file, and click Open, and clickNext.
- On the Object Discovery and Selection page, select the
objects to be imported. On the left panel, expand the object nodes
to select subcategories, and once you have made your select, click
the Add icon in the middle. Your selections appear in the right panel.
- On the Configuration Parameters page, select an object
discovered from the query.
CAUTION:
Do not
click Okay until you have selected properties
for each of the objects that you want to add.
- On the Object Discovery and Selection page, the objects
that you configured in the previous step appear in the Objects to be imported right panel. To import these projects
using the express or quick way, follow these steps: To import these
objects, This is an express way to add the three conversational properties
to your project, isConvEnded, convID, and UseConvID.
- Express® route to
importing objects:
- Click , Enable conversational support
for the imported objects, on the top menu bar.
- This process automatically adds the three MFS properties required
for conversational transactions: convID, useConvID and convEnded to your method.
- Click Next.
- Manual route to importing objects:
- Click , Select any InteractionSpec
or ConnectionSpec properties as your method input parameter or fields
in the method output wrapper bean, on the top menu bar.
- On the Expose Input or Output Parameters page, select the properties
that you want to include in your method.
Note: If you clicked
,
Enable conversational support for the imported
objects before clicking this manual process,
convID,
useConvID and
convEnded have
been preselected.
- Click Next.
- On the J2C Bean Creation and Deployment Configuration page,
type a name in the Java™ Project name field, and click New to create a Java Project.
- Type the package name in the Package name field, the interface name in the Interface name field, and the implementation name in the Implementation
name field.
- Select Managed Connection or Non-managed Connection, and provide your connection information.
- For Managed Connection, provide JNDI Name in the JNDI Lookup Name field.
- For Non-managed Connection, provide the following required
information:
- host name
- port number
- Data store name
What to do next
The following artifacts are created by this process:
- A J2C Bean (interface and implementation)
- Implementation class code that includes the isConvEnded, convID, and UseConvID parameters:
package sample.mfs;
import javax.resource.ResourceException;
import javax.resource.cci.Connection;
import javax.resource.cci.Interaction;
import javax.resource.cci.ConnectionFactory;
import javax.resource.cci.ConnectionSpec;
import javax.resource.cci.InteractionSpec;
import javax.resource.cci.Record;
import javax.resource.cci.ResourceAdapterMetaData;
/**
* @j2c.connectionFactory jndi-name="MyJNDI"
* @j2c.connectionSpec class="com.ibm.connector2.ims.ico.IMSConnectionSpec"
* @generated
*/
public class CustomerImpl implements sample.mfs.Customer {
private ConnectionSpec typeLevelConnectionSpec;
private InteractionSpec invokedInteractionSpec;
private InteractionSpec interactionSpec;
private ConnectionSpec connectionSpec;
private Connection connection;
private ConnectionFactory connectionFactory;
/**
* @j2c.interactionSpec class="com.ibm.connector2.ims.ico.IMSInteractionSpec"
* @j2c.interactionSpec-property name="imsRequestType" value="3"
* @j2c.interactionSpec-property name="mapName" value="IVTCBMO2"
* @j2c.interactionSpec-property name="convID" argumentBinding="convID"
* @j2c.interactionSpec-property name="convEnded" argumentBinding="convEnded"
* @j2c.interactionSpec-property name="useConvID" argumentBinding="useConvID"
* @j2c.interactionSpec-returnProperty name="convID" outputBinding="convID"
* @j2c.interactionSpec-returnProperty name="convEnded" outputBinding="convEnded"
* @j2c.interactionSpec-returnProperty name="useConvID" outputBinding="useConvID"
* @generated
*/
- A Wrapper bean for each operation to wrap the original method
output type and the output types selected from InteractionSpec The
wrapper bean name is constructed from methodName + output data type
name + “Wrapper.”
package sample.mfs;
import com.ibm.ims.mfs.emd.databinding.IVTCBMO2;
/**
* @generated
*/
public class IVTCBMI1IVTCBMO2Wrapper {
private IVTCBMO2 IVTCBMO2response;
private boolean useConvID;
private boolean convEnded;
private java.lang.String convID;
Note: One wrapper class
is created for each operation you create.
- The list of Data binding files for method inputs and output types.