From 6a1ec9a70f129ad746ef17708de4f4c73230e167 Mon Sep 17 00:00:00 2001 From: Mikel Rico Date: Wed, 7 Dec 2022 08:30:28 +0100 Subject: [PATCH 1/6] Refs #16328: Set FASTDDS_STATISTICS CMake option to ON Signed-off-by: Mikel Rico --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index e42a9f8d05a..f1ae790eddd 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -349,7 +349,7 @@ endif() ############################################################################### # Fast DDS statistics tool default setup ############################################################################### -option(FASTDDS_STATISTICS "Enable Fast DDS Statistics Module" OFF) +option(FASTDDS_STATISTICS "Enable Fast DDS Statistics Module" ON) ############################################################################### # Compile library. From ca7c3452eddfb6797b9ab432d67349dac02db933 Mon Sep 17 00:00:00 2001 From: Mikel Rico Date: Wed, 7 Dec 2022 09:16:04 +0100 Subject: [PATCH 2/6] Refs #16328: versions.md Signed-off-by: Mikel Rico --- versions.md | 1 + 1 file changed, 1 insertion(+) diff --git a/versions.md b/versions.md index a4703eed129..0f93070fc3d 100644 --- a/versions.md +++ b/versions.md @@ -5,6 +5,7 @@ Forthcoming * Statistics metrics are only calculated/accumulated when their corresponding DataWriter is enabled (behaviour change) * Added new log macros `EPROSIMA_LOG_INFO`, `EPROSIMA_LOG_WARNING` and `EPROSIMA_LOG_ERROR`, and change all old macros `logInfo`, `logWarning`, and `logError` in the project. * Added `ENABLE_OLD_LOG_MACROS` CMake option to support disabling the compilation of old log macros `logInfo`, `logWarning`, and `logError`. +* FASTDDS_STATISTICS build option set to ON by default Version 2.8.0 ------------- From 476470b558ded36e2763c5549b496a616f3f6226 Mon Sep 17 00:00:00 2001 From: Miguel Company Date: Wed, 7 Dec 2022 15:46:50 +0100 Subject: [PATCH 3/6] Do not include what you don't use Signed-off-by: Miguel Company --- test/unittest/statistics/dds/StatisticsQosTests.cpp | 1 - 1 file changed, 1 deletion(-) diff --git a/test/unittest/statistics/dds/StatisticsQosTests.cpp b/test/unittest/statistics/dds/StatisticsQosTests.cpp index 239a9ed6157..d5c1f73d1f1 100644 --- a/test/unittest/statistics/dds/StatisticsQosTests.cpp +++ b/test/unittest/statistics/dds/StatisticsQosTests.cpp @@ -33,7 +33,6 @@ #ifdef FASTDDS_STATISTICS #include -#include #endif // ifdef FASTDDS_STATISTICS namespace eprosima { From bcb24f191cf6fe488c20399756418d2e8302dd53 Mon Sep 17 00:00:00 2001 From: Eduardo Ponz Date: Wed, 7 Dec 2022 20:34:41 +0100 Subject: [PATCH 4/6] Refs #16328: Fix BlackboxTests_DDS_PIM.DDSDiscovery.AddDiscoveryServerToList when compiling with Statistics Signed-off-by: Eduardo Ponz --- test/blackbox/api/dds-pim/PubSubParticipant.hpp | 1 + 1 file changed, 1 insertion(+) diff --git a/test/blackbox/api/dds-pim/PubSubParticipant.hpp b/test/blackbox/api/dds-pim/PubSubParticipant.hpp index a2b0ab003a3..180edcdeca9 100644 --- a/test/blackbox/api/dds-pim/PubSubParticipant.hpp +++ b/test/blackbox/api/dds-pim/PubSubParticipant.hpp @@ -313,6 +313,7 @@ class PubSubParticipant if (participant_ != nullptr) { + participant_qos_ = participant_->get_qos(); type_.reset(new type_support()); participant_->register_type(type_); return true; From 9428f55c5acd30bcc2871d191eeb0c44f389e3b0 Mon Sep 17 00:00:00 2001 From: Miguel Company Date: Fri, 9 Dec 2022 12:33:52 +0100 Subject: [PATCH 5/6] Fix build errors on VS 141 --- src/cpp/statistics/rtps/StatisticsBase.cpp | 11 ++++------- .../statistics/rtps/reader/StatisticsReaderImpl.cpp | 10 ++++++++-- .../statistics/rtps/writer/StatisticsWriterImpl.cpp | 10 ++++++++-- 3 files changed, 20 insertions(+), 11 deletions(-) diff --git a/src/cpp/statistics/rtps/StatisticsBase.cpp b/src/cpp/statistics/rtps/StatisticsBase.cpp index 59fba61245c..a27f325f692 100644 --- a/src/cpp/statistics/rtps/StatisticsBase.cpp +++ b/src/cpp/statistics/rtps/StatisticsBase.cpp @@ -27,9 +27,6 @@ #include #include -using namespace eprosima::fastdds::statistics; -using eprosima::fastrtps::rtps::RTPSParticipantImpl; - namespace eprosima { namespace fastdds { namespace statistics { @@ -90,10 +87,6 @@ detail::SampleIdentity_s to_statistics_type( return *reinterpret_cast(&sample_id); } -} // statistics -} // fastdds -} // eprosima - StatisticsAncillary* StatisticsListenersImpl::get_aux_members() const { return members_.get(); @@ -644,3 +637,7 @@ void StatisticsParticipantImpl::on_edp_packet( listener->on_statistics_data(data); }); } + +} // statistics +} // fastdds +} // eprosima diff --git a/src/cpp/statistics/rtps/reader/StatisticsReaderImpl.cpp b/src/cpp/statistics/rtps/reader/StatisticsReaderImpl.cpp index 3c915064ed3..f8565957923 100644 --- a/src/cpp/statistics/rtps/reader/StatisticsReaderImpl.cpp +++ b/src/cpp/statistics/rtps/reader/StatisticsReaderImpl.cpp @@ -21,12 +21,14 @@ #include #include -using namespace eprosima::fastdds::statistics; - using eprosima::fastrtps::RecursiveTimedMutex; using eprosima::fastrtps::rtps::RTPSReader; using eprosima::fastrtps::rtps::GUID_t; +namespace eprosima { +namespace fastdds { +namespace statistics { + StatisticsReaderImpl::StatisticsReaderImpl() { init_statistics(); @@ -176,3 +178,7 @@ void StatisticsReaderImpl::on_subscribe_throughput( }); } } + +} // namespace statistics +} // namespace fastdds +} // namespace eprosima diff --git a/src/cpp/statistics/rtps/writer/StatisticsWriterImpl.cpp b/src/cpp/statistics/rtps/writer/StatisticsWriterImpl.cpp index 8eb040ffd30..ee811525310 100644 --- a/src/cpp/statistics/rtps/writer/StatisticsWriterImpl.cpp +++ b/src/cpp/statistics/rtps/writer/StatisticsWriterImpl.cpp @@ -21,12 +21,14 @@ #include #include -using namespace eprosima::fastdds::statistics; - using eprosima::fastrtps::RecursiveTimedMutex; using eprosima::fastrtps::rtps::RTPSWriter; using eprosima::fastrtps::rtps::GUID_t; +namespace eprosima { +namespace fastdds { +namespace statistics { + StatisticsWriterImpl::StatisticsWriterImpl() { init_statistics(); @@ -241,3 +243,7 @@ void StatisticsWriterImpl::on_publish_throughput( }); } } + +} // namespace statistics +} // namespace fastdds +} // namespace eprosima From d9e75bb93b3cb830194bf5a2767bfe3b380ed5bc Mon Sep 17 00:00:00 2001 From: Eduardo Ponz Date: Fri, 9 Dec 2022 13:09:15 +0100 Subject: [PATCH 6/6] Refs #16328: Fix linux warnings Signed-off-by: Eduardo Ponz --- src/cpp/rtps/participant/RTPSParticipantImpl.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/cpp/rtps/participant/RTPSParticipantImpl.cpp b/src/cpp/rtps/participant/RTPSParticipantImpl.cpp index 8e6566bd8b0..06e9b53eb35 100644 --- a/src/cpp/rtps/participant/RTPSParticipantImpl.cpp +++ b/src/cpp/rtps/participant/RTPSParticipantImpl.cpp @@ -1680,7 +1680,7 @@ bool RTPSParticipantImpl::createReceiverResources( while (!ret && (tries < m_att.builtin.mutation_tries)) { tries++; - *it_loc = applyLocatorAdaptRule(*it_loc); + applyLocatorAdaptRule(*it_loc); ret = m_network_Factory.BuildReceiverResources(*it_loc, newItemsBuffer, max_receiver_buffer_size); } }