Class MetricsOrchestrator
java.lang.Object
de.cuioss.benchmarking.common.metrics.MetricsOrchestrator
Orchestrator for metrics processing.
Coordinates the transformation and export of real-time Prometheus metrics.
Delegates all transformation logic to BenchmarkMetricsTransformer.
-
Constructor Summary
ConstructorsConstructorDescriptionMetricsOrchestrator(PrometheusClient prometheusClient) Creates a new metrics orchestrator. -
Method Summary
Modifier and TypeMethodDescriptionvoidcollectBenchmarkMetrics(String benchmarkName, Instant startTime, Instant endTime, Path outputDir) Collects real-time metrics from Prometheus for a benchmark execution.
-
Constructor Details
-
MetricsOrchestrator
Creates a new metrics orchestrator.- Parameters:
prometheusClient- PrometheusClient for real-time metrics collection
-
-
Method Details
-
collectBenchmarkMetrics
public void collectBenchmarkMetrics(String benchmarkName, Instant startTime, Instant endTime, Path outputDir) throws IOException Collects real-time metrics from Prometheus for a benchmark execution. Fetches time-series data, calculates statistics (avg, p50, p95, max), and exports to JSON format.- Parameters:
benchmarkName- Name of the benchmark for file namingstartTime- Start time of the benchmark executionendTime- End time of the benchmark executionoutputDir- Directory to store the metrics JSON file- Throws:
IOException- if I/O operations fail
-