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

Early hints extension #342

Merged
merged 1 commit into from
Aug 25, 2022
Merged

Early hints extension #342

merged 1 commit into from
Aug 25, 2022

Conversation

pgjones
Copy link
Contributor

@pgjones pgjones commented Aug 23, 2022

This gives an ASGI mechanism for the application to indicate to the
server what early hints to send.

See https://developers.cloudflare.com/cache/about/early-hints/, https://httpwg.org/specs/rfc8297.html, and https://www.rfc-editor.org/rfc/rfc8288.html.

I hope to implement this in Hypercorn and replace my server push usage.

docs/extensions.rst Outdated Show resolved Hide resolved
docs/extensions.rst Outdated Show resolved Hide resolved
@andrewgodwin
Copy link
Member

Ah yes, with Server Push basically being officially dead it does seem like time. This looks pretty good - any concerns or other ways you might want to do it you avoided here?

@pgjones
Copy link
Contributor Author

pgjones commented Aug 24, 2022

I had thought of a more general http.informational_response message, but I can't think of why the ASGI app should want to send any other types. I also considered being more prescriptive about the link structure, but I think that is something the ASGI app can structure and decide like other headers.

Copy link
Member

@andrewgodwin andrewgodwin left a comment

Choose a reason for hiding this comment

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

OK, sounds sensible and totally agree on those points - a couple of tiny copy-edit changes and then I'm pretty happy with this.

docs/extensions.rst Outdated Show resolved Hide resolved
docs/extensions.rst Outdated Show resolved Hide resolved
This gives an ASGI mechanism for the application to indicate to the
server what early hints to send.
@andrewgodwin
Copy link
Member

Lovely, thanks. Let's hope this gains much more traction overall than Server Push!

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