UNPKG

@aws/aws-distro-opentelemetry-node-autoinstrumentation

Version:

This package provides Amazon Web Services distribution of the OpenTelemetry Node Instrumentation, which allows for auto-instrumentation of NodeJS applications.

30 lines 1.31 kB
import { AggregationSelector, AggregationTemporalitySelector } from '@opentelemetry/sdk-metrics'; import type { LogEvent, CloudWatchLogsClientConfig } from '@aws-sdk/client-cloudwatch-logs'; import { EMFExporterBase } from './emf-exporter-base'; /** * OpenTelemetry metrics exporter for CloudWatch EMF format. * * This exporter converts OTel metrics into CloudWatch EMF logs which are then * sent to CloudWatch Logs. CloudWatch Logs automatically extracts the metrics * from the EMF logs. */ export declare class AWSCloudWatchEMFExporter extends EMFExporterBase { private logClient; constructor(namespace: string | undefined, logGroupName: string, logStreamName?: string, aggregationTemporalitySelector?: AggregationTemporalitySelector, aggregationSelector?: AggregationSelector, cloudwatchLogsConfig?: CloudWatchLogsClientConfig); /** * Send a log event to CloudWatch Logs using the log client. * * @param logEvent The log event to send * @returns {Promise<void>} */ protected sendLogEvent(logEvent: Required<LogEvent>): Promise<void>; /** * Force flush any pending metrics. */ forceFlush(): Promise<void>; /** * Shutdown the exporter. */ shutdown(): Promise<void>; } //# sourceMappingURL=aws-cloudwatch-emf-exporter.d.ts.map