git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [BUG?] git http connection reuse

From
Daniel Stenberg <daniel@haxx.se>
Date
Feb 16, 2014, 12:18 UTC
Message-ID
<alpine.DEB.2.00.1402161307160.10435@tvnag.unkk.fr>
In-Reply-To
<377DF3F4-1F9B-4CB0-A9BF-658E561F4349@gmail.com>
On Sat, 15 Feb 2014, Kyle J. McKay wrote:
> If pipelining is off (the default) and total connections is not 1 it sounds 
> to me from the description above that the requests will be executed on 
> separate connections until the maximum number of connections is in use and 
> then there might be some reuse.

Not exactly. When about to do a request, libcurl will always try to find an existing idle but open connection in its connection pool to re-use. With the multi interface you can of course easily start N requests at once to the same host and then they'll only re-use connections to the extent there are connections to pick, otherwise it'll create new connections.

>> Daniel Stenberg (7 Jan 2014)
>> - ConnectionExists: fix NTLM check for new connection
> Looks like you're just lucky as that above change first appears in 7.35.0. 
> But it seems there are some patches for older versions so they might be 
> affected as well [2].

Right, the problem is there to make sure that a NTLM-auth connection with different credentials aren't re-used. NTLM with its connection-oriented authentication breaks the traditional HTTP paradigms and before this change there was a risk that libcurl would wrongly re-use a NTLM connection that was done with different credentials!

I suspect we introduced a regression here with that fix. I'll dig into this.
-- 
  / daniel.haxx.se
Previous: Kyle J. McKayNext: Daniel Stenberg
Message 3 of 11 in “[BUG?] git http connection reuse”
  1. Jeff KingFeb 16, 2014
  2. Kyle J. McKayFeb 16, 2014
  3. Daniel StenbergFeb 16, 2014
  4. Daniel StenbergFeb 16, 2014
  5. Jeff KingFeb 17, 2014
  6. Jeff KingFeb 17, 2014
  7. Daniel StenbergFeb 18, 2014
  8. Jeff KingFeb 18, 2014
  9. Daniel StenbergFeb 18, 2014
  10. Daniel StenbergFeb 18, 2014
  11. http: never use curl_easy_performJeff King, Feb 18, 2014

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.