You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Abhishek kumar srivastava <ab...@gmail.com> on 2019/01/21 08:36:04 UTC
Tomcat 9 : How to access Http/2 pseudoHeaders info from Request
Hi All ,
I want to access the value of "host" header at the Back-End in
servlet-filter , Before Http/2.0 Host information was available in the
Headers .
After switching to Http/2 I am able to send the request and receive the
response but information about the "host" header is not accessible on
calling request.getHeader("host") or request.getHeader(":authority") I am
getting null .
Is there any standarad API or workaround to get the Host information .
Tomcat : 9.0.12
java : jdk 8
Thank and Regards :
Rudra
Re: Tomcat 9 : How to access Http/2 pseudoHeaders info from Request
Posted by Mark Thomas <ma...@apache.org>.
On 21/01/2019 08:36, Abhishek kumar srivastava wrote:
> Hi All ,
>
> I want to access the value of "host" header at the Back-End in
> servlet-filter , Before Http/2.0 Host information was available in the
> Headers .
> After switching to Http/2 I am able to send the request and receive the
> response but information about the "host" header is not accessible on
> calling request.getHeader("host") or request.getHeader(":authority") I am
> getting null .
>
> Is there any standarad API or workaround to get the Host information .
ServletRequest.getServerName()
This works irrespective of the underlying protocol.
Mark
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org