You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Maurice Marrink <ma...@gmail.com> on 2008/02/29 14:20:15 UTC

fix for WICKET-1365 causes ClassCastException

Matej,

I am afraid your latest change is causing page expired all over the
place in our application.
The underlying exception seems to be:
org.apache.wicket.RequestCycle.detach(RequestCycle.java:1095) : there
was an error detaching the request from the session
nl.topicus.soundscape.app.SoundScapeSession@709366.
java.lang.ClassCastException:
org.apache.wicket.protocol.http.pagestore.SerializedPagesCache
$SerializedPageWithSession cannot be cast to java.lang.ref.SoftReference
	at
org.apache.wicket.protocol.http.pagestore.SerializedPagesCache.removePage(SerializedPagesCache.java:63)
	at
org.apache.wicket.protocol.http.pagestore.SerializedPagesCache.storePage(SerializedPagesCache.java:145)
	at
org.apache.wicket.protocol.http.pagestore.DiskPageStore.storePage(DiskPageStore.java:808)
	at org.apache.wicket.protocol.http.SecondLevelCacheSessionStore
$SecondLevelCachePageMap.put(SecondLevelCacheSessionStore.java:332)
	at org.apache.wicket.Session.requestDetached(Session.java:1370)
	at org.apache.wicket.RequestCycle.detach(RequestCycle.java:1091)
	at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1348)
	at org.apache.wicket.RequestCycle.request(RequestCycle.java:493)
	at
org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:358)
	at
org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:194)
	at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
	at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
	at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
	at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
	at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
	at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)


Maurice

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: fix for WICKET-1365 causes ClassCastException

Posted by Matej Knopp <ma...@gmail.com>.
Hi,

sorry about that. Didn't have time to test that properly. The fix
should be committed.

Thanks
-Matej

On Fri, Feb 29, 2008 at 3:42 PM, Maurice Marrink <ma...@gmail.com> wrote:
> The problem seems to be line 97 of SerializedPagesCache where you add
>  a SerializedPageWithSession to a list who's entries will later be cast
>  to a SoftReference (at line 63).
>
>  Maurice
>
>
>
>
>  On Fri, Feb 29, 2008 at 2:20 PM, Maurice Marrink <ma...@gmail.com> wrote:
>  > Matej,
>  >
>  >  I am afraid your latest change is causing page expired all over the
>  >  place in our application.
>  >  The underlying exception seems to be:
>  >  org.apache.wicket.RequestCycle.detach(RequestCycle.java:1095) : there
>  >  was an error detaching the request from the session
>  >  nl.topicus.soundscape.app.SoundScapeSession@709366.
>  >  java.lang.ClassCastException:
>  >  org.apache.wicket.protocol.http.pagestore.SerializedPagesCache
>  >  $SerializedPageWithSession cannot be cast to java.lang.ref.SoftReference
>  >         at
>  >  org.apache.wicket.protocol.http.pagestore.SerializedPagesCache.removePage(SerializedPagesCache.java:63)
>  >         at
>  >  org.apache.wicket.protocol.http.pagestore.SerializedPagesCache.storePage(SerializedPagesCache.java:145)
>  >         at
>  >  org.apache.wicket.protocol.http.pagestore.DiskPageStore.storePage(DiskPageStore.java:808)
>  >         at org.apache.wicket.protocol.http.SecondLevelCacheSessionStore
>  >  $SecondLevelCachePageMap.put(SecondLevelCacheSessionStore.java:332)
>  >         at org.apache.wicket.Session.requestDetached(Session.java:1370)
>  >         at org.apache.wicket.RequestCycle.detach(RequestCycle.java:1091)
>  >         at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1348)
>  >         at org.apache.wicket.RequestCycle.request(RequestCycle.java:493)
>  >         at
>  >  org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:358)
>  >         at
>  >  org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:194)
>  >         at
>  >  org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>  >         at
>  >  org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>  >         at
>  >  org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
>  >         at
>  >  org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
>  >         at
>  >  org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
>  >         at
>  >  org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>  >
>  >
>  >  Maurice
>  >
>
>  ---------------------------------------------------------------------
>  To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
>  For additional commands, e-mail: users-help@wicket.apache.org
>
>



-- 
Resizable and reorderable grid components.
http://www.inmethod.com

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org


Re: fix for WICKET-1365 causes ClassCastException

Posted by Maurice Marrink <ma...@gmail.com>.
The problem seems to be line 97 of SerializedPagesCache where you add
a SerializedPageWithSession to a list who's entries will later be cast
to a SoftReference (at line 63).

Maurice


On Fri, Feb 29, 2008 at 2:20 PM, Maurice Marrink <ma...@gmail.com> wrote:
> Matej,
>
>  I am afraid your latest change is causing page expired all over the
>  place in our application.
>  The underlying exception seems to be:
>  org.apache.wicket.RequestCycle.detach(RequestCycle.java:1095) : there
>  was an error detaching the request from the session
>  nl.topicus.soundscape.app.SoundScapeSession@709366.
>  java.lang.ClassCastException:
>  org.apache.wicket.protocol.http.pagestore.SerializedPagesCache
>  $SerializedPageWithSession cannot be cast to java.lang.ref.SoftReference
>         at
>  org.apache.wicket.protocol.http.pagestore.SerializedPagesCache.removePage(SerializedPagesCache.java:63)
>         at
>  org.apache.wicket.protocol.http.pagestore.SerializedPagesCache.storePage(SerializedPagesCache.java:145)
>         at
>  org.apache.wicket.protocol.http.pagestore.DiskPageStore.storePage(DiskPageStore.java:808)
>         at org.apache.wicket.protocol.http.SecondLevelCacheSessionStore
>  $SecondLevelCachePageMap.put(SecondLevelCacheSessionStore.java:332)
>         at org.apache.wicket.Session.requestDetached(Session.java:1370)
>         at org.apache.wicket.RequestCycle.detach(RequestCycle.java:1091)
>         at org.apache.wicket.RequestCycle.steps(RequestCycle.java:1348)
>         at org.apache.wicket.RequestCycle.request(RequestCycle.java:493)
>         at
>  org.apache.wicket.protocol.http.WicketFilter.doGet(WicketFilter.java:358)
>         at
>  org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:194)
>         at
>  org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
>         at
>  org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
>         at
>  org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
>         at
>  org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
>         at
>  org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
>         at
>  org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
>
>
>  Maurice
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@wicket.apache.org
For additional commands, e-mail: users-help@wicket.apache.org