You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Felix Meschberger (JIRA)" <ji...@apache.org> on 2009/08/14 21:02:15 UTC

[jira] Created: (SLING-1087) RedirectServlet must not redirect if the response is committed or in included requests

RedirectServlet must not redirect if the response is committed or in included requests
--------------------------------------------------------------------------------------

                 Key: SLING-1087
                 URL: https://issues.apache.org/jira/browse/SLING-1087
             Project: Sling
          Issue Type: Bug
          Components: Servlets Get
    Affects Versions: Servlets Get 2.0.4
            Reporter: Felix Meschberger


If a redirect resource is rendered with the RedirectServlet. This servlet should *not* actually do the redirect if (a) the request has already been committed (to prevent an IllegalStateException) and/or if (b) the request is an included one (we don't expect such things in included requests)

The fix is probably to add such a check at the beginning of the RedirectServlet.doGet method:

   if (response.isCommitte()) {
       log warn
       return;
   } else if (response is included) {
       log warn
       return;
   }

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


[jira] Resolved: (SLING-1087) RedirectServlet must not redirect if the response is committed or in included requests

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

Felix Meschberger resolved SLING-1087.
--------------------------------------

       Resolution: Fixed
    Fix Version/s: Servlets Get 2.0.8
         Assignee: Felix Meschberger

Implemented this safe guard in Rev. 889379.

> RedirectServlet must not redirect if the response is committed or in included requests
> --------------------------------------------------------------------------------------
>
>                 Key: SLING-1087
>                 URL: https://issues.apache.org/jira/browse/SLING-1087
>             Project: Sling
>          Issue Type: Bug
>          Components: Servlets
>    Affects Versions: Servlets Get 2.0.4
>            Reporter: Felix Meschberger
>            Assignee: Felix Meschberger
>             Fix For: Servlets Get 2.0.8
>
>
> If a redirect resource is rendered with the RedirectServlet. This servlet should *not* actually do the redirect if (a) the request has already been committed (to prevent an IllegalStateException) and/or if (b) the request is an included one (we don't expect such things in included requests)
> The fix is probably to add such a check at the beginning of the RedirectServlet.doGet method:
>    if (response.isCommitte()) {
>        log warn
>        return;
>    } else if (response is included) {
>        log warn
>        return;
>    }

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


[jira] Closed: (SLING-1087) RedirectServlet must not redirect if the response is committed or in included requests

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

Carsten Ziegeler closed SLING-1087.
-----------------------------------


> RedirectServlet must not redirect if the response is committed or in included requests
> --------------------------------------------------------------------------------------
>
>                 Key: SLING-1087
>                 URL: https://issues.apache.org/jira/browse/SLING-1087
>             Project: Sling
>          Issue Type: Bug
>          Components: Servlets
>    Affects Versions: Servlets Get 2.0.4
>            Reporter: Felix Meschberger
>            Assignee: Felix Meschberger
>             Fix For: Servlets Get 2.0.8
>
>
> If a redirect resource is rendered with the RedirectServlet. This servlet should *not* actually do the redirect if (a) the request has already been committed (to prevent an IllegalStateException) and/or if (b) the request is an included one (we don't expect such things in included requests)
> The fix is probably to add such a check at the beginning of the RedirectServlet.doGet method:
>    if (response.isCommitte()) {
>        log warn
>        return;
>    } else if (response is included) {
>        log warn
>        return;
>    }

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