Files
inbuxa-server/crates/smtp/src/lib.rs
T
jcoffey-dev f59b084ce5 Import upstream v0.16.24, stripped
Upstream commit: af37a234981722493b74623a983581691d2b70b6
Enterprise-only files removed or emptied: 63
Enterprise-only snippets removed: 118 in 50 files
Dangling module declarations removed: 5
Edits turning enterprise off: 25
Third-party code: 14 files, 0 not in THIRD-PARTY.md
Renamed identifiers: 62 in 18 files
Verification: clean

The same Enterprise footprint as v0.16.23. The build check fails only on
tests/src/directory/issuer.rs, unchanged since v0.16.23: it calls a helper
from upstream's Enterprise-only OIDC test, and tests issuer-based directory
routing, an Enterprise feature. main has never carried it.
2026-09-28 06:29:38 -07:00

65 lines
2.0 KiB
Rust

/*
* SPDX-FileCopyrightText: 2020 Stalwart Labs LLC <[email protected]>
*
* SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-SEL
*
* Modified by Coffey Labs in 2026 for INBUXA.
*/
// inbuxa: composite stores (sharded members, read replicas) nest store
// futures deeply enough to pass rustc's default query depth
#![recursion_limit = "512"]
#![warn(clippy::large_futures)]
use common::{
Inner,
manager::boot::{BootManager, IpcReceivers},
};
use queue::manager::SpawnQueue;
use reporting::scheduler::SpawnReport;
use std::sync::Arc;
pub mod core;
pub mod inbound;
pub mod outbound;
pub mod queue;
pub mod reporting;
pub mod scripts;
pub trait StartQueueManager {
fn start_queue_manager(&mut self);
}
pub trait SpawnQueueManager {
fn spawn_queue_manager(&mut self, inner: Arc<Inner>);
}
impl StartQueueManager for BootManager {
fn start_queue_manager(&mut self) {
self.ipc_rxs.spawn_queue_manager(self.inner.clone());
}
}
impl SpawnQueueManager for IpcReceivers {
fn spawn_queue_manager(&mut self, inner: Arc<Inner>) {
let core = inner.shared_core.load();
// inbuxa: upstream started these only when the node's role included
// outboundMta at boot, so turning the role on later did nothing and
// turning it off left them delivering until a restart. They now run
// on every node: the queue follows the role live (see Queue::start),
// and the report scheduler records DMARC and TLS results on every
// node, whatever its role (see reporting/scheduler.rs). This also
// drains the queue channel on nodes
// without the role, where every queued message's refresh used to sit
// in a channel nobody read until it filled and queueing blocked.
if !core.storage.registry.is_recovery_mode() {
// Spawn queue manager
self.queue_rx.take().unwrap().spawn(inner.clone());
// Spawn report manager
self.report_rx.take().unwrap().spawn(inner);
}
}
}