SPB Git forge
38commits 1branches 0releases
338.7 MBsize
maindefault branch
4 h agolast push
HTML 53.9% TypeScript 44.5% JavaScript 0.6% SQL 0.5%
946 B · 21 lines typescript
Raw Blame History
1/**2 * Operator connectors — batch 2 (OVHcloud, DataBank, EdgeConneX, TierPoint, NEXTDC, AirTrunk, Colt DCS, …).3 * Parsers register themselves on import; `register()` is the entry point picked up by the worker / try-connector.4 * Config: config/connectors/<operator>.yaml — docs: docs/connectors/<operator>.md5 */6import { listParsers } from "@dci/connectors";7import { AMERICAS_PARSERS } from "./americas.js";8import { EMEA_PARSERS } from "./emea.js";9import { APAC_PARSERS } from "./apac.js";1011export const OPERATORS2_PARSERS: readonly string[] = [...AMERICAS_PARSERS, ...EMEA_PARSERS, ...APAC_PARSERS];1213let registered = false;14export function register(): void {15  if (registered) return;16  registered = true;17  const have = new Set(listParsers().map((p) => p.name));18  const missing = OPERATORS2_PARSERS.filter((n) => !have.has(n));19  if (missing.length) throw new Error(`operators2: parsers not registered: ${missing.join(", ")}`);20}21