Selective peers will not meet you where a satellite is your only way out (#83)

An island or remote town that only satellite circuits join to the rest of
your network (satOnly: no built wave, fiber, cable or pie dish there, its
fastest circuit otherwise) is a place many selective networks will not
peer: they would hand you traffic for your whole network to haul through
orbit. Like remote peering, the verdict is stable per network (a hash):
60 in 100 selective networks refuse a GEO hop, 15 in 100 a MEO one, and
every network that minds MEO minds GEO too. It is judged on what is built,
never on today's cuts, so the single-spur trap does not also pause your
peering mid-outage.

peerOk refuses new IX sessions and PNIs there with one line naming the
orbit and the circuit's round trip; ixSessions leaves an existing session
out while the island is satellite-only, without deleting it from S.peers,
so it carries again once a wave or cable is lit. Existing PNIs stay. No new
state, nothing for saves.
This commit is contained in:
jvanvik 2026-11-09 22:56:55 +01:00
parent ae78e82ddb
commit 1f76639b8f
12 changed files with 77 additions and 1 deletions

View file

@ -21,6 +21,7 @@ All notable changes to this project are documented here. The project follows
- Set a build standard for your whole network: routers, a second building and a generator at every POP, LAGs, exchange ports and PNIs, line systems, optics and wave sizes, all in one sheet. New POPs get the POP part the day they open, the sheet shows what is below the standard and what fixing it costs, one tap brings everything up, and the new "Keep to the build standard" order has your intern do it a few jobs a day with money to spare. Find it in the menu, the Standing orders sheet and every POP's router section.
- IPv4 is scarce now: business customers need public address blocks, and the homes that do not fit share addresses behind CGNAT. A new network starts with a /21 from its registry, enough for its first months; buy, lease or sell blocks from /24 to /16 on the transfer market in the bank's new Address space section, or lease spare ones out for a monthly income. An offer you have no addresses for says so and waits, a customer that wants to grow at renewal stays at its size until you have the addresses, CGNAT costs a little and annoys some gamers, and you pick how many homes share an address. IPv6 stays free for everyone. This is part of On-call and BGP at 3 a.m.; the gentler rules, Sandbox, puzzles and scenarios keep IPv4 plentiful, and saved games get the addresses they already use plus room to grow (#150).
- Express lightpaths now pay their share when you add a regen site, and a dirty connector on a fiber dims the expresses riding it too (#58). A regen site added to a fiber that already carries expresses needs a regen card for each of their channels, just as for the fiber's own, and the price on the fiber's button includes them. A dirty connector dims every wave in that fiber, and the express's panel says which fiber it is; an MTU mismatch, microbursts or a marginal optic stay with that fiber's own routers and optics, which an express passes by.
- Many selective networks now refuse to peer on an island or in a remote town that only a satellite circuit joins to the rest of your network (#83). They would hand you traffic for your whole network to haul through orbit, so more of them turn down a GEO hop (about 600 ms there and back) than a MEO one (about 130 ms), and each says why on the exchange and PNI lists. Once a wave, fiber or cable to the island is lit they peer again; a session you already had there pauses until then.
## [3.3.0] — 2026-11-09

View file

@ -3721,6 +3721,7 @@
"peering_policy.already_reach_you_through_your":"Erreichen dich hier schon über deinen Transit-Provider und finden das in Ordnung.",
"peering_policy.moved_everything_in_this_city_to":"Haben in dieser Stadt alles auf PNIs umgestellt. Bitte lies ihre PearingDB-Seite, alle 40 Seiten davon.",
"peering_policy.not_accepting_new_peers_in_this":"Nehmen in dieser Region gerade keine neuen Peers an.",
"peering_policy.not_while_a_satellite_is_your_only_way":"Peert nicht in {city}, solange ein {orb}-Satellit dein einziger Weg hinaus ist ({ms} ms hin und zurück): Sie wollen dein Backbone dort, wo sie dich treffen.",
"peering_policy.only_peers_over_pnis_in_this":"Peert in dieser Stadt nur über PNIs. Bestell stattdessen einen Cross-Connect.",
"peering_policy.only_peers_with_members_they_can":"Peert nur mit Mitgliedern, die sie ohne 1.500-km-Haarnadelkurve erreichen.",
"peering_policy.policy_no_remote_peers_be_in":"Policy: keine Remote-Peers. Sei im Gebäude oder auf der Transit-Rechnung.",

View file

@ -3719,6 +3719,7 @@
"peering_policy.already_reach_you_through_your":"Ya llegan a ti a través de tu proveedor de tránsito aquí y creen que eso está bien.",
"peering_policy.moved_everything_in_this_city_to":"Movieron todo en esta ciudad a PNIs. Lee su página de PearingDB, las 40 páginas.",
"peering_policy.not_accepting_new_peers_in_this":"No aceptan peers nuevos en esta región por ahora.",
"peering_policy.not_while_a_satellite_is_your_only_way":"No hace peering en {city} mientras un satélite {orb} sea tu única salida ({ms} ms de ida y vuelta): quieren tu backbone allí donde te encuentran.",
"peering_policy.only_peers_over_pnis_in_this":"Solo hacen peering por PNIs en esta área metropolitana. Pide una interconexión cruzada.",
"peering_policy.only_peers_with_members_they_can":"Solo hacen peering con miembros a los que llegan sin una horquilla de 1500 km.",
"peering_policy.policy_no_remote_peers_be_in":"Política: sin peers remotos. Estás en el edificio o estás en la factura de tránsito.",

View file

@ -3719,6 +3719,7 @@
"peering_policy.already_reach_you_through_your":"Te joignent déjà via ton fournisseur de transit ici et trouvent que ça suffit.",
"peering_policy.moved_everything_in_this_city_to":"Ont tout migré en PNI dans cette ville. Merci de lire leur page PearingDB, les 40 pages.",
"peering_policy.not_accepting_new_peers_in_this":"N’acceptent pas de nouveaux peers dans cette région pour le moment.",
"peering_policy.not_while_a_satellite_is_your_only_way":"Ne fait pas de peering à {city} tant qu’un satellite {orb} est ta seule sortie ({ms} ms aller-retour) : ils veulent ton backbone là où ils te rencontrent.",
"peering_policy.only_peers_over_pnis_in_this":"Ne peere qu’en PNI dans cette métropole. Commande plutôt un cross-connect.",
"peering_policy.only_peers_with_members_they_can":"Ne fait du peering qu’avec les membres joignables sans hairpin de 1 500 km.",
"peering_policy.policy_no_remote_peers_be_in":"Politique : pas de peers distants. Sois dans le bâtiment, ou sur la facture de transit.",

View file

@ -3719,6 +3719,7 @@
"peering_policy.already_reach_you_through_your":"Ti raggiungono già tramite il tuo provider di transit qui, e per loro va bene così.",
"peering_policy.moved_everything_in_this_city_to":"In questa città hanno spostato tutto su PNI. Leggi la loro pagina PearingDB, tutte e 40 le pagine.",
"peering_policy.not_accepting_new_peers_in_this":"Per ora non accettano nuovi peer in questa regione.",
"peering_policy.not_while_a_satellite_is_your_only_way":"Non fa peering a {city} finché un satellite {orb} è la tua unica via d’uscita ({ms} ms andata e ritorno): vogliono il tuo backbone dove ti incontrano.",
"peering_policy.only_peers_over_pnis_in_this":"In questa metro fa peering solo via PNI. Ordina un cross-connect.",
"peering_policy.only_peers_with_members_they_can":"Fanno peering solo con membri raggiungibili senza un hairpin di 1.500 km.",
"peering_policy.policy_no_remote_peers_be_in":"Policy: niente peer remoti. O sei nell’edificio, o sei nella bolletta del transit.",

View file

@ -3719,6 +3719,7 @@
"peering_policy.already_reach_you_through_your":"Já chegam até você pelo seu provedor de transit aqui e acham que está ótimo.",
"peering_policy.moved_everything_in_this_city_to":"Passaram tudo nesta cidade para PNI. Leia a página deles no PearingDB, todas as 40 páginas.",
"peering_policy.not_accepting_new_peers_in_this":"No momento não aceitam novos peers nesta região.",
"peering_policy.not_while_a_satellite_is_your_only_way":"Não faz peering em {city} enquanto um satélite {orb} for sua única saída ({ms} ms ida e volta): querem seu backbone onde encontram você.",
"peering_policy.only_peers_over_pnis_in_this":"Nesta metro, só faz peering via PNI. Peça um cross-connect.",
"peering_policy.only_peers_with_members_they_can":"Só fazem peering com membros que alcançam sem um hairpin de 1.500 km.",
"peering_policy.policy_no_remote_peers_be_in":"Policy: nada de peers remotos. Ou você está no prédio, ou está na conta do transit.",

View file

@ -40,6 +40,12 @@ const satFrom=b=>satRemote(b)?teleCities().filter(a=>a!==b&&satBirds(a,b).length
// it, as one ordered next to a link does, and the player hears about it. Without this the pair's load is shared with orbit.
function satBeside(a,b){const ls=pairLinks(a,b).filter(l=>l.kind==='sat'&&!l.standby);for(const l of ls)l.standby=true;
if(ls.length)toast(trn('satellites.n_circuits_go_on_standby',ls.length,{a:CITY[a].name,b:CITY[b].name}));return ls.length;}
/* An island or remote town that only satellites join to the rest of your network: its fastest circuit (null when a wave,
a fiber, a cable or a pie dish reaches it too). What is built counts, never today's cuts: a selective peer judges what
you built, not this week's repair (50-peering-policy.js). */
function satOnly(c){if(!satRemote(c)||!S.pops[c]||S.pie&&(S.pie.dishes||[]).some(x=>x.city===c))return null;let best=null;
for(const l of S.links){if(l.a!==c&&l.b!==c)continue;if(l.kind!=='sat'){if(!(l.ready>S.day))return null;continue;}if(!best||satLat(l)<satLat(best))best=l;}
return best;}
// What the teleports and their circuits cost a month (R.cost.sat).
function satMoAll(){let m=0;for(const c in S.pops){const t=teleOf(c);if(t)m+=TPORT_MO+(t>1?TRK_MO:0);}for(const l of S.links)if(l.kind==='sat')m+=l.mo||0;return m;}
/* compute(): what users notice on the edges a satellite circuit is on. sv: the losses of the orbits there; sx: the edge's

View file

@ -29,7 +29,7 @@ function ixCap(c){return ixLagF(c)*(S.myIx[c]?myFab(c).g*(myIxLive(c)?1:0):liveC
function ixSessions(c){
const s=new Set(); if(S.ixp[c]===undefined)return s;
for(const id of ixMembers(c)){const n=NET[id];
if(S.peers[id+'@'+c]&&!snub(id,c)&&!(isRemote(c)&&noRemote(id)))s.add(id);
if(S.peers[id+'@'+c]&&!snub(id,c)&&!(isRemote(c)&&noRemote(id))&&!satNo(id,ixCity(c)))s.add(id);
else if(S.rs[c]&&n.pol==='open'&&ppol()==='open')s.add(id);
else if(S.myIx[c]&&(n.pol==='open'||n.pol==='selective'))s.add(id);}
return s;

View file

@ -20,6 +20,14 @@ const REMOTE_WARN=`<p class="note" style="color:var(--tx-red,var(--bad))">${tr('
const REMOTE_WHY=[tr('peering_policy.policy_no_remote_peers_be_in'),tr('peering_policy.saw_your_session_come_in_over'),tr('peering_policy.only_peers_with_members_they_can'),tr('peering_policy.their_pearingdb_entry_says_remote'),tr('peering_policy.tried_a_remote_peer_once_it')];
function isRemote(c){return S.ixp[c]!==undefined&&!S.pops[ixCity(c)]&&!S.myIx[c];}
function noRemote(id){const n=NET[id];if(!n||n.pol!=='selective')return false;return hstr(id+'|remote')%100<(n.share>=0.03?60:30);}
/* Satellite islands (#83): where a satellite circuit is your only way out of a city, many selective networks will not
peer there. They would hand you traffic for your whole network to haul through orbit: most refuse a GEO hop (about
600 ms there and back), few a MEO one (about 130 ms). A stable verdict per network, like remote peering. */
const SAT_NO={geo:60,meo:15};
const noSat=(id,orb)=>{const n=NET[id];return !!n&&n.pol==='selective'&&own(SAT_NO,orb)&&hstr(id+'|sat')%100<SAT_NO[orb];};
// The circuit network id will not take your traffic over in city c (null when it will, or no satellite is in the way).
function satNo(id,c){const n=NET[id];if(!n||n.pol!=='selective'||hstr(id+'|sat')%100>=SAT_NO.geo)return null;const l=satOnly(c);return l&&noSat(id,SATS[l.bird].orb)?l:null;}
function satPeerWhy(id,c){const l=satNo(id,c);return l?tr('peering_policy.not_while_a_satellite_is_your_only_way',{city:CITY[c].name,orb:SAT_ORB[SATS[l.bird].orb].n,ms:Math.round(2*satLat(l))}):'';}
/* Europe's peering market is crowded and competitive: ports are cheaper, and incumbents cut prices
when a challenger in the same metro gets too popular. DE-KICKS harmonises instead. */
const IX_REG={EU:0.8};

View file

@ -14,6 +14,7 @@ function peerOk(id,via,city){
const sn=snub(id,city);if(sn&&(via==='ix'||sn.all))return {ok:false,snub:true,why:snubWhy(sn)};
if(msfNope(id,city))return {ok:false,why:tr(MSF_NOPE[hstr(ixCity(city)+S.day)%MSF_NOPE.length])};
if(via==='ix'&&city&&isRemote(city)&&noRemote(id))return {ok:false,remote:true,why:REMOTE_WHY[hstr(id)%REMOTE_WHY.length]};
if(city&&(via==='ix'||via==='pni')){const w=satPeerWhy(id,ixCity(city));if(w)return {ok:false,sat:true,why:w};}
if(n.pol==='open')return {ok:true};
// In the Cogentle Spat, Goggle's peering desk wants eight times the usual traffic first, so cheap Cogentle-only transit really costs you Goggle (playtest).
if(n.pol==='selective'){const need=Math.round((via==='pni'?n.minPni:n.minIx)*confBoost(id)*salesPeerMul()*(id==='ggl'&&scnRule('spat')?8:1));return dem>=need?{ok:true}:{ok:false,why:tr('sold_out.wants_need_gbps_of_traffic_from',{need,dem:dem.toFixed(1)})};}

View file

@ -3720,6 +3720,7 @@
"peering_policy.already_reach_you_through_your":"Already reach you through your transit provider here and think that is fine.",
"peering_policy.moved_everything_in_this_city_to":"Moved everything in this city to PNIs. Please read their PearingDB page, all 40 pages of it.",
"peering_policy.not_accepting_new_peers_in_this":"Not accepting new peers in this region right now.",
"peering_policy.not_while_a_satellite_is_your_only_way":"Won't peer in {city} while a {orb} satellite is your only way out ({ms} ms there and back): they want your backbone where they meet you.",
"peering_policy.only_peers_over_pnis_in_this":"Only peers over PNIs in this metro. Order a cross-connect instead.",
"peering_policy.only_peers_with_members_they_can":"Only peers with members they can reach without a 1,500 km hairpin.",
"peering_policy.policy_no_remote_peers_be_in":"Policy: no remote peers. Be in the building or be in the transit bill.",

View file

@ -107,6 +107,60 @@ test('a teleport and a GEO circuit: level, price, lead time, capacity, latency,
assert.deepEqual(errors, []);
});
test('selective peers will not meet you on an island only a satellite reaches: many refuse GEO, few MEO, none once a cable lands', (t) => {
// Suva has an exchange with the big content networks on it; Sydney's teleport reaches it over Intelsplat 18.
const { ev, errors } = game(t, "ACT.buildPop({city:'syd'});ACT.launchBB({city:'syd'});ACT.buyTransit({city:'syd',net:'cog',tier:1});ACT.teleBuild({city:'syd'});ACT.buySat({a:'syd',b:'suv',bird:'is18',g:5});");
ev('window.innerWidth=360;window.innerHeight=740;window.dispatchEvent(new window.Event("resize"))');
ev(ready + ";ACT.buyIx({city:'suv',tier:0});closeModal();compute()");
assert.equal(ev("S.ixp.suv"), 0, 'a port on the island exchange');
assert.equal(ev("satOnly('suv').bird"), 'is18', 'the circuit is the only way out of Suva');
assert.equal(ev("satOnly('syd')"), null, 'Sydney is no island');
const sel = J(ev, "ixMembers('suv').filter(id=>NET[id].pol==='selective')");
const geoNo = sel.filter((id) => ev(`noSat('${id}','geo')`));
assert.ok(geoNo.length > 0 && geoNo.length < sel.length, 'some selective members refuse, some do not: ' + geoNo.join(','));
const ms = ev(`Math.round(2*satLat(${sat}))`);
assert.ok(ms > 500 && ms < 650, 'a GEO round trip: ' + ms);
for (const id of geoNo) {
for (const via of ['ix', 'pni']) {
const r = J(ev, `peerOk('${id}','${via}','suv')`);
assert.equal(r.ok, false, id + ' ' + via);
assert.equal(r.sat, true, id + ' ' + via);
assert.equal(r.why, `Won't peer in Suva while a GEO satellite is your only way out (${ms} ms there and back): they want your backbone where they meet you.`);
}
}
for (const id of sel.filter((x) => !geoNo.includes(x))) assert.ok(!J(ev, `peerOk('${id}','ix','suv')`).sat, id + ' does not mind');
for (const id of J(ev, "ixMembers('suv').filter(id=>NET[id].pol==='open')")) assert.equal(ev(`peerOk('${id}','ix','suv').ok`), true, id + ' is open');
// A session from before stays on the books but carries nothing while only the satellite reaches the island.
const k = geoNo[0];
ev(`S.peers['${k}@suv']=true;compute()`);
assert.equal(ev(`ixSessions('suv').has('${k}')`), false);
assert.equal(ev(`!!S.peers['${k}@suv']`), true, 'not torn down');
// The why, in the island's exchange section, at 360 px.
ev("UI.sel={type:'city',id:'suv'};UI.tab='peer';renderAll()");
assert.ok(ev("$('panel').textContent").includes(`Won't peer in Suva while a GEO satellite is your only way out (${ms} ms there and back)`));
// Fewer selective networks mind a MEO hop, and only ones that also mind GEO; the faster circuit is the one they judge.
const all = J(ev, "NETS.filter(n=>n.pol==='selective').map(n=>[n.id,noSat(n.id,'geo'),noSat(n.id,'meo')])");
const nGeo = all.filter((x) => x[1]).length, nMeo = all.filter((x) => x[2]).length;
assert.ok(nMeo > 0 && nMeo < nGeo / 2, `MEO ${nMeo}, GEO ${nGeo}`);
assert.ok(all.every((x) => !x[2] || x[1]), 'a network that minds MEO minds GEO too');
ev("ACT.teleTrk({city:'syd'});ACT.buySat({a:'syd',b:'suv',bird:'o3b',g:2});closeModal();S.day=S.links.find(l=>l.bird==='o3b').ready;compute()");
assert.equal(ev("satOnly('suv').bird"), 'o3b', 'MEO is the faster way out');
for (const id of geoNo) assert.equal(!!J(ev, `peerOk('${id}','ix','suv')`).sat, ev(`noSat('${id}','meo')`), id + ' over MEO');
// A wave lands: only once it is lit does Suva stop being a satellite island.
ev("UI.pending={a:'syd',b:'suv'};ACT.buildLink({tier:1});closeModal();compute()");
const w = "S.links.find(l=>l.kind==='wave')";
ev(`${w}.ready=S.day+5;compute()`);
assert.ok(ev("!!satOnly('suv')"), 'still being provisioned');
ev(`S.day=${w}.ready;compute()`);
assert.equal(ev("satOnly('suv')"), null);
for (const id of geoNo) assert.ok(!J(ev, `peerOk('${id}','ix','suv')`).sat, id + ' with a backbone to meet');
assert.equal(ev(`ixSessions('suv').has('${k}')`), true, 'the old session carries again');
// A cut does not change what is built: the island is still on the backbone as far as the peers go.
ev(`${w}.cut=S.day+30;compute()`);
assert.equal(ev("satOnly('suv')"), null);
assert.deepEqual(errors, []);
});
test('MEO needs tracking antennas and a higher level, and users barely notice it', (t) => {
const { ev, errors } = game(t, ISLE + "ACT.teleBuild({city:'syd'});");
ev("ACT.buySat({a:'syd',b:'tbu',bird:'o3b',g:5})");