web server - Borland Technical Publications

web server - Borland Technical Publications web server - Borland Technical Publications

techpubs.borland.com
from techpubs.borland.com More from this publisher
12.11.2014 Views

Application development overview Deployment Descriptors for Application Components The application component deployment descriptors need to specify connection factory information for the Resource Adapter which the component will use. Appropriate entries are required in: 1 In the component's Sun standard deployment descriptor. For example, in ejbjar.xml, the following is required: ■ res-ref-name: shme/shmeAdapter ■ res-type: javax.resource.cci.ConnectionFactory ■ res-auth: Application | Container 2 In addition, any version specific entries can be included. For example, EJB 2.0's ressharing-scope: ■ res-sharing-scope: Shareable | Unshareable 3 In the component's Borland-specific deployment descriptor. For example, in ejbborland.xml, the following is required: ■ res-ref-name: shme/shmeAdapter ■ res-type: javax.resource.cci.ConnectionFactory 4 In addition, any version specific entries can be included. For example, EJB 1.1's cmp-resource: ■ cmp-resource: True | False The following details example deployment descriptors for two EJBs - the first written to the EJB 2.0 spec, the second written to the EJB 1.1 spec. Both the standard and Borland-specific deployment descriptors are shown. In these examples, a hypothetical Resource Adapter is referenced. EJB 2.x example ejb-jar.xml deployment descriptor This example uses container-managed persistence SHME Integration Jar Interface EJB for shmeAdapter Class /shme/test/ shmeAdapter/schema/Customer customer_bean shme/customer_bean com.shme.test.shmeAdapter.schema.CustomerHome com.shme.test.shmeAdapter.schema.CustomerRemote com.shme.test.shmeAdapter.schema.CustomerBean Stateful Container SHME Repository URL for Connector configuration repositoryUrl java.lang.String s_repository://S_APP01 Chapter 27: Using VisiConnect 275

Application development overview Location of Resource Adapter Configuration within the SHME Repository configurationUrl java.lang.String /shme/client Reference to SHME Resource Adapter shme/shmeAdapter com.shme.shmeAdapter.ConnectionFactory Container Shareable customer_bean Remote s_exec_customer_query Required This corresponds to the ejb-jar.xml above. shme/customer_bean shme/customer_bean shme/shmeAdapter eis/shmeAdapter 276 BES Developer’s Guide

Application development overview<br />

<br />

<br />

Location of Resource Adapter Configuration within<br />

the SHME Repository<br />

configurationUrl<br />

java.lang.String<br />

/shme/client<br />

<br />

<br />

Reference to SHME Resource Adapter<br />

shme/shmeAdapter<br />

com.shme.shmeAdapter.ConnectionFactory<br />

Container<br />

Shareable<br />

<br />

<br />

<br />

<br />

<br />

<br />

customer_bean<br />

Remote<br />

s_exec_customer_query<br />

<br />

<br />

Required<br />

<br />

<br />

<br />

This corresponds to the ejb-jar.xml above.<br />

<br />

<br />

<br />

<br />

<br />

shme/customer_bean<br />

shme/customer_bean<br />

<br />

shme/shmeAdapter<br />

eis/shmeAdapter<br />

<br />

<br />

<br />

<br />

276 BES Developer’s Guide

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!