You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@wicket.apache.org by Jens Zastrow <ma...@jens-zastrow.de> on 2010/06/12 22:34:30 UTC

RequestLogger 'Detach'-problem with recordSessionSize

Hi wicket-experts,

Using the default RequestLogger which calculates the session-size by 
serializing the page-objects leads to problems since the models are not 
detached
while doing this step.

The source-code of the RequestCycle shows that the Session/Page gets 
detached AFTER the requestcycle-code, thus the Serialize-step tries to 
store a lot of non-detached models which doest work in my case.

Is this by Design?

Thank
Jens

[RequestCycle.java]
// if we have a request logger, update that now
         try
         {
             IRequestLogger requestLogger = 
getApplication().getRequestLogger();
             if (requestLogger != null)
             {
                 requestLogger.requestTime((System.currentTimeMillis() - 
startTime));
             }
         }
         catch (RuntimeException re)
         {
             log.error("there was an error in the RequestLogger 
ending.", re);
         }

         // let the session cleanup after a request, flushing changes etc.
         if (sessionExists())
         {
             try
             {
                 getSession().requestDetached();
             }
             catch (RuntimeException re)
             {
                 log.error("there was an error detaching the request 
from the session " + session +
                     ".", re);
             }
         }

-- 
dipl. inform jens zastrow

phone | +49.152.04840108
mail  | mail@jens-zastrow.de
web   | http://jens-zastrow.de
xing  | http://www.xing.com/profile/Jens_Zastrow


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