Hi Miyako,

Hmm, sounds like I should be able to make something work, then. Worth trying.

Thanks.

--
Cannon.Smith
Synergy Farm Solutions Inc.
Hill Spring, AB Canada
403-626-3236
<[email protected]>
<www.synergyfarmsolutions.com>


> On Dec 14, 2017, at 5:45 PM, Keisuke Miyako via 4D_Tech 
> <[email protected]> wrote:
> 
> I have only started to learn using libcurl so my understanding is limited,
> but I think the general idea goes like this:
> 
> for a time consuming operation like HTTP where the slowness is largely 
> external to the application (i.e. network, server response), it could be 
> better to have a single thread performing multiple requests in a round robin 
> manner, where it will alternate between waiting (no point in stressing the 
> system) and calling select() with a decent timeout for each request. ideally, 
> you could get near completing 3 requests that each take 3 seconds to complete 
> in 3 seconds, not 9 seconds.
> 
> so it is not enough to just be non-blocking, or yielding to other threads. 
> the caller must also be nicer to other threads by alternating between idle 
> and busy while it waits for data, especially when the server takes time to 
> respond.
> 
> it might be interesting to call HTTP Request in a preemptive worker, but 
> whether the call relieves the application from stress may depend on other 
> factors as well.

**********************************************************************
4D Internet Users Group (4D iNUG)
FAQ:  http://lists.4d.com/faqnug.html
Archive:  http://lists.4d.com/archives.html
Options: http://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[email protected]
**********************************************************************

Reply via email to