myfaces-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Bjørn T Johansen <...@havleik.no>
Subject Re: Switching from RI to myfaces...
Date Wed, 26 Apr 2006 06:25:49 GMT
No, still using server side saving..

But setting org.apache.myfaces.SERIALIZE_STATE_IN_SESSION to false solved this exception problem
but now I
get another problem... 
I store an object in the session scope when I login, but when I try to get this object now,
this object is
now null..
Do I need to set more context parameters?


BTJ

On Wed, 26 Apr 2006 06:08:10 +0000
"Dennis Byrne" <dennis@dbyrne.net> wrote:

> Somewhere in an ArrayList there is an object that is not serializable.  When you went
from RO to MyFaces,
> did you also go from server side saving to client?  Another possible answer to your problem
would be to set
> the following context parameter to false:
> 
> org.apache.myfaces.SERIALIZE_STATE_IN_SESSION
> 
> Dennis Byrne
> 
> >-----Original Message-----
> >From: Bjørn T Johansen [mailto:btj@havleik.no]
> >Sent: Wednesday, April 26, 2006 01:57 AM
> >To: 'MyFaces Discussion'
> >Subject: Switching from RI to myfaces...
> >
> >I am trying to switch from Sun RI impl. to myfaces, but when I try to run my webapp
now, I just get this
> >exception..:
> >
> >26.04.2006 07:47:33,179 - Exiting serializeView - Could not serialize state:
> >org.apache.myfaces.context.servlet.ServletFacesContextImpl java.io.NotSerializableException:
> >org.apache.myfaces.context.servlet.ServletFacesContextImpl at
> >java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1075) at
> >java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1369) at
> >java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1341) at
> >java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1284) at
> >java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1073) at
> >java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1369) at
> >java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1341) at
> >java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1284) at
> >java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1073) at
> >java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1245) at
> >java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1069) at
> >java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1245) at
> >java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1069) at
> >java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:291) at
> >java.util.ArrayList.writeObject(ArrayList.java:569) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native
> >Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> >        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> >        at java.lang.reflect.Method.invoke(Method.java:585)
> >        at java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:890)
> >        at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1333)
> >        at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1284)
> >        at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1073)
> >        at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1245)
> >        at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1069)
> >        at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:291)
> >        at java.util.ArrayList.writeObject(ArrayList.java:569)
> >        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> >        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> >        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> >        at java.lang.reflect.Method.invoke(Method.java:585)
> >        at java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:890)
> >        at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1333)
> >        at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1284)
> >        at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1073)
> >        at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1245)
> >        at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1069)
> >        at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:291)
> >        at java.util.ArrayList.writeObject(ArrayList.java:569)
> >        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> >        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> >        at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> >        at java.lang.reflect.Method.invoke(Method.java:585)
> >        at java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:890)
> >        at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1333)
> >        at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1284)
> >        at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1073)
> >        at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1245)
> >        at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1069)
> >        at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:291)
> >        at
> > org.apache.myfaces.application.jsp.JspStateManagerImpl.serializeView(JspStateManagerImpl.java:590)
at
> >org.apache.myfaces.application.jsp.JspStateManagerImpl.saveSerializedViewInServletSession(JspStateManagerImpl.java:493)
> >at org.apache.myfaces.application.jsp.JspStateManagerImpl.saveSerializedView(JspStateManagerImpl.java:332)
> >at org.apache.myfaces.taglib.core.ViewTag.doAfterBody(ViewTag.java:122) at
> >org.apache.jsp.protected_.index_005ft_jsp._jspx_meth_f_view_0(index_005ft_jsp.java:150)
at
> >org.apache.jsp.protected_.index_005ft_jsp._jspService(index_005ft_jsp.java:102) at
> >org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97) at
> >javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at
> >org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:332) at
> >org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314) at
> >org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264) at
> >javax.servlet.http.HttpServlet.service(HttpServlet.java:802) at
> >org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at
> >org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at
> >no.havleik.dt.security.AuthFilter.doFilter(AuthFilter.java:83) at
> >org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
at
> >org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at
> >org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:672)
at
> >org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:463)
at
> >org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:398)
at
> >org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301)
at
> >org.apache.myfaces.context.servlet.ServletExternalContextImpl.dispatch(ServletExternalContextImpl.java:416)
> >at org.apache.shale.tiles.TilesViewHandler.dispatchToTile(TilesViewHandler.java:318)
at
> >org.apache.shale.tiles.TilesViewHandler.renderView(TilesViewHandler.java:159) at
> >org.apache.shale.view.faces.ViewViewHandler.renderView(ViewViewHandler.java:146)
at
> >org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:367) at
> >javax.faces.webapp.FacesServlet.service(FacesServlet.java:138) at
> >org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
at
> >org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at
> >org.apache.shale.faces.ShaleApplicationFilter.doFilter(ShaleApplicationFilter.java:285)
at
> >org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
at
> >org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
at
> >org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at
> >org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at
> >org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126) at
> >org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105) at
> >org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
at
> >org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148) at
> >org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869) at
> >org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
> >at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
at
> >org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
at
> >org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
at
> >java.lang.Thread.run(Thread.java:595)
> >
> >
> >I am also getting this in the log, which indicate something loading twice?
> >(and no, I do not have faces-config.xml in javax.faces.CONFIG_FILES..)
> >
> >26.04.2006 07:53:22,013 - No context init parameter 'org.apache.myfaces.PRETTY_HTML'
found, using default
> >value true
> >26.04.2006 07:53:22,013 - No context init parameter 'org.apache.myfaces.ALLOW_JAVASCRIPT'
found,
> >using default value true 
> >26.04.2006 07:53:22,013 - No context init parameter
> >'org.apache.myfaces.DETECT_JAVASCRIPT' found, using default value false 
> >26.04.2006 07:53:22,013 - No context init parameter 'org.apache.myfaces.AUTO_SCROLL'
found, using default
> >value false 
> >26.04.2006 07:53:22,013 - No context init parameter 'org.apache.myfaces.ADD_RESOURCE_CLASS'
found, using
> >default value org.apache.myfaces.renderkit.html.util.DefaultAddResource 
> >26.04.2006 07:53:22,044 - No context init parameter 'org.apache.myfaces.PRETTY_HTML'
found, using default
> >value true 
> >26.04.2006 07:53:22,044 - No context init parameter 'org.apache.myfaces.ALLOW_JAVASCRIPT'
found, using
> >default value true 
> >26.04.2006 07:53:22,044 - No context init parameter 'org.apache.myfaces.DETECT_JAVASCRIPT'
found, using
> >default value false 
> >26.04.2006 07:53:22,044 - No context init parameter 'org.apache.myfaces.AUTO_SCROLL'
found, using default
> >value false 
> >26.04.2006 07:53:22,044 - No context init parameter 'org.apache.myfaces.ADD_RESOURCE_CLASS'
found, using
> >default value org.apache.myfaces.renderkit.html.util.DefaultAddResource
> >
> >
> >
> >Regards,
> >
> >BTJ
> >
> >-- 
> >-----------------------------------------------------------------------------------------------
> >Bjørn T Johansen
> >
> >btj@havleik.no
> >-----------------------------------------------------------------------------------------------
> >Someone wrote:
> >"I understand that if you play a Windows CD backwards you hear strange Satanic messages"
> >To which someone replied:
> >"It's even worse than that; play it forwards and it installs Windows"
> >-----------------------------------------------------------------------------------------------
> >
> 

Mime
View raw message