Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Titan » Test Performance in TITAN using Timestamps
Test Performance in TITAN using Timestamps [message #1791877] Fri, 06 July 2018 12:15 Go to next message
raed ben is currently offline raed benFriend
Messages: 2
Registered: June 2018
Junior Member
I would like to conduct a test performance between a server and a client by calculating the round trip time of one request. For this propose I have been using timer and to print out the value of the timer when receiving the server response. Although this approach works, when I conducted a traffic analyzer using wareshark, the results are quite different!
Therefore I would like to know how can i use timestamps in titan ?
thanks and regards
Re: Test Performance in TITAN using Timestamps [message #1792247 is a reply to message #1791877] Fri, 13 July 2018 08:17 Go to previous messageGo to next message
Elemer Lelik is currently offline Elemer LelikFriend
Messages: 1120
Registered: January 2015
Senior Member
Hi raed,

it's nothing surprising that the two timestamps , the one in Wireshark and the one in Titan , are different , although they should not differ by more than
maybe a few miliseconds.

If your processes are running on one processor thread, then Wireshark and Titan will execute sequentially, with a timing determined by the operating system, which presumably is a non-real time OS.
If they are executing on parallel processor threads , again, there's no reason the timestamps should be exactly the same.

If you are after ultimate accuracy you will have to use a real time operating system, possibly executing on a hardware that supports it;
we had experience with Titan running in such environment, but for a specific RTOS probably specific problems will have to be addressed.

Please remember that the (non-real time) operating system will distribute the execution between different processes as it sees fit ;
also , the more Titan logging you have activated ( as writing to hard disk is slow ) the more incertitude is introduced in the accuracy of timestamps .

In a generic environment you can trust the accuracy of Titan timestamps down to maybe around one millisecond, but in a specific environment you will have to run measurements to know exactly.

However performance and accuracy are two different things, and it's not clear from the above which is really important for you.
Titan is perfectly capable of running scalable traffic that can be used for performance test; we have also published code that supports this, see


RIoT - the IoT load/performance generator based on TTCN-3 and Titan
https://www.eclipse.org/forums/index.php/t/1093619/


Best regards
Elemer










Re: Test Performance in TITAN using Timestamps [message #1792249 is a reply to message #1792247] Fri, 13 July 2018 09:07 Go to previous messageGo to next message
Elemer Lelik is currently offline Elemer LelikFriend
Messages: 1120
Registered: January 2015
Senior Member
Hi raed ,

one more thing: when sending small TCP packets (less than 1000 bytes) the default behaviour of the kernel is to delay sending by 100 mseconds , with the reason that maybe there's some
data coming that can be sent together. This delay can affect timestamps significantly..

For instance, in the IPL4 test port this behaviour can be controlled by the boolean option no_delay:

type union Option {
  ReuseAddress  reuseAddress,
  TcpKeepAlive  tcpKeepAlive,
  SctpEventHandle   sctpEventHandle,
  TcpKeepAlive   sslKeepAlive,
  HostList       sctpAdditionalLocalAddresses ,
  integer        sctpEINConfigGroup,
  Linger_opt     solinger,
  SSL_proto_support ssl_support,
  boolean        no_delay,
  charstring     dtlsSrtpProfiles,
  SSL_cert_options  cert_options,
  boolean        freebind,
  record of charstring  alpn_list,
  charstring     tls_hostname,
  UDP_ENCAP_Param udp_encap,
  integer         dscp,
  MTU_discover mtu_discover,
  PSK_options    psk_options
}



BR

Elemer



Re: Test Performance in TITAN using Timestamps [message #1792572 is a reply to message #1792247] Thu, 19 July 2018 15:15 Go to previous messageGo to next message
raed ben is currently offline raed benFriend
Messages: 2
Registered: June 2018
Junior Member
Hallo Elemer,

many thanks for your detailed response. Actually in my case i am seeking accuracy because i m trying to develop a testbed which will allows me to figure weather a server is capable to work in a specific environment or not. For this propose I am trying to calculate the RTT of each request send to the server. I am using this code in order to get the RTT each time:
timer t;
//Connect to server 
connectToServer();
t.start(2.0);
//Send Message to the server
        SendMessage(testPort, LocalTCPConnection, connId, msgToSend);
//Receive Message from server
        if (ReceiveMessage(testPort, actualMsg))
            {
                log(t.read)
            }

Do you think what i used to calculate the RTT can be considered as accurate ? because as you may see I am using timers.
Also I m walling to install my application on a RTOS. Do you have any recommendation to do so ?
Since i m running the titan over a beaglebone without any desktop environment this solution (https://www.eclipse.org/forums/index.php/t/1093619/) won't work I'm guessing ?
thank you and regards,
Raed
Re: Test Performance in TITAN using Timestamps [message #1792601 is a reply to message #1792572] Fri, 20 July 2018 06:42 Go to previous message
Elemer Lelik is currently offline Elemer LelikFriend
Messages: 1120
Registered: January 2015
Senior Member
Hi Raed,


again, accuracy for a generic Linux environment should be around one msec;
a RTOS offers a non-buffering deterministic execution so certainly accuracy will improve; there are many RTOS's out there, I recommend you chose one
close to Linux, as it will have to support the gnu toolchain (gcc, make , ld).

One more thing you should keep in mind: timestamping can be done in different protocol layers, see below:

index.php/fa/33465/0/

technically, for UDP timestamping can be done in the kernel , or the test port code , which connects the kernel stack to the abstract application layer written in TTCN-3 or in the application layer itself.
For TCP timestamping can only be done in the test port code (after message extraction), as the kernel is agnostic to the concept of TCP message , or the application layer.

Timestamping in the kernel might improve accuracy, but it's available for UDP only and it assumes the TTCN-3 real time extension, which is not yet supported by Titan.
However for TCP timestamping in the kernel is not an option. (this is the reason we did not add the real-time extension as it would not significantly improve the accuracy of timing in Titan)


As for RIoT, if you successfully build Titan on Beaglebone, then RIoT should work as well. We have built Titan on Raspberry, Hummingboard etc. so Beaglebone should not be a problem.
The RIoT GUI is optional, it also has a command line interface, so you don't need desktop to run it.

Best regards
Elemer

[Updated on: Fri, 20 July 2018 06:46]

Report message to a moderator

Previous Topic:Problem with duplicate incoming message type boolean
Next Topic:A new set of JSON tools as external functions
Goto Forum:
  


Current Time: Thu Apr 25 14:37:52 GMT 2024

Powered by FUDForum. Page generated in 0.03346 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top