curl-library
Re: Application to request http2 content with multiplexed multiple streams
Date: Wed, 8 Aug 2018 14:39:10 +0200 (CEST)
On Tue, 7 Aug 2018, Rajvardhan Deshmukh wrote:
>> I looks fine, and you can verify yourself by reading the verbose
>> output as it states clearly when it reuses connections.
>
> It reuses some connections and most of the times it says " * Connection 75
> seems to be dead!
> * Closing connection 75 " and uses new one. Should i use some additional
> functionality that will keep the connection alive in all cases?
Normally that "seems to be dead" situation happens when the other side or a
NAT/firewall in the middle have deemed the connection idle and it has been
killed off.
> to get responses back to back (after one is downloaded request for the next)
> should i do something else (other than using curl_multi_perform() in a loop)?
> Do you mean i should include sleep so that it doesn't use the 100% of CPU?
If you look at the multi-using examples, they all use select() or
curl_multi_wait() in the loop to avoid it from spinning 100%. If there's
nothing to do, there's no point in looping...
-- / daniel.haxx.se ------------------------------------------------------------------- Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library Etiquette: https://curl.haxx.se/mail/etiquette.htmlReceived on 2018-08-08