| Use WebSphere bindings to define resource reference names |
|
WebLogic-specific deployment descriptors, weblogic.xml or weblogic-ejb-jar.xml, might contain resource references. These references map the EJB reference to the JNDI name, as demonstrated in the example. This rule detects the resource references. The automated fix will migrate the references to the WebSphere traditional and Liberty bindings file. Example of weblogic.xml constructs
<weblogic-web-app>
<reference-descriptor> <resource-description> <res-ref-name>ejb/myBean</res-ref-name> <jndi-name>ejb/myBean</jndi-name> </resource-description> </reference-descriptor> The JNDI name is saved in the bindings file, and the reference is correlated to the entry in the web.xml file. Example of weblogic-ejb-jar.xml constructs
<weblogic-ejb-jar>
<weblogic-enterprise-bean> <reference-descriptor> <resource-description> <res-ref-name>ejb/myBean</res-ref-name> <jndi-name>ejb/myBean</jndi-name> </resource-description> |