You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Martin Grigorov (JIRA)" <ji...@apache.org> on 2014/07/17 15:40:04 UTC

[jira] [Reopened] (WICKET-5643) storeBufferedResponse should check if session is temporary.

     [ https://issues.apache.org/jira/browse/WICKET-5643?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Martin Grigorov reopened WICKET-5643:
-------------------------------------


I am a bit concerned from the silent way this is going to be handled - if the sessionId is null then nothing happens! 
So Wicket attempts to store a buffered response and make a redirect to it.
But the response is not stored and what happens after the redirect ? I guess again the warning is logged. I have to run the quickstart to be sure.

I think WebApplication#storeBufferedResponse() should blow when a null is passed as sessionId. But this may break applications in production.
So we need to log a warning and return immediately. This way the users will see the warning and notify us that some combination in WebPageRenderer is not covered (like in your case).
But the fix IMO should be in WebPageRenderer.


What is the use case of having a stateless page and populate its page parameters in its constructor ? Do you expect that the url in the browser address bar should show the parameters ?

> storeBufferedResponse should check if session is temporary.
> -----------------------------------------------------------
>
>                 Key: WICKET-5643
>                 URL: https://issues.apache.org/jira/browse/WICKET-5643
>             Project: Wicket
>          Issue Type: Bug
>    Affects Versions: 6.16.0, 7.0.0-M2
>            Reporter: Andrea Del Bene
>            Assignee: Andrea Del Bene
>             Fix For: 7.0.0-M3, 6.17.0
>
>         Attachments: wicket5578.tar.gz
>
>
> WebApplication.storeBufferedResponse does not check if sessionId is null. This could lead to wrong behaviors as it happens  in the quickstart project. Let's say we have a stateless home page with page parameters that are populated inside page constructor. Under these conditions class WebPageRenderer will call storeBufferedResponse and will redirect the response to the final URL (line 289). But as the session is temporary, the buffered response is not consumed and  WebPageRenderer will rise a warning (line 194).
> I think we should check for null sessionId inside WebApplication or inside WebPageRender.



--
This message was sent by Atlassian JIRA
(v6.2#6252)