#[non_exhaustive]pub struct PhantomConfig {
pub keepalive_interval: Duration,
pub session_timeout: Duration,
pub max_packet_size: u32,
pub send_buffer_size: u32,
pub recv_buffer_size: u32,
pub session_cache_capacity: u32,
pub session_ticket_lifetime: Duration,
pub auto_fallback: bool,
pub fallback_loss_threshold: u8,
pub fallback_failure_threshold: u32,
pub connect_timeout: Duration,
pub upgrade_delay: Duration,
}std only.Expand description
Tunable parameters for a Phantom session / listener, exported across the UniFFI boundary as a plain record.
NOTE: this is a stable FFI config surface, but the core does not yet read
most of these fields on the live data path — PhantomConfig is currently
re-exported and FFI-exported only. The auto_fallback / fallback_* /
upgrade_delay fields in particular describe the legacy multi-leg
fallback model; transport-leg fallback / aggregation was deliberately
dropped in favour of single-path connection migration, so those knobs are
presently inert. Treat the presets below as documented intent, not as
behaviour the core enforces today.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.keepalive_interval: DurationInterval between keep-alive pings
session_timeout: DurationSession inactivity timeout
max_packet_size: u32Maximum packet size (MTU)
send_buffer_size: u32Send buffer size in packets
recv_buffer_size: u32Receive buffer size in packets
session_cache_capacity: u32Maximum tickets in session cache
session_ticket_lifetime: DurationLifetime of a session ticket
auto_fallback: boolEnable automatic transport fallback (legacy multi-leg model; inert — see the struct-level note).
fallback_loss_threshold: u8Packet loss percentage to trigger fallback (legacy multi-leg model; inert).
fallback_failure_threshold: u32Connection failures to trigger fallback (legacy multi-leg model; inert).
connect_timeout: DurationTimeout for connection attempts
upgrade_delay: DurationDelay before attempting to upgrade transport (legacy multi-leg model; inert).
Implementations§
Trait Implementations§
Source§impl Clone for PhantomConfig
impl Clone for PhantomConfig
Source§fn clone(&self) -> PhantomConfig
fn clone(&self) -> PhantomConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more