can't we get it? maybe we should just change the lazy strategy

for me that's really a warning

*Romain Manni-Bucau*
*Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
*Blog: **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
*LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
*Github: https://github.com/rmannibucau*



2013/4/16 Thomas Andraschko <[email protected]>

> Shoudln't we change the log level then? Warning is a little bit high for a
> case which occurs always for every session.
>
>
> 2013/4/16 Romain Manni-Bucau <[email protected]>
>
>> If the session expires it should be able to get it and it is mandatory to
>> cleanup beans which could have been put in a forgotten session (mainly
>> @SessionScoped, @ConversationScoped)
>>
>> *Romain Manni-Bucau*
>> *Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
>> *Blog: 
>> **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
>> *LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
>> *Github: https://github.com/rmannibucau*
>>
>>
>>
>> 2013/4/16 Thomas Andraschko <[email protected]>
>>
>>> Here is the stacktrace:
>>>
>>>     at
>>> org.apache.webbeans.web.context.WebContextsService.lazyStartSessionContext(WebContextsService.java:793)
>>>     at
>>> org.apache.webbeans.web.context.WebContextsService.getSessionContext(WebContextsService.java:708)
>>>     at
>>> org.apache.webbeans.web.context.WebContextsService.getCurrentContext(WebContextsService.java:248)
>>>     at
>>> org.apache.webbeans.context.ContextFactory.getStandardContext(ContextFactory.java:185)
>>>     at
>>> org.apache.webbeans.container.BeanManagerImpl.getContext(BeanManagerImpl.java:307)
>>>     at
>>> org.apache.webbeans.portable.creation.AbstractProducer.getCreationalContext(AbstractProducer.java:105)
>>>     at
>>> org.apache.webbeans.portable.creation.InjectionTargetProducer.preDestroy(InjectionTargetProducer.java:132)
>>>     at
>>> org.apache.webbeans.component.InjectionTargetWrapper.preDestroy(InjectionTargetWrapper.java:98)
>>>     at
>>> org.apache.webbeans.component.AbstractOwbBean.destroy(AbstractOwbBean.java:251)
>>>     at
>>> org.apache.webbeans.context.AbstractContext.destroyInstance(AbstractContext.java:205)
>>>     at
>>> org.apache.webbeans.context.AbstractContext.destroy(AbstractContext.java:227)
>>>     at
>>> org.apache.webbeans.web.context.SessionContextManager.destroySessionContextWithSessionId(SessionContextManager.java:84)
>>>     at
>>> org.apache.webbeans.web.context.WebContextsService.destroySessionContext(WebContextsService.java:495)
>>>     at
>>> org.apache.webbeans.web.context.WebContextsService.endContext(WebContextsService.java:216)
>>>     at
>>> org.apache.webbeans.servlet.WebBeansConfigurationListener.sessionDestroyed(WebBeansConfigurationListener.java:197)
>>>     at
>>> org.eclipse.jetty.server.session.AbstractSessionManager.removeSession(AbstractSessionManager.java:801)
>>>     at
>>> org.eclipse.jetty.server.session.AbstractSession.timeout(AbstractSession.java:340)
>>>     at
>>> org.eclipse.jetty.server.session.HashSessionManager.scavenge(HashSessionManager.java:320)
>>>     at
>>> org.eclipse.jetty.server.session.HashSessionManager$2.run(HashSessionManager.java:282)
>>>     at java.util.TimerThread.mainLoop(Timer.java:555)
>>>     at java.util.TimerThread.run(Timer.java:505)
>>>
>>> It happens when the session expires.
>>> Any idea? IMO it should not try to lazy start a session if the session
>>> will be destroyed.
>>>
>>>
>>> 2013/4/12 Thomas Andraschko <[email protected]>
>>>
>>>> Hi Mark,
>>>>
>>>> hmm, weird. I always get them at runtime. 7-8 times today. I only
>>>> changed some pages and layout stuff and refreshed the page.
>>>> Maybe it's because Jetty's change scanning.
>>>> I will try it with Tomcat on Monday.
>>>>
>>>>
>>>>
>>>> 2013/4/12 Mark Struberg <[email protected]>
>>>>
>>>>> Hi Thomas, this sometimes happens at container startup if the
>>>>> container code invokes some SessionScoped event. But the Session is only
>>>>> available in a request of course. this should be in the code already since
>>>>> a long time (1.1.2 or so)
>>>>>
>>>>> LieGrue,
>>>>> strub
>>>>>
>>>>>
>>>>>
>>>>>   ------------------------------
>>>>>  *From:* Thomas Andraschko <[email protected]>
>>>>> *To:* [email protected]
>>>>> *Sent:* Friday, April 12, 2013 4:40 PM
>>>>> *Subject:* Could NOT lazily initialize session context because of
>>>>> null RequestContext
>>>>>
>>>>> Hi,
>>>>>
>>>>> i have many times this warning during development:
>>>>>
>>>>> WARNING: Could NOT lazily initialize session context because of null
>>>>> RequestContext
>>>>>
>>>>> Why does this occur and how can i avoid it?
>>>>> I never mentioned this error in my old application which runned
>>>>> perfectly with 1.1.6 (or 1.1.5, cant remember)
>>>>>
>>>>> Regards,
>>>>> Thomas
>>>>>
>>>>>
>>>>>
>>>>
>>>
>>
>

Reply via email to