0 Replies Latest reply on Jun 27, 2002 10:37 PM by Tim Bauer

    Error deploying my ejb-jar in 3.0

    Tim Bauer Novice

      Dear Friends,

      With all the great advice in these forums I'm gettting very close to deploying my 2.4.4 ear in 3.0. One last problem (I hope).

      I'm receiving an error:

      18:21:14,710 ERROR [EjbModule] Initialization failed
      org.jboss.deployment.DeploymentException: expected only one datasource tag

      jboss.deployment.DeploymentException
      18:21:14,734 ERROR [MainDeployer] could not create deployment: njar:file:/Applications/jboss-3.0.0/server/default/tmp/deploy/server/default/deploy/webstaffer.ear/60.webstaffer.ear^/webstaffer-ejb.jar
      org.jboss.deployment.DeploymentException: error in create of EjbModule: njar:file:/Applications/jboss-3.0.0/server/default/tmp/deploy/server/default/deploy/webstaffer.ear/60.webstaffer.ear^/webstaffer-ejb.jar; - nested throwable: (org.jboss.deployment.DeploymentException: expected only one datasource tag)

      I'm pretty sure I know who/what the culprit is, but not sure how to fix it...

      In my ejb-jar.xml file I have a sesion bean that I use that does direct sql access to the database via the container datasource. It is defined as such in the ejb-jar.xml file:


      The SQLFinder Utility Bean
      <ejb-name>ICSRegSQLFinderUtilsEJB</ejb-name>
      com.icshealth.ejb.api.ICSRegSQLFinderUtilsHome
      com.icshealth.ejb.api.ICSRegSQLFinderUtils
      <ejb-class>com.icshealth.ejb.session.ICSRegSQLFinderUtilsEJB</ejb-class>
      <session-type>Stateless</session-type>
      <transaction-type>Bean</transaction-type>
      <resource-ref>
      <res-ref-name>jdbc/ICSHealthRegDS</res-ref-name>
      <res-type>javax.sql.DataSource</res-type>
      <res-auth>Container</res-auth>
      </resource-ref>


      In my jboss.xml file, the sesion bean is defined as such:


      <ejb-name>ICSRegSQLFinderUtilsEJB</ejb-name>
      <jndi-name>icsReg/ICSRegSQLFinderUtils</jndi-name>
      <resource-ref>
      <res-ref-name>jdbc/ICSHealthRegDS</res-ref-name>
      <resource-name>jdbc/ICSRegDS</resource-name>
      </resource-ref>


      jdbc/ICSregDS is the name of the datasource (service) that I defined in my /server/default/deploy/mysql-service.xml file.

      Any clues as to why I'm getting the deployment error??

      Thanks in advance for the help....