From b336fd39444e8089d35a7a2bd4c0c3e8228c6c36 Mon Sep 17 00:00:00 2001 From: Mroik Date: Fri, 10 Apr 2026 00:21:25 +0200 Subject: Add mail processing scaffolding After receiving the email we don't want to process it in the same thread as soon as we can, instead we queue it to a MailProcessor. This allows us to be more flexible with the pipeline and reduce the amount of concurrency for the database connection. This also helps with writing possible fences around resource consumption. Signed-off-by: Mroik --- src/model.rs | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/model.rs') diff --git a/src/model.rs b/src/model.rs index 7fcf80f..37a855f 100644 --- a/src/model.rs +++ b/src/model.rs @@ -346,6 +346,13 @@ impl SubscriptionQuery<'_> { } } +// TODO +pub struct Mail { + pub from: String, + pub recipient: Vec, + pub data: String, +} + #[cfg(test)] mod tests { use anyhow::Result; -- cgit v1.3