Indy TIdHTTP POSTs getting slow responses

Posted on 2013-06-19
Medium Priority
Last Modified: 2013-07-04
I am having a problem with a Delphi 5 app, utilising first Indy 9, and then Indy 10.

Components in use (Indy 9):
TIdHTTP, TIdConnectionIntercept & TIdSSLIOHandlerSocket.
Components in use (Indy 10):
TIdHTTP, TIdConnectionIntercept & TIdSSLIOHanlderSocketOpenSSL.
(SSL is in use, with no TIdAntiFreeze in use)

The problem the app is presently experiencing is slow responses (between 3 and 25 seconds) to TIdHTTP POSTs.

Based on assorted links, I have tried:
- setting ConnectTimeout to zero
- setting the HTTPOptions flag hoKeepOriginalProtocol
- upgraded from 9 to 10 (10.5.8 XE2)

As a test, I also tried using a test executable written in C# (HttpWebRequest), which gets split-second response times.

Is there anything else I can try with Indy 9/10 config?
Question by:brenlex
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 3

Expert Comment

ID: 39261720
off the top of my head, it could be a certificate verification issue.
try disabling SSL, just to test if it makes any difference.

Author Comment

ID: 39262029
Not possible. Customer won't allow it.

Expert Comment

ID: 39262150
I didn't mean to disable SSL permanently or in the final product.
I meant to disable it temporarily, only to test if something changes.
If nothing changes, you have to look elsewhere.
If something changes, you'll know what to focus on.

Alternatively, you can use Wireshark to track the connection and see where's the bottleneck.
Looking for the Wi-Fi vendor that's right for you?

We know how difficult it can be to evaluate Wi-Fi vendors, so we created this helpful Wi-Fi Buyer's Guide to help you find the Wi-Fi vendor that's right for your business! Download the guide and get started on our checklist today!


Author Comment

ID: 39264747
I understand -- it would be easier to diagnose. Unfortunately the equipment to which I am attaching is only accessible via HTTPS -- out of my control.

I don't think Wireshark would work with SSL in place.

Accepted Solution

lomo74 earned 1500 total points
ID: 39265016
What about stunnel + wireshark.

Author Closing Comment

ID: 39299787
In the end I just rewrote the app in C# - now no issues with speed. Have some points for the heads-up on stunnel -- handy one for next time.

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

A lot of questions regard threads in Delphi.   One of the more specific questions is how to show progress of the thread.   Updating a progressbar from inside a thread is a mistake. A solution to this would be to send a synchronized message to the…
Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
Have you created a query with information for a calendar? ... and then, abra-cadabra, the calendar is done?! I am going to show you how to make that happen. Visualize your data!  ... really see it To use the code to create a calendar from a q…
In this video, Percona Solution Engineer Rick Golba discuss how (and why) you implement high availability in a database environment. To discuss how Percona Consulting can help with your design and architecture needs for your database and infrastr…
Suggested Courses

719 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question