I figured it out. I had it deployed in application-deployments instead of
the applications directory.

Maybe Orion should prevent this by disallowing deployments into a directory
other than the one configured as application-directory in server.xml?



                                                                                       
                                         
                    [EMAIL PROTECTED]                                                  
                                         
                    Sent by:                          To:     Orion-Interest 
<[EMAIL PROTECTED]>                   
                    owner-orion-interest@orion        cc:                              
                                         
                    server.com                        Subject:     
IllegalArgumentException                                     
                                                                                       
                                         
                                                                                       
                                         
                    08/10/00 04:03 PM                                                  
                                         
                                                                                       
                                         
                                                                                       
                                         




Does anybody know what causes this exception when running a client
application that is trying to connect to an EJB?

C:\orion\application-deployments\demo\account>java -classpath .;c:
\orion\orion.jar;c:\orion\ejb.jar;c:\orion\jndi.jar AccountClient
Getting initial context
Looking up home
Class: __Proxy1
Creating bean
Caught an exception.
java.lang.IllegalArgumentException: object is not an instance of declaring
class

        at com.evermind.server.rmi.a8.invokeMethod(Compiled Code)
        at com.evermind.server.rmi.a_.invoke(JAX)
        at com.evermind.server.rmi.a0.invoke(Compiled Code)
        at __Proxy1.create(Unknown Source)
        at AccountClient.main(Compiled Code)


application.xml:

<?xml version="1.0"?>
<!DOCTYPE application PUBLIC "-//Sun Microsystems, Inc.//DTD J2EE
Application 1.2//EN" "http://java.sun.com/j2ee/dtds/application_1_2.dtd">

<application>
     <display-name>Demo</display-name>
     <module>
          <ejb>account</ejb>
     </module>
</application>


ejb-jar.xml:

<?xml version="1.0"?>
<!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise
JavaBeans 1.2//EN" "http://java.sun.com/j2ee/dtds/ejb-jar_1_2.dtd">

<ejb-jar>
     <display-name>Demo</display-name>
     <description>Demo BMP entity EJB example</description>
     <enterprise-beans>
          <entity>
               <description>Account EJB</description>
               <ejb-name>MyAccount</ejb-name>
               <home>AccountHome</home>
               <remote>Account</remote>
               <ejb-class>AccountEJB</ejb-class>
               <primkey-class>java.lang.String</primkey-class>
               <reentrant>False</reentrant>
               <persistence-type>Bean</persistence-type>
          </entity>
     </enterprise-beans>
     <assembly-descriptor>
     </assembly-descriptor>
</ejb-jar>


application-client.xml:

<?xml version="1.0"?>
<!DOCTYPE application-client PUBLIC "-//Sun Microsystems, Inc.//DTD J2EE
Application Client 1.2//EN"
"http://java.sun.com/j2ee/dtds/application-client_1_2.dtd">

<application-client>
     <ejb-ref>
          <ejb-ref-name>MyAccount</ejb-ref-name>
          <ejb-ref-type>Entity</ejb-ref-type>
          <home>AccountHome</home>
          <remote>Account</remote>
     </ejb-ref>
</application-client>











Reply via email to