简体   繁体   中英

get push stream in response send by server push with OkHttp

I am trying to test the push response from a server which support HTTP2 Server with an android app (Os=Android KitKat) . The server push another ressources(pictures) after a http request for index.html.

I don't know how to access to push stream (picture). I have done capture on server and it send the push stream. But the client (Okhttp 2.1.0) always send a frame RST_STREAM and just return the index page content . I just start use okhttp and would like to know how to acces push stream from Okhttpclient response ? I have read that that it exist API for handle push stream from HTTP2. is it available in Okhttp 2.1.0 or Okhttp 2.2.0?

Thanks.

OkHttp doesn't implement pushed streams yet. When we do, it'll likely be to push into the cache only.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM