Function ros2_medkit_gateway::classify_component_routing

Function Documentation

ClassifiedRouting ros2_medkit_gateway::classify_component_routing(const std::vector<Component> &merged_components, const std::vector<PeerClaim> &peer_claims)

Classify merged Components into hierarchical parents and leaves.

A Component is a hierarchical parent iff some other Component in the merged set references it via parent_component_id. Hierarchical parents are removed from the routing table (served locally from the merged cache, mirroring how Areas/Functions are handled). Leaves stay in the routing table and forward on request.

Multi-peer collisions on a leaf Component ID are reported as warnings; routing falls back to last-writer-wins (the last peer in peer_claims whose claim set contains the ID).