eProsima / Fast-DDS-monitor

eProsima Fast DDS Monitor is a graphical desktop application aimed at monitoring DDS environments deployed using the eProsima Fast DDS library. Looking for commercial support? Contact info@eprosima.com
https://eprosima.com
GNU General Public License v3.0
39 stars 10 forks source link

latency statistic data is empty #194

Closed wannastar closed 10 months ago

wannastar commented 10 months ago

![Uploading image.png…]()

image

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.

rsanchez15 commented 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"