PSS. why can't it call the callback when it has some data and then call it
again when it gets more? kinda like curl does. There is only so much a
socket can get at a time.

So your loop holds onto the socket and if there is data calls the call back
for that socket, then goes back to the top of the loop.
A slow reader or a slow writer just doesn't have data on the socket and
does not impact the other readers and writers. (like LIVE555 does for RTSP)


On Tue, Aug 19, 2014 at 5:33 PM, Sergey Lyubka <[email protected]> wrote:

> Mongoose does this: spools file to memory, and when the whole file is
> buffered, it invokes a callback.
> I think mongoose blocks during big file write IO operation, and the
> callbacks blocks for a long time.
>
> Could you try using upload.c example please?
>
> I think I might refactor the example to save the file in the separate
> thread.
>
>
> On Tue, Aug 19, 2014 at 9:48 PM, <[email protected]> wrote:
>
>> Hi,
>>
>> When uploading a large file (100+ megabytes), Mongoose seems to block
>> until the entire file is uploaded.  New requests are not accepted and the
>> user callback function is not invoked.  It can take many minutes before
>> unblocking.  I'm patterning my code off of the "big_upload.c" example.
>>
>> Is it expected that Mongoose will block while reading the data and only
>> once that is done, invoke the callback and accept new connections?  Does
>> Mongoose hold the entire data set in memory or could there be some sort of
>> streaming going on?
>>
>> Thanks,
>> Doug
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "mongoose-users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected].
>> To post to this group, send email to [email protected].
>> Visit this group at http://groups.google.com/group/mongoose-users.
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>  --
> You received this message because you are subscribed to the Google Groups
> "mongoose-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> Visit this group at http://groups.google.com/group/mongoose-users.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups 
"mongoose-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/mongoose-users.
For more options, visit https://groups.google.com/d/optout.

Reply via email to