Hello,
I am using a class that has an RMI call in it. When I attempt to debug everything executes as expected until the object is returned. When the contract object returns, I recieve an error like this:
java.io.InvalidClassException: com.dn.lca.dataobjects.Contract; local class incompatible: stream classdesc serialVersionUID = -7475071795924394977, local class serialVersionUID = -3554625892121869643>
org.springframework.remoting.RemoteConnectFailureException: Cannot connect to remote service [rmi://localhost:1199/RemoteService]; nested exception is java.rmi.UnmarshalException: error unmarshalling return; nested exception is:
java.io.InvalidClassException: com.dn.lca.dataobjects.Contract; local class incompatible: stream classdesc serialVersionUID = -7475071795924394977, local class serialVersionUID = -3554625892121869643
Caused by:
java.rmi.UnmarshalException: error unmarshalling return; nested exception is:
java.io.InvalidClassException: com.rn.mca.dataobjects.Contract; local class incompatible: stream classdesc serialVersionUID = -7475071795924394977, local class serialVersionUID = -3554625892121869643
at sun.rmi.server.UnicastRef.invoke(Unknown Source)
at org.springframework.remoting.rmi.RmiInvocationWrapper_Stub.invoke(Unknown Source)
at org.springframework.remoting.rmi.RmiClientInterceptor.doInvoke(RmiClientInterceptor.java:400)
at org.springframework.remoting.rmi.RmiClientInterceptor.doInvoke(RmiClientInterceptor.java:344)
at org.springframework.remoting.rmi.RmiClientInterceptor.invoke(RmiClientInterceptor.java:259)
at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:176)
at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:210)
at $Proxy4.generateRenewalContract(Unknown Source)
at com.rn.mca.client.service.RenewalGenServiceImpl.generateRenewalContract(RenewalGenServiceImpl.java:52)
at com.rn.mca.ui.wizard.WizardController$7.run(WizardController.java:610)
at java.lang.Thread.run(Unknown Source)
Caused by: java.io.InvalidClassException: com.rn.mca.dataobjects.Contract; local class incompatible: stream classdesc serialVersionUID = -7475071795924394977, local class serialVersionUID = -3554625892121869643
at java.io.ObjectStreamClass.initNonProxy(Unknown Source)
at java.io.ObjectInputStream.readNonProxyDesc(Unknown Source)
at java.io.ObjectInputStream.readClassDesc(Unknown Source)
at java.io.ObjectInputStream.readNonProxyDesc(Unknown Source)
at java.io.ObjectInputStream.readClassDesc(Unknown Source)
at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source)
at java.io.ObjectInputStream.readObject0(Unknown Source)
at java.io.ObjectInputStream.readObject(Unknown Source)
at sun.rmi.server.UnicastRef.unmarshalValue(Unknown Source)
... 11 more
I have checked my jar files and they all have the same time stamp. I have used a decompiler to check the compiled classes as well with the same findings. I am currently using eclipse europa to debug this issue and haven't been able to come up with anything that makes much sense. I have heard about the serialver tool but I have been having
alot of trouble using it. Are there any other alternatives that provide a entry level guy a more faster way to determine what versions the compiler is seeing?
Thanks for your help!!