开发者

Error calling action method of component with id pageForm:next_button Java faces

开发者 https://www.devze.com 2023-02-22 11:29 出处:网络
Hello i am developing a web application using java faces .. i know a terrible choice anyways i am receiving this error :

Hello i am developing a web application using java faces .. i know a terrible choice anyways i am receiving this error :

java.io.InvalidClassException - core.entities.PrimaryUser; local class incompatible: stream classdesc serialVersionUID = -3071143254300957400, local class serialVersionU开发者_StackOverflow中文版ID = 1

would you please help or guide me ... thanks alot


It looks like you've serialized an old version of PrimaryUser, and now you're trying to load that data back again, having changed the class. That won't work, in general. Binary serialization in Java is extremely tricky when it comes to backward and forward compatibility :(

If you've just changed the class in a compatible way, you could try setting the serialVersionUID to -3071143254300957400 explicitly... it looks like you're currently setting it to 1. In general I'd try to move away from the default serialization though, if at all possible.

0

精彩评论

暂无评论...
验证码 换一张
取 消