Closed wannastar closed 10 months ago
Hi @wannastar
As you mentioned, FASTDDS_STATISTICS is set to ON by default in latest versions of Fast DDS. However, this does not imply that the internal statistics are enabled, as you should explicitly enable each specific statistic you want your application to report. Here you have the link to the documentation explaining how to do so.
For this case, my recommendation is to do it via environment variable. On each terminal running a Fast DDS application, just run the following command:
export FASTDDS_STATISTICS="HISTORY_LATENCY_TOPIC;NETWORK_LATENCY_TOPIC;PUBLICATION_THROUGHPUT_TOPIC;SUBSCRIPTION_THROUGHPUT_TOPIC;RTPS_SENT_TOPIC;RTPS_LOST_TOPIC;HEARTBEAT_COUNT_TOPIC;ACKNACK_COUNT_TOPIC;NACKFRAG_COUNT_TOPIC;GAP_COUNT_TOPIC;DATA_COUNT_TOPIC;RESENT_DATAS_TOPIC;SAMPLE_DATAS_TOPIC;PDP_PACKETS_TOPIC;EDP_PACKETS_TOPIC;DISCOVERY_TOPIC;PHYSICAL_DATA_TOPIC"
This will enable all the statistics in Fast DDS applications. In case you want to report just the latency statistic, run this other command:
export FASTDDS_STATISTICS="HISTORY_LATENCY_TOPIC"
![Uploading image.png…]()
step1: compile fastdds with -DFASTDDS_STATISTICS=ON(default is on)and -DPERFORMANCE_TESTS=ON step2: ./LatencyTest publisher -f payloads_demands.csv --domain 0 -s 1000000 ./LatencyTest subscriber -f payloads_demands.csv --domain 0 step3: configure fastddsmonitor to introspect FASTDDS LATENCY like picture1, but the graph is always empty.