-
Notifications
You must be signed in to change notification settings - Fork 414
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
Is http2 supported? #124
Comments
Yes, you can test it with: package main
import (
"fmt"
"github.com/parnurzeal/gorequest"
)
func main() {
url := "https://http2.golang.org/reqinfo"
request := gorequest.New()
_, body, errs := request.Get(url).End()
if len(errs) == 0 {
fmt.Printf("%s", string(body))
} else {
fmt.Printf("ERR: %v\n", errs)
}
} which outputs:
|
It will fall back to HTTP/1.1 when you do anything special (such as Fix: import "golang.org/x/net/http2"
s := gorequest.New().Timeout(15 * time.Second)
http2.ConfigureTransport(s.Transport) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Is http 2.0 supported ?'
The text was updated successfully, but these errors were encountered: