You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Terrence August <ta...@corp2k.com> on 2001/12/17 18:25:13 UTC

Help with session problems

I am experiencing a problem with session expiration I believe.  Basically,
my struts application grabs job objects and places them into the session for
viewing on the page.  Everything works fine until I leave the computer alone
overnight and come back in the morning.  At this time, I'll hit submit to
get the latest list of jobs.  It returns this list in the session, but this
time says ClassCastException.  It cannot pull the jobs out of the session
and cast them back to Job objects.  I am not sure why an expiration in the
session causes this type of problem.  I even checked the session, and the
job objects are in fact there.  But for some reason, there is a
ClassCastException only when something on the server is expired.  Does
struts require something I am not familiar with?  Any help would be greatly
appreciated.

<bean:define id="jobList" name="categoryIterator" property="value"
type="java.util.List"/>

<logic:iterate id="jobsIterator" indexId="jobsIndex" name="jobList">
  <bean:define id="job" name="jobsIterator" type="com.tsg.bean.Job"/>
  <tr class="DarkGreyRow">
    <td width="60"><font class="JobText"><a href="/listJob.do"><bean:write
name="job" property="jobId"/></a></td>
    <td width="50"><font class="JobText"><bean:write name="job"
property="jobState"/></td>
    <td width="110" wrap="on"><font class="JobText"><bean:write name="job"
property="jobCompany"/></td>
    <td width="218" wrap="on"><font class="JobText"><bean:write name="job"
property="jobPosition"/></td>
    <td width="80" wrap="on"><font class="JobText"><bean:write name="job"
property="jobStartDate"/></td>
    <td width="100" wrap="on"><font class="JobText"><bean:write name="job"
property="jobSalary"/>
    </td>
  </tr>
</logic:iterate>


--
To unsubscribe, e-mail:   <ma...@jakarta.apache.org>
For additional commands, e-mail: <ma...@jakarta.apache.org>