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
Support H2 early hints #2047
Comments
I try to update the Server side code myself but I have no idea how to test C/C++ code locally |
Thanks for this suggestion and contribution. We'll take a closer look in the near future. |
For testing I did this: compiled the branch with Currently it appears that there is a problem with |
This currently sends as many 103 responses as there are asset tags, which MAY be valid but certainly isn't ideal. This is due to rails calling the rack EARLY HINTS lambda in each asset tag (https://github.com/rails/rails/blob/master/actionview/lib/action_view/helpers/asset_tag_helper.rb). I can't seem to find the rack spec for early hints, to check if the callback should be called only once or if multiple calls are permitted and the app server should aggregate on its end. Since rails is going for n calls, we'll likely have to support that regardless. |
I guess it's not very possible to have 1 call only ===== Hi I am splitter =====
If it's not implemented that way the hints won't be "early" |
I've got this working in the standalone builtin engine, but both nginx and apache have issues with the early-header style. |
@CamJN |
I think Camden was referring to issues within Nginx and Apache itself. Factors that we have little control over. By the way w.r.t. how the Passenger C++ code is structured: I've been playing with the idea for a while of slowly moving portions of the Passenger codebase to Go, in order to make development and maintenance easier in the future. The biggest problem would be requiring users who aren't using our binaries (e.g. Debian packages) to have a sufficiently recent Go compiler installed. What do you think of this idea? |
It depends on how easy to get and use the compiler for developing passenger in different environments |
Yes I agree, I am also thinking about writing more developer documentation in the future. |
Issue report
Fill in as much as possible so that we can understand, find and fix the problem.
Question 1: What is the problem?
Support setting
rack.early_hints
inenv
when processing a request which allow rails to send early hint headersNot supported yet
Rails PR
Puma PR
Question 2: Passenger version and integration mode:
open source 5.2.1 standalone
Your answer:
Question 3: OS or Linux distro, platform (including version):
OS X 10.12.6 Sierra, x86_64
Your answer:
Question 4: Passenger installation method:
Your answer:
[x] RubyGems + Gemfile
[ ] RubyGems, no Gemfile
[ ] Phusion APT repo
[ ] Phusion YUM repo
[ ] OS X Homebrew
[ ] source tarball
[ ] Other, please specify:
Question 5: Your app's programming language (including any version managers) and framework (including versions):
Your answer:
Ruby 2.5.0, RVM, Rails 5.1.5
The text was updated successfully, but these errors were encountered: