Expand description
§rvoip-core
Transport-agnostic spine for RVoIP. Carries the voip-3 vocabulary
(Conversation, Session, Connection, MediaStream, Message,
Participant), the ConnectionAdapter trait that adapter crates implement,
the cross-transport BridgeManager, and the Orchestrator entry point.
See INTERFACE_DESIGN.md §3, §6, §7.5, §10.2 for the canonical design.
§Two-layer surface
- Pure-SIP consumers (carriers, SIP softphones, SIP-only B2BUAs) stay on
rvoip_sip::api::*andrvoip_sip::server::*— they don’t touch this crate. Seervoip-sipfor that surface. - Cross-transport consumers (Thelve, future CPaaS, anyone planning to
add WebRTC / QUIC adapters) build a
Orchestratorhere and register adapters against it. SIP is one such adapter today (rvoip_sip::SipAdapter);rvoip-webrtcandrvoip-quicregister against the same handle when they ship.
§Cross-transport entry point
use rvoip_core::{Config, Orchestrator, Transport};
let orchestrator = Orchestrator::new(Config::default());
orchestrator.register(my_adapter)?;
let mut events = orchestrator.subscribe_events();
// events.recv() yields normalized rvoip-core Events (Connection*, Session*,
// Conversation*) translated from each adapter's protocol-native AdapterEvents.Orchestrator::register dispatches every per-connection command
(Orchestrator::route_inbound_connection, Orchestrator::prepare_outbound_connection,
PreparedOutboundConnection::commit, Orchestrator::originate_connection,
Orchestrator::end_connection, Orchestrator::hold, Orchestrator::resume,
Orchestrator::transfer_connection, Orchestrator::send_dtmf,
Orchestrator::mute, Orchestrator::unmute,
Orchestrator::play_audio) through the adapter for the
connection’s Transport. Cross-transport bridging
(cross-codec frame-pump per INTERFACE_DESIGN.md §10.2) is fully
wired, including hot-swap on renegotiate_media and DTMF auto-
route across legs.
§Conversation / Session / Participant lifecycle
Beyond per-Connection dispatch, the Orchestrator owns live
Conversation/Session/Participant state. See
Orchestrator::open_conversation, Orchestrator::start_session,
Orchestrator::join_session, Orchestrator::leave_session,
Orchestrator::end_session, Orchestrator::close_conversation
and the cross-substrate messaging methods
Orchestrator::send_message_to_conversation +
Orchestrator::list_messages + Orchestrator::mark_message_read.
§vCon, recording, transcription, AI harness
With the vcon feature enabled, every Session gets a
DefaultVconBuilder auto-bound at start_session; on end_session the
snapshot is encoded, persisted via VconStore, and emitted as
Event::VconReady. Recording and transcription dispatch via
consumer-registered providers
(Orchestrator::register_recording_sink,
Orchestrator::register_asr_provider); the AI harness path
includes barge-in support (Event::BargeInDetected).
§Tenant scoping, capacity, observability
Config::TenantQuotas enforces
per-tenant maxes on concurrent sessions, recordings, and AI
attachments. Periodic emit cadences live in
Orchestrator::spawn_capacity_scheduler,
Orchestrator::spawn_media_quality_sampler, and
Orchestrator::spawn_idle_closer (Ephemeral Conversation
close-after-idle driver).
See examples/sip_only_orchestrator.rs for the working SIP-adapter
flow end-to-end, and GAP_PLAN.md
for the phased-roadmap status.
§Layering rule
Per INTERFACE_DESIGN.md §18: this crate never imports an adapter crate.
Adapters depend on rvoip-core, not the other way round. The only
external dep that’s transport-flavored is rvoip-media-core (a common
crate, not an adapter), used by bridge for the SIP-fast-path bridge
handle.
Re-exports§
pub use adapter::ConnectionAdapter;pub use bridge::BridgeManager;pub use bridge::DirectionalMediaBridgePlan;pub use commands::AttachmentRef;pub use commands::AudioSource;pub use commands::Command;pub use commands::InboundAction;pub use commands::ListenerSink;pub use commands::ListenerTarget;pub use commands::MuteDirection;pub use commands::RecordingSink;pub use commands::RecordingTarget;pub use config::Config;pub use conversation::Conversation;pub use conversation::ConversationPolicy;pub use conversation::ConversationState;pub use events::AnomalyKind;pub use events::ConnectionProgressKind;pub use events::Event;pub use events::SessionQualityReport;pub use events::UsageKind;pub use identity::Device;pub use identity::DtlsFingerprint;pub use identity::Identity;pub use identity::IdentityProvider;pub use inbound_admission::InboundAdmission;pub use inbound_admission::InboundAdmissionTermination;pub use inbound_admission::ProvisionalMediaRoute;pub use inbound_admission::StagedInboundDataChannel;pub use inbound_admission::StagedInboundDataPolicy;pub use inbound_admission::StagedInboundDataReceiver;pub use inbound_admission::StagedInboundDataSender;pub use inbound_admission::MAX_STAGED_INBOUND_DATA_CAPACITY;pub use inbound_admission::MAX_STAGED_INBOUND_DATA_LABELS;pub use media_graph::start_media_graph;pub use media_graph::MediaGraphActivityObservation;pub use media_graph::MediaGraphHandle;pub use media_graph::MediaGraphPolicy;pub use media_graph::DEFAULT_MEDIA_GRAPH_MAX_SINKS;pub use media_graph::MEDIA_GRAPH_ACTIVITY_OBSERVATION_INTERVAL;pub use message::ContentType;pub use message::Message;pub use message::MessageOrigin;pub use message::MessageRecipients;pub use operational_events::OperationalEndReason;pub use operational_events::OperationalEvent;pub use operational_events::OperationalEventKind;pub use operational_events::OperationalEventStreamHealth;pub use operational_events::OperationalEventStreamHealthSubscription;pub use operational_events::OperationalFailureReason;pub use operational_events::OperationalTransferOutcome;pub use operational_events::OperationalTransferTarget;pub use orchestrator::Orchestrator;pub use orchestrator::PreparedOutboundConnection;pub use participant::Participant;pub use participant::ParticipantKind;pub use participant::ParticipantRole;pub use session::Session;pub use session::SessionMedium;pub use session::SessionState;pub use store::ConversationFilter;pub use store::ConversationStore;pub use store::MemoryConversationStore;pub use store::MemoryMessageStore;pub use store::MemoryVconStore;pub use store::MessageFilter;pub use store::MessagePage;pub use store::MessageStore;pub use store::PageCursor;pub use store::VconStore;pub use vcon::DefaultVconBuilder;pub use vcon::VconAnalysis;pub use vcon::VconAnalysisKind;pub use vcon::VconAttachment;pub use vcon::VconBuilderHandle;pub use vcon::VconDialog;pub use vcon::VconDialogKind;pub use vcon::VconParty;pub use vcon::VconRef;pub use vcon::VconSnapshot;pub use virtual_publisher::ManagedVirtualPublisher;pub use virtual_publisher::VirtualPublisherDescriptor;pub use virtual_publisher::DEFAULT_VIRTUAL_PUBLISHER_QUEUE_CAPACITY;
Modules§
- adapter
- bridge
- Cross-transport bridge primitive.
- broadcast
- Broadcast contracts re-exported from the cycle-safe trait surface.
- capability
- V2.A — re-exports from
rvoip-core-traits::capability. - commands
- config
- connection
- V2.A — re-exports from
rvoip-core-traits::connection. - conversation
- error
- V2.A — re-exports from
rvoip-core-traits::error. - events
- harness
- V2.A — re-exports from
rvoip-core-traits::harness. - identity
- Identity surface — the trait + the rich structs that reference
rvoip-core’s
Resulttype live here; the pure data types (Jwk,IdentityKind,DeviceKind,IdentityAssurance,CredentialKind,Credential) moved torvoip-core-traitsin V2.A.1 and are re-exported below souse rvoip_core::identity::*call sites work unchanged. - ids
- V2.A — ID newtypes moved to
rvoip-core-traitsto break thervoip-core → rvoip-vcon → rvoip-auth-core → rvoip-corecycle. This module re-exports everything souse rvoip_core::ids::*call sites keep working unchanged. - inbound_
admission - Opt-in, fail-closed admission for inbound transport connections.
- media_
graph - Bounded, one-source-to-many real-time media routing.
- message
- operational_
events - Authoritative, bounded operational lifecycle events.
- orchestrator
- Cross-transport entry point.
- participant
- session
- signing
- P7 — RFC 9421 / JSON Canonical Form helpers + envelope replay cache.
- store
- stream
- V2.A — re-exports from
rvoip-core-traits::stream. - subscriptions
- Per-Session subscription routing table for N-Participant Sessions.
- vcon
- In-flight vCon builder, per INTERFACE_DESIGN §3.9 / §11.4.
- virtual_
publisher - MediaGraph-backed logical publishers for transport subscribers.
Structs§
- AiAttachment
Id - Attachment
Id - Authenticated
Principal - Transport-neutral result of successful authentication.
- Bridge
Handle - Handle representing an active bridge between two media sessions.
- Bridge
Id - Broadcast
Descriptor - Legacy publication descriptor retained for source compatibility.
- Broadcast
Drain Descriptor - Result snapshot for a drain operation.
- Broadcast
Drain Request - Request to stop admitting listeners and finish by a fixed deadline.
- Broadcast
Endpoint - Subscriber-facing endpoint and protocol resource.
- Broadcast
Health Descriptor - Point-in-time publisher health and bounded capacity data.
- Broadcast
Lifecycle Descriptor - Lifecycle snapshot suitable for an API or diagnostic response.
- Broadcast
Protocol Descriptor - Protocol compatibility tuple used by a publication.
- Broadcast
Relay Hop - One diagnosable hop from a publisher origin to its subscribers.
- Broadcast
Sanitized Event - One fixed-model sanitized event indexed by Unix wallclock milliseconds.
- Broadcast
Sanitized Event Capability - Bounded fixed-model event capability exposed by a publisher.
- Capability
Descriptor - Capability descriptor that round-trips through CONVERSATION_PROTOCOL.md §8’s JSON shape. Field order matches the spec for readability.
- Capability
Intersection - Codec
Info - Legacy flat-fields codec entry — used internally by SIP/RTP adapters
that need the parsed
clock_rate_hz/channelsnumbers directly. Bridges to/fromCodec(the spec wire shape) viaFrom/TryFrom. - Connection
- Connection
Handle - Connection
Id - Conversation
Id - Data
Message - A data-plane message that can be mapped to a WebRTC DataChannel, UCTP
message.send, SIP MESSAGE, or an application-owned metadata transport. - Device
Id - External
Connection Reference - A stable external identifier learned while activating an outbound route.
- Identity
Id - Inbound
Connection Context - Principal- and transport-bound context for one inbound connection.
- Inbound
Routing Hint - Opaque, redacted routing material captured before an inbound adapter normalizes its signaling event.
- Inbound
Signaling Metadata - Ordered, duplicate-preserving signaling metadata captured for an inbound
connection. Field values are redacted from
Debugoutput. - Jwk
- Opaque JWK placeholder. Real shape lives in
rvoip-identity. - Listener
Id - Media
Frame - Media
Receiver Reservation - Provisional ownership of a stream’s single-consumer inbound receiver.
- Media
Route Id - Media
Stream Handle - Cheap, cloneable reference a
crate::Connectionholds to its media flows. Wraps anArc<dyn MediaStream>so the trait object can live inDebugtypes likeConnectionwithout forcing every adapter to implement Debug. - Message
Id - Negotiated
Codecs - Originate
Context - Opaque adapter-owned options for one outbound originate operation.
- Originate
Request - Outbound
Activation - Adapter receipt produced only after outbound activation succeeds.
- Participant
Id - Playback
Handle - Handle returned by adapter playback paths that lets callers stop an in-flight playback.
- Playback
Id - Principal
Ownership Key - Stable authorization ownership boundary for a principal-owned resource.
- Quality
Snapshot - Recording
Id - Session
Id - Signature
Headers - Stream
Id - Tenant
Id - Transcription
Id - Transfer
Attempt Id
Enums§
- Adapter
Event - Adapter-native event surface.
rvoip-corenormalizes these into the orchestration event vocabulary; consumers wanting protocol-native access can subscribe directly to the adapter. - Adapter
Kind - Authentication
Method - Authentication mechanism that established an
AuthenticatedPrincipal. - Bearer
Auth Error - Bearer validation failure retained in the dependency-cycle-free trait
surface so
AuthenticatedPrincipal::require_scoperemains source compatible when the principal type is re-exported by auth-core. - Bridge
Error - Errors specific to bridge creation and teardown.
- Broadcast
Drain Reason - Operator intent behind a drain operation.
- Broadcast
Drain State - Progress of a drain operation.
- Broadcast
Health Issue - Bounded health reason codes. Resource identifiers intentionally do not appear here so these values are safe to aggregate in metrics.
- Broadcast
Health Status - Aggregate health state with a bounded metric-label vocabulary.
- Broadcast
Lifecycle State - Managed publisher lifecycle state.
- Broadcast
Protocol Family - Stable protocol family used for aggregate metrics and compatibility checks.
- Broadcast
Relay Role - Role of one address in a relay path.
- Broadcast
Resource - Transport-specific resource addressed by a broadcast endpoint.
- Broadcast
Sanitized Event Error - Broadcast
Sanitized Event Kind - Fixed, transport-neutral lifecycle events allowed on sanitized broadcasts.
- Broadcast
Substrate - Network substrate carrying the application broadcast protocol.
- Broadcast
Transport - Broadcast protocol family exposed by a publisher.
- Connection
State - Credential
- Credential
Kind - Data
Message Validation Error - Data
Reliability - Delivery contract requested by an application data message.
- Direction
- EndReason
- External
Connection Reference Error - Validation failure for an adapter-owned external connection reference.
- Identity
Assurance - IdentityAssurance gradient per CONVERSATION_PROTOCOL.md §5.6.
- Inbound
Context Error - Validation failure for adapter-supplied inbound connection context.
- Reject
Reason - Rvoip
Error - Stream
Kind - Transfer
Status - Transport-neutral asynchronous transfer status.
- Transfer
Target - Transport
Constants§
- MAX_
BROADCAST_ EVENT_ JSON_ INTEGER - Largest integer represented exactly by interoperable JSON number parsers.
- MAX_
CONTENT_ TYPE_ BYTES - MAX_
DATA_ LABEL_ BYTES - MAX_
DATA_ MESSAGE_ BYTES - MAX_
DATA_ MESSAGE_ ID_ BYTES - MAX_
EXTERNAL_ CONNECTION_ REFERENCES - Maximum number of adapter-owned external identifiers on one activation.
- MAX_
EXTERNAL_ REFERENCE_ KIND_ BYTES - Maximum UTF-8 size of an external identifier namespace.
- MAX_
EXTERNAL_ REFERENCE_ VALUE_ BYTES - Maximum UTF-8 size of one external identifier value.
- MAX_
INBOUND_ ROUTING_ HINT_ BYTES - Maximum UTF-8 size of an adapter-owned inbound routing hint.
Traits§
- Broadcast
Publisher - Object-safe lifecycle and media contract shared by broadcast publishers.
- Media
Stream - Transport-agnostic media flow. Channel-based per INTERFACE_DESIGN §3.6 to avoid per-frame async overhead at high frame rates.