I have an application which was running on JBoss4(with Hibernate for persistence) and had some data serialized ( saved in database ).
Now, we migrated the application to JBoss6 with the serialized data retained. However, when reading one of the entities from this data, I am facing InvalidClassException.
The exception is similar to
java.io.InvalidClassException: org.hibernate.proxy.pojo.javassist.SerializableProxy; local class incompatible: stream classdesc serialVersionUID = <some number> , local class serialVersionUID = <some diff number>
I understand that this error can occur in case of serializing entities with a class and trying to deserialize it back with the same class(but with different serialversion uuid). The entity that I am trying to read has compatible changes. So, I believe there should not be any issue with my entity.
And, the exception also does not complain about my entity but rather complaining about the Hibernate class SerializableProxy being different.
Any ideas on what is wrong here and how I can resolve this? Is this because the Hibernate being using with JBoss6 is different from the Hibernate version of JBoss4 which i used to persist these entities?