12.11.2014 Views

web server - Borland Technical Publications

web server - Borland Technical Publications

web server - Borland Technical Publications

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Application development overview<br />

Deployment Descriptors for Application Components<br />

The application component deployment descriptors need to specify connection factory<br />

information for the Resource Adapter which the component will use. Appropriate<br />

entries are required in:<br />

1 In the component's Sun standard deployment descriptor. For example, in ejbjar.xml,<br />

the following is required:<br />

■<br />

res-ref-name: shme/shmeAdapter<br />

■<br />

res-type: javax.resource.cci.ConnectionFactory<br />

■<br />

res-auth: Application | Container<br />

2 In addition, any version specific entries can be included. For example, EJB 2.0's ressharing-scope:<br />

■<br />

res-sharing-scope: Shareable | Unshareable<br />

3 In the component's <strong>Borland</strong>-specific deployment descriptor. For example, in ejbborland.xml,<br />

the following is required:<br />

■<br />

res-ref-name: shme/shmeAdapter<br />

■<br />

res-type: javax.resource.cci.ConnectionFactory<br />

4 In addition, any version specific entries can be included. For example, EJB 1.1's<br />

cmp-resource:<br />

■<br />

cmp-resource: True | False<br />

The following details example deployment descriptors for two EJBs - the first written to<br />

the EJB 2.0 spec, the second written to the EJB 1.1 spec. Both the standard and<br />

<strong>Borland</strong>-specific deployment descriptors are shown. In these examples, a hypothetical<br />

Resource Adapter is referenced.<br />

EJB 2.x example<br />

ejb-jar.xml deployment descriptor<br />

This example uses container-managed persistence<br />

<br />

<br />

<br />

SHME Integration Jar<br />

<br />

<br />

Interface EJB for shmeAdapter Class /shme/test/<br />

shmeAdapter/schema/Customer<br />

customer_bean<br />

shme/customer_bean<br />

com.shme.test.shmeAdapter.schema.CustomerHome<br />

com.shme.test.shmeAdapter.schema.CustomerRemote<br />

com.shme.test.shmeAdapter.schema.CustomerBean<br />

Stateful<br />

Container<br />

<br />

SHME Repository URL for Connector configuration<br />

repositoryUrl<br />

java.lang.String<br />

s_repository://S_APP01<br />

Chapter 27: Using VisiConnect 275

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

Saved successfully!

Ooh no, something went wrong!