curl-and-php
CURL HTTP request Timeout
Date: Mon, 18 Apr 2011 14:08:34 +0530
Also copying murugaprabum_at_gmail.com, who is also involved but not in the mailing list.
Hi,
I am writing an application in which I will have to make multiple(50-100) HTTP requests to the same URL at the same time with different data.
Everytime I run X number of requests 75% of the requests complete in less than 20 seconds and the remaining 25% of the requests take between 200-600 seconds on an average.
1) Why is this happening ??
2) Assuming that it is happening by random probability. I naturally tend to Time out the CURL HTTP request in 20 seconds ( Average completion time for 75% of the requests) and retry the CURL request. I am afraid if this is the right thing to do.
Assuming that the Server will stop execution when the client closes the connection explicitly, will it not create the Server Side data inconsistent ??
For eg Lets say, the page I am requesting using CURL makes 10 DB inserts and I close the connection from client side when only 2 DB inserts are over. Will the 2 DB inserts actually happen ??
regards,
Kuberan Marimuthu
homepage: www.kuberan.me
twitter: @ikuberan
_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
Received on 2011-04-18