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

http: add support selecting http version #1968

Merged
merged 1 commit into from
Dec 6, 2018

Conversation

dscho
Copy link
Member

@dscho dscho commented Dec 6, 2018

This is a backport of git@d73019feb44b (which made it already to next). It allows setting http.version to HTTP/1.1 or HTTP/2 to choose the version of the HTTP protocol to use.

This might be important e.g. to let users choose to downgrade to HTTP/1.1 when the desired authentication scheme is incompatible with HTTP/2 (such is the case for NTLM, but we already have a cURL-side patch for that in the pipeline: curl/curl#3345).

Usually we don't need to set libcurl to choose which version of the
HTTP protocol to use to communicate with a server.
But different versions of libcurl, the default value is not the same.

CURL >= 7.62.0: CURL_HTTP_VERSION_2TLS
CURL < 7.62: CURL_HTTP_VERSION_1_1

In order to give users the freedom to control the HTTP version,
we need to add a setting to choose which HTTP version to use.

Signed-off-by: Force Charlie <charlieio@outlook.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Copy link

@derrickstolee derrickstolee left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm happy to forward-port this, since you're using the commit directly out of 'next'. Should help if we don't get the curl fix in early enough.

@dscho dscho merged commit 433dc93 into git-for-windows:master Dec 6, 2018
@dscho dscho deleted the http-version branch December 6, 2018 22:31
@dscho dscho added this to the v2.20.0 milestone Dec 6, 2018
dscho added a commit to git-for-windows/build-extra that referenced this pull request Dec 6, 2018
The desired HTTP version (HTTP/2 or HTTP/1.1)
[can now be configured via the `http.version`
setting](git-for-windows/git#1968).

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
dscho added a commit to dscho/git that referenced this pull request Dec 6, 2018
http: add support selecting http version
dscho added a commit to dscho/git that referenced this pull request Dec 9, 2018
http: add support selecting http version
dscho added a commit to dscho/git that referenced this pull request Dec 15, 2018
http: add support selecting http version
dscho added a commit to dscho/git that referenced this pull request Feb 7, 2019
http: add support selecting http version
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants