//! A transport assigns live provenance before the channel admits a publication.
use crate::error::LiminalError;
use crate::protocol::DeliveredId;
/// One transport incarnation's identity allocator, shared by its channels.
pub trait PublicationIdentity: Send + Sync + std::fmt::Debug {
/// Allocates an identity before any durable append or delivery.
///
/// # Errors
/// The allocator exhausted its identity space or cannot name its incarnation.
fn next(&self) -> Result<DeliveredId, LiminalError>;
}