Adds immediate migration results in progress

This commit is contained in:
torsten committed 2026-08-19 11:18:24 +02:00
1 parent 8453e104c5
commit 3bb6e89496
2102 files changed
+17482 -15071

No files matched your search

@@ -53,19 +53,19 @@ public:
const std::string &specialTopicName,
const StructType &structType)
{
DEBUG_LOG() << "IN DynamicDataReader::create ("
DEBUG_LOG(m_logger) << "IN DynamicDataReader::create ("
<< m_structType->name()
<< ")";
if (domainParticipant == nullptr)
{
ERROR_LOG() << "DomainParticipant does not exist ";
ERROR_LOG(m_logger) << "DomainParticipant does not exist ";
return false;
}
if (m_ddsTopic != nullptr)
{
ERROR_LOG() << "Type '"
ERROR_LOG(m_logger) << "Type '"
<< m_structType->name()
<< "' already created";
return false;
@@ -84,7 +84,7 @@ public:
DDS::Helper::getShortTopicName(m_structType->name()) :
specialTopicName;
DEBUG_LOG() << "Creating topic " << topicName << " with type: "
DEBUG_LOG(m_logger) << "Creating topic " << topicName << " with type: "
<< m_structType->name();
m_ddsTopic = dds::topic::find<dds::topic::Topic<DynamicData>>(domainParticipant, topicName);
@@ -97,16 +97,16 @@ public:
m_ddsTopic = dds::topic::Topic<DynamicData>(domainParticipant, topicName, structType);
}
DEBUG_LOG() << "m_ddsTopic created: " << m_ddsTopic.name();
DEBUG_LOG(m_logger) << "m_ddsTopic created: " << m_ddsTopic.name();
if (m_logger.isDebugEnabled())
{
dds::sub::qos::SubscriberQos subscriberQoS = ddsSubscriber.qos();
dds::core::policy::Partition partition = subscriberQoS.policy<dds::core::policy::Partition>();
dds::core::StringSeq parititionNames = partition.name();
DEBUG_LOG() << "Subscribing partitions: " << parititionNames.size();
DEBUG_LOG(m_logger) << "Subscribing partitions: " << parititionNames.size();
for (const std::string &name : parititionNames)
DEBUG_LOG() << "SubscriberQoS: partition name = " << name;
DEBUG_LOG(m_logger) << "SubscriberQoS: partition name = " << name;
}
dds::sub::qos::DataReaderQos dataReaderQos = ddsSubscriber.default_datareader_qos();
@@ -129,7 +129,7 @@ public:
if (m_dataReader == nullptr)
{
ERROR_LOG() << "Creating dataReader for '" << topicName << "' with type: '"
ERROR_LOG(m_logger) << "Creating dataReader for '" << topicName << "' with type: '"
<< m_structType->name()
<< "' failed";
return false;
@@ -138,11 +138,11 @@ public:
}
catch (const dds::core::Exception &ex)
{
ERROR_LOG() << ex.what();
ERROR_LOG(m_logger) << ex.what();
return false;
}
DEBUG_LOG() << "dataReader created ("
DEBUG_LOG(m_logger) << "dataReader created ("
<< m_structType->name()
<< ")";
@@ -153,7 +153,7 @@ public:
bool hasSamples() const
{
qint64 sampleSize = m_dataReader->datareader_cache_status().sample_count();
DEBUG_LOG() << "sampleSize = " << sampleSize;
DEBUG_LOG(m_logger) << "sampleSize = " << sampleSize;
return sampleSize > 0;
}
@@ -162,7 +162,7 @@ public:
{
dds::sub::LoanedSamples<DynamicData> samples =
m_dataReader.select().state(dds::sub::status::InstanceState::alive()).read();
TRACE_LOG() << "readAlive for " << DDS::topic_type_name<TopicType>::value()
TRACE_LOG(m_logger) << "readAlive for " << DDS::topic_type_name<TopicType>::value()
<< ", count: " << samples.length()
<< ", this: " << this << ", instance handle " << m_dataReader.instance_handle();
@@ -175,7 +175,7 @@ public:
{
dds::sub::LoanedSamples<DynamicData> samples =
m_dataReader.select().state(dds::sub::status::InstanceState::alive()).take();
TRACE_LOG() << "takeAlive for " << DDS::topic_type_name<TopicType>::value()
TRACE_LOG(m_logger) << "takeAlive for " << DDS::topic_type_name<TopicType>::value()
<< ", count: " << samples.length()
<< ", this: " << this << ", instance handle " << m_dataReader.instance_handle();
@@ -187,7 +187,7 @@ public:
{
dds::sub::LoanedSamples<DynamicData> samples =
m_dataReader.select().state(dds::sub::status::InstanceState::not_alive_disposed()).take();
TRACE_LOG() << "takeDisposed for " << DDS::topic_type_name<TopicType>::value()
TRACE_LOG(m_logger) << "takeDisposed for " << DDS::topic_type_name<TopicType>::value()
<< ", count: " << samples.length()
<< ", this: " << this << ", instance handle " << m_dataReader.instance_handle();
return samples;
@@ -196,18 +196,18 @@ public:
template<typename C>
bool read(C callbackFunc)
{
DEBUG_LOG() << "IN read ("
DEBUG_LOG(m_logger) << "IN read ("
<< DDS::topic_type_name<TopicType>::value()
<< "), this: " << this << ", instance handle " << m_dataReader.instance_handle();
if (m_dataReader == nullptr || m_ddsTopic == nullptr)
{
ERROR_LOG() << "No dataReader initialised ";
ERROR_LOG(m_logger) << "No dataReader initialised ";
return false;
}
if (!isValid(callbackFunc))
{
ERROR_LOG() << "No subscriber set for "
ERROR_LOG(m_logger) << "No subscriber set for "
<< DDS::topic_type_name<TopicType>::value();
return false;
}
@@ -216,7 +216,7 @@ public:
dds::sub::LoanedSamples<DynamicData> samples = m_dataReader.select().state(dds::sub::status::DataState::new_data()).read();
DEBUG_LOG() << "got " << samples.length() + m_newSamplesDuringRead.size() << " samples from reader for "
DEBUG_LOG(m_logger) << "got " << samples.length() + m_newSamplesDuringRead.size() << " samples from reader for "
<< DDS::topic_type_name<TopicType>::value();
for (const auto &sample : samples)
@@ -297,7 +297,7 @@ private:
if (samples.length() == 0)
return false;
DEBUG_LOG() << "got " << samples.length() << " disposed instances from reader for "
DEBUG_LOG(m_logger) << "got " << samples.length() << " disposed instances from reader for "
<< m_ddsTopic.name();
for (const auto &sample : samples)