Put a link on standby; the routing metric stays per city pair (#122)
A backup-only link next to a normal one still carried traffic, because parallel links merge into one edge. The metric stays on the city pair (S.pairMet), and any link can go on standby: it adds capacity that fills only after the active links, so it idles as a backup, takes the overflow when they are full and carries the traffic when they are down. Build order no longer matters, and adding a link never idles the others. Old saves keep each pair's lowest metric with every link active, which is how they routed before. The panel says what a standby link is doing, the redundancy list tags it, the map draws it dashed while idle, and traceroute shows the active link.
This commit is contained in:
parent
da69c5d843
commit
b4f8d9c7f5
18 changed files with 217 additions and 18 deletions
|
|
@ -106,8 +106,10 @@ never freezes the game.
|
|||
## compute(): the traffic model
|
||||
|
||||
1. Builds a graph from your live links: parallel links between the same two cities
|
||||
merge into one edge with summed capacity. Link metrics set weights; Dijkstra gives
|
||||
shortest paths from each POP.
|
||||
merge into one edge with summed capacity. The routing metric belongs to the city pair
|
||||
(`S.pairMet`) and sets the edge's weight; Dijkstra gives shortest paths from each POP.
|
||||
Links on standby (`l.standby`) add their capacity to the edge, but when loads are
|
||||
handed back to links the active ones fill first and standby links take the rest.
|
||||
2. Builds the exit list `E`: embedded caches (rank 0), PNIs (1), IX ports (2),
|
||||
transit (3). Each exit has a capacity, the networks it can reach (`ok(net)`) and an
|
||||
egress preference (`high`, `normal`, `low` = backup only).
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue