Sun Java System Application Server Enterprise Edition 8.1 2005Q2 Upgrade and Migration Guide

Migrating Deployment Descriptors

There are two types of deployment descriptors, namely, Standard Deployment Descriptors and Runtime Deployment Descriptors. Standard deployment descriptors are portable across J2EE platform versions and vendors and does not require any modifications. Currently, there are exceptions due to standards interpretation. The following table lists such deployment descriptors.

Source Deployment Descriptor  

Target Deployment Descriptor  

ejb-jar.xml - 1.1

ejb-jar.xml - 2.0

web.xml

web.xml

application.xml

application.xml

The J2EE standard deployment descriptors ejb-jar.xml, web.xml and application.xml are not modified significantly. However, the ejb-jar.xml deployment descriptor is modified to make it compliant with EJB 2.0 specification in order to make the application deployable on Sun Java System Application Server 8.1.

Runtime deployment descriptors are vendor and product specific and are not portable across application servers due to difference in their format. Hence, deployment descriptors require migration. This section describes how you can manually create the runtime deployment descriptors and migrate relevant information.

The following table summarizes the deployment descriptor migration mapping.

Source Deployment Descriptor  

Target Deployment Descriptor  

ias-ejb-jar.xml

sun-ejb-jar.xml

<bean-name>-ias-cmp.xml

sun-cmp-mappings.xml

ias-web.xml

sun-web.xml

The standard deployment descriptors of Application Server 6.x needs modification when moving to Application Server 8.1 because of non-conformance with the DTDs.

A majority of the information required for creating sun-ejb-jar.xml and sun-web.xml comes from ias-ejb-jar.xml and ias-web.xml respectively. However, there is some information that is required and extracted from the home interface (java file) of the CMP entity bean, in case the sun-ejb-jar.xml being migrated declares one. This is required to build the <query-filter> construct inside the sun-ejb-jar.xml, which requires information from inside the home interface of that CMP entity bean. If the source file is not present during the migration time, the <query-filter> construct is created, but with missing information (which manifests itself in the form of REPLACE ME phrases in the migrated sun-ejb-jar.xml).

Additionally, if the ias-ejb-jar.xml contains a <message-driven> element, then information from inside this element is picked up and used to fill up information inside both ejb-jar.xml and sun-ejb-jar.xml. Also, inside the <message-driven> element of ias-ejb-jar.xml, there is an element <destination-name>, which holds the JNDI name of the topic or queue to which the MDB listens. In Application Server 6.5, the naming convention for this jndi name is cn=<SOME_NAME>. Since a JMS Topic or Queue with this name is not deployable on Application Server, the application server changes this to <SOME_NAME>, and inserts this information in the sun-ejb-jar.xml. This change must be reflected for all valid input files, namely, all .java, .jsp and .xml files. Hence, this JNDI name change is propagated across the application, and if some source files that contain reference to this jndi-name are unavailable, the administrator must make the changes manually so that the application becomes deployable.