Bugzilla – Bug 217
sample/regression program tcp-2way
Last modified: 2008-06-24 12:17:12 UTC
Working towards a version of tcp-2way.cc suitable for release.
Created attachment 162 [details] proposed ns-3-dev/examples/tcp-2way.cc I have some #def's set for use as a regression test. It doesn't output anything as is except for ascii and pcap traces. I've changed the formatting to follow ns-3-dev, but may have missed a few things. I've included copyrights from my starting code and other things I've stolen, .... err. aggregated. With the current MTU, it send a first fragment with 3 packets in it, followed by fragments with the rest of the last packet. It also send 2 packets, in one fragment, on the back channel. It also tests if Tags are preserved from Tx to Rx over TCP.
Created attachment 163 [details] patch for ns-3-dev/examples/wscript to add tcp-2way
Created attachment 164 [details] proposed ns-3-dev/regression/tests/test-tcp-2way.py
Created attachment 169 [details] proposed ns-3-dev/examples/tcp-2way.cc Changed the SetConnectionCallback and SetAcceptCallback to the current API. There's some cleanup and some new callbacks to add as TODOs.
Created attachment 170 [details] new version that sends increasing sizes back and forth.... This test version send packets from size 0 to 10000 by decades. There are a few weird packets that very large headers, and MTUs that are > they typical value of 536.
Created attachment 174 [details] cleaned up version of tcp-2way with packet's scheduled in.... I removed most of the #defines to clean up the code, and removed a bunch of debugging output to make the code a little more readable. Still more to do. Right now I get different fatal errors depending on if VERBOSE_TESTING is #defined or not. With it, the program dies during Packet::Print, without it dies in the NS_ASSERT that checks the existence of Rx addr. Both of these are in TalkerApp::HandleRead().
Created attachment 175 [details] much cleaned up and better documented version. I've added more comments and cleaned up the code a bit more. NOTE: I've also added a #define TOO_SMALL_BUG which is you uncomment in the code will cause the program to die earlier than the other bug this program exercises.
fixed in the latest version. thx