Hi!
Many thanks for your response. I just implemented the Serializable interface in my BackingBeans, but I get errors from JBoss now, saying that javax.faces.model.ListDataModel is not serializable. I need to use ListDataModel to wrap the java.util.List instances of data shown in dataTables. How did you solve that problem, if it had been a task for you? The problem has also been mentioned in the following post, but it shows no concrete solutions for me. http://www.mail-archive.com/[email protected]/msg12092.html Regards, Matthias > -----Ursprüngliche Nachricht----- > Von: [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] Auftrag > von Mike Kienenberger > Gesendet: Dienstag, 29. November 2005 17:49 > An: MyFaces Discussion > Betreff: Re: WIKI article - How JSF State Management Works > > > I think JSF doesn't perform saveState on backing beans in this > situation. I'm not an expert on container session serialization, but > your container might attempt to serialize session-scoped backing beans > when the container shuts down or for clustering reasons. > > Again, I'm guessing somewhat on this as I've never really researched > it. If you want to be safe, always implement serializable. If it's > not used, it only costs you a little code (just an "implements" > statement in most cases). And if it's used (whether by the container > or JSF), then you don't have to worry about it. > > On 11/29/05, Matthias Kahlau <[EMAIL PROTECTED]> wrote: > > Hi! > > > > > > Yes, I use server-side state saving and session-scoped BackingBeans. My > > BackingBeans don't have any superclasses, and don't implement > Serializable > > or StateHolder directly. Referencing to your explanation, the Container > > seems to manage the state saving. Is this really container > dependent, that > > said, is it possible, that the app won't run in a different > container. Do I > > have to implement Serializable in the BackingBeans, that the app is > > container-independent, and will that be enough? (that isn't > mentioned in the > > JSF book from Andy Bosch that I read, is that MyFaces specific?) > > > > > > Regards, > > Matthias > > > > > -----Ursprüngliche Nachricht----- > > > Von: [EMAIL PROTECTED] > > > > [mailto:[EMAIL PROTECTED] Auftrag > > > von Mike Kienenberger > > > Gesendet: Dienstag, 29. November 2005 17:24 > > > An: MyFaces Discussion > > > Betreff: Re: WIKI article - How JSF State Management Works > > > > > > > > > It's hard to comment without a specific use case. > > > > > > You only have to implement Serializable or StateHolder if you're going > > > to save the bean. Maybe you're not saving the bean. If you're using > > > server-side state management and session-scoped beans, it'd depend on > > > your container whether they're "saved." > > > > > > If you're using client-side state management, they should always > > > be "saved." > > > > > > Also, check your inheritance hierarchy. Perhaps some base superclass > > > is already implementing Serializable. > > > > > > On 11/29/05, Matthias Kahlau <[EMAIL PROTECTED]> wrote: > > > > Hi! > > > > > > > > > > > > I have a question regarding a MyFaces WIKI article about state > > > management. > > > > In the article is described, that BackingBeans will have to > > > implement the > > > > Serializable interface or StateHolder. I neither implement > > > Serializable, nor > > > > StateHolder, but my BackingBeans work. Isn't the article > > > up-to-date, or is > > > > there some misunderstanding? > > > > > > > > http://wiki.apache.org/myfaces/How_JSF_State_Management_Works > > > > > > > > > > > > > > > > Regards, > > > > Matthias > > > > > > > > > > > >

