You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cxf.apache.org by "Chris Wilson (JIRA)" <ji...@apache.org> on 2010/12/27 16:15:46 UTC

[jira] Created: (CXF-3221) StaxInInterceptor doesn't handle redirects well

StaxInInterceptor doesn't handle redirects well
-----------------------------------------------

                 Key: CXF-3221
                 URL: https://issues.apache.org/jira/browse/CXF-3221
             Project: CXF
          Issue Type: Bug
    Affects Versions: 2.2.7
            Reporter: Chris Wilson


StaxInInterceptor detects the wrong content type of the response, and throws an exception, in handleMessage().

However it doesn't check the response code to see whether it's a redirect. In this case there may not be any useful HTML output, so the INVALID_HTML_RESPONSETYPE exception will not contain any information that helps to debug the fault.

This could alternatively be seen as the job of HTTPConduit.WrappedOutputStream, which checks for 404 errors (HTTP_NOT_FOUND), but assumes that there will always be a response body.

It's also not clear what the accessed URL was, to help with debugging.

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


[jira] [Resolved] (CXF-3221) StaxInInterceptor doesn't handle redirects well

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

Daniel Kulp resolved CXF-3221.
------------------------------

       Resolution: Fixed
    Fix Version/s:     (was: NeedMoreInfo)
                   2.3.3

Marking this as fixed with 2.3.3 due to the refactoring of the redirect handling in the conduit.

> StaxInInterceptor doesn't handle redirects well
> -----------------------------------------------
>
>                 Key: CXF-3221
>                 URL: https://issues.apache.org/jira/browse/CXF-3221
>             Project: CXF
>          Issue Type: Bug
>    Affects Versions: 2.2.7
>            Reporter: Chris Wilson
>            Assignee: Christian Schneider
>             Fix For: 2.3.3
>
>
> StaxInInterceptor detects the wrong content type of the response, and throws an exception, in handleMessage().
> However it doesn't check the response code to see whether it's a redirect. In this case there may not be any useful HTML output, so the INVALID_HTML_RESPONSETYPE exception will not contain any information that helps to debug the fault.
> This could alternatively be seen as the job of HTTPConduit.WrappedOutputStream, which checks for 404 errors (HTTP_NOT_FOUND), but assumes that there will always be a response body.
> It's also not clear what the accessed URL was, to help with debugging.

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

[jira] Assigned: (CXF-3221) StaxInInterceptor doesn't handle redirects well

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

Daniel Kulp reassigned CXF-3221:
--------------------------------

    Assignee: Christian Schneider


I'm going to assign this to Christian.  For 2.3.2, he did some work in the HTTPConduit to get it to throw more reasonable exceptions in some of these types of cases.    If this isn't covered by that, then it probably should be.   

Christian: can you take a look?

> StaxInInterceptor doesn't handle redirects well
> -----------------------------------------------
>
>                 Key: CXF-3221
>                 URL: https://issues.apache.org/jira/browse/CXF-3221
>             Project: CXF
>          Issue Type: Bug
>    Affects Versions: 2.2.7
>            Reporter: Chris Wilson
>            Assignee: Christian Schneider
>
> StaxInInterceptor detects the wrong content type of the response, and throws an exception, in handleMessage().
> However it doesn't check the response code to see whether it's a redirect. In this case there may not be any useful HTML output, so the INVALID_HTML_RESPONSETYPE exception will not contain any information that helps to debug the fault.
> This could alternatively be seen as the job of HTTPConduit.WrappedOutputStream, which checks for 404 errors (HTTP_NOT_FOUND), but assumes that there will always be a response body.
> It's also not clear what the accessed URL was, to help with debugging.

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


[jira] Commented: (CXF-3221) StaxInInterceptor doesn't handle redirects well

Posted by "Chris Wilson (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CXF-3221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12995820#comment-12995820 ] 

Chris Wilson commented on CXF-3221:
-----------------------------------

