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

Questions about HTTP/2 implementation methods. #50

Closed
dgrr opened this issue Aug 7, 2018 · 3 comments
Closed

Questions about HTTP/2 implementation methods. #50

dgrr opened this issue Aug 7, 2018 · 3 comments

Comments

@dgrr
Copy link

dgrr commented Aug 7, 2018

Hello,

I am developing HTTP/2 for fasthttp a week ago and I am finding some troubles.
My implementation consists of integrating HTTP/2 protocol inside fasthttp and making user choose if he/she wants HTTP/2 enabled or not by using boolean var in Server.
All goes well until now... To make this implementation possible I do the following:

  • Create a new handler (I tried to keep the serveConn function as default connection handler but this is impossible due to framing model of HTTP/2).
  • I adapted some functions to HTTP/2 request and response model.
  • Obviously I implemented HPACK RFC.
  • And another stuff I don't remember right now.

At this point I am confused with the current implementation. I want to reuse all the code as much as I can but I see that the best way to make HTTP/2 possible in fasthttp is by making a new package (or subpackage) implementing this protocol (as net/http has) or making a radical change of the library.

There are two ways:

  • Keeping the current schema and adapting it to HTTP/2 protocol by changing all the code written by @valyala as much as we need to make HTTP/2 possible.
  • Creating new subpackage and making Server.tlsConfig public (because this variable must be treated by HTTP/2 implementation)

What do you think or what do you prefer?

@erikdubbelboer
Copy link
Owner

It's hard for me to reason about this as I have no idea what kind of changes would be required to the code. Would a subpackage and making Server.tlsConfig public be enough? What would the interface for this subpackage be?

@dgrr
Copy link
Author

dgrr commented Aug 11, 2018

Okay. I created new repository to implement HTTP/2 protocol and to be compatible with your fork @erikdubbelboer

@erikdubbelboer
Copy link
Owner

Ok I added myself as Watcher so I can see your commits.

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

No branches or pull requests

2 participants