in case you are storing beans from other framework that are not serializable i really dont see an easy way. the creators of those projects should make sure their objects are serializable. the only thing i see that you can do is to create a serializable bean yourself that has the necessary logic to translate to and from the other bean. or subclass it, override writeReplace/readReplace and do the same thing.
in case you are talking about stateless objects from other frameworks you have a lot more options:
use a pure getter
use a null-check-getter in conjunection with a transient field if lookups are expensive and you want to cache them for a while
use a wicket-spring type of proxy that is serializable and knows how to look up the dependency - kinda like a middleman between your dependency and serialization
-Igor
On 7/18/06, Steve Moitozo <[EMAIL PROTECTED]> wrote:
> not really sure what you mean or why you would have to do that. what is the
> usecase for having something that is not serializable in session?
As I trace this issue through my code it's becoming apparent that since
pages are added to the session any properties that is in a page that
isn't serializable causes the error. So it's not that I want to store
non-serializable things in the session necessarily. Many of my pages use
third-party libraries that are not serializable and these seem to cause
the issue.
I'll admit I'm a new comer so I may be missing something or violating a
Wicket principle as I build out my app.
> the debug feature serializes immediately so you get the error now
> instead of whenever the servlet container tries to replicate your session
> for you - at which point you will get a very similar error.
Thank you for this!
-S2
--
Steve Moitozo II
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys -- and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Wicket-user mailing list
Wicket-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/wicket-user
------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________ Wicket-user mailing list Wicket-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/wicket-user