-
1. Re: Problem with deployment of EJB
robinpaul Dec 17, 2001 7:23 AM (in response to nitinrustagi)Hi Nitin
The problem might be that your bean B might be calling some methods on bean A. Try making a single jar file containg both the beans with a common ejb-jar.xml and a jboss.xml.
for example (in ejb-jar.xml)
<?xml version="1.0" encoding="Cp1252"?>
<!DOCTYPE ejb-jar PUBLIC '-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 1.1//EN' 'http://java.sun.com/j2ee/dtds/ejb-jar_1_1.dtd'>
<ejb-jar>
<enterprise-beans>
<ejb-name>EffWorkControllerBean</ejb-name>
jpraxisserver.bizservices.uplift.EffWorkControllerHome
jpraxisserver.bizservices.uplift.EffWorkController
<ejb-class>jpraxisserver.bizservices.uplift.EffWorkControllerBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
<resource-ref>
<res-ref-name>jdbc/oraclePool</res-ref-name>
<res-type>javax.sql.DataSource</res-type>
<res-auth>Container</res-auth>
</resource-ref>
<ejb-name>FlightControllerBean</ejb-name>
jpraxisserver.bizservices.uplift.FlightControllerHome
jpraxisserver.bizservices.uplift.FlightController
<ejb-class>jpraxisserver.bizservices.uplift.FlightControllerBean</ejb-class>
<session-type>Stateless</session-type>
<transaction-type>Container</transaction-type>
<resource-ref>
<res-ref-name>jdbc/oraclePool</res-ref-name>
<res-type>javax.sql.DataSource</res-type>
<res-auth>Container</res-auth>
</resource-ref>
</enterprise-beans>
<assembly-descriptor>
<container-transaction>
<ejb-name>EffWorkControllerBean</ejb-name>
<method-intf>Remote</method-intf>
<method-name>getData</method-name>
<trans-attribute>NotSupported</trans-attribute>
</container-transaction>
<container-transaction>
<ejb-name>FlightControllerBean</ejb-name>
<method-name>*</method-name>
<trans-attribute>Required</trans-attribute>
</container-transaction>
</assembly-descriptor>
</ejb-jar>
Regarding DefaultDS, you will have to map your jndi name of the datasource to point to DefaultDS
For example ( in jboss.xml )
<?xml version="1.0" encoding="UTF-8"?>
<enterprise-beans>
<ejb-name>FlightScheduleControllerBean</ejb-name>
<jndi-name>jpraxisserver.bizservices.uplift.masters.flightschedulecontroller.FlightScheduleController</jndi-name>
<reference-descriptor>
<resource-description>
<res-ref-name>jdbc/oraclePool</res-ref-name>
<jndi-name>java:/DefaultDS</jndi-name>
</resource-description>
</reference-descriptor>
</enterprise-beans>
Robin Paul -
2. Re: Problem with deployment of EJB
nitinrustagi Dec 18, 2001 12:04 AM (in response to nitinrustagi)Hi Robin,
thanks for the reply.
A.jar contains bean for application A and B.jar for application B. so A doesn't refer to any method of B or vice versa. But when jboss tries to deploy B.jar it shows error of A. because A contains some error and its deployed first. Also none of A and B uses DefaultDS so why it shows DefaultDS not bound.
*** When DefaultDS Pool(which is orginally there in Jboss) start up server show-
[DefaultDS] java.lang.ClassNotFoundException: org.jboss.pool.jdbc.xa.wrapper.XAD
[DefaultDS] at java.lang.Class.forName(Class.java:120)(ClassLoader.java:313)
[DefaultDS] at org.jboss.jdbc.XADataSourceLoader.startService(XADataSourceLo
ader.java:270)
[DefaultDS] at org.jboss.util.ServiceMBeanSupport.start(ServiceMBeanSupport.
java:93)
[DefaultDS] at java.lang.reflect.Method.invoke(Native Method)
[DefaultDS] at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl
.java:1628)
[DefaultDS] at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl
[DefaultDS] at java.lang.reflect.Method.invoke(Native Method)trol.java:97)
[DefaultDS] at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl
.java:1628)
[DefaultDS] at com.sun.management.jmx.MBeanServerImpl.invoke(MBeanServerImpl
.java:1523)
[DefaultDS] at org.jboss.Main.(Main.java:203)
[DefaultDS] at org.jboss.Main.main(Main.java:103)rivileged(Native Method)
**********
Is in Jboss two or application can be deploy If yes then how to differentiate between them. -
3. Re: Problem with deployment of EJB
robinpaul Dec 18, 2001 12:52 AM (in response to nitinrustagi)Hi nitin
Give me a copy of your server log after it has completed its startup procedures and also your ejb-jar.xml and jboss.xml