Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ambiguous documentation for timing information while following redirects #4250

Closed
brandondong opened this issue Aug 21, 2019 · 4 comments
Closed

Comments

@brandondong
Copy link

While reading through https://curl.haxx.se/libcurl/c/CURLINFO_TOTAL_TIME.html which mentions "total time of previous transfer" and https://curl.haxx.se/libcurl/c/CURLINFO_REDIRECT_TIME.html which mentions "the total time ... before final transaction was started", I got the impression that the CURLINFO_REDIRECT_TIME would include all the total times of the requests before the final one and CURLINFO_TOTAL_TIME would report the time for the final request. In addition, the time breakdown properties of CURLINFO_TOTAL_TIME like https://curl.haxx.se/libcurl/c/CURLINFO_NAMELOOKUP_TIME.html mention "total time in seconds from the start until ...." which would only make sense in the context of a single request rather than times being summed up for all the requests further reinforcing the idea that total time and its breakdown properties were describing the final request.

After some investigation, I found that this was not the case as a result of #1602. The documentation gave the impression of the old behaviour prior to the change and I feel that it should be updated or made clearer for the case of following redirects.

@bagder
Copy link
Member

bagder commented Aug 26, 2019

Do you have any suggestion wording we should add that would make the behavior clearer in your view?

@brandondong
Copy link
Author

I feel like adding a sentence explicitly mentioning what happens in the case of following redirects for all the timing properties except redirect time would be sufficient. Maybe something like, "When a redirect is followed, the time from each request is summed."

@bagder
Copy link
Member

bagder commented Aug 27, 2019

Thanks, that's what I did in PR #4269...

@brandondong
Copy link
Author

Looks good. Much appreciated!

@bagder bagder closed this as completed in 44c9884 Aug 27, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Nov 25, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Development

Successfully merging a pull request may close this issue.

2 participants