feat(status): expose per-trunk routable_prefixes and routable_wildcard
Surface the ROUTABLE_PREFIXES configuration in the trunk /status JSON (and therefore the MQTT retained status and Redis snapshots) so operators can see, per trunk, which pass-through prefixes the link carries and whether it is a default (*) route. Read-only exposure of existing state — no routing change. - routable_prefixes: gateway-routed prefixes reachable via the peer but not owned by it (from m_routable_prefixes). - routable_wildcard: true when the link is configured as a * default route. Documented in docs/PEER_PROTOCOL.md.
This commit is contained in:
1 parent
67f5c6683f
commit
0885352b1c
2 files changed
+14
No files matched your search
@@ -588,6 +588,14 @@ Json::Value TrunkLink::statusJson(void) const
|
||||
for (const auto& p : m_remote_prefix) remote_arr.append(p);
|
||||
obj["remote_prefix"] = remote_arr;
|
||||
|
||||
// Extra prefixes reachable VIA this peer (gateway routing). These are not
|
||||
// owned by the peer (that's remote_prefix) but are forwarded onward toward
|
||||
// it; "*" is a default route, surfaced separately as routable_wildcard.
|
||||
Json::Value routable_arr(Json::arrayValue);
|
||||
for (const auto& p : m_routable_prefixes) routable_arr.append(p);
|
||||
obj["routable_prefixes"] = routable_arr;
|
||||
obj["routable_wildcard"] = m_routable_wildcard;
|
||||
|
||||
// active_talkers: per-peer active TGs (already post-TG_MAP remap).
|
||||
// We use m_peer_active_tgs directly instead of filtering the global
|
||||
// trunk-talker map by isSharedTG, because a TG_MAP entry can remap a
|
||||
|
||||
Reference in new issue
Block a user