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 Funk (JIRA)" <ji...@apache.org> on 2010/12/21 17:54:03 UTC

[jira] Created: (WICKET-3276) CLONE -How to set custom HTTP response header in Wicket's Ajax responses?

CLONE -How to set custom HTTP response header in Wicket's Ajax responses?
-------------------------------------------------------------------------

                 Key: WICKET-3276
                 URL: https://issues.apache.org/jira/browse/WICKET-3276
             Project: Wicket
          Issue Type: Bug
            Reporter: Martin Funk


http://stackoverflow.com/questions/4397211/how-to-set-custom-http-response-header-in-wickets-ajax-responses/4399434#4399434



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


[jira] Commented: (WICKET-3276) CLONE -How to set custom HTTP response header in Wicket's Ajax responses?

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

Hudson commented on WICKET-3276:
--------------------------------

Integrated in Apache Wicket 1.4.x #424 (See [https://hudson.apache.org/hudson/job/Apache%20Wicket%201.4.x/424/])
    added javadoc warnings
Issue: WICKET-3276


> CLONE -How to set custom HTTP response header in Wicket's Ajax responses?
> -------------------------------------------------------------------------
>
>                 Key: WICKET-3276
>                 URL: https://issues.apache.org/jira/browse/WICKET-3276
>             Project: Wicket
>          Issue Type: Bug
>            Reporter: Martin Funk
>            Assignee: Igor Vaynberg
>
> http://stackoverflow.com/questions/4397211/how-to-set-custom-http-response-header-in-wickets-ajax-responses/4399434#4399434

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] Commented: (WICKET-3276) CLONE -How to set custom HTTP response header in Wicket's Ajax responses?

Posted by "Martin Funk (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3276?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12973761#action_12973761 ] 

Martin Funk commented on WICKET-3276:
-------------------------------------

Sorry that I cloned this issue, but I wasn't able to reopen.

May I have a second view on this one?

The proposed patch is not just a different way to cast. It is calling a different method.

If someone relies on overriding WebRequestCycle.getWebResponse(), which is public and not final
 like:

   private class MyRequestCycle extends WebRequestCycle {

        /* (non-Javadoc)
         * @see org.apache.wicket.protocol.http.WebRequestCycle#getWebResponse()
         */
        @Override
        public WebResponse getWebResponse() {
            WebResponse response = super.getWebResponse();
            response.setHeader("X-custom", "NewHeader" );
            return response;
        }

        public MyRequestCycle(WebApplication application, WebRequest request, Response response) {
            super(application, request, response);
        }

then the AjaxRequestTarget.respond(final RequestCycle requestCycle)

will not call the getWebResponse but the getResponse

and no header will be set

mf

> CLONE -How to set custom HTTP response header in Wicket's Ajax responses?
> -------------------------------------------------------------------------
>
>                 Key: WICKET-3276
>                 URL: https://issues.apache.org/jira/browse/WICKET-3276
>             Project: Wicket
>          Issue Type: Bug
>            Reporter: Martin Funk
>
> http://stackoverflow.com/questions/4397211/how-to-set-custom-http-response-header-in-wickets-ajax-responses/4399434#4399434

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


[jira] Commented: (WICKET-3276) CLONE -How to set custom HTTP response header in Wicket's Ajax responses?

Posted by "Martin Grigorov (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3276?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12973758#action_12973758 ] 

Martin Grigorov commented on WICKET-3276:
-----------------------------------------

Please create a quickstart that shows the problem.
As I told you in the previous ticket - the headers are properly set for both Ajax and normal responses if I use custom RequestCycle.

> CLONE -How to set custom HTTP response header in Wicket's Ajax responses?
> -------------------------------------------------------------------------
>
>                 Key: WICKET-3276
>                 URL: https://issues.apache.org/jira/browse/WICKET-3276
>             Project: Wicket
>          Issue Type: Bug
>            Reporter: Martin Funk
>
> http://stackoverflow.com/questions/4397211/how-to-set-custom-http-response-header-in-wickets-ajax-responses/4399434#4399434

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


[jira] Commented: (WICKET-3276) CLONE -How to set custom HTTP response header in Wicket's Ajax responses?

Posted by "Martin Funk (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/WICKET-3276?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12974116#action_12974116 ] 

Martin Funk commented on WICKET-3276:
-------------------------------------

The quickstart:
https://github.com/mafulafunk/Quickstart_WICKET-3276

> CLONE -How to set custom HTTP response header in Wicket's Ajax responses?
> -------------------------------------------------------------------------
>
>                 Key: WICKET-3276
>                 URL: https://issues.apache.org/jira/browse/WICKET-3276
>             Project: Wicket
>          Issue Type: Bug
>            Reporter: Martin Funk
>
> http://stackoverflow.com/questions/4397211/how-to-set-custom-http-response-header-in-wickets-ajax-responses/4399434#4399434

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


[jira] Resolved: (WICKET-3276) CLONE -How to set custom HTTP response header in Wicket's Ajax responses?

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

Igor Vaynberg resolved WICKET-3276.
-----------------------------------

    Resolution: Won't Fix
      Assignee: Igor Vaynberg

getwebresponse() shouldve been made final. however, we cannot fix it now. i added javadoc warnings to getweb* methods explaning how to use the properly. this is better in 1.5.

> CLONE -How to set custom HTTP response header in Wicket's Ajax responses?
> -------------------------------------------------------------------------
>
>                 Key: WICKET-3276
>                 URL: https://issues.apache.org/jira/browse/WICKET-3276
>             Project: Wicket
>          Issue Type: Bug
>            Reporter: Martin Funk
>            Assignee: Igor Vaynberg
>
> http://stackoverflow.com/questions/4397211/how-to-set-custom-http-response-header-in-wickets-ajax-responses/4399434#4399434

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira