1#[cfg(any(feature = "sources-vector", feature = "sinks-vector"))]
2use crate::event::proto as event;
3
4#[cfg(any(feature = "sources-vector", feature = "sinks-vector"))]
5pub mod vector;
6
7#[cfg(feature = "sinks-datadog_metrics")]
8pub mod fds {
9 use std::sync::OnceLock;
10
11 use prost_reflect::DescriptorPool;
12
13 pub fn protobuf_descriptors() -> &'static DescriptorPool {
14 static PROTOBUF_FDS: OnceLock<DescriptorPool> = OnceLock::new();
15 PROTOBUF_FDS.get_or_init(|| {
16 DescriptorPool::decode(include_bytes!(concat!(env!("OUT_DIR"), "/protobuf-fds.bin")).as_ref())
17 .expect("should not fail to decode protobuf file descriptor set generated from build script")
18 })
19 }
20}