diff --git a/app/mon/mon_tui/src/model/data/topic.hpp b/app/mon/mon_tui/src/model/data/topic.hpp index 42cc29248c..45a26d07bb 100644 --- a/app/mon/mon_tui/src/model/data/topic.hpp +++ b/app/mon/mon_tui/src/model/data/topic.hpp @@ -51,7 +51,6 @@ struct Topic int32_t local_connections_count; int32_t external_connections_count; int32_t message_drops; - int64_t data_id; int64_t data_clock; int32_t data_frequency_mhz; std::map attributes; diff --git a/app/mon/mon_tui/src/model/monitor.hpp b/app/mon/mon_tui/src/model/monitor.hpp index 1057b449dc..b72f3899bf 100644 --- a/app/mon/mon_tui/src/model/monitor.hpp +++ b/app/mon/mon_tui/src/model/monitor.hpp @@ -213,7 +213,6 @@ class MonitorModel topic.local_connections_count = t.connections_local(); topic.external_connections_count = t.connections_external(); topic.message_drops = t.message_drops(); - topic.data_id = t.data_id(); topic.data_clock = t.data_clock(); topic.data_frequency_mhz = t.data_frequency(); } diff --git a/ecal/core/include/ecal/types/monitoring.h b/ecal/core/include/ecal/types/monitoring.h index 10e8fc505d..dfcdfd8b31 100644 --- a/ecal/core/include/ecal/types/monitoring.h +++ b/ecal/core/include/ecal/types/monitoring.h @@ -89,6 +89,7 @@ namespace eCAL int32_t connections_external{0}; //!< number of external connected entities int32_t message_drops{0}; //!< dropped messages + [[deprecated("The data_id field is deprecated and will always be zero")]] int64_t data_id{0}; //!< data send id (publisher setid) int64_t data_clock{0}; //!< data clock (send / receive action) int32_t data_frequency{0}; //!< data frequency (send / receive samples per second) [mHz] diff --git a/ecal/core/src/io/shm/ecal_memfile_header.h b/ecal/core/src/io/shm/ecal_memfile_header.h index a016179f59..d8f92ffe5f 100644 --- a/ecal/core/src/io/shm/ecal_memfile_header.h +++ b/ecal/core/src/io/shm/ecal_memfile_header.h @@ -1,6 +1,6 @@ /* ========================= eCAL LICENSE ================================= * - * Copyright (C) 2016 - 2019 Continental Corporation + * Copyright (C) 2016 - 2025 Continental Corporation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -31,6 +31,7 @@ namespace eCAL { //-V802 uint16_t hdr_size = sizeof(SMemFileHeader); uint64_t data_size = 0; + [[deprecated("This field is deprecated, but must be kept for compatibility reasons")]] uint64_t id = 0; uint64_t clock = 0; int64_t time = 0; diff --git a/ecal/core/src/io/shm/ecal_memfile_pool.cpp b/ecal/core/src/io/shm/ecal_memfile_pool.cpp index efc90d9675..58d1faf093 100644 --- a/ecal/core/src/io/shm/ecal_memfile_pool.cpp +++ b/ecal/core/src/io/shm/ecal_memfile_pool.cpp @@ -223,13 +223,13 @@ namespace eCAL // calculate user payload address data_buf = static_cast(buf) + mfile_hdr.hdr_size; // call user callback function - m_data_callback(data_buf, mfile_hdr.data_size, (long long)mfile_hdr.id, (long long)mfile_hdr.clock, (long long)mfile_hdr.time, (size_t)mfile_hdr.hash); + m_data_callback(data_buf, mfile_hdr.data_size, (long long)mfile_hdr.clock, (long long)mfile_hdr.time, (size_t)mfile_hdr.hash); } } else { // call user callback function - m_data_callback(data_buf, mfile_hdr.data_size, (long long)mfile_hdr.id, (long long)mfile_hdr.clock, (long long)mfile_hdr.time, (size_t)mfile_hdr.hash); + m_data_callback(data_buf, mfile_hdr.data_size, (long long)mfile_hdr.clock, (long long)mfile_hdr.time, (size_t)mfile_hdr.hash); } } } @@ -264,7 +264,7 @@ namespace eCAL if (post_process_buffer) { // add sample to data reader (and call user callback function) - if (m_data_callback) m_data_callback(receive_buffer.data(), receive_buffer.size(), (long long)mfile_hdr.id, (long long)mfile_hdr.clock, (long long)mfile_hdr.time, (size_t)mfile_hdr.hash); + if (m_data_callback) m_data_callback(receive_buffer.data(), receive_buffer.size(), (long long)mfile_hdr.clock, (long long)mfile_hdr.time, (size_t)mfile_hdr.hash); } // send acknowledge event diff --git a/ecal/core/src/io/shm/ecal_memfile_pool.h b/ecal/core/src/io/shm/ecal_memfile_pool.h index 3ee5bbab01..7ad688072e 100644 --- a/ecal/core/src/io/shm/ecal_memfile_pool.h +++ b/ecal/core/src/io/shm/ecal_memfile_pool.h @@ -1,6 +1,6 @@ /* ========================= eCAL LICENSE ================================= * - * Copyright (C) 2016 - 2024 Continental Corporation + * Copyright (C) 2016 - 2025 Continental Corporation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -42,7 +42,7 @@ namespace eCAL { - using MemFileDataCallbackT = std::function; + using MemFileDataCallbackT = std::function; //////////////////////////////////////// // CMemFileObserver diff --git a/ecal/core/src/io/shm/ecal_memfile_sync.cpp b/ecal/core/src/io/shm/ecal_memfile_sync.cpp index 440f4e6ec0..83b91b0a40 100644 --- a/ecal/core/src/io/shm/ecal_memfile_sync.cpp +++ b/ecal/core/src/io/shm/ecal_memfile_sync.cpp @@ -167,8 +167,6 @@ namespace eCAL struct SMemFileHeader memfile_hdr; // set data size memfile_hdr.data_size = static_cast(data_.len); - // set header id - memfile_hdr.id = static_cast(data_.id); // set header clock memfile_hdr.clock = static_cast(data_.clock); // set header time diff --git a/ecal/core/src/monitoring/ecal_monitoring_impl.cpp b/ecal/core/src/monitoring/ecal_monitoring_impl.cpp index 96e3721e64..165a6f438d 100644 --- a/ecal/core/src/monitoring/ecal_monitoring_impl.cpp +++ b/ecal/core/src/monitoring/ecal_monitoring_impl.cpp @@ -154,7 +154,6 @@ namespace eCAL } const int32_t connections_local = sample_topic.connections_local; const int32_t connections_external = sample_topic.connections_external; - const int64_t data_id = sample_topic.data_id; const int64_t data_clock = sample_topic.data_clock; const int32_t message_drops = sample_topic.message_drops; const int32_t data_frequency = sample_topic.data_frequency; @@ -237,7 +236,6 @@ namespace eCAL TopicInfo.topic_size = static_cast(topic_size); TopicInfo.connections_local = static_cast(connections_local); TopicInfo.connections_external = static_cast(connections_external); - TopicInfo.data_id = data_id; TopicInfo.data_clock = data_clock; TopicInfo.message_drops = message_drops; TopicInfo.data_frequency = data_frequency; diff --git a/ecal/core/src/pubsub/ecal_publisher.cpp b/ecal/core/src/pubsub/ecal_publisher.cpp index c3407a8229..016e8f5b01 100644 --- a/ecal/core/src/pubsub/ecal_publisher.cpp +++ b/ecal/core/src/pubsub/ecal_publisher.cpp @@ -103,7 +103,7 @@ namespace eCAL // send content via data writer layer const long long write_time = (time_ == DEFAULT_TIME_ARGUMENT) ? eCAL::Time::GetMicroSeconds() : time_; - return m_publisher_impl->Write(payload_, write_time, 0); + return m_publisher_impl->Write(payload_, write_time); } bool CPublisher::Send(const std::string& payload_, long long time_) diff --git a/ecal/core/src/pubsub/ecal_publisher_impl.cpp b/ecal/core/src/pubsub/ecal_publisher_impl.cpp index 93ff598c6b..50b6b7ac87 100644 --- a/ecal/core/src/pubsub/ecal_publisher_impl.cpp +++ b/ecal/core/src/pubsub/ecal_publisher_impl.cpp @@ -147,7 +147,7 @@ namespace eCAL Unregister(); } - bool CPublisherImpl::Write(CPayloadWriter& payload_, long long time_, long long filter_id_) + bool CPublisherImpl::Write(CPayloadWriter& payload_, long long time_) { // get payload buffer size (one time, to avoid multiple computations) const size_t payload_buf_size(payload_.GetSize()); @@ -174,7 +174,7 @@ namespace eCAL } // prepare counter and internal states - const size_t snd_hash = PrepareWrite(filter_id_, payload_buf_size); + const size_t snd_hash = PrepareWrite(payload_buf_size); // did we write anything bool written(false); @@ -195,7 +195,6 @@ namespace eCAL // fill writer data struct SWriterAttr wattr; wattr.len = payload_buf_size; - wattr.id = m_id; wattr.clock = m_clock; wattr.hash = snd_hash; wattr.time = time_; @@ -258,7 +257,6 @@ namespace eCAL // fill writer data struct SWriterAttr wattr; wattr.len = payload_buf_size; - wattr.id = m_id; wattr.clock = m_clock; wattr.hash = snd_hash; wattr.time = time_; @@ -307,7 +305,6 @@ namespace eCAL // fill writer data struct SWriterAttr wattr; wattr.len = payload_buf_size; - wattr.id = m_id; wattr.clock = m_clock; wattr.hash = snd_hash; wattr.time = time_; @@ -630,7 +627,6 @@ namespace eCAL ecal_reg_sample_topic.process_name = m_attributes.process_name; ecal_reg_sample_topic.unit_name = m_attributes.unit_name; - ecal_reg_sample_topic.data_id = m_id; ecal_reg_sample_topic.data_clock = m_clock; ecal_reg_sample_topic.data_frequency = GetFrequency(); @@ -818,11 +814,8 @@ namespace eCAL #endif } - size_t CPublisherImpl::PrepareWrite(long long id_, size_t len_) + size_t CPublisherImpl::PrepareWrite(size_t len_) { - // store id - m_id = id_; - // handle write counters RefreshSendCounter(); diff --git a/ecal/core/src/pubsub/ecal_publisher_impl.h b/ecal/core/src/pubsub/ecal_publisher_impl.h index 1a701585c4..3718003446 100644 --- a/ecal/core/src/pubsub/ecal_publisher_impl.h +++ b/ecal/core/src/pubsub/ecal_publisher_impl.h @@ -77,7 +77,7 @@ namespace eCAL CPublisherImpl(const SDataTypeInformation& topic_info_, const eCAL::eCALWriter::SAttributes& attr_); ~CPublisherImpl(); - bool Write(CPayloadWriter& payload_, long long time_, long long filter_id_); + bool Write(CPayloadWriter& payload_, long long time_); bool SetDataTypeInformation(const SDataTypeInformation& topic_info_); @@ -120,7 +120,7 @@ namespace eCAL size_t GetConnectionCount(); - size_t PrepareWrite(long long id_, size_t len_); + size_t PrepareWrite(size_t len_); TransportLayer::eType DetermineTransportLayer2Start(const std::vector& enabled_pub_layer_, const std::vector& enabled_sub_layer_, bool same_host_); @@ -148,7 +148,6 @@ namespace eCAL std::mutex m_event_id_callback_mutex; PubEventCallbackT m_event_id_callback; - long long m_id = 0; long long m_clock = 0; std::mutex m_frequency_calculator_mutex; diff --git a/ecal/core/src/pubsub/ecal_subgate.cpp b/ecal/core/src/pubsub/ecal_subgate.cpp index f1a3145f9e..26f9f78792 100644 --- a/ecal/core/src/pubsub/ecal_subgate.cpp +++ b/ecal/core/src/pubsub/ecal_subgate.cpp @@ -162,7 +162,6 @@ namespace eCAL ecal_sample.topic_info, payload_addr, payload_size, - ecal_sample_content.id, ecal_sample_content.clock, ecal_sample_content.time, static_cast(ecal_sample_content.hash), @@ -178,7 +177,7 @@ namespace eCAL return (applied_size > 0); } - bool CSubGate::ApplySample(const Payload::TopicInfo& topic_info_, const char* buf_, size_t len_, long long id_, long long clock_, long long time_, size_t hash_, eTLayerType layer_) + bool CSubGate::ApplySample(const Payload::TopicInfo& topic_info_, const char* buf_, size_t len_, long long clock_, long long time_, size_t hash_, eTLayerType layer_) { if (!m_created) return false; @@ -199,7 +198,7 @@ namespace eCAL for (const auto& reader : readers_to_apply) { - applied_size = reader->ApplySample(topic_info_, buf_, len_, id_, clock_, time_, hash_, layer_); + applied_size = reader->ApplySample(topic_info_, buf_, len_, clock_, time_, hash_, layer_); } return (applied_size > 0); diff --git a/ecal/core/src/pubsub/ecal_subgate.h b/ecal/core/src/pubsub/ecal_subgate.h index ac5662c4f9..beb15b94de 100644 --- a/ecal/core/src/pubsub/ecal_subgate.h +++ b/ecal/core/src/pubsub/ecal_subgate.h @@ -1,6 +1,6 @@ /* ========================= eCAL LICENSE ================================= * - * Copyright (C) 2016 - 2024 Continental Corporation + * Copyright (C) 2016 - 2025 Continental Corporation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -49,7 +49,7 @@ namespace eCAL bool HasSample(const std::string& sample_name_); bool ApplySample(const char* serialized_sample_data_, size_t serialized_sample_size_, eTLayerType layer_); - bool ApplySample(const Payload::TopicInfo& topic_info_, const char* buf_, size_t len_, long long id_, long long clock_, long long time_, size_t hash_, eTLayerType layer_); + bool ApplySample(const Payload::TopicInfo& topic_info_, const char* buf_, size_t len_, long long clock_, long long time_, size_t hash_, eTLayerType layer_); void ApplyPublisherRegistration(const Registration::Sample& ecal_sample_); void ApplyPublisherUnregistration(const Registration::Sample& ecal_sample_); diff --git a/ecal/core/src/pubsub/ecal_subscriber_impl.cpp b/ecal/core/src/pubsub/ecal_subscriber_impl.cpp index 069ec56b27..491200db1d 100644 --- a/ecal/core/src/pubsub/ecal_subscriber_impl.cpp +++ b/ecal/core/src/pubsub/ecal_subscriber_impl.cpp @@ -232,15 +232,6 @@ namespace eCAL return true; } - void CSubscriberImpl::SetFilterIDs(const std::set& filter_ids_) - { -#ifndef NDEBUG - Logging::Log(Logging::log_level_debug2, m_attributes.topic_name + "::CSubscriberImpl::SetFilterIDs"); -#endif - - m_id_set = filter_ids_; - } - void CSubscriberImpl::ApplyPublisherRegistration(const SPublicationInfo& publication_info_, const SDataTypeInformation& data_type_info_, const SLayerStates& pub_layer_states_) { // flag write enabled from publisher side (information not used yet) @@ -370,7 +361,7 @@ namespace eCAL #endif } - size_t CSubscriberImpl::ApplySample(const Payload::TopicInfo& topic_info_, const char* payload_, size_t size_, long long id_, long long clock_, long long time_, size_t /*hash_*/, eTLayerType layer_) + size_t CSubscriberImpl::ApplySample(const Payload::TopicInfo& topic_info_, const char* payload_, size_t size_, long long clock_, long long time_, size_t /*hash_*/, eTLayerType layer_) { // ensure thread safety const std::lock_guard lock(m_receive_callback_mutex); @@ -391,12 +382,6 @@ namespace eCAL return size_; } - // We might not want to apply samples sent with a given ID (deprecated!) - if (!ShouldApplySampleBasedOnId(id_)) - { - return 0; - } - // store receive layer m_layers.udp.active |= layer_ == tl_ecal_udp; m_layers.shm.active |= layer_ == tl_ecal_shm; @@ -774,17 +759,6 @@ namespace eCAL return true; } - bool CSubscriberImpl::ShouldApplySampleBasedOnId(long long id_) const - { - // - if (!m_id_set.empty() && (m_id_set.find(id_) == m_id_set.end())) - { - return false; - } - - return true; - } - void CSubscriberImpl::TriggerFrequencyUpdate() { const auto receive_time = std::chrono::steady_clock::now(); diff --git a/ecal/core/src/pubsub/ecal_subscriber_impl.h b/ecal/core/src/pubsub/ecal_subscriber_impl.h index 349355818e..f4f76c4144 100644 --- a/ecal/core/src/pubsub/ecal_subscriber_impl.h +++ b/ecal/core/src/pubsub/ecal_subscriber_impl.h @@ -85,8 +85,6 @@ namespace eCAL bool SetEventCallback(const SubEventCallbackT& callback_); bool RemoveEventCallback(); - void SetFilterIDs(const std::set& filter_ids_); - void ApplyPublisherRegistration(const SPublicationInfo& publication_info_, const SDataTypeInformation& data_type_info_, const SLayerStates& pub_layer_states_); void ApplyPublisherUnregistration(const SPublicationInfo& publication_info_, const SDataTypeInformation& data_type_info_); @@ -103,7 +101,7 @@ namespace eCAL const SDataTypeInformation& GetDataTypeInformation() const { return(m_topic_info); } void InitializeLayers(); - size_t ApplySample(const Payload::TopicInfo& topic_info_, const char* payload_, size_t size_, long long id_, long long clock_, long long time_, size_t hash_, eTLayerType layer_); + size_t ApplySample(const Payload::TopicInfo& topic_info_, const char* payload_, size_t size_, long long clock_, long long time_, size_t hash_, eTLayerType layer_); protected: void Register(); @@ -127,7 +125,6 @@ namespace eCAL bool ShouldApplySampleBasedOnClock(const SPublicationInfo& publication_info_, long long clock_) const; bool ShouldApplySampleBasedOnLayer(eTLayerType layer_) const; - bool ShouldApplySampleBasedOnId(long long id_) const; void TriggerFrequencyUpdate(); void TriggerMessageDropUdate(const SPublicationInfo& publication_info_, uint64_t message_counter); @@ -177,8 +174,6 @@ namespace eCAL using CounterCacheMapT = CounterCacheMap; CounterCacheMapT m_publisher_message_counter_map; - - std::set m_id_set; SLayerStates m_layers; std::atomic m_created; diff --git a/ecal/core/src/readwrite/ecal_writer_data.h b/ecal/core/src/readwrite/ecal_writer_data.h index 347c9de329..ab5f6868cd 100644 --- a/ecal/core/src/readwrite/ecal_writer_data.h +++ b/ecal/core/src/readwrite/ecal_writer_data.h @@ -1,6 +1,6 @@ /* ========================= eCAL LICENSE ================================= * - * Copyright (C) 2016 - 2019 Continental Corporation + * Copyright (C) 2016 - 2025 Continental Corporation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -30,7 +30,6 @@ namespace eCAL struct SWriterAttr { size_t len = 0; - long long id = 0; long long clock = 0; size_t hash = 0; long long time = 0; diff --git a/ecal/core/src/readwrite/shm/ecal_reader_shm.cpp b/ecal/core/src/readwrite/shm/ecal_reader_shm.cpp index 1a6164785d..62c41d66a3 100644 --- a/ecal/core/src/readwrite/shm/ecal_reader_shm.cpp +++ b/ecal/core/src/readwrite/shm/ecal_reader_shm.cpp @@ -59,20 +59,20 @@ namespace eCAL topic_info.topic_id = par_.topic_id; topic_info.process_id = par_.process_id; - auto data_callback = [this, topic_info](const char* buf_, size_t len_, long long id_, long long clock_, long long time_, size_t hash_)->size_t + auto data_callback = [this, topic_info](const char* buf_, size_t len_, long long clock_, long long time_, size_t hash_)->size_t { - return OnNewShmFileContent(topic_info, buf_, len_, id_, clock_, time_, hash_); + return OnNewShmFileContent(topic_info, buf_, len_, clock_, time_, hash_); }; g_memfile_pool()->ObserveFile(memfile_name, memfile_event, m_attributes.registration_timeout_ms, data_callback); } } } - size_t CSHMReaderLayer::OnNewShmFileContent(const Payload::TopicInfo& topic_info_, const char* buf_, size_t len_, long long id_, long long clock_, long long time_, size_t hash_) + size_t CSHMReaderLayer::OnNewShmFileContent(const Payload::TopicInfo& topic_info_, const char* buf_, size_t len_, long long clock_, long long time_, size_t hash_) { if (g_subgate() != nullptr) { - if (g_subgate()->ApplySample(topic_info_, buf_, len_, id_, clock_, time_, hash_, tl_ecal_shm)) + if (g_subgate()->ApplySample(topic_info_, buf_, len_, clock_, time_, hash_, tl_ecal_shm)) { return len_; } diff --git a/ecal/core/src/readwrite/shm/ecal_reader_shm.h b/ecal/core/src/readwrite/shm/ecal_reader_shm.h index 9b0c54a3d1..c5b0fe97f3 100644 --- a/ecal/core/src/readwrite/shm/ecal_reader_shm.h +++ b/ecal/core/src/readwrite/shm/ecal_reader_shm.h @@ -50,7 +50,7 @@ namespace eCAL void SetConnectionParameter(SReaderLayerPar& par_) override; private: - size_t OnNewShmFileContent(const Payload::TopicInfo& topic_info_, const char* buf_, size_t len_, long long id_, long long clock_, long long time_, size_t hash_); + size_t OnNewShmFileContent(const Payload::TopicInfo& topic_info_, const char* buf_, size_t len_, long long clock_, long long time_, size_t hash_); eCAL::eCALReader::SHM::SAttributes m_attributes; }; diff --git a/ecal/core/src/readwrite/tcp/ecal_reader_tcp.cpp b/ecal/core/src/readwrite/tcp/ecal_reader_tcp.cpp index ee98ac239d..7b44df074f 100644 --- a/ecal/core/src/readwrite/tcp/ecal_reader_tcp.cpp +++ b/ecal/core/src/readwrite/tcp/ecal_reader_tcp.cpp @@ -121,7 +121,6 @@ namespace eCAL ecal_header_topic_info, data_payload, static_cast(ecal_header_content.size), - ecal_header_content.id, ecal_header_content.clock, ecal_header_content.time, ecal_header_content.hash, diff --git a/ecal/core/src/readwrite/tcp/ecal_writer_tcp.cpp b/ecal/core/src/readwrite/tcp/ecal_writer_tcp.cpp index 6613c8d568..7e626bdfe1 100644 --- a/ecal/core/src/readwrite/tcp/ecal_writer_tcp.cpp +++ b/ecal/core/src/readwrite/tcp/ecal_writer_tcp.cpp @@ -81,7 +81,6 @@ namespace eCAL // set payload content (without payload) auto& proto_header_content = proto_header.content; - proto_header_content.id = attr_.id; proto_header_content.clock = attr_.clock; proto_header_content.time = attr_.time; proto_header_content.hash = static_cast(attr_.hash); diff --git a/ecal/core/src/readwrite/udp/ecal_writer_udp.cpp b/ecal/core/src/readwrite/udp/ecal_writer_udp.cpp index a6a57e70ff..d73f418550 100644 --- a/ecal/core/src/readwrite/udp/ecal_writer_udp.cpp +++ b/ecal/core/src/readwrite/udp/ecal_writer_udp.cpp @@ -74,7 +74,6 @@ namespace eCAL // append content auto& ecal_sample_content = ecal_sample.content; - ecal_sample_content.id = attr_.id; ecal_sample_content.clock = attr_.clock; ecal_sample_content.time = attr_.time; ecal_sample_content.hash = attr_.hash; diff --git a/ecal/core/src/serialization/ecal_serialize_monitoring.cpp b/ecal/core/src/serialization/ecal_serialize_monitoring.cpp index 5206b1b645..e04e871b7e 100644 --- a/ecal/core/src/serialization/ecal_serialize_monitoring.cpp +++ b/ecal/core/src/serialization/ecal_serialize_monitoring.cpp @@ -181,8 +181,6 @@ namespace pb_topic_.connections_external = topic_.connections_external; // message_drops pb_topic_.message_drops = topic_.message_drops; - // data_id - pb_topic_.data_id = topic_.data_id; // data_clock pb_topic_.data_clock = topic_.data_clock; // data_frequency @@ -645,8 +643,6 @@ namespace topic_.connections_external = pb_topic_.connections_external; // message_drops topic_.message_drops = pb_topic_.message_drops; - // data_id - topic_.data_id = pb_topic_.data_id; // data_clock topic_.data_clock = pb_topic_.data_clock; // data_frequency diff --git a/ecal/core/src/serialization/ecal_serialize_sample_payload.cpp b/ecal/core/src/serialization/ecal_serialize_sample_payload.cpp index b7aaba5b62..56a5e96bef 100644 --- a/ecal/core/src/serialization/ecal_serialize_sample_payload.cpp +++ b/ecal/core/src/serialization/ecal_serialize_sample_payload.cpp @@ -83,7 +83,6 @@ namespace // topic content pb_sample_.has_content = true; - pb_sample_.content.id = payload_.content.id; pb_sample_.content.clock = payload_.content.clock; pb_sample_.content.time = payload_.content.time; pb_sample_.content.hash = payload_.content.hash; @@ -183,7 +182,6 @@ namespace payload_.topic_info.process_id = pb_sample.topic.process_id; // topic content - payload_.content.id = pb_sample.content.id; payload_.content.clock = pb_sample.content.clock; payload_.content.time = pb_sample.content.time; payload_.content.hash = pb_sample.content.hash; diff --git a/ecal/core/src/serialization/ecal_serialize_sample_registration.cpp b/ecal/core/src/serialization/ecal_serialize_sample_registration.cpp index 1d8d68b896..57f68ff4f3 100644 --- a/ecal/core/src/serialization/ecal_serialize_sample_registration.cpp +++ b/ecal/core/src/serialization/ecal_serialize_sample_registration.cpp @@ -184,8 +184,6 @@ namespace pb_topic_.connections_external = registration_topic_.connections_external; // message_drops pb_topic_.message_drops = registration_topic_.message_drops; - // data_id - pb_topic_.data_id = registration_topic_.data_id; // data_clock pb_topic_.data_clock = registration_topic_.data_clock; // data_frequency @@ -456,8 +454,6 @@ namespace registration_.topic.connections_external = pb_sample_.topic.connections_external; // message_drops registration_.topic.message_drops = pb_sample_.topic.message_drops; - // data_id - registration_.topic.data_id = pb_sample_.topic.data_id; // data_clock registration_.topic.data_clock = pb_sample_.topic.data_clock; // data_frequency diff --git a/ecal/core/src/serialization/ecal_struct_sample_payload.h b/ecal/core/src/serialization/ecal_struct_sample_payload.h index 08023f8f90..33cbb99485 100644 --- a/ecal/core/src/serialization/ecal_struct_sample_payload.h +++ b/ecal/core/src/serialization/ecal_struct_sample_payload.h @@ -64,7 +64,6 @@ namespace eCAL // Topic content struct Content { - int64_t id = 0; // payload id int64_t clock = 0; // internal used clock int64_t time = 0; // time the content was updated int64_t hash = 0; // unique hash for that payload diff --git a/ecal/core/src/serialization/ecal_struct_sample_registration.h b/ecal/core/src/serialization/ecal_struct_sample_registration.h index f217a94ae0..3f6a6b8894 100644 --- a/ecal/core/src/serialization/ecal_struct_sample_registration.h +++ b/ecal/core/src/serialization/ecal_struct_sample_registration.h @@ -274,7 +274,6 @@ namespace eCAL int32_t connections_external = 0; // number of external connected entities int32_t message_drops = 0; // dropped messages - int64_t data_id = 0; // data send id (publisher setid) int64_t data_clock = 0; // data clock (send / receive action) int32_t data_frequency = 0; // data frequency (send / receive registrations per second) [mHz] @@ -292,7 +291,6 @@ namespace eCAL connections_local == other.connections_local && connections_external == other.connections_external && message_drops == other.message_drops && - data_id == other.data_id && data_clock == other.data_clock && data_frequency == other.data_frequency; } @@ -314,7 +312,6 @@ namespace eCAL connections_external = 0; message_drops = 0; - data_id = 0; data_clock = 0; data_frequency = 0; } diff --git a/ecal/core/src/v5/pubsub/ecal_publisher.cpp b/ecal/core/src/v5/pubsub/ecal_publisher.cpp index 8b6239a04a..757f646281 100644 --- a/ecal/core/src/v5/pubsub/ecal_publisher.cpp +++ b/ecal/core/src/v5/pubsub/ecal_publisher.cpp @@ -117,8 +117,7 @@ namespace eCAL }; CPublisher::CPublisher() : - m_publisher_impl(nullptr), - m_filter_id(0) + m_publisher_impl(nullptr) { } @@ -142,8 +141,7 @@ namespace eCAL **/ CPublisher::CPublisher(CPublisher&& rhs) noexcept : m_publisher_impl(std::move(rhs.m_publisher_impl)), - m_callback_adapter(std::move(rhs.m_callback_adapter)), - m_filter_id(rhs.m_filter_id) + m_callback_adapter(std::move(rhs.m_callback_adapter)) { rhs.m_publisher_impl = nullptr; rhs.m_callback_adapter = nullptr; @@ -159,7 +157,6 @@ namespace eCAL m_publisher_impl = std::move(rhs.m_publisher_impl); m_callback_adapter = std::move(rhs.m_callback_adapter); - m_filter_id = rhs.m_filter_id; rhs.m_publisher_impl = nullptr; @@ -214,24 +211,25 @@ namespace eCAL return m_publisher_impl->SetDataTypeInformation(data_type_info_); } - bool CPublisher::SetAttribute(const std::string& attr_name_, const std::string& attr_value_) + bool CPublisher::SetAttribute(const std::string& /*attr_name_*/, const std::string& /*attr_value_*/) { if(m_publisher_impl == nullptr) return false; Logging::Log(Logging::log_level_warning, m_publisher_impl->GetTopicName() + "::CPublisher::SetAttribute - Setting publisher attributes no longer has an effect."); return false; } - bool CPublisher::ClearAttribute(const std::string& attr_name_) + bool CPublisher::ClearAttribute(const std::string& /*attr_name_*/) { if(m_publisher_impl == nullptr) return false; Logging::Log(Logging::log_level_warning, m_publisher_impl->GetTopicName() + "::CPublisher::ClearAttribute - Clear publisher attributes no longer has an effect."); return false; } - bool CPublisher::SetID(long long filter_id_) + bool CPublisher::SetID(long long /*filter_id_*/) { - m_filter_id = filter_id_; - return true; + if (m_publisher_impl == nullptr) return false; + Logging::Log(Logging::log_level_warning, m_publisher_impl->GetTopicName() + "::CPublisher::SetID - Setting the publisher ID no longer has an effect."); + return false; } size_t CPublisher::Send(const void* const buf_, const size_t len_, const long long time_ /* = DEFAULT_TIME_ARGUMENT */) @@ -257,7 +255,7 @@ namespace eCAL // send content via data writer layer const long long write_time = (time_ == DEFAULT_TIME_ARGUMENT) ? eCAL::Time::GetMicroSeconds() : time_; - const size_t written_bytes = m_publisher_impl->Write(payload_, write_time, m_filter_id); + const size_t written_bytes = m_publisher_impl->Write(payload_, write_time); // return number of bytes written return written_bytes; diff --git a/ecal/core/src/v5/pubsub/ecal_subscriber.cpp b/ecal/core/src/v5/pubsub/ecal_subscriber.cpp index 6736c19578..af0d235267 100644 --- a/ecal/core/src/v5/pubsub/ecal_subscriber.cpp +++ b/ecal/core/src/v5/pubsub/ecal_subscriber.cpp @@ -203,21 +203,21 @@ namespace eCAL return(true); } - bool CSubscriber::SetID(const std::set& filter_ids_) + bool CSubscriber::SetID(const std::set& /*filter_ids_*/) { if (m_subscriber_impl == nullptr) return(false); - m_subscriber_impl->SetFilterIDs(filter_ids_); + Logging::Log(Logging::log_level_warning, m_subscriber_impl->GetTopicName() + "::CSubscriber::SetID - Setting subscriber ID attributes no longer has an effect."); return(true); } - bool CSubscriber::SetAttribute(const std::string& attr_name_, const std::string& attr_value_) + bool CSubscriber::SetAttribute(const std::string& /*attr_name_*/, const std::string& /*attr_value_*/) { if (m_subscriber_impl == nullptr) return false; Logging::Log(Logging::log_level_warning, m_subscriber_impl->GetTopicName() + "::CSubscriber::SetAttribute - Setting subscriber attributes no longer has an effect."); return false; } - bool CSubscriber::ClearAttribute(const std::string& attr_name_) + bool CSubscriber::ClearAttribute(const std::string& /*attr_name_*/) { if (m_subscriber_impl == nullptr) return false; Logging::Log(Logging::log_level_warning, m_subscriber_impl->GetTopicName() + "::CSubscriber::SetAttribute - Setting subscriber attributes no longer has an effect."); diff --git a/ecal/core_pb/src/ecal/core/pb/ecal.proto b/ecal/core_pb/src/ecal/core/pb/ecal.proto index b5c0044940..6e65b24b5e 100644 --- a/ecal/core_pb/src/ecal/core/pb/ecal.proto +++ b/ecal/core_pb/src/ecal/core/pb/ecal.proto @@ -1,6 +1,6 @@ /* ========================= eCAL LICENSE ================================= * - * Copyright (C) 2016 - 2024 Continental Corporation + * Copyright (C) 2016 - 2025 Continental Corporation * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -31,7 +31,7 @@ message Content // topic content // Reserved fields in enums are not supported in protobuf 3.0 // reserved 5; - int64 id = 1; // sample id + //int64 id = 1; // sample id int64 clock = 2; // internal used clock int64 time = 3; // time the content was updated bytes payload = 4; // octet stream diff --git a/ecal/core_pb/src/ecal/core/pb/topic.proto b/ecal/core_pb/src/ecal/core/pb/topic.proto index 161d335f9f..91eebc1f57 100644 --- a/ecal/core_pb/src/ecal/core/pb/topic.proto +++ b/ecal/core_pb/src/ecal/core/pb/topic.proto @@ -27,7 +27,7 @@ package eCAL.pb; message Topic // eCAL topic { // Reserved fields in enums are not supported in protobuf 3.0 - // reserved 9, 10, 11, 14, 15, 22 to 26, 29; + // reserved 9, 10, 11, 14, 15, 19, 22 to 26, 29; int32 registration_clock = 1; // registration clock (heart beat) string host_name = 2; // host name @@ -49,7 +49,6 @@ message Topic // eCAL topic int32 connections_external = 17; // number of external connected entities int32 message_drops = 18; // dropped messages - int64 data_id = 19; // data send id (publisher setid) int64 data_clock = 20; // data clock (send / receive action) int32 data_frequency = 21; // data frequency (send / receive samples per second) [mHz] diff --git a/ecal/samples/cpp/monitoring/monitoring_rec/src/monitoring_rec.cpp b/ecal/samples/cpp/monitoring/monitoring_rec/src/monitoring_rec.cpp index 34abd3d88d..9f6c01a98d 100644 --- a/ecal/samples/cpp/monitoring/monitoring_rec/src/monitoring_rec.cpp +++ b/ecal/samples/cpp/monitoring/monitoring_rec/src/monitoring_rec.cpp @@ -204,7 +204,6 @@ int main() std::cout << "connections external : " << topic.connections_external() << "\n"; // number of external connected entities std::cout << "message drops : " << topic.message_drops() << "\n"; // dropped messages - std::cout << "data id : " << topic.data_id() << "\n"; // data send id (publisher setid) std::cout << "data clock : " << topic.data_clock() << "\n"; // data clock (send / receive action) std::cout << "data frequency : " << topic.data_frequency() << "\n"; // data frequency (send / receive samples per second * 1000) diff --git a/ecal/tests/cpp/registration_test/src/registration_timout_provider_test.cpp b/ecal/tests/cpp/registration_test/src/registration_timout_provider_test.cpp index 6660f1ab12..e2578afb0e 100644 --- a/ecal/tests/cpp/registration_test/src/registration_timout_provider_test.cpp +++ b/ecal/tests/cpp/registration_test/src/registration_timout_provider_test.cpp @@ -73,7 +73,6 @@ void InitializeAllSamples() pub_foo_process_a_register_1.topic.connections_local = 2; pub_foo_process_a_register_1.topic.connections_external = 2; pub_foo_process_a_register_1.topic.message_drops = 0; - pub_foo_process_a_register_1.topic.data_id = 0; pub_foo_process_a_register_1.topic.data_clock = 1; pub_foo_process_a_register_1.topic.data_frequency = 10; @@ -98,7 +97,6 @@ void InitializeAllSamples() sub_foo_process_a_register_1.topic.connections_local = 2; sub_foo_process_a_register_1.topic.connections_external = 2; sub_foo_process_a_register_1.topic.message_drops = 0; - sub_foo_process_a_register_1.topic.data_id = 0; sub_foo_process_a_register_1.topic.data_clock = 1; sub_foo_process_a_register_1.topic.data_frequency = 10; @@ -123,7 +121,6 @@ void InitializeAllSamples() sub_foo_process_b_register_1.topic.connections_local = 2; sub_foo_process_b_register_1.topic.connections_external = 2; sub_foo_process_b_register_1.topic.message_drops = 0; - sub_foo_process_b_register_1.topic.data_id = 0; sub_foo_process_b_register_1.topic.data_clock = 1; sub_foo_process_b_register_1.topic.data_frequency = 10; diff --git a/ecal/tests/cpp/serialization_test/src/monitoring_generate.cpp b/ecal/tests/cpp/serialization_test/src/monitoring_generate.cpp index cfa6f6898b..ced6132678 100644 --- a/ecal/tests/cpp/serialization_test/src/monitoring_generate.cpp +++ b/ecal/tests/cpp/serialization_test/src/monitoring_generate.cpp @@ -70,7 +70,6 @@ namespace eCAL topic.connections_local = rand() % 10; topic.connections_external = rand() % 10; topic.message_drops = rand() % 100; - topic.data_id = rand() % 10000; topic.data_clock = rand() % 10000; topic.data_frequency = rand() % 100; return topic; diff --git a/ecal/tests/cpp/serialization_test/src/payload_compare.cpp b/ecal/tests/cpp/serialization_test/src/payload_compare.cpp index 45bc01b7c8..72215f7276 100644 --- a/ecal/tests/cpp/serialization_test/src/payload_compare.cpp +++ b/ecal/tests/cpp/serialization_test/src/payload_compare.cpp @@ -43,8 +43,7 @@ namespace eCAL } // compare content - if (sample1.content.id != sample2.content.id || - sample1.content.clock != sample2.content.clock || + if (sample1.content.clock != sample2.content.clock || sample1.content.time != sample2.content.time || sample1.content.hash != sample2.content.hash || sample1.content.size != sample2.content.size) { diff --git a/ecal/tests/cpp/serialization_test/src/payload_generate.cpp b/ecal/tests/cpp/serialization_test/src/payload_generate.cpp index 7abdfdd95d..d0d16d2823 100644 --- a/ecal/tests/cpp/serialization_test/src/payload_generate.cpp +++ b/ecal/tests/cpp/serialization_test/src/payload_generate.cpp @@ -65,7 +65,6 @@ namespace eCAL Content GenerateContent(const char* payload_addr, size_t payload_size) { Content content; - content.id = rand() % 100; content.clock = rand() % 1000; content.time = rand() % 10000; content.hash = rand() % 100000; @@ -79,7 +78,6 @@ namespace eCAL Content GenerateContent(const std::vector& payload_vec) { Content content; - content.id = rand() % 100; content.clock = rand() % 1000; content.time = rand() % 10000; content.hash = rand() % 100000; diff --git a/ecal/tests/cpp/serialization_test/src/registration_generate.cpp b/ecal/tests/cpp/serialization_test/src/registration_generate.cpp index 5f451441b4..8bde38ba3a 100644 --- a/ecal/tests/cpp/serialization_test/src/registration_generate.cpp +++ b/ecal/tests/cpp/serialization_test/src/registration_generate.cpp @@ -116,7 +116,6 @@ namespace eCAL topic.connections_local = rand() % 50; topic.connections_external = rand() % 50; topic.message_drops = rand() % 10; - topic.data_id = rand(); topic.data_clock = rand(); topic.data_frequency = rand() % 100; return topic;