1 Reply Latest reply on Oct 2, 2006 2:45 PM by Andrew Rubinger

    Embedded EJB3 Proxy and EJB3-RC9 server

    darren hartford Expert

      Hi all,
      I'm trying to use the embedded EJB3 jars in an application that will require both local/embed server access as well as remote server access.

      Using Embed RC9-Alpha and a 4.0.4.GA patched jbossas with EJB3-RC9 I keep getting the following error on the client side when trying to communicate with the server:

      javax.naming.CommunicationException [Root exception is java.io.InvalidClassException: org.jboss.ejb3.stateless.StatelessLocalProxy; local class incompatible: stream classdesc serialVersionUID = -3241008127518089831, local class serialVersionUID = -3824844512835539077]

      Using the following contexts for testing:

       private static Hashtable getLocalContextProperties()
       Hashtable props = new Hashtable();
       props.put("java.naming.factory.initial", "org.jnp.interfaces.LocalOnlyContextFactory");
       props.put("java.naming.factory.url.pkgs", "org.jboss.naming:org.jnp.interfaces");
       return props;
       private static Hashtable getRemoteContextProperties(){
       Hashtable env = new Hashtable();
       env.put("java.naming.factory.initial", "org.jnp.interfaces.NamingContextFactory");
       env.put("java.naming.provider.url", "my.remote.server:1099");
       env.put("java.naming.factory.url.pkgs", "org.jnp.interfaces");
       return env;

      If I use embed, is there something special I need to do to also use remote ejb3?