All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.smallrye.opentelemetry.test.InMemoryMetricExporterProvider Maven / Gradle / Ivy

There is a newer version: 2.8.0
Show newest version
package io.smallrye.opentelemetry.test;

import jakarta.enterprise.inject.spi.CDI;

import io.opentelemetry.sdk.autoconfigure.spi.ConfigProperties;
import io.opentelemetry.sdk.autoconfigure.spi.metrics.ConfigurableMetricExporterProvider;
import io.opentelemetry.sdk.metrics.export.MetricExporter;
import io.opentelemetry.sdk.testing.exporter.InMemoryMetricExporter;

public class InMemoryMetricExporterProvider implements ConfigurableMetricExporterProvider {
    @Override
    public MetricExporter createExporter(ConfigProperties configProperties) {
        return CDI.current().select(InMemoryMetricExporter.class).get();
    }

    @Override
    public String getName() {
        return "in-memory";
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy