From 1c42c41df01488a5f905b5f286cf30404a89233f Mon Sep 17 00:00:00 2001 From: Frederic Jung Date: Tue, 27 Oct 2026 08:54:12 +0100 Subject: [PATCH] PNIs: usually a month, 15% stuck for 6-12 months; routes sometimes sold out of a wave size Big-network PNIs and augments now take 30 days, with a 15% chance of 6 to 12 months (still halved at a conference). Help and order text say so. Leased waves can be sold out on a route for a while: a stable verdict per route, cable, size and 90-day window (2% for the smallest, rising to 10% for the biggest), with a reason. The link window greys out sold out sizes with the days left. Never in the first 90 days or the tutorial. --- CHANGELOG.md | 2 ++ site/i18n/fr.js | 12 ++++++++++-- site/i18n/it.js | 12 ++++++++++-- site/i18n/pt.js | 12 ++++++++++-- site/index.html | 24 ++++++++++++++++-------- tests/inbox.test.js | 38 +++++++++++++++++++++++++++++++++++--- 6 files changed, 83 insertions(+), 17 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 410401d..b870d88 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,8 @@ All notable changes to this project are documented here. The project follows ## [Unreleased] +- PNIs with the big networks are quicker again: most arrive in about a month, and only about one order in seven gets stuck in provisioning for 6 to 12 months. +- Now and then a carrier is sold out of a wave size on a route for a while, and bigger waves sell out more often. The link window shows which sizes are sold out and for how long; a smaller wave or another route usually still works, and nothing sells out in your first 90 days. - You can now start in Sydney, on hard mode. Australia is a long way from everywhere: transit costs three times the usual price and any wave touching the country costs far more than in Asia, though IX ports are cheaper than in Europe. Homes pay well for broadband, but the Nearly Broadband Network keeps 45% of every bill, and business customers pay more per gigabit but buy less of it. - Fiber between Perth and the rest of Australia crosses the Nullarbor and costs 1.7 times as much, because the incumbents own it. Waves round the south coast to Perth on SMAP are priced as domestic instead of overseas, so the sea route is now slightly cheaper. Australian outages have local flavour: cockatoos, kangaroos, backhoes, emus, copper thieves who dig up fiber by mistake, bushfires, huntsman spiders, possums and heatwaves. - Australian peering now follows the real exchanges. Sydney's exchange is IX Straya, with At-The-Edge IX as the challenger. Telstraya, Floptus, the Toilet Paper Group and their budget brands only peer privately, the big content networks peer in Sydney and Melbourne but not in Darwin or Hobart, and only carriers that really sell transit in Australia sell it there: Telstraya, Hocus Pocus, Speedyloop, SingTell, Drizzle Electric, Not That Telecom and, new in Sydney, Level Tree and Cogentle (Cogentle in Perth too). diff --git a/site/i18n/fr.js b/site/i18n/fr.js index 978dabc..ead66dd 100644 --- a/site/i18n/fr.js +++ b/site/i18n/fr.js @@ -2704,7 +2704,7 @@ "Loaded {name}. Check it, then deploy.":"{name} chargé. Vérifiez-le, puis déployez.", "Commit complete. Traffic down {p}.
The AI apologises for the confusion, and remains completely sure the script was right. Fix it from the NOC tab.":"Commit terminé. Trafic en baisse de {p}.
L’IA s’excuse pour la confusion, et reste absolument certaine que le script était juste. Corrigez-le depuis l’onglet NOC.", "Rules for your Auto-TE controller: which exits to prefer, which to avoid, and when to spill onto the next one. The editor’s help explains every rule and has ready-made scripts.":"Des règles pour votre contrôleur Auto-TE : quelles sorties préférer, lesquelles éviter et quand déborder sur la suivante. L’aide de l’éditeur explique chaque règle et propose des scripts tout prêts.", -"Delivery: 6 to 12 months":"Livraison : 6 à 12 mois", +"Delivery: about a month, sometimes 6 to 12 months":"Livraison : environ un mois, parfois 6 à 12 mois", "Delivery: 2 to 6 weeks":"Livraison : 2 à 6 semaines", "Their team quotes {m} months":"Leur équipe annonce {m} mois", "Ready in about {n} days":"Prête dans environ {n} jours", @@ -2803,7 +2803,7 @@ "sells PNIs down to 1G":"vend des PNI dès 1G", "on order: {n} days":"commandée : {n} jours", "PNI lead times":"Délais des PNI", -"A cross-connect with a small network takes a few weeks. The big content networks, Tier 1s and big eyeball networks quote 6 to 12 months for a new PNI or an augment, and the content networks and Tier 1s start at 100G. Doitsche Telekomm still sells 1G.":"Un cross-connect avec un petit réseau prend quelques semaines. Les grands réseaux de contenu, les Tier 1 et les grands opérateurs d’accès annoncent 6 à 12 mois pour une nouvelle PNI ou une extension, et les réseaux de contenu et les Tier 1 commencent à 100G. Doitsche Telekomm vend encore du 1G.", +"A cross-connect with a small network takes a few weeks. With the big content networks, Tier 1s and big eyeball networks, a new PNI or an augment usually takes about a month, but one order in seven slips to 6 to 12 months. The content networks and Tier 1s start at 100G. Doitsche Telekomm still sells 1G.":"Un cross-connect avec un petit réseau prend quelques semaines. Avec les grands réseaux de contenu, les Tier 1 et les grands opérateurs d’accès, une nouvelle PNI ou une extension prend en général environ un mois, mais une commande sur sept glisse à 6 à 12 mois. Les réseaux de contenu et les Tier 1 commencent à 100G. Doitsche Telekomm vend encore du 1G.", "Every IX port brings peering requests and max-prefix alerts, in the Networks tab. A session that blows past its limit is down until you look: raise the limit for growth, keep it down for a leak. Ignore your mail and selective networks get pickier.":"Chaque port IX amène des demandes de peering et des alertes max-prefix, dans l’onglet Réseaux. Une session qui dépasse sa limite reste coupée tant que vous n’y regardez pas : relevez la limite si c’est de la croissance, laissez-la coupée si c’est une fuite. Ignorez votre courrier et les réseaux sélectifs deviennent plus exigeants.", "No navigable sea route connects these landing stations.": "Aucun itinéraire maritime navigable ne relie ces stations d’atterrissement.", "Surveying a sea route\u2026":"Recherche d’un itinéraire maritime…", @@ -2903,4 +2903,12 @@ "{ix} LAG":"LAG {ix}", "A member at {ix} leaked the full routing table into the route server. Max-prefix limits tripped everywhere. Your peering there is down.":"Un membre de {ix} a fait fuiter la table de routage complète dans le route server. Les limites max-prefix ont sauté partout. Ton peering là-bas est tombé.", "{net} de-peered you at {ix}.
{why} Traffic falls back to your next best path.":"{net} a coupé le peering avec toi sur {ix}.
{why} Le trafic bascule sur ton meilleur chemin suivant.", +"A hyperscaler bought every wave of that size on this route last week.":"Un hyperscaler a acheté la semaine dernière toutes les ondes de cette taille sur cette route.", +"The carrier is out of spectrum here until its next line-system upgrade.":"L’opérateur n’a plus de spectre ici jusqu’à la prochaine mise à niveau du système de ligne.", +"The transponders for this route are on a container ship. The ship is somewhere near Singapore.":"Les transpondeurs pour cette route sont sur un porte-conteneurs. Le navire est quelque part près de Singapour.", +"The capacity is “available in the system”. Nobody can find it in the system.":"La capacité est « disponible dans le système ». Personne ne la trouve dans le système.", +"Their capacity planner is on holiday, and he took the spreadsheet with him.":"Leur planificateur de capacité est en vacances, et il a emporté le tableur.", +"The upgrade is planned for Q3. Which year, the email does not say.":"La mise à niveau est prévue pour le T3. De quelle année, l’e-mail ne le dit pas.", +"No {wave} capacity on this route right now.
{why} Try a smaller wave, another route, or ask again in {n} days.":"Plus de capacité {wave} sur cette route pour l’instant.
{why} Essayez une onde plus petite, une autre route, ou redemandez dans {n} jours.", +"sold out for {n} days":"épuisé pour {n} jours", }; diff --git a/site/i18n/it.js b/site/i18n/it.js index b0afd34..fbef8e9 100644 --- a/site/i18n/it.js +++ b/site/i18n/it.js @@ -2707,7 +2707,7 @@ "Loaded {name}. Check it, then deploy.":"{name} caricato. Controllalo, poi fai il deploy.", "Commit complete. Traffic down {p}.
The AI apologises for the confusion, and remains completely sure the script was right. Fix it from the NOC tab.":"Commit completato. Traffico giù del {p}.
L’IA si scusa per la confusione, e resta sicurissima che lo script fosse giusto. Correggilo dalla scheda NOC.", "Rules for your Auto-TE controller: which exits to prefer, which to avoid, and when to spill onto the next one. The editor’s help explains every rule and has ready-made scripts.":"Regole per il tuo controller Auto-TE: quali uscite preferire, quali evitare e quando passare alla successiva. L’aiuto dell’editor spiega ogni regola e ha script pronti.", -"Delivery: 6 to 12 months":"Consegna: da 6 a 12 mesi", +"Delivery: about a month, sometimes 6 to 12 months":"Consegna: circa un mese, a volte da 6 a 12 mesi", "Delivery: 2 to 6 weeks":"Consegna: da 2 a 6 settimane", "Their team quotes {m} months":"Il loro team parla di {m} mesi", "Ready in about {n} days":"Pronta in circa {n} giorni", @@ -2806,7 +2806,7 @@ "sells PNIs down to 1G":"vende PNI anche da 1G", "on order: {n} days":"in ordine: {n} giorni", "PNI lead times":"Tempi di consegna delle PNI", -"A cross-connect with a small network takes a few weeks. The big content networks, Tier 1s and big eyeball networks quote 6 to 12 months for a new PNI or an augment, and the content networks and Tier 1s start at 100G. Doitsche Telekomm still sells 1G.":"Un cross-connect con una rete piccola richiede qualche settimana. Le grandi reti di contenuti, i Tier 1 e i grandi operatori di accesso parlano di 6-12 mesi per una nuova PNI o un ampliamento, e le reti di contenuti e i Tier 1 partono da 100G. Doitsche Telekomm vende ancora 1G.", +"A cross-connect with a small network takes a few weeks. With the big content networks, Tier 1s and big eyeball networks, a new PNI or an augment usually takes about a month, but one order in seven slips to 6 to 12 months. The content networks and Tier 1s start at 100G. Doitsche Telekomm still sells 1G.":"Un cross-connect con una rete piccola richiede qualche settimana. Con le grandi reti di contenuti, i Tier 1 e i grandi operatori di accesso, una nuova PNI o un ampliamento arriva di solito in circa un mese, ma un ordine su sette slitta a 6-12 mesi. Le reti di contenuti e i Tier 1 partono da 100G. Doitsche Telekomm vende ancora 1G.", "Every IX port brings peering requests and max-prefix alerts, in the Networks tab. A session that blows past its limit is down until you look: raise the limit for growth, keep it down for a leak. Ignore your mail and selective networks get pickier.":"Ogni porta IX porta richieste di peering e allarmi max-prefix, nella scheda Reti. Una sessione che supera il limite resta giù finché non ci guardi: alza il limite se è crescita, tienila giù se è un leak. Ignora la posta e le reti selettive diventano più esigenti.", "No navigable sea route connects these landing stations.": "Nessuna rotta marittima navigabile collega queste stazioni di approdo.", "Surveying a sea route\u2026":"Ricerca di una rotta marittima…", @@ -2903,4 +2903,12 @@ "{ix} LAG":"LAG {ix}", "A member at {ix} leaked the full routing table into the route server. Max-prefix limits tripped everywhere. Your peering there is down.":"Un membro di {ix} ha fatto leak dell’intera tabella di routing nel route server. I limiti max-prefix sono scattati ovunque. Il tuo peering lì è giù.", "{net} de-peered you at {ix}.
{why} Traffic falls back to your next best path.":"{net} ti ha tolto il peering su {ix}.
{why} Il traffico ripiega sul miglior percorso rimasto.", +"A hyperscaler bought every wave of that size on this route last week.":"Un hyperscaler ha comprato la settimana scorsa ogni onda di questa misura su questa tratta.", +"The carrier is out of spectrum here until its next line-system upgrade.":"Il carrier ha finito lo spettro qui fino al prossimo aggiornamento del sistema di linea.", +"The transponders for this route are on a container ship. The ship is somewhere near Singapore.":"I transponder per questa tratta sono su una nave portacontainer. La nave è da qualche parte vicino a Singapore.", +"The capacity is “available in the system”. Nobody can find it in the system.":"La capacità è “disponibile nel sistema”. Nessuno la trova nel sistema.", +"Their capacity planner is on holiday, and he took the spreadsheet with him.":"Il loro capacity planner è in ferie, e si è portato via il foglio di calcolo.", +"The upgrade is planned for Q3. Which year, the email does not say.":"L’aggiornamento è previsto per il Q3. Di quale anno, l’email non lo dice.", +"No {wave} capacity on this route right now.
{why} Try a smaller wave, another route, or ask again in {n} days.":"Nessuna capacità {wave} su questa tratta al momento.
{why} Prova un’onda più piccola, un’altra tratta, o chiedi di nuovo tra {n} giorni.", +"sold out for {n} days":"esaurito per {n} giorni", }; diff --git a/site/i18n/pt.js b/site/i18n/pt.js index f43a808..68287bf 100644 --- a/site/i18n/pt.js +++ b/site/i18n/pt.js @@ -2707,7 +2707,7 @@ "Loaded {name}. Check it, then deploy.":"{name} carregado. Verifique e depois faça o deploy.", "Commit complete. Traffic down {p}.
The AI apologises for the confusion, and remains completely sure the script was right. Fix it from the NOC tab.":"Commit concluído. Tráfego caiu {p}.
A IA pede desculpas pela confusão, e continua totalmente certa de que o script estava correto. Corrija pela aba NOC.", "Rules for your Auto-TE controller: which exits to prefer, which to avoid, and when to spill onto the next one. The editor’s help explains every rule and has ready-made scripts.":"Regras para o seu controlador Auto-TE: quais saídas preferir, quais evitar e quando passar para a próxima. A ajuda do editor explica cada regra e tem scripts prontos.", -"Delivery: 6 to 12 months":"Entrega: de 6 a 12 meses", +"Delivery: about a month, sometimes 6 to 12 months":"Entrega: cerca de um mês, às vezes de 6 a 12 meses", "Delivery: 2 to 6 weeks":"Entrega: de 2 a 6 semanas", "Their team quotes {m} months":"A equipe deles fala em {m} meses", "Ready in about {n} days":"Pronta em cerca de {n} dias", @@ -2806,7 +2806,7 @@ "sells PNIs down to 1G":"vende PNI a partir de 1G", "on order: {n} days":"encomendada: {n} dias", "PNI lead times":"Prazos de PNI", -"A cross-connect with a small network takes a few weeks. The big content networks, Tier 1s and big eyeball networks quote 6 to 12 months for a new PNI or an augment, and the content networks and Tier 1s start at 100G. Doitsche Telekomm still sells 1G.":"Um cross-connect com uma rede pequena leva algumas semanas. As grandes redes de conteúdo, os Tier 1 e as grandes operadoras de acesso falam em 6 a 12 meses para uma PNI nova ou uma ampliação, e as redes de conteúdo e os Tier 1 começam em 100G. A Doitsche Telekomm ainda vende 1G.", +"A cross-connect with a small network takes a few weeks. With the big content networks, Tier 1s and big eyeball networks, a new PNI or an augment usually takes about a month, but one order in seven slips to 6 to 12 months. The content networks and Tier 1s start at 100G. Doitsche Telekomm still sells 1G.":"Um cross-connect com uma rede pequena leva algumas semanas. Com as grandes redes de conteúdo, os Tier 1 e as grandes operadoras de acesso, uma PNI nova ou uma ampliação costuma levar cerca de um mês, mas um pedido em cada sete atrasa para 6 a 12 meses. As redes de conteúdo e os Tier 1 começam em 100G. A Doitsche Telekomm ainda vende 1G.", "Every IX port brings peering requests and max-prefix alerts, in the Networks tab. A session that blows past its limit is down until you look: raise the limit for growth, keep it down for a leak. Ignore your mail and selective networks get pickier.":"Cada porta de IX traz pedidos de peering e alertas de max-prefix, na aba Redes. Uma sessão que estoura o limite fica fora até você olhar: aumente o limite se for crescimento, deixe fora se for vazamento. Ignore seus e-mails e as redes seletivas ficam mais exigentes.", "No navigable sea route connects these landing stations.": "Nenhuma rota marítima navegável conecta estas estações de aterragem.", "Surveying a sea route\u2026":"Pesquisando uma rota marítima…", @@ -2903,4 +2903,12 @@ "{ix} LAG":"LAG do {ix}", "A member at {ix} leaked the full routing table into the route server. Max-prefix limits tripped everywhere. Your peering there is down.":"Um membro do {ix} vazou a tabela de roteamento inteira no route server. Limites de max-prefix estouraram em todo lugar. Seu peering lá caiu.", "{net} de-peered you at {ix}.
{why} Traffic falls back to your next best path.":"{net} cortou o peering com você no {ix}.
{why} O tráfego volta para o seu próximo melhor caminho.", +"A hyperscaler bought every wave of that size on this route last week.":"Um hyperscaler comprou semana passada todas as ondas desse tamanho nesta rota.", +"The carrier is out of spectrum here until its next line-system upgrade.":"A operadora está sem espectro aqui até a próxima atualização do sistema de linha.", +"The transponders for this route are on a container ship. The ship is somewhere near Singapore.":"Os transponders desta rota estão num navio porta-contêineres. O navio está em algum lugar perto de Singapura.", +"The capacity is “available in the system”. Nobody can find it in the system.":"A capacidade está “disponível no sistema”. Ninguém acha no sistema.", +"Their capacity planner is on holiday, and he took the spreadsheet with him.":"O planejador de capacidade deles está de férias, e levou a planilha junto.", +"The upgrade is planned for Q3. Which year, the email does not say.":"A atualização está prevista para o Q3. De que ano, o e-mail não diz.", +"No {wave} capacity on this route right now.
{why} Try a smaller wave, another route, or ask again in {n} days.":"Sem capacidade de {wave} nesta rota agora.
{why} Tente uma onda menor, outra rota, ou pergunte de novo em {n} dias.", +"sold out for {n} days":"esgotado por {n} dias", }; diff --git a/site/index.html b/site/index.html index d1037b4..bc16839 100644 --- a/site/index.html +++ b/site/index.html @@ -1824,16 +1824,16 @@ function t1Club(){ if(R.sessions<20)miss.push(tr('20+ peering sessions ({n})',{n:R.sessions})); return {ok:!miss.length,missing:miss}; } -/* ---------- PNIs with the big networks: months of lead time and no small ports ---------- - Big content networks, Tier 1s and big eyeball networks quote 6 to 12 months for a PNI or an augment, and - the content networks and Tier 1s start at 100G. Doitsche Telekomm sells PNIs down to 1G, and takes its time too. */ +/* ---------- PNIs with the big networks: slow orders and no small ports ---------- + Big content networks, Tier 1s and big eyeball networks usually deliver a PNI or an augment in about 30 days, but + 15% of orders get lost in provisioning for 6 to 12 months. The content networks and Tier 1s start at 100G. Doitsche Telekomm sells PNIs down to 1G, and takes its time too. */ const pniBig=id=>{const n=NET[id];return n.type==='t1'||(n.type==='cdn'&&n.pol!=='open')||(n.type==='eye'&&n.share>=0.02);}; const pniMin=id=>{const n=NET[id];return n.type==='t1'||(n.type==='cdn'&&n.pol!=='open')?1:0;}; const pniG1=id=>id==='dtk'; // A beer with their peering coordinator at a conference halves the wait. It is how it really works. -const pniLead=id=>{const n=pniBig(id)?180+Math.floor(Math.random()*186):14+Math.floor(Math.random()*29);return S.conf&&S.conf.until>S.day?Math.round(n/2):n;}; +const PNI_SLOW=0.15,pniLead=id=>{const n=pniBig(id)?(Math.random()S.day?Math.round(n/2):n;}; const pniG=p=>p.g1?1:PORT[p.tier].g,pniPN=p=>p.g1?'1G':PORT[p.tier].n,pniOn=p=>!(p.ready>S.day); -const pniEta=id=>pniBig(id)?tr('Delivery: 6 to 12 months'):tr('Delivery: 2 to 6 weeks'); +const pniEta=id=>pniBig(id)?tr('Delivery: about a month, sometimes 6 to 12 months'):tr('Delivery: 2 to 6 weeks'); const PNI_G1_COST=1200,pniWhen=n=>n>=60?tr('Their team quotes {m} months',{m:Math.round(n/30)}):tr('Ready in about {n} days',{n}); function pniWait(p,c){return `
${(p.n||1)>1?p.n+'×':''}${pniPN(p)} PNI${tr('on order')}
${tr('About {n} days to go. Nothing to do but wait, or chase it.',{n:Math.max(0,p.ready-S.day)})}
${btn(tr('Chase it'),'pniChase',{id:p.id},'ghost sm')}${btn(UI.confirm===p.id?tr('Really remove?'):tr('Cancel the order'),'cancelPni',{id:p.id},'ghost sm')}
`;} function pniDay(d){for(const p of S.pni){const nm=esc(NET[p.net].name),city=esc(CITY[p.city].name); @@ -1981,6 +1981,13 @@ function dkTick(d){if(!S.dk)return;const dk=S.dk; function elephant(){S.phpDone=true;S.ev.php=S.day+4; toast(tr(`🐘 BREAKING: CVE-2026-31337 just took down half the internet.
A bug in PHP turned every WordPress-ish site on Earth into a crypto miner. Eyeball traffic is down 30% for a few days while the world patches. Your hosting customers are doing it at 3 a.m.`),'bad');sfx('alert');renderMega();} +/* Sold out: now and then a carrier has no spare capacity of a size on a route. Each route, size and 90-day window + gets a stable verdict from a hash, so asking again does not reroll it, and bigger waves sell out more often. */ +const SOLD_WIN=90,SOLD_WHY=[N_('A hyperscaler bought every wave of that size on this route last week.'),N_('The carrier is out of spectrum here until its next line-system upgrade.'),N_('The transponders for this route are on a container ship. The ship is somewhere near Singapore.'),N_('The capacity is “available in the system”. Nobody can find it in the system.'),N_('Their capacity planner is on holiday, and he took the spreadsheet with him.'),N_('The upgrade is planned for Q3. Which year, the email does not say.')]; +const soldP=tier=>Math.min(0.1,0.02+0.012*tier); +// Never in the first 90 days: a new network has enough on its plate. Never in the tutorial or a scenario's first quarter either. +function soldOut(a,b,tier,via){if(!S||S.day=soldP(tier)*1000)return null;return {why:SOLD_WHY[(h>>>10)%SOLD_WHY.length],until:(ep+1)*SOLD_WIN-off};} function snubWhy(sn){const d=Math.max(1,sn.until-S.day);return sn.why+' '+trn('They will reconsider in {n} day.','They will reconsider in {n} days.',d);} // Paid-peering giants drop the fee for networks too big to ignore (freeLv: the customer level that does it). const paidFree=n=>!!(n&&n.freeLv&&lvl()>=n.freeLv); @@ -3334,7 +3341,8 @@ const ACT={ buildLink:({tier})=>{tier=+tier;const p=UI.pending;if(!p)return;const {a,b}=p;const km=kmBetween(a,b),sub=isSub(a,b),sib=pairLinks(a,b).filter(l=>l.kind!=='vxc'),jn=sib.length?routeJoin(a,b):null,same=!!jn,border=cnCity(a)!==cnCity(b),mult=(sib.length&&!(jn&&jn.k===(landTrenches(a,b)[0]||{}).k)?DIVERSE:1)*(border?3*(UI.cnPrem&&(a==='hkg'||b==='hkg')?1.6:1):1); if((cnCity(a)||cnCity(b))&&!cnOk())return; if(!waveOk(a,b,tier)){toast(tr('A {wave} wave needs {need} at both ends.',{wave:LT[tier].n,need:esc(waveNeed(tier))}),'bad');sfx('err');return;} - const wr=waveRoute(a,b,mult,border);if(!wr){toast(tr('No cable available for that route right now.'),'bad');sfx('err');return;}{const w=subWaveWhy(tier,wr.km,wr.sub);if(w){toast(tr('No {wave} waves on this cable.
{why}',{wave:LT[tier].n,why:esc(w)}),'bad');sfx('err');return;}}const base=Math.round(waveMo(wr.km,wr.sub,tier)*wr.wm),cost=base+(S.pops[b]?0:popCost(b)); + const wr=waveRoute(a,b,mult,border);if(!wr){toast(tr('No cable available for that route right now.'),'bad');sfx('err');return;} + {const so=soldOut(a,b,tier,wr.cab);if(so){toast(tr('No {wave} capacity on this route right now.
{why} Try a smaller wave, another route, or ask again in {n} days.',{wave:LT[tier].n,why:tr(so.why),n:Math.max(1,so.until-S.day)}),'bad');sfx('err');return;}}{const w=subWaveWhy(tier,wr.km,wr.sub);if(w){toast(tr('No {wave} waves on this cable.
{why}',{wave:LT[tier].n,why:esc(w)}),'bad');sfx('err');return;}}const base=Math.round(waveMo(wr.km,wr.sub,tier)*wr.wm),cost=base+(S.pops[b]?0:popCost(b)); if(!portGate(a,1)||!portGate(b,1))return;if(!spend(cost))return;if(!S.pops[b])S.pops[b]={day:S.day,bb:null,boost:0,down:0,routers:1,gen:false}; const id=uid();const l={id,a,b,kind:'wave',border,premium:border&&!!UI.cnPrem&&(a==='hkg'||b==='hkg'),tier,km:wr.km,sub:wr.sub,cable:wr.cab,mo:base,mult:wr.wm,trench:wr.cab?'cab:'+wr.cab:(jn?jn.k:id),cut:0,day:S.day};S.links.push(l);closeModal(); if(sib.length){UI.sel={type:'link',id};}else{UI.sel={type:'city',id:b};UI.tab='cust';} @@ -4346,7 +4354,7 @@ function showHelp(){
CDN
${tr('Content networks like NetChill and Goggle. Most of your traffic comes from them. Peer with them and that traffic is free.')}
${tr('IX (Internet Exchange)')}
${tr('A shared switch in a city. One port, many free peering sessions. The route server peers you with every open member at once.')}
PNI
${tr('Private network interconnect: a cable straight to one network in the same building. For big traffic.')}
-
${tr('PNI lead times')}
${tr('A cross-connect with a small network takes a few weeks. The big content networks, Tier 1s and big eyeball networks quote 6 to 12 months for a new PNI or an augment, and the content networks and Tier 1s start at 100G. Doitsche Telekomm still sells 1G.')}
+
${tr('PNI lead times')}
${tr('A cross-connect with a small network takes a few weeks. With the big content networks, Tier 1s and big eyeball networks, a new PNI or an augment usually takes about a month, but one order in seven slips to 6 to 12 months. The content networks and Tier 1s start at 100G. Doitsche Telekomm still sells 1G.')}
${tr('Backhaul latency')}
${tr('Users feel the round trip to wherever their traffic leaves your network for transit. Up to 20 ms (about 1,500 km) is fine; past 50 ms broadband and internet services count as bad service, which costs revenue and customers. Traffic over your own peering, PNIs and caches is not penalised.')}
${tr('Peering inbox')}
${tr('Every IX port brings peering requests and max-prefix alerts, in the Networks tab. A session that blows past its limit is down until you look: raise the limit for growth, keep it down for a leak. Ignore your mail and selective networks get pickier.')}
${tr('Embedded cache')}
${tr('A CDN\'s server in your rack. Serves most of that CDN\'s traffic locally, for the price of power.')}
@@ -4377,7 +4385,7 @@ function openLinkModal(a,b){ openModal(`${head}

${tr('Waves are leased at a flat monthly rate. Bigger and longer costs more, and subsea is 1.8×. First month is due now.')}

${pop?`

${tr('Includes a new POP in {city} ({price}{extra}).',{city:CITY[b].name,price:fmt$(popCost(b)),extra:ruCity(b)?', '+tr('government box included'):CITY[b].uae?', '+tr('free-zone license included'):CITY[b].saudi?', '+tr('local telecom licence included'):''})}

`:''}${route}${viaSeg(a,b)} -
${LT.map((T,i)=>{const lc=Math.round(waveMo(wr.km,wr.sub,i)*wr.wm),c=lc+pop,sw=subWaveWhy(i,wr.km,wr.sub),ok=waveOk(a,b,i)&&!sw;return !waveShown(i)?'':``;}).join('')}
`); +
${LT.map((T,i)=>{const lc=Math.round(waveMo(wr.km,wr.sub,i)*wr.wm),c=lc+pop,sw=subWaveWhy(i,wr.km,wr.sub),so=!sw&&soldOut(a,b,i,wr.cab),ok=waveOk(a,b,i)&&!sw&&!so;return !waveShown(i)?'':``;}).join('')}
`); } /* Your own subsea cable (#22). Tier 1 networks lay their own: very expensive, slow to build, and it pays for itself after a few years if it replaces enough leased waves. Both ends need a cable landing station. You own diff --git a/tests/inbox.test.js b/tests/inbox.test.js index 35fe0f4..65e0f56 100644 --- a/tests/inbox.test.js +++ b/tests/inbox.test.js @@ -6,13 +6,14 @@ function setup(ev) { ev("ACT.start({});S.cash=1e9;S.lvl=6;for(const g of GOALS)S.done[g.id]=0;ACT.launchBB({city:'fra'});for(const c in S.pops)S.pops[c].rgen=3;compute()"); } -test('PNIs with the big networks take 6 to 12 months and start at 100G; small ones take weeks', () => { +test('PNIs with the big networks take a month, now and then 6 to 12, and start at 100G; small ones take weeks', () => { const { ev, errors } = load(); setup(ev); ev("R.demTo.nfx=1e4;ACT.pni({city:'fra',net:'nfx',tier:0})"); assert.equal(ev('S.pni.length'), 0, 'no 10G PNI with NetChill'); assert.match(ev("document.getElementById('toasts').textContent"), /does not do 10G/); - ev("R.demTo.nfx=1e4;ACT.pni({city:'fra',net:'nfx',tier:1})"); + // one order in seven gets lost in provisioning for months + ev("Math.random=()=>0.1;R.demTo.nfx=1e4;ACT.pni({city:'fra',net:'nfx',tier:1})"); const p = JSON.parse(ev('JSON.stringify(S.pni[0])')); assert.ok(p.ready - ev('S.day') >= 180 && p.ready - ev('S.day') <= 365, `six to twelve months (${p.ready - ev('S.day')} days)`); ev('compute()'); @@ -33,9 +34,16 @@ test('PNIs with the big networks take 6 to 12 months and start at 100G; small on ev("Math.random=()=>0.5;R.demTo.nfx=1e4;ACT.pni({city:'fra',net:'nfx',tier:3});const r0=S.pni[0].up.ready;ACT.pniChase({id:S.pni[0].id});window.__r=[r0,S.pni[0].up.ready]"); const [r0, r1] = JSON.parse(ev('JSON.stringify(__r)')); assert.equal(r0, r1); + // most orders arrive in about a month + ev("Math.random=()=>0.5;S.pni=[];R.demTo.ggl=1e4;ACT.pni({city:'fra',net:'ggl',tier:1})"); + assert.equal(ev("S.pni.find(p=>p.net==='ggl').ready-S.day"), 30); + ev("S.pni=S.pni.filter(p=>p.net!=='ggl')"); // a beer at a conference halves the wait ev("Math.random=()=>0.99;S.conf={until:S.day+10,reg:'EU',name:'RIPE'}"); - assert.equal(ev("pniLead('ggl')"), Math.round((180 + Math.floor(0.99 * 186)) / 2)); + assert.equal(ev("pniLead('ggl')"), 15, 'the usual month, halved'); + ev('Math.random=()=>0.1'); + assert.equal(ev("pniLead('ggl')"), Math.round((180 + Math.floor(0.1 * 186)) / 2), 'a slow one, halved'); + ev('Math.random=()=>0.99'); ev('S.conf=null'); // a small network: a few weeks const small = ev("NETS.find(n=>n.pops.includes('fra')&&!pniBig(n.id)&&n.pol==='open'&&n.type!=='cdn').id"); @@ -181,3 +189,27 @@ test('saves: the inbox and PNIs on order survive, and garbage is repaired', () = assert.equal(ev('__p.inbox.bot'), false); assert.deepEqual(errors, []); }); + +test('now and then a route is sold out of a wave size, for a while, and asking again does not reroll it', () => { + const { ev, errors } = load(); + setup(ev); + ev("ACT.buildPop({city:'ams'});S.pops.ams.rgen=3"); + assert.equal(ev("S.day=10;!!soldOut('fra','ams',3,null)||!!soldOut('fra','ams',1,null)"), false, 'never in the first 90 days'); + // find a day when 400G is sold out between Frankfurt and Amsterdam + const day = ev("(()=>{for(let d=90;d<20000;d++){S.day=d;if(soldOut('fra','ams',2,null))return d;}return -1;})()"); + assert.ok(day > 0, 'it happens'); + ev(`S.day=${day}`); + const so = JSON.parse(ev("JSON.stringify(soldOut('fra','ams',2,null))")); + assert.ok(so.until > day && so.until - day <= 90); + assert.equal(ev(`S.day=${so.until - 1};!!soldOut('fra','ams',2,null)`), true, 'the same verdict for the whole window'); + ev(`S.day=${day}`); + const share = ev("(()=>{let n=0;for(let d=90;d<20090;d++){S.day=d;if(soldOut('ams','fra',5,null))n++;}return n/20000;})()"); + assert.ok(share > 0.02 && share < 0.2, `rare, a bit more for big waves (${share})`); + ev(`S.day=${day};UI.via=null;openLinkModal('fra','ams')`); + assert.match(ev("document.getElementById('modalCard').textContent"), /sold out for \d+ days/); + const n = ev('S.links.length'); + ev('ACT.buildLink({tier:2})'); + assert.equal(ev('S.links.length'), n, 'no 400G today'); + assert.match(ev("document.getElementById('toasts').textContent"), /No 400G capacity on this route/); + assert.deepEqual(errors, []); +});