Bugzilla – Bug 638
Add a Tx trace source to UdpEchoClient class
Last modified: 2009-08-13 03:48:09 UTC
This add a "Tx" trace source to UdpEchoClient so that every time UdpEchoClient send a packet, a connected trace sink can receive the packet. I added this as I need to check the same packet when it is just transmitted out of a UdpEchoClient object and check again when it is just arrived to a PacketSink object. There are already many trace sources for PacketSink, but none is available to UdpEchoClient. OnOffApplication can also generate traffic, and it provides many trace sources including the Tx trace source coded in this patch. Nevertheless, UdpEchoClient allows specifying traffic generation process in terms of number of packets and inter-packet time interval. These are not provided by OnOffApplication class.
Created attachment 530 [details] Based on changeset 2081e0f6709d
+1; I noticed this trace is missing last week.
Created attachment 535 [details] Call Tx trace sinks before packets are sent Fixed a bug in the previous patch. Now the Tx trace is called right before calling the udp socket send. In this way, PacketTag added in trace sinks can be sent across networks. Previous patch placed the Tx trace after calling the udp socket send, thus adding PacketTag in trace sinks have no effect to the packets actually being sent.
since tom acked it, I pushed a slightly-modified version of the patch changeset e56da5fd6697