http2

Detect browser if capable/enabled for http2 via javascript or php

懵懂的女人 提交于 2020-01-07 06:25:27
问题 I've checked on similar questions and found two options I can proceed with, however both have problematic issues. if ( performance && performance.timing.nextHopProtocol ) { console.log('Protocol:' + performance.timing.nextHopProtocol); } else if ( window.chrome && window.chrome.loadTimes ) { console.log('Protocol:' + window.chrome.loadTimes().connectionInfo); } else { console.log("Browser does not expose connection protocol"); } The above code does return the protocol however, while using my

Java 12 JMeter 5 HTTP/2 request java.lang.NoClassDefFoundError: org/eclipse/jetty/alpn/client/ALPNClientConnectionFactory

▼魔方 西西 提交于 2020-01-02 19:16:07
问题 I am using Java 12, JMeter 5.1.1 on Ubuntu 9.0.4 and bumps into the following exception when trying to send HTTP/2 request: Response code: Non HTTP response code: java.util.concurrent.ExecutionException Response message: Non HTTP response message: java.lang.IllegalStateException: No Client ALPNProcessors! And this stack trace in the response body: java.util.concurrent.ExecutionException: java.lang.IllegalStateException: No Client ALPNProcessors! at org.eclipse.jetty.util.FuturePromise.get

Jetty HTTP/2 Client example

China☆狼群 提交于 2020-01-02 08:09:44
问题 I used the client code Jetty provide to us. And some problem occurs. The code I wanna run is here https://github.com/eclipse/jetty.project/blob/master/jetty-http2/http2-client/src/test/java/org/eclipse/jetty/http2/client/Client.java And actually I know I come across the same problem like this Jetty HTTP/2 client receive server push example I stopped at this guy's update 2 and I have built a new project under the http2-client folder. But the problem still remains. INFO::main: Logging

HTTP/2 or Websockets for low latency client to server messages

南楼画角 提交于 2020-01-01 09:20:50
问题 I have a requirement to have very low latency for client to server messages in my web application. I have seen several posts on stackoverflow saying it would be preferable to use websockets instead of HTTP for this requirement, but it was quite some time ago. Today, in 2018, with the progress of HTTP/2, is it still worth using websockets for this use case ? 回答1: HTTP/2 has multiplexing, meaning that there should be no wait time - like there was under HTTP/1 due to the 6 connection limit per

Safari won't load some resources over http/2

陌路散爱 提交于 2020-01-01 08:33:53
问题 Http/2 is enabled on server and yesterday I noticed that on Iphone (IOS 10.2) does not load some resources with error: failed to load resource:connecting to server is not possible . When I connect Iphone to Mac there are no errors in console but simply result of some requests result imidiatelly in that error. Interesting thing could be the fact that resources which are not loaded are subdomain of real domain( CNAME to be correct). Site is on https. Server is Windows server 2016. EDIT: We

How to use http/2 with Okhttp on Android devices?

泪湿孤枕 提交于 2020-01-01 08:30:09
问题 I'M testing a site that supports HTTP/2,like this, and I try to use okhttp to send the request: OkHttpClient okHttpClient = new OkHttpClient(); Request request = new Request.Builder() .url("https://www.google.it") .build(); okHttpClient.newCall(request).enqueue(new Callback() { @Override public void onFailure(Request request, IOException e) { e.printStackTrace(); } @Override public void onResponse(Response response) throws IOException { Log.d("TestHttp", "OkHttp-Selected-Protocol: " +

Java HTTP/2 Server Socket

可紊 提交于 2019-12-30 06:21:12
问题 I want to get server sockets working for HTTP/2 in Java, preferably TLS/https. I've got a TLS server socket working fine, but browsers will only talk HTTP/1.1 to it. If I understand correctly, you need ALPN to get a HTTP/2 browser to connect to your TLS socket and start running HTTP/2 on it; browsers won't ask for upgrade to HTTP/2 on https. It seems Java8 does not do ALPN so far. Maybe there is some other way to coerce browsers to do HTTP/2, at least non-TLS. So, anybody know how to make a

Is it possible to run gRPC or HTTP/2 application in a AppEngine Managed VM?

让人想犯罪 __ 提交于 2019-12-25 05:30:14
问题 I am trying to build a gRPC backend and trying to deploy it on an AppEngine Managed VM. Is HTTP/2 supported? If not, can I simply expose it on a separate port and disable health checks or should I deploy this on compute engine/container engine. 回答1: At this point http/2 is not supported by Managed VMs. The best current solution is to run your http/2 server on a different port and specify the port number to forward in app.yaml (doc link). You can keep health checking active on the default

What is the best and current way to move to HTTPS on a large website?

时间秒杀一切 提交于 2019-12-25 03:37:34
问题 From watching HTTPS everywhere on YouTube they suggest that HTTPS and SPDY combined will be quicker than just serving web pages/assets over HTTP but then since reading SPDY is Dead. Long Live HTTP/2 and what with with HTTP2 support being a way off I am in two minds as to whether to move a large site I'm working on to HTTPS entirely as ultimately it will be slower since doing perf comparison tests (the DOM content loaded took twice the time to load). I also just read somewhere that browsers

Decoding http2 frame header/data in Go

二次信任 提交于 2019-12-25 03:19:04
问题 I am trying to read from a tcp connection which contains HTTP/2 data. Below is the code for reading HEADERS frame - framer := http2.NewFramer(conn, conn) frame, _ := framer.ReadFrame() fmt.Printf("fh type: %s\n", frame.Header().Type) fmt.Printf("fh type: %d\n", frame.Header().Type) fmt.Printf("fh flag: %d\n", frame.Header().Flags) fmt.Printf("fh length: %d\n", frame.Header().Length) fmt.Printf("fh streamid: %d\n", frame.Header().StreamID) headersframe := (frame1.(*http2.HeadersFrame)) fmt