Name resolution delays

(obones) #1

We are using various “Super” channels here and we have noticed somewhat random delays when using the channels.
Basically, if we set the host name to localhost, we see a delay between 3 to 20 seconds before the connection establishes.
If we use then the connection is made really fast, in less than one second.
And the same goes if we use a real server name like versus its IP address.
What’s even stranger is that the delays are not for the first use of any given name, but may suddenly go from 3 to 20 seconds after having used them 5 or 10 times.

Do you guys have any hint as to what we could look at to solve this? We are especially surprised by the localhost situation that seems to us should be immediate.


(EvgenyK) #2


What platform you are using (Delphi or .NET)?


(obones) #3

The server is in Delphi and the clients are 99% Delphi with 1% C#
The slowdowns were all reported with Delphi but the C# part is quite young, so we can’t be sure.


(EvgenyK) #4

is this delay reproduced with all SuperTCP channels or with specific implementation, say with Indy only or with Synapse only ?


(obones) #5

In the most common project, we are using TROSynapseSuperHTTPChannel on the Delphi client side and IpSuperHttpClientChannel on the C# client side.
On the server side, we use TROIpSuperHTTPServer
I haven’t checked with Indy based channels for the client side.

On another project, Delphi only this time, we use TROSynapseSuperTCPServer on the server side and TROSynapseSuperTCPChannel

I hope this makes it clearer


(EvgenyK) #6

Can you recheck if delay will be reproduced with TROSuperTCPChannel (indy based) in your environment?


(marc hoffman) #7

I assume you have ruled out general issues with local DNS resolving? Do host name resolve fine in the browser, or with nslookup from the command line? what about a generic non-RO Indy client?

indeed. But this will still go thru the OS’s name lookup logic, even if it should (of course) resolve locally w/o a remote DNS request. Since both C# and Delphi clients show the problem, my money would be on something wring in the OS network stack, not the apps.