Skip to content

Publishers never forget subscribers in Network Mode #2676

Description

@genevanmeter

Problem Description

When configured with communication_mode: "network" publishers never forgets remote subscribers after they close. If there is an active local subscription and a remote host that had previously subscribed to a topic it will also get the data even if the remote isn't actively subscribed to the data. The can cause unintended excess network bandwidth.

How to reproduce

Configure two machines for "network" mode

HOST-A
Terminal 1

ecal_sample_performance_snd

Terminal 2

ecal_sample_performance_rec

Leave them running.


HOST-B

ecal_sample_performance_rec

Observe the network utilization via System Monitor or wireshark on HOST-B. Should be some significant amount based on network.

Now stop ecal_sample_performance_rec

Observe the network utilization via System Monitor or wireshark on HOST-B. Should be minimal

Now start any ecal application that does NOT actively subscribe to Performance topic ie

ecal_sample_person_send

Observe the network utilization via System Monitor or wireshark on HOST-B. It will show significant traffic again even though the Performance topic wasn't subscribed to.

How did you get eCAL?

Custom Build / Built from source

Environment

eCAL 6.1.1 and master
Ubuntu 24.04

eCAL System Information

[eCAL][Config] Yaml configuration loaded from "/opt/dawg/etc/ecal/ecal.yaml".
------------------------- SYSTEM ---------------------------------
Version                  : v6.1.1-dirty (31.03.2026)
Platform                 : linux

------------------------- CONFIGURATION --------------------------
Default INI              : /opt/dawg/etc/ecal/ecal.yaml

------------------------- NETWORK --------------------------------
Host name                : glaptop
SHM transport domain     : glaptop
Network mode             : cloud
Network ttl              : 10
Network sndbuf           : 5 MByte
Network rcvbuf           : 5 MByte
Multicast cfg version    : v2
Multicast group          : 239.0.0.1
Multicast mask           : 255.255.255.240
Multicast ports          : 14002 - 14012
Multicast join all IFs   : off

------------------------- TIME -----------------------------------
Synchronization realtime : ecaltime-localtime
Synchronization replay   :
State                    :  synchronized
Master / Slave           :  Master
Status (Code)            : "everything is fine." (0)

------------------------- SUBSCRIPTION LAYER DEFAULTS ------------
Layer Mode UDP MC        : on
Drop out-of-order msgs   : on

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions