users@glassfish.java.net

Re: Mismatched serialization UIDs

From: Ryan J <ryan.j_at_vacode.com>
Date: Fri, 15 Jun 2007 14:34:05 -0600

Thanks for the reply.

As I finished writing this I noticed I was declaring serialVersionUID in
my beans 'private' rather than 'public'. It may be possible that small
oversight is what's been causing my problems (?), but I won't be able to
test things until next week (maybe later today if things go real well).

Anyway, here's my original reply to your question:

My development server is running:

Ubuntu Server 6.10
JDK 1.6.0_01-b06

I have three clients that I usually test with:

Windows Vista (Main dev machine)
JDK 1.6.0_01-b06

WinXP
JRE 1.6.0_01-b06

Win2K
JRE 1.6.0-b105

I've never had an issue with the Vista machine. I have problems with
the WinXP machine once in a while and have problems with the Win2K
machine the most often.

I did a fair bit of googling before posting and the best theory I saw
was that different JKD/JRE versions don't calculate the same
serialization UIDs. However, I was under the impression that I could
override the built in calculations using something like:

public static final long serialVersionUID = 1L;

... and increment that number every time I make non-transient changes.


glassfish_at_javadesktop.org wrote:
> Someone else was having a similar issue. Are both the client and the server running with the same version of the JDK?
> --Gordon
> [Message sent by forum member 'gyorke' (gyorke)]
>
> http://forums.java.net/jive/thread.jspa?messageID=222464
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>