Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[jetty-users] Asynchronous HTTP/2 requests + handle pushed resources

Hello,

I am trying to write an HTTP/2 client which takes a file, containing a list of URLs i.i resources to be fetched, as an argument. Previously I coded an HTTP/1 client that does this asynchronously: 

Asynchronous requests code snippet


I need to do something similar for HTTP/2 client as well but it needs to handle pushed resources as well. As per Simone's comment here: http://stackoverflow.com/questions/30010016/jetty-http-2-client-receive-server-push-example , the generic HTTP API doesn't support receiving pushed resources.

Now if I use lowlevel HTTP2CLIENT (because the client should receive pushed resources), is there any way that I can do asynchronous requests over the same connection, maintaining the requirement of only one TCP connection per domain, and still handling resources pushed by Jetty server.

I have gone through the API but do not understand yet how I can go about this.

Will you please provide some guidance or possible directions to look into.

Thank You.

Back to the top