Thanks Mark & Chris this is a very informative. I am using a httpd that supports http/2 and wow is it impressive. Sorry, I had to stop using Apache/Tomcat to use it but the performance and bandwidth gains are so nice it is addicting and my users have noticed. I will look into jre/jdk 9 and ask Oracle if servlet 4 is in the EA's. I would like to stay with http/2 rather than go to websockets but I am an early adaptor and if it is stable and has servlet 4 with http/2 I will give it a try and let you know the results. Best Regards,-Tony From: Mark Thomas <ma...@apache.org> To: Tomcat Users List <users@tomcat.apache.org> Sent: Friday, May 15, 2015 12:28 PM Subject: Re: Http 2 support in Tomcat On 15/05/2015 19:23, Christopher Schultz wrote: > Mark, > > On 5/15/15 12:59 PM, Mark Thomas wrote: >> On 15/05/2015 17:49, Christopher Schultz wrote: >>> Tony, >>> >>> On 5/15/15 12:06 PM, PerfGuru wrote: >>>> Good news thanks for the update. It may be some time before >>>> servlet 4 support is released but good to know Tomcat will be >>>> ready then. But does APR support http/2? I know other web >>>> servers now do. >>> >>> Mark's initial work on the HTTP/2 connector has been using APR. >>> Note that APR doesn't handle the HTTP protocol, it just helps >>> manage sockets, pools, etc. The protocol needs to be built on top >>> of those building blocks. Please see the dev list (archives) for >>> details. Just search for "HTTP/2" subjects. > >> Correct. This is primarily because ALPN support is not there in >> JSSE yet and wont be until Java 9. That said, one of the reasons >> for the huge amount of connector refactoring that I did before >> starting on HTTP/2 was so that the connector implementation >> specific code was kept to a minimum (so far just ALPN). HTTP/2 will >> work just fine with NIO and NIO2 just as soon as JSSE support ALPN >> and we plumb it in. > > Is this something that's workable with the current pre-release builds > of Java 9?
I have no idea. I haven't had time to look at it. If you fancy playing with it ..; ;) > Presumably, Servlet 4 will require Java 8. Does that mean > that HTTP/2 with the NIO connectors will only be available with a > higher JRE version? The good folks over at Jetty have an ugly hack (involves replacing part of the JRE) that back-ports the feature to Java 8 so it will be available that way. There are other options too. >> h2c support (HTTP/2 over a cleartext channel via HTTP upgrade >> rather than TLS) is also on the TODO list. It shouldn't be much >> work to add (less than a day) and it wil be available for all >> connectors. > >>> >>>> Also, I think Tomcat supports websockets which has the >>>> important capabilities that http/2 has and has been available >>>> longer. >>> >>> Tomcat supports Websocket since Tomcat 7, as long as you are >>> running on Java 7 or higher. >>> >>>> Depending upon your strategy you might want to go with that or >>>> wait a couple of years for http/2. Remember the firewalls, >>>> proxies and other network systems have to support http/2 before >>>> it can reach Tomcat. So it may be by the time http/3 is >>>> approved. > >> Tomcat has no choice (application developers do). Servlet 4.0 will >> require HTTP/2 so Tomcat has to support it. > >>> Correct. Using Websocket through certain proxies (e.g. httpd) is >>> even still sometimes tricky. > >> Yeah. We should touch base with jimjag and discuss this. I think >> the httpd thinking around WebSockets and the Java world thinking >> about WebSockets aren't quite lined up. > > +1 > > Perhaps there isn't much use for Websockets in the Perl or PHP world, > where a lot of httpd installations are being used. > > Jim Riggs's (reprise, I believe) presentation at ApacheCon about how > "mod_php needs to die" (paraphrasing) advocates more extensive use of > mod_proxy_* to physically separate the web tier from the application > tier, in a way that more closely resembles how Java webapps are > deployed. Perhaps if the world starts listening to the Jim Riggses of > the world, the shortcomings of mod_proxy_websocket and friends will > become more apparent. +1. Mark --------------------------------------------------------------------- To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org For additional commands, e-mail: users-h...@tomcat.apache.org