You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Eelco Hillenius (JIRA)" <ji...@apache.org> on 2007/03/11 03:23:09 UTC
[jira] Resolved: (WICKET-366) Set Request Cycle in ThreadLocal
[ https://issues.apache.org/jira/browse/WICKET-366?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Eelco Hillenius resolved WICKET-366.
------------------------------------
Resolution: Fixed
Implemented as a protected method, so you need to expose it yourself. It has this warning:
You typically DO NOT NEED to call this method, as the request cycle is set to current for you in the constructor. However, if you have a <a href="http://issues.apache.org/jira/browse/WICKET-366">very special need</a> to set it to something else, you can expose this method.
> Set Request Cycle in ThreadLocal
> --------------------------------
>
> Key: WICKET-366
> URL: https://issues.apache.org/jira/browse/WICKET-366
> Project: Wicket
> Issue Type: New Feature
> Components: wicket
> Affects Versions: 1.3, 2.0
> Reporter: Robert
> Priority: Minor
> Fix For: 1.3, 2.0
>
>
> I want to request a static set method on RequestCycle to set the cycle in the current ThreadLocal, so that Wicket can create components and such in a different thread than where the HTTP request entered.
> Without this a WicketRuntimeException("Can not set the attribute. No RequestCycle available") is thrown from the Session.setAttribute method.
> Suggested implementation:
> public static void set(RequestCycle cycle)
> {
> current.set(cycle);
> }
> This is similar to the static set methods for Session and Application.
> This method can also be protected if desired.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.