Join GitHub today
GitHub is home to over 50 million developers working together to host and review code, manage projects, and build software together.Sign up
GitHub is where the world builds software
Millions of developers and companies build, ship, and maintain their software on GitHub — the largest and most advanced development platform in the world.
Ambiguous documentation for timing information while following redirects #4250
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.
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."
Suggested-by: Brandon Dong Fixes #4250