Not sure, but this could be it:  TC saves Session objects to files when the
webapp is started/stopped.  (This is a configurable feature in context.xml).
To do this, any attribute that you add to a Session object must be
serializable.  Therefore I would guess that if you call
Session#setAttribute() with a non-serializable object as an arg, it might be
complaining.

I'd be interested to know if this is the problem, because I had trouble in a
related area a while back, which arose because TC did *not* complain about
the attribute at the time, only when the webapp was stopped and it tried to
write it to sessions.ser 

> -----Original Message-----
> From: Graf László [mailto:[EMAIL PROTECTED] 
> Sent: Thursday 27 October 2005 17:04
> To: users@tomcat.apache.org
> Subject: org.apache.jasper.JasperException: setAttribute: 
> Non-serializable attribute
> 
> 
> Hi,
> 
> I am using JBoss-4.0.3 which runs an embeded Tomcat 5.5.9.
> Before sending the code segment I would like to ask you,
> when throws the server the following exception:
> 
> -------
> java.lang.IllegalArgumentException: setAttribute: 
> Non-serializable attribute
> -------
> 
> Below you can see the whole output of the server.
> 
> 
> 
> "HTTP Status 500 -
> type Exception report
> message
> description The server encountered an internal error () that 
> prevented 
> it from fulfilling this request.
> 
> exception
> 
> org.apache.jasper.JasperException: setAttribute: 
> Non-serializable attribute
>     
> org.apache.jasper.servlet.JspServletWrapper.service(JspServlet
Wrapper.java:370)
>     
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet
.java:314)
>     org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
>     javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
>     
> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyH
eaderFilter.java:81)
> 
> root cause
> 
> java.lang.IllegalArgumentException: setAttribute: 
> Non-serializable attribute
>     
> org.apache.catalina.session.StandardSession.setAttribute(Stand
ardSession.java:1233)
>     
> org.apache.catalina.session.StandardSessionFacade.setAttribute
> (StandardSessionFacade.java:129)
>     
> org.apache.jasper.runtime.PageContextImpl.doSetAttribute(PageC
> ontextImpl.java:341)
>     
> org.apache.jasper.runtime.PageContextImpl.setAttribute(PageCon
> textImpl.java:320)
>     
> org.apache.jsp.alt_005ffejlec_jsp._jspService(org.apache.jsp.a
> lt_005ffejlec_jsp:94)
>     org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
>     javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
>     
> org.apache.jasper.servlet.JspServletWrapper.service(JspServlet
Wrapper.java:322)
>     
> org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet
.java:314)
>     org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
>     javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
>     
> org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyH
eaderFilter.java:81)
> 
> note The full stack trace of the root cause is available in 
> the Apache 
> Tomcat/5.5.9 logs."
> 
> -- 
> Graf László
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to