[
https://issues.apache.org/jira/browse/WICKET-4019?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13127347#comment-13127347
]
Peter Pastrnak commented on WICKET-4019:
----------------------------------------
Since wicket-core 1.5.1 we've got much more pages rendered as stateless. What,
I believe, is because the PageProvider has changed and the stateless hint is
not set in the constructor anymore
"((Page)pageInstance).setStatelessHint(false);". Now, if a page is bookmarkable
(e.g. has the default constructor) and no stateful hint is explicitly set and
has no stateful component, then it is stateless. So if I add a page like this
to the ajaxrequesttarget or i return it as a reference wrapped by a
pageprovider, it will be stored as a buffered response and after the redirect
returned from this buffer to the user.
I know, that it is probably my duty to tell Wicket that it should not try to
render a page like this as a stateless page (e.g. by not adding the default
contructor or explicitly setting the hint), but my problem is that these pages
will be rendered differently in portlet container and in a standard servlet
environment. The reason is the "redirect-to-render" strategy, that is used by
the portlet bridge and that makes the WebPageRenderer to not store a page like
this in the response buffer, causing "PageExpiredException" in the portlet
container case...
On the other hand, is it correct, that page instances are not stored in a
pagestore in this case? I know I probably should not redirect to instances of a
stateless page, but what if I do? This page can be returned from the buffered
response only once...
It might be, that I haven't investigated enough, so just tell me if I'm not
right :).
> Portlet Support 1.5
> -------------------
>
> Key: WICKET-4019
> URL: https://issues.apache.org/jira/browse/WICKET-4019
> Project: Wicket
> Issue Type: New Feature
> Components: wicket
> Affects Versions: 1.5-RC7
> Reporter: Peter Pastrnak
> Attachments: PortletServletRequestWrapper.java, ResponseState.java,
> Wicket - Portlet.htm, wicket-portlet-1.5.0.zip, wicket-portlet-1.5.1.1.zip,
> wicket-portlet-1.5.1.2.zip, wicket-portlet-1.5.1.3.zip,
> wicket-portlet-1.5.1.4.zip, wicket-portlet-1.5.1.zip,
> wicket-portlet-1.5.RC7.zip, with bind(this).jpg, without bind(this).jpg
>
>
> Url returned by the RequestMapper does not seem to be properly rendered, as
> it does not encode question mark character in the Url parameter value (I
> haven't checked the w3c spec, but at least Liferay Portal seems to require it
> to be encoded)
> The reason is this definition in the UrlEncoder:
> case QUERY :
> // to allow direct passing of URL in query
> dontNeedEncoding.set('/');
> // to allow direct passing of URL in query
> dontNeedEncoding.set('?');
> Currently URL "http://host/file?param=a?b" would be encoded as
> "http://host/file?param=a?b", instead of "http://host/file?param=a%3Fb"
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira