TWIN: forward mirrored audio/flush to satellites + integration tests
TwinLink::handleMsgTrunkAudio and handleMsgTrunkFlush now call forwardAudioToSatellitesExcept / forwardFlushToSatellitesExcept, mirroring TrunkLink. Without this, satellites attached to a twin member only saw talker-state updates for traffic originated on the partner — the audio frames themselves were dropped. Adds test_09 (satellite handshakes with the twin parent) and test_10 (client on ref2 transmits; satellite on ref1 receives TalkerStart + audio frames via the TWIN-mirror path). Wires a [SATELLITE] section and host port mapping into the twin topology generator and lets SatellitePeer.connect_satellite take an explicit port override.
This commit is contained in:
1 parent
7507c116e6
commit
337cfa7208
5 files changed
+169
-7
No files matched your search
@@ -174,6 +174,11 @@ TWIN_TRUNKS = [
|
||||
# Cluster TGs for the twin topology
|
||||
TWIN_CLUSTER_TGS = [222000, 999]
|
||||
|
||||
# Which twin-topology reflector accepts satellite connections. Picking one of
|
||||
# the twin pair lets tests verify that audio mirrored via the [TWIN] link is
|
||||
# also forwarded out to satellites attached to the partner.
|
||||
TWIN_SATELLITE_PARENT = "ref1"
|
||||
|
||||
# Shared secret for a trunk link (twin topology uses link name)
|
||||
def twin_trunk_secret(link_name: str) -> str:
|
||||
return f"secret_{link_name.lower()}"
|
||||
@@ -229,6 +234,10 @@ def twin_mapped_twin_port(name: str) -> int:
|
||||
"""Host-mapped port for the [TWIN] listen port."""
|
||||
return TWIN_REFLECTORS[name]["trunk_port_base"] + 304
|
||||
|
||||
def twin_mapped_satellite_port(name: str) -> int:
|
||||
"""Host-mapped port for the [SATELLITE] listen port in twin topology."""
|
||||
return TWIN_REFLECTORS[name]["trunk_port_base"] + 303
|
||||
|
||||
def twin_trunks_for(name: str) -> list:
|
||||
"""Return all TWIN_TRUNKS entries that involve this reflector."""
|
||||
return [t for t in TWIN_TRUNKS if name in t["peers"]]
|
||||
Reference in new issue
Block a user