cURL / Mailing Lists / curl-library / Single Mail

curl-library

libcurl : Issue with Threads and slower response time

From: Sandeep Kale <sandeep.skale_at_patni.com>
Date: Sun, 7 Sep 2008 19:58:15 +0530

Hi Dan,

I have am now getting good response time for the same request (in 700 - 1200
milli seconds) which is more than expected :).

I have done few changes in my libcurl code like,
1] Made an attempt to reuse the curl handle for subsequent transactions.
2} Replaced the CURLOPT_READFUNCTION and CURLOPT_READDATA function callbacks
with CURLOPT_POSTFIELDS option. This helped a lot.
3] Made CURLOPT_MAXCONNECTS and CURLOPT_FRESH_CONNECT set to 0 (force reuse
of the connection).

Thanks a lot for your help and attention :).

Regards,
San.

Date: Sat, 6 Sep 2008 09:50:21 -0700
From: Dan Fandrich <dan_at_coneharvesters.com>
Subject: Re: libcurl : Issue with Threads and slower response time
To: curl-library_at_cool.haxx.se
Message-ID: <20080906165020.GA9952_at_coneharvesters.com>
Content-Type: text/plain; charset=us-ascii

On Sat, Sep 06, 2008 at 03:04:18PM +0530, Sandeep Kale wrote:
> Currently I am getting correct response in 3.8 - 4 secs using libcurl ,
but
> I need the response within 1.5 - 1.9 sec as the other code using Rouge
wave
> library brings the response in 1.8 secs.

Just run Wireshark with both methods and see where the extra time is coming
from. There are too many possible source of the problem for us armchair
speculators to guess about without any data.

>>> Dan
Received on 2008-09-07