Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckExporterLogs

func CheckExporterLogs(t *testing.T, exporter string, acceptedLogRecords, droppedLogRecords int64)

CheckExporterLogs checks that for the current exported values for logs exporter metrics match given values. When this function is called it is required to also call SetupRecordedMetricsTest as first thing.

func CheckExporterMetrics

func CheckExporterMetrics(t *testing.T, exporter string, acceptedMetricsPoints, droppedMetricsPoints int64)

CheckExporterMetrics checks that for the current exported values for metrics exporter metrics match given values. When this function is called it is required to also call SetupRecordedMetricsTest as first thing.

func CheckExporterTraces

func CheckExporterTraces(t *testing.T, exporter string, acceptedSpans, droppedSpans int64)

CheckExporterTraces checks that for the current exported values for trace exporter metrics match given values. When this function is called it is required to also call SetupRecordedMetricsTest as first thing.

func CheckProcessorLogs

func CheckProcessorLogs(t *testing.T, processor string, acceptedLogRecords, refusedLogRecords, droppedLogRecords int64)

CheckProcessorLogs checks that for the current exported values for logs exporter metrics match given values. When this function is called it is required to also call SetupRecordedMetricsTest as first thing.

func CheckProcessorMetrics

func CheckProcessorMetrics(t *testing.T, processor string, acceptedMetricPoints, refusedMetricPoints, droppedMetricPoints int64)

CheckProcessorMetrics checks that for the current exported values for metrics exporter metrics match given values. When this function is called it is required to also call SetupRecordedMetricsTest as first thing.

func CheckProcessorTraces

func CheckProcessorTraces(t *testing.T, processor string, acceptedSpans, refusedSpans, droppedSpans int64)

CheckProcessorTraces checks that for the current exported values for trace exporter metrics match given values. When this function is called it is required to also call SetupRecordedMetricsTest as first thing.

func CheckReceiverLogs

func CheckReceiverLogs(t *testing.T, receiver, protocol string, acceptedLogRecords, droppedLogRecords int64)

CheckReceiverLogs checks that for the current exported values for logs receiver metrics match given values. When this function is called it is required to also call SetupRecordedMetricsTest as first thing.

func CheckReceiverMetrics

func CheckReceiverMetrics(t *testing.T, receiver, protocol string, acceptedMetricPoints, droppedMetricPoints int64)

CheckReceiverMetrics checks that for the current exported values for metrics receiver metrics match given values. When this function is called it is required to also call SetupRecordedMetricsTest as first thing.

func CheckReceiverTraces

func CheckReceiverTraces(t *testing.T, receiver, protocol string, acceptedSpans, droppedSpans int64)

CheckReceiverTraces checks that for the current exported values for trace receiver metrics match given values. When this function is called it is required to also call SetupRecordedMetricsTest as first thing.

func CheckScraperMetrics

func CheckScraperMetrics(t *testing.T, receiver, scraper string, scrapedMetricPoints, erroredMetricPoints int64)

CheckScraperMetrics checks that for the current exported values for metrics scraper metrics match given values. When this function is called it is required to also call SetupRecordedMetricsTest as first thing.

func SetupRecordedMetricsTest

func SetupRecordedMetricsTest() (func(), error)

SetupRecordedMetricsTest does setup the testing environment to check the metrics recorded by receivers, producers or exporters. The returned function should be deferred.

Types

This section is empty.