Review Request: Cleanup the use of HTTPProtocol::httpClose
Dawit Alemayehu
adawit at kde.org
Sun Oct 23 17:09:28 BST 2011
> On Oct. 12, 2011, 10:51 p.m., Andreas Hartmetz wrote:
> > This changeset changes some important parts without obvious (to me) gain.
> > Before I spend an hour or two thinking through all the cases, which may or may not catch potential regressions, I'd like to know what this does for us.
> > The current approach of acting a bit dumb seems more robust.
>
> Dawit Alemayehu wrote:
> Here is the gains we get out of this change:
>
> #1. Keep persistent connection on non-connection related errors. There is no reason to tear down our connection to a server on errors such as ERR_USR_CANCELED.
> #2. Avoid unnecessary performance hit by not calling httpClose multiple times. This is especially true for ::get which is by the far the most called function in this ioslave. For no good reason however, httpClose is called at least two times everytime ::get is successfully invoked.
>
> BTW, if you tell me the use cases which I should test, then I will be willing to do the regression testing. I have already gone through each of the ioslave functions to see if this change will affect any of them. I have even tested the most commonly used ones (get, post, put) through a proxy server to see if there are any regressions. So far I have not encountered one.
Can I commit this change ? Or do you still have objections to it ?
- Dawit
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/102801/#review7282
-----------------------------------------------------------
On Oct. 8, 2011, 5:16 a.m., Dawit Alemayehu wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> http://git.reviewboard.kde.org/r/102801/
> -----------------------------------------------------------
>
> (Updated Oct. 8, 2011, 5:16 a.m.)
>
>
> Review request for kdelibs and Andreas Hartmetz.
>
>
> Description
> -------
>
> This patch cleans up where and under what circumstances httpClose gets called. This is done to avoid unnecessary invocation of httpClose. With this patch the function will only get called under the following circumstances:
>
> #1. from functions that only call proceedUntilResponseHeader directly.
> #2. from proceedUntilResponseContent.
> #3. from error
> #4. from davFinished.
>
> The main purpose of this change is to avoid httpClose being called multiple times on every GET request which is by far the most invoked call.
>
>
> Diffs
> -----
>
> kioslave/http/http.h 4c62841
> kioslave/http/http.cpp 2862707
>
> Diff: http://git.reviewboard.kde.org/r/102801/diff/diff
>
>
> Testing
> -------
>
>
> Thanks,
>
> Dawit Alemayehu
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20111023/68bbd566/attachment.htm>
More information about the kde-core-devel
mailing list