curl / Mailing Lists / curl-library / Single Mail

curl-library

Re: Serverside Streaming connection using libcurl

From: Prashant Shubham via curl-library <curl-library_at_cool.haxx.se>
Date: Mon, 17 Dec 2018 17:12:22 +0530

On 12/16/18, Daniel Stenberg <daniel_at_haxx.se> wrote:
> On Sat, 15 Dec 2018, Prashant Shubham wrote:
>
>> But the data will not be coming always, I need to implement something like
>>
>> an action on server side will trigger a reponse which will go to client.
>> And
>> client will always keep listening for that response on that channel either
>>
>> there is data coming or not. Something similar to async push from server
>> to
>> client.
>>
>> Is there any API in libcurl to implement this?
>
> If you want the client to get the data as soon as it gets available then you
>
> should probably just make a request with curl and not have a timeout. Then
> curl will just sit there waiting for the transfer to start or complete,
> until
> the server does that. And when one transfer is done, the client can just
> issue
> another request and go back to waiting...
>
> --
>
> / daniel.haxx.se
>

Hi Daniel,
But meanwhile when we client is issuing another request what if server
has to send another new command to client, wouldn't the client miss
that command?

Thanks,
Prashant
-------------------------------------------------------------------
Unsubscribe: https://cool.haxx.se/list/listinfo/curl-library
Etiquette: https://curl.haxx.se/mail/etiquette.html
Received on 2018-12-17