[
https://issues.apache.org/jira/browse/WICKET-3643?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Igor Vaynberg resolved WICKET-3643.
-----------------------------------
Resolution: Invalid
Assignee: Igor Vaynberg
such functionality is available to irequestcyclelistener implementations.
onrequesthandlerresolved() can be used to find the originally requested page,
while onrequesthandlerscheduled can be used to find the response page.
in both of these methods the handler can be checked for
icomponentrequesthandler, ipageclassrequesthandler, or ipagerequesthandler, and
page extracted by downcasting.
custom request handlers that deal with pages, i doubt there will be any since
doing so is a core concern, should implement those interfaces.
> Cannot get the request/response pages from the RequestCycle anymore
> -------------------------------------------------------------------
>
> Key: WICKET-3643
> URL: https://issues.apache.org/jira/browse/WICKET-3643
> Project: Wicket
> Issue Type: Bug
> Components: wicket-core
> Affects Versions: 1.5-RC3
> Reporter: Emond Papegaaij
> Assignee: Igor Vaynberg
>
> With Wicket 1.5 it has become virtually impossible to find the request and
> response pages for the current request. The methods
> RequestCycle.getResponsePage and Request.getPage have both been removed and
> no replacement is provided. We identified a few locations that hacked around
> this issue, such as DefaultExceptionMapper and DummyRequestLogger. Both check
> for several known request handler interfaces to try to determine the pages
> and both forget 1 or 2 (for example IRequestHandlerDelegate or
> IComponentRequestHandler). This does not seem to be a very good solution,
> especially when people start writing their own request handlers. Also, with
> this technique it is impossible to determine the request page, because that
> request handler may no longer be available. Another major problem is that
> IPageRequestHandler.getPage instantiates the page when it was not yet
> instantiated. This makes it a bad candidate to use for the request logger.
> Please provide accurate methods to determine the request/response pages (or
> null when the request is not page-related, or the page is not (yet)
> instantiated).
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira