Hi,

I just stumbled upon an issue regarding view scope I have not noticed before. As the view scope map is stored in the view root it takes part in state saving. My problem is this: I have a backing bean in view scope with an application scoped bean injected by the managed bean creation facility. As MyFaces serializes the state by default the bean is serialized and deserialized on postback even with server side state saving. This also means that the application scoped bean is serialized and deserialized which will create a new instance of this bean which should be unique.

I can handle this with turning off serialization for server state saving or with making the property transient and loading it again in readObject(), but is this really handy for end users? But then on the other hand I guess this is exactly the expected behavior. Should/could we do something about that?

Another question in this context: why is serialization and compression on server state enabled by default?

regards
Michael

Reply via email to