hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Oleg Kalnichevski (JIRA)" <j...@apache.org>
Subject [jira] Updated: (HTTPCLIENT-927) "Narrowly avoided an infinite loop in execute" should not be logged as an error.
Date Thu, 08 Apr 2010 13:50:36 GMT

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

Oleg Kalnichevski updated HTTPCLIENT-927:
-----------------------------------------

    Affects Version/s:     (was: 4.0.1)
                       3.1 Final
        Fix Version/s:     (was: 4.1 Alpha2)

The given code snippet is from 3.1 version of HttpClient, not from 4.0.1 as stated in the
report. There will be no changes in the HttpClient code line other than fixes for severe security
related issues.

Closing as WONTFIX

Oleg.

> "Narrowly avoided an infinite loop in execute" should not be logged as an error.
> --------------------------------------------------------------------------------
>
>                 Key: HTTPCLIENT-927
>                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-927
>             Project: HttpComponents HttpClient
>          Issue Type: Improvement
>          Components: HttpClient
>    Affects Versions: 3.1 Final
>            Reporter: Qin Zang
>
> In the executeMethod(), upon received the "Redirect" as the HTTP Response Code, the code
will log an error if the maxRedirects was set to 0 as in the following code. This is not an
error, if someone want to stop the automatic redirect behavior. It should be logged as a warning
or debug message.
>   178 if (isRedirectNeeded(method)) {
>   179                       if (processRedirectResponse(method)) {
>   180                           retry = true;
>   181                           ++redirectCount;
>   182                           if (redirectCount >= maxRedirects) {
>   183                               LOG.error("Narrowly avoided an infinite loop in execute");
>   184                               throw new RedirectException("Maximum redirects ("
>   185                                   + maxRedirects + ") exceeded");
>   186                           }
>   187                           if (LOG.isDebugEnabled()) {
>   188                               LOG.debug("Execute redirect " + redirectCount + "
of " + maxRedirects);
>   189                           }
>   190                       }
>   191                   }

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


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org


Mime
View raw message