Corporation Video Gaming Accessories User Manual

Configuring Multiple Adapters
3-4 Oracle Application Server Adapters for IMS/DB User's Guide
3.
Create a Connection object using this ConnectionFactory. Specify the
interaction properties using an AttuInteractionSpec object. The
AttuInteractionSpec object has the following format:
AttuInteractionSpec(java.lang.String name, int verb, int timeOut)
The following table describes the properties that can be specified:
The following is an InteractionSpec sample:
AttuInteractionSpec iSpeq = new AttuInteractionSpec("query",
javax.resource.cci.InteractionSpec.SYNC_RECEIVE, 60);
javax.resource.cci.RecordFactory rf = new AttuRecordFactory(con,
mcf.getLogger());
javax.resource.cci.MappedRecord queryRecord = rf.createMappedRecord("query"),
queryRecord.put("##text", "select * from disam:nation");
javax.resource.cci.Record oRec = interaction.execute(iSpec, queryRecord);
4. Invoke the execute method on the interaction to initiate a call to the EIS. Pass
any data for the interaction as input and output records.
5. Once the interactions have been processed, close the Interaction and
Connection objects.
Configuring Multiple Adapters
Each J2CA 1.5 IMS/DB adapter requires an entry in the oc4j-ra.xml file as
described in "Configuring the J2CA 1.5 IMS/DB Adapter" on page 3-2.
Updating Configuration Information
You can change the configuration settings for a resource adapter by editing the
relevant connector-factory entry in the oc4j-ra.xml file. For these changes to
take effect, you need to stop and restart Oracle Application Server.
Table 3–2 Interaction Spec Properties
Property Description
name Specifies the interaction name.
verb Specifies the mode for the interaction: SYNC_SEND, SYNC_
SEND_RECEIVE, or SYNC_RECEIVE.
timeOut Specifies the time (in milliseconds) to wait for an EIS to
run the specified interaction.
See Also: Oracle Application Server Adapter Concepts Guide