curl / Mailing Lists / curl-library / Single Mail

curl-library

Application to request http2 content with multiplexed multiple streams

From: Rajvardhan Deshmukh via curl-library <curl-library_at_cool.haxx.se>
Date: Tue, 07 Aug 2018 14:58:38 -0400

Hi All,

1. I have written a code [1] to download 2 files at a time (multiplexed
using 2 streams). And i intend to download 100 total files. Can you
verify if i'm reusing the connection properly (concern as i use
curl_easy_init(); for each url). But this doc [2] says as long as i use
the same multi handle i should be good.

2. I also need to identify the api which requests chunks of data (so
that not all response data is written to the memory at the same time,
but as multiple of chunks). (Just like the 'iter_content(CHUNK_SIZE)' in
the requests [3] python library). Also can you give me an example of its
use? (Intend to use it with the code [1] in 1.)

Thanks,
Raj

Links:
------
[1]
https://gist.github.com/deshmukhrajvardhan/e3332da70925b40932216c3407b0caa3#file-multi-stream-libcurl-L1
[2] https://ec.haxx.se/libcurl-connectionreuse.html
[3]
https://github.com/requests/requests/blob/e4fc3539b43416f9e9ba6837d73b1b7392d4b242/requests/models.py#L724

-------------------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2018-08-07