You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Jonas (JIRA)" <ji...@apache.org> on 2010/03/12 10:37:27 UTC

[jira] Created: (WICKET-2778) Set Application ThreadLocal in WicketSessionFilter

Set Application ThreadLocal in WicketSessionFilter
--------------------------------------------------

                 Key: WICKET-2778
                 URL: https://issues.apache.org/jira/browse/WICKET-2778
             Project: Wicket
          Issue Type: Improvement
          Components: wicket
    Affects Versions: 1.4.5
            Reporter: Jonas
            Priority: Minor
             Fix For: 1.4.8


WicketSessionFilter currently only sets the Session ThreadLocal, but not the Application ThreadLocale.
This leads to WicketRuntimeException when trying to get the Application using Application#get or Session#getApplication.
It would be handy if the Application ThreadLocal would also be set in WicketSessionFilter.

see also:
http://old.nabble.com/Application-get-in-WicketSessionFilter-ts27862681.html#a27862681

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (WICKET-2778) Set Application ThreadLocal in WicketSessionFilter

Posted by "Jonas (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/WICKET-2778?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jonas updated WICKET-2778:
--------------------------

    Attachment: WICKET-2778.patch

I also attached a patch against
https://svn.eu.apache.org/repos/asf/wicket/branches/wicket-1.4.x/wicket
hoping that this will make it into the next release...?

> Set Application ThreadLocal in WicketSessionFilter
> --------------------------------------------------
>
>                 Key: WICKET-2778
>                 URL: https://issues.apache.org/jira/browse/WICKET-2778
>             Project: Wicket
>          Issue Type: Improvement
>          Components: wicket
>    Affects Versions: 1.4.5
>            Reporter: Jonas
>            Priority: Minor
>             Fix For: 1.4.8
>
>         Attachments: WICKET-2778.patch
>
>
> WicketSessionFilter currently only sets the Session ThreadLocal, but not the Application ThreadLocale.
> This leads to WicketRuntimeException when trying to get the Application using Application#get or Session#getApplication.
> It would be handy if the Application ThreadLocal would also be set in WicketSessionFilter.
> see also:
> http://old.nabble.com/Application-get-in-WicketSessionFilter-ts27862681.html#a27862681

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (WICKET-2778) Set Application ThreadLocal in WicketSessionFilter

Posted by "Maarten Billemont (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-2778?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12869987#action_12869987 ] 

Maarten Billemont commented on WICKET-2778:
-------------------------------------------

Looks to me like you just broke WicketSessionFilter.  Every request after the first, application is null (because the local application variable it is only set when looking up the sessionKey, which is the first time) and Application.set(application); fails:

2010-05-21 15:54:39.706::WARN:  /img
java.lang.IllegalArgumentException: Argument application can not be null
        at org.apache.wicket.Application.set(Application.java:222)
        at org.apache.wicket.protocol.http.servlet.WicketSessionFilter.doFilter(WicketSessionFilter.java:197)
        at com.google.inject.servlet.FilterDefinition.doFilter(FilterDefinition.java:129)
        at com.google.inject.servlet.FilterChainInvocation.doFilter(FilterChainInvocation.java:59)
        at org.apache.wicket.protocol.http.WicketFilter.doFilter(WicketFilter.java:363)

> Set Application ThreadLocal in WicketSessionFilter
> --------------------------------------------------
>
>                 Key: WICKET-2778
>                 URL: https://issues.apache.org/jira/browse/WICKET-2778
>             Project: Wicket
>          Issue Type: Improvement
>          Components: wicket
>    Affects Versions: 1.4.5
>            Reporter: Jonas
>            Assignee: Igor Vaynberg
>            Priority: Minor
>             Fix For: 1.4.8, 1.5-M1
>
>         Attachments: WICKET-2778.patch
>
>
> WicketSessionFilter currently only sets the Session ThreadLocal, but not the Application ThreadLocale.
> This leads to WicketRuntimeException when trying to get the Application using Application#get or Session#getApplication.
> It would be handy if the Application ThreadLocal would also be set in WicketSessionFilter.
> see also:
> http://old.nabble.com/Application-get-in-WicketSessionFilter-ts27862681.html#a27862681

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (WICKET-2778) Set Application ThreadLocal in WicketSessionFilter

Posted by "Igor Vaynberg (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/WICKET-2778?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Igor Vaynberg resolved WICKET-2778.
-----------------------------------

       Resolution: Fixed
    Fix Version/s: 1.5-M1
         Assignee: Igor Vaynberg

> Set Application ThreadLocal in WicketSessionFilter
> --------------------------------------------------
>
>                 Key: WICKET-2778
>                 URL: https://issues.apache.org/jira/browse/WICKET-2778
>             Project: Wicket
>          Issue Type: Improvement
>          Components: wicket
>    Affects Versions: 1.4.5
>            Reporter: Jonas
>            Assignee: Igor Vaynberg
>            Priority: Minor
>             Fix For: 1.4.8, 1.5-M1
>
>         Attachments: WICKET-2778.patch
>
>
> WicketSessionFilter currently only sets the Session ThreadLocal, but not the Application ThreadLocale.
> This leads to WicketRuntimeException when trying to get the Application using Application#get or Session#getApplication.
> It would be handy if the Application ThreadLocal would also be set in WicketSessionFilter.
> see also:
> http://old.nabble.com/Application-get-in-WicketSessionFilter-ts27862681.html#a27862681

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.