curl-library
Re: curl_http_post: How to minimize the data usage
Date: Tue, 17 Jan 2017 23:41:32 +0000
Hi Daniel,
Is there any curl_debug option, to capture the exact amount of data usage
that is happening via http_post?
thanks.
On Tue, Jan 17, 2017 at 11:10 PM, Daniel Stenberg <daniel_at_haxx.se> wrote:
> On Tue, 17 Jan 2017, Kman Devnull wrote:
>
> I am currently using HTTP_POST with curl on my RPi like device to send
>> data to cloud from my IoT sensor. It consumes around 3MB of data on my SIM
>> connection.
>>
>> Is there anything I could set in my curl/options to minimize the
>> data_usage? i.e. something like may be to strip away all the HTTP headers,
>> and to ensure only the actual data is sent across ?
>>
>
> If you check how much headers curl sends in a request like that, you'll
> notice that the total ammount will be at max a few hundred bytes. If you'd
> do it over http2 it could compress the headers, even if it would compress
> really good you'd only gain data in the order of hundreds of bytes and
> you're talking about a 3MB post here.
>
> Your post is large simply because you're sending large amounts of data.
>
> --
>
> / daniel.haxx.se
> -------------------------------------------------------------------
> List admin: https://cool.haxx.se/list/listinfo/curl-library
> Etiquette: https://curl.haxx.se/mail/etiquette.html
-------------------------------------------------------------------
List admin: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2017-01-18