From 40df2a0c893a1676aec7684e9c06baa6f92ee816 Mon Sep 17 00:00:00 2001 From: sbruens Date: Thu, 17 Oct 2024 12:21:03 -0400 Subject: [PATCH] Revert changes to `prometheus_scraper.ts`. --- src/shadowbox/infrastructure/prometheus_scraper.ts | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/src/shadowbox/infrastructure/prometheus_scraper.ts b/src/shadowbox/infrastructure/prometheus_scraper.ts index c461cd619..aee0239a6 100644 --- a/src/shadowbox/infrastructure/prometheus_scraper.ts +++ b/src/shadowbox/infrastructure/prometheus_scraper.ts @@ -21,14 +21,10 @@ import * as path from 'path'; import * as logging from '../infrastructure/logging'; -export interface QueryResultMetric { - [labelValue: string]: string; -} - export interface QueryResultData { resultType: 'matrix' | 'vector' | 'scalar' | 'string'; result: Array<{ - metric: QueryResultMetric; + metric: {[labelValue: string]: string}; value: [number, string]; }>; } @@ -105,7 +101,7 @@ async function spawnPrometheusSubprocess( prometheusEndpoint: string ): Promise { logging.info('======== Starting Prometheus ========'); - logging.info(`${binaryFilename} ${processArgs.map((a) => `"${a}"`).join(' ')}`); + logging.info(`${binaryFilename} ${processArgs.map(a => `"${a}"`).join(' ')}`); const runProcess = child_process.spawn(binaryFilename, processArgs); runProcess.on('error', (error) => { logging.error(`Error spawning Prometheus: ${error}`);