Welcome! Log In Create A New Profile

Advanced

Re: [PATCH] HTTP/2: copy additional headers in the pushed requests

Alessandro Ghedini
February 08, 2018 03:52PM
On Thu, Feb 08, 2018 at 10:28:34PM +0300, Ruslan Ermilov wrote:
> On Thu, Feb 08, 2018 at 05:07:49PM +0000, Alessandro Ghedini wrote:
> > On Thu, Feb 08, 2018 at 05:04:58PM +0000, Alessandro Ghedini wrote:
> > > # HG changeset patch
> > > # User Alessandro Ghedini <alessandro@cloudflare.com>
> > > # Date 1518109032 0
> > > # Thu Feb 08 16:57:12 2018 +0000
> > > # Branch push-copy-headers
> > > # Node ID 4f7f42e6d13add2ab0c7a9654472bb74085181d1
> > > # Parent a49af443656f2b65ca5de9d8cad5594f44e18ff7
> > > HTTP/2: copy additional headers in the pushed requests.
> > >
> > > To ensure pushed requests are processed consistently with the original
> > > client request, some headers need to be copied from the original request
> > > into the pushed one.
> > >
> > > The headers currently copied are User-Agent, Accept, Accept-Language and
> > > Accept-Encoding.
> >
> > So, I'm not quite sure if this is the correct way to go about doing this, but
> > I think the issue is real and worth fixing, so I'd be happy to implement this
> > differently if you have alternative ideas.
>
> I don't think this is a good idea. Copying Accept is definitely
> a bad idea. If this is at all needed, this should be implemented
> as an "http2_push_header <header> <value>" directive, but then it
> could not be made dependent on the pushed resource.

So, I guess this could be implemented so you can have something like:

http2_push_header User-Agent $http_user_agent
...

This would work for me, and indeed is much better than just having a static
list of headers like I did. I'll look into making a patch if this is something
you'd be happy with.

Cheers
_______________________________________________
nginx-devel mailing list
nginx-devel@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx-devel
Subject Author Views Posted

[PATCH] HTTP/2: copy additional headers in the pushed requests

Alessandro Ghedini 1010 February 08, 2018 12:06PM

Re: [PATCH] HTTP/2: copy additional headers in the pushed requests

Alessandro Ghedini 388 February 08, 2018 12:10PM

Re: [PATCH] HTTP/2: copy additional headers in the pushed requests

Maxim Dounin 398 February 08, 2018 02:20PM

Re: [PATCH] HTTP/2: copy additional headers in the pushed requests

Alessandro Ghedini 370 February 08, 2018 03:06PM

Re: [PATCH] HTTP/2: copy additional headers in the pushed requests

ru@nginx.com 502 February 09, 2018 02:26AM

Re: [PATCH] HTTP/2: copy additional headers in the pushed requests

Alessandro Ghedini 385 February 12, 2018 07:44AM

Re: [PATCH] HTTP/2: copy additional headers in the pushed requests

ru@nginx.com 479 February 08, 2018 02:30PM

Re: [PATCH] HTTP/2: copy additional headers in the pushed requests

Alessandro Ghedini 343 February 08, 2018 03:52PM

Re: [PATCH] HTTP/2: copy additional headers in the pushed requests

Piotr Sikora via nginx-devel 362 February 08, 2018 03:58PM

Re: [PATCH] HTTP/2: copy additional headers in the pushed requests

Maxim Dounin 361 February 09, 2018 10:50AM



Sorry, you do not have permission to post/reply in this forum.

Online Users

Guests: 204
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready