use std::error;
use std::future::Future;
use time::OffsetDateTime;
#[cfg(feature = "huggingface")]
pub mod huggingface;
#[derive(Debug, Clone, PartialEq)]
pub struct WindowMeta {
pub pipeline: String,
pub start: OffsetDateTime,
pub end: OffsetDateTime,
}
pub trait Sink<R>: Send {
type Error: error::Error + Send + Sync + 'static;
fn ingest(
&mut self,
meta: &WindowMeta,
records: Vec<R>,
) -> impl Future<Output = Result<(), Self::Error>> + Send;
fn flush(&mut self) -> impl Future<Output = Result<(), Self::Error>> + Send;
}