Join 34,000+ subscribers and receive articles from our blog about software quality, testing, QA and security.
 

Question about time with TCP


#1

I noted tha TCP is quite slow. My question is once there is a connection and we have KeepConnection true there is a big overhead or not.

some time is usefull to use timesamp in packets to profile some part of code.

Thanks
Ing Giuseppe Monteleone


#2

Hello Giuseppe,

You can say that there is a factor of 20-50 in performance between logging with TCP and logging to a file. Logging with TCP is more expensive because the log packet must go through the entire TCP/network stack before the Console can receive and display it. When accurate timestamps are needed for profiling, it is thus recommended to log to a file rather than to use TCP.


#3

Giuseppe,

how many log entries per second can you log with your current configuration? If it’s less than a few thousands per second via TCP/IP, then there’s something wrong (e.g., the library is trying to reconnect the entire time because it loses its connection).


#4

Hi

I’m sorrry i red your article about memory performance only after I wrote the post.
Actually i use backlog (wich has speed like memory protocol, I presume) with a dummy error to dump on consolle.

Due the advantage of memory protocol could be usefull a dispatch method do flush entry to consolle. This could be usefull when used with the capability of Borland BreakPoint to execute code, for example

Merging Memory protocol and file or TCP protocol could give to Si a extreme powerfull method to profile code.

Regards
Ing Giuseppe Monteleone


#5

Hello Giuseppe,

Thanks for the idea. It sounds indeed very interesting. I added it to our feature request list.