Hi Christian,

The RITA RPC client (http://rita.logscluster.org/browser/rita/src/org/wfp/rita/rpc/RpcClientFactory.java), if configured to access the old server (http://rita.wfplogistics.org/rita/rpc/RpcServerInterface1), which sends redirects, should fail with this error.

Cheers, Chris.

> StaxInInterceptor doesn't handle redirects well
> -----------------------------------------------
>
>                 Key: CXF-3221
>                 URL: https://issues.apache.org/jira/browse/CXF-3221
>             Project: CXF
>          Issue Type: Bug
>    Affects Versions: 2.2.7
>            Reporter: Chris Wilson
>            Assignee: Christian Schneider
>             Fix For: NeedMoreInfo
>
>
> StaxInInterceptor detects the wrong content type of the response, and throws an exception, in handleMessage().
> However it doesn't check the response code to see whether it's a redirect. In this case there may not be any useful HTML output, so the INVALID_HTML_RESPONSETYPE exception will not contain any information that helps to debug the fault.
> This could alternatively be seen as the job of HTTPConduit.WrappedOutputStream, which checks for 404 errors (HTTP_NOT_FOUND), but assumes that there will always be a response body.
> It's also not clear what the accessed URL was, to help with debugging.

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

        

[jira] Commented: (CXF-3221) StaxInInterceptor doesn't handle redirects well

Posted by "Christian Schneider (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/CXF-3221?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12985551#action_12985551 ] 

Christian Schneider commented on CXF-3221:
------------------------------------------

Hi Chris. Redirects should be handled in HTTPConduit so they should not get to the StaxInterceptor. We also have tests for redirects so the normal case should work. Could you give me some more details under what circumstances the exception appears? Ideal would be a small maven project that I can run and see the problem. Could you also try with the just released 2.3.2 version maybe we already fixed that. 


> StaxInInterceptor doesn't handle redirects well
> -----------------------------------------------
>
>                 Key: CXF-3221
>                 URL: https://issues.apache.org/jira/browse/CXF-3221
>             Project: CXF
>          Issue Type: Bug
>    Affects Versions: 2.2.7
>            Reporter: Chris Wilson
>            Assignee: Christian Schneider
>
> StaxInInterceptor detects the wrong content type of the response, and throws an exception, in handleMessage().
> However it doesn't check the response code to see whether it's a redirect. In this case there may not be any useful HTML output, so the INVALID_HTML_RESPONSETYPE exception will not contain any information that helps to debug the fault.
> This could alternatively be seen as the job of HTTPConduit.WrappedOutputStream, which checks for 404 errors (HTTP_NOT_FOUND), but assumes that there will always be a response body.
> It's also not clear what the accessed URL was, to help with debugging.

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


[jira] Updated: (CXF-3221) StaxInInterceptor doesn't handle redirects well

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

Daniel Kulp updated CXF-3221:
-----------------------------

    Fix Version/s: NeedMoreInfo

> StaxInInterceptor doesn't handle redirects well
> -----------------------------------------------
>
>                 Key: CXF-3221
>                 URL: https://issues.apache.org/jira/browse/CXF-3221
>             Project: CXF
>          Issue Type: Bug
>    Affects Versions: 2.2.7
>            Reporter: Chris Wilson
>            Assignee: Christian Schneider
>             Fix For: NeedMoreInfo
>
>
> StaxInInterceptor detects the wrong content type of the response, and throws an exception, in handleMessage().
> However it doesn't check the response code to see whether it's a redirect. In this case there may not be any useful HTML output, so the INVALID_HTML_RESPONSETYPE exception will not contain any information that helps to debug the fault.
> This could alternatively be seen as the job of HTTPConduit.WrappedOutputStream, which checks for 404 errors (HTTP_NOT_FOUND), but assumes that there will always be a response body.
> It's also not clear what the accessed URL was, to help with debugging.

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