serverless-otlp-forwarder-core 0.2.1

Core library for Serverless OTLP Forwarders on AWS Lambda
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
use crate::telemetry::TelemetryData;
use anyhow::Result;

pub trait EventParser {
    // The specific AWS event type (e.g., LogsEvent, KinesisEvent)
    // that this parser instance knows how to handle.
    type EventInput;

    fn parse(
        &self,
        event_payload: Self::EventInput,
        source_identifier: &str,
    ) -> Result<Vec<TelemetryData>>;
}