Possible Duplicate:
Java serialization - java.io.InvalidClassException local class incompatible
I have written a program that stores an Object (say A) as a file (say F). So when you run the program later you can load it and use its contents. So far so good. But today i decided to make a some changes to class A. I made a backup of the original (called it Aold). But the thing i realized too late, is that the information stored on F is very valuable to me. And ofcourse when i tried to load it as a new Object A it failed. Next i wrote a converter, that takes a file with an Aold object as its contents and turns it into a new A class (still with me?) next writes it back to disk. This, so that next time my program can load it directly. I renamed oldA to A again.
But the horror. the horror. I got this exception when i tried to load and A object from disk:
java.io.InvalidClassException: model.A; local class incompatible: stream classdesc serialVersionUID = -4621085703760431015, local class serialVersionUID = -3183461156231139807
Did i just messed up, and is the information lost? Or is there a solution?