3 Replies Latest reply on Dec 28, 2004 5:31 PM by Scott Stark

    InvalidClassException on jboss 3.2.5, but not on 3.0.6

    Ken Roberts Newbie

      Hi folks.

      I'm doing a JNDI lookup over HTTP from an applet. It works fine on jboss 3.0.6, but not on 3.2.5. I'm not sure about 4.0, because none of our customer base uses 4.0 yet.

      I have an absolutely stock (from the pay docs) jndi.properites file for the server-side stuff, exactly as follows:
      java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
      java.naming.provider.url=jnp://localhost:1099

      On the applet, I followed the directions for the most part, and set up the following variables:
      applet.naming.url.path=/invoker/JNDIFactory
      java.naming.factory.initial=org.jboss.naming.HttpNamingContextFactory

      The applet.naming.url.path value is in hopes of getting around the firewall/nat issue. Instead of using standard values I create a new URL from the applet codebase and this string, which gives me the correct hostname and port no matter what network I hit from. That's the theory, but it's still untested through an actual NAT firewall.

      Another point of interest is that I'm using a jboss-app.xml exactly as specified elsewhere on this forum to tell the class loader to use this war rather than other ones, because one of our requirements is that the application not interfere with older versions of the same applet/servlet/bean.

      Can somebody tell me where to start on this? Thanks.

      Here's the exception:

      javax.naming.NamingException: Failed to retrieve Naming interface [Root exception is java.io.InvalidClassException: org.jboss.invocation.InvokerInterceptor; local class incompatible: stream classdesc serialVersionUID = 2548120545997920357, local class serialVersionUID = -5331993782953462504]
      at org.jboss.naming.HttpNamingContextFactory.getInitialContext(HttpNamingContextFactory.java:72)
      at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:662)
      at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243)
      at javax.naming.InitialContext.init(InitialContext.java:219)
      at javax.naming.InitialContext.(InitialContext.java:195)
      at com.nineci.applet.HelloBeanApplet.start(HelloBeanApplet.java:31)
      at sun.applet.AppletPanel.run(AppletPanel.java:377)
      at java.lang.Thread.run(Thread.java:534)
      Caused by: java.io.InvalidClassException: org.jboss.invocation.InvokerInterceptor; local class incompatible: stream classdesc serialVersionUID = 2548120545997920357, local class serialVersionUID = -5331993782953462504
      at java.io.ObjectStreamClass.initNonProxy(ObjectStreamClass.java:463)
      at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1521)
      at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1435)
      at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1626)
      at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274)
      at java.io.ObjectInputStream.skipCustomData(ObjectInputStream.java:1810)
      at java.io.ObjectInputStream.readExternalData(ObjectInputStream.java:1698)
      at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1644)
      at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274)
      at java.io.ObjectInputStream.readObject(ObjectInputStream.java:324)
      at org.jboss.proxy.Interceptor.readExternal(Interceptor.java:109)
      at java.io.ObjectInputStream.readExternalData(ObjectInputStream.java:1686)
      at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1644)
      at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274)
      at java.io.ObjectInputStream.skipCustomData(ObjectInputStream.java:1810)
      at java.io.ObjectInputStream.readExternalData(ObjectInputStream.java:1698)
      at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1644)
      at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274)
      at java.io.ObjectInputStream.readObject(ObjectInputStream.java:324)
      at org.jboss.proxy.ClientContainer.readExternal(ClientContainer.java:104)
      at java.io.ObjectInputStream.readExternalData(ObjectInputStream.java:1686)
      at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1644)
      at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274)
      at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1845)
      at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1769)
      at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1646)
      at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1274)
      at java.io.ObjectInputStream.readObject(ObjectInputStream.java:324)
      at org.jboss.invocation.MarshalledValue.get(MarshalledValue.java:78)
      at org.jboss.naming.HttpNamingContextFactory.getNamingServer(HttpNamingContextFactory.java:117)
      at org.jboss.naming.HttpNamingContextFactory.getInitialContext(HttpNamingContextFactory.java:68)