Hi all,

I am new to Jboss. I try to access a postgresql db through a stateless session bean. 
However the doesn't get deployed in JBoss. It gives the following error message when I 
try to deploy.

I think it has to do something with my datasource, because I managed to deploy an 
oridinary HelloWorld session bean. 

Bean   : DatabaseApiEJB
Section: 22.2
Warning: The Bean Provider must specify the fully-qualified name of the Java class 
that implements the enterprise bean's business methods in the <ejb-class> element.
Info   : Class not found on 'vub.starlab.ds.ontobase.ejb.DatabaseApiEJB': Unexpected 
error during load of: vub.starlab.ds.ontobase.ejb.DatabaseApiEJB, 
msg=vub/starlab/ds/ontobase/ejb/DatabaseApiEJB (Bad magic number)

13:42:42,698 ERROR [MainDeployer] could not create deployment: 
file:/usr/share/jboss-3.2.3/server/default/deploy/ontobaseapi.jar
org.jboss.deployment.DeploymentException: Verification of Enterprise Beans failed, see 
above for error messages.
        at org.jboss.ejb.EJBDeployer.create(EJBDeployer.java:491)
        at org.jboss.deployment.MainDeployer.create(MainDeployer.java:786)
        at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:641)
        at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:605)
        at sun.reflect.GeneratedMethodAccessor18.invoke(Unknown Source)
        at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
        at java.lang.reflect.Method.invoke(Method.java:324)
        at 
org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
        at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:546)
        at org.jboss.mx.util.MBeanProxyExt.invoke(MBeanProxyExt.java:177)
        at $Proxy6.deploy(Unknown Source)
        at 
org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:302)
        at 
org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:476)
        at 
org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.doScan(AbstractDeploymentScanner.java:201)
        at 
org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.loop(AbstractDeploymentScanner.java:212)
        at 
org.jboss.deployment.scanner.AbstractDeploymentScanner$ScannerThread.run(AbstractDeploymentScanner.java:191)

**********************************************
In the META-INF of my ontobaseapi.jar I have the ejb-jar.xml and jboss.xml. 

excerpt from ejb-jar.xml :(not complete)
<ejb-jar>
 <enterprise-beans>
        
          
          <ejb-name>DatabaseApiEJB</ejb-name>
          vub.starlab.ds.ontobase.ejb.DatabaseApiEJBHomeRemote
          vub.starlab.ds.ontobase.ejb.DatabaseApiEJBRemote
          <ejb-class>vub.starlab.ds.ontobase.ejb.DatabaseApiEJB</ejb-class>
          <session-type>Stateless</session-type>
          <transaction-type>Container</transaction-type>
          <security-identity><use-caller-identity/></security-identity>
          <resource-ref>
            DataSource for the lexon database
            <res-ref-name>jdbc/ontobaseDB</res-ref-name>
            <res-type>javax.sql.DataSource</res-type>
            <res-auth>Container</res-auth>
          </resource-ref>
        
 </enterprise-beans>

excerpt from jboss.xml:


   <enterprise-beans>
      
         <ejb-name>DatabaseApiEJB</ejb-name>
         <jndi-name>DatabaseApiEJBHomeRemote</jndi-name>
         <resource-ref>
            <res-ref-name>jdbc/ontobaseDB</res-ref-name>
            <jndi-name>java:/LexonbaseDS</jndi-name>
         </resource-ref>
      
   </enterprise-beans>


My postgresql datasource is in the deploy directory:



   <local-tx-datasource>

      <jndi-name>LexonbaseDS</jndi-name>
      <connection-url>jdbc:postgresql://134.184.65.6/lexonbase</connection-url>
      <driver-class>org.postgresql.Driver</driver-class>
      <user-name>jan</user-name>
      3jrk!
      <min-pool-size>5</min-pool-size>
      <max-pool-size>20</max-pool-size>

    </local-tx-datasource>



I also put the  postgres-jdbc2-service.xml in the jms directory, under the deploy 
directory and I have put changed standardjbosscmp-jdbc.xml where necessary.

Please help me, I cannot find the error myself! I am really getting desparate!! -(

Any hepl is welcome, thx in advance!!

Jan

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3837365#3837365

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3837365


-------------------------------------------------------
This SF.Net email is sponsored by the new InstallShield X.
>From Windows to Linux, servers to mobile, InstallShield X is the one
installation-authoring solution that does it all. Learn more and
evaluate today! http://www.installshield.com/Dev2Dev/0504
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to