pub struct RuntimeConfig {Show 15 fields
pub tick_period: Duration,
pub spdp_period: Duration,
pub spdp_multicast_group: Ipv4Addr,
pub multicast_interface: Ipv4Addr,
pub announce_secure_endpoints: bool,
pub wlp_period: Duration,
pub participant_lease_duration: Duration,
pub user_data: Vec<u8>,
pub observability: SharedSink,
pub recv_thread_priority: Option<i32>,
pub tick_thread_priority: Option<i32>,
pub recv_thread_cpus: Option<Vec<usize>>,
pub tick_thread_cpus: Option<Vec<usize>>,
pub data_representation_offer: Vec<i16>,
pub data_rep_match_mode: DataRepMatchMode,
}Expand description
Konfiguration fuer die Runtime. Exposed via DomainParticipant- Factory-Methoden.
Fields§
§tick_period: DurationTick-Periode des Event-Loops. Default 50 ms.
spdp_period: DurationSPDP-Announce-Periode. Default 5 s.
spdp_multicast_group: Ipv4AddrSPDP-Multicast-Gruppe (IPv4). Default 239.255.0.1 (Spec §9.6.1.4.1).
multicast_interface: Ipv4AddrInterface-Address fuer Multicast-Join. Default 0.0.0.0 (Kernel waehlt das Default-Interface).
announce_secure_endpoints: booltrue → SPDP-Beacon annonciert zusaetzlich die 12 Secure-
Discovery-Bits (16..27, DDS-Security 1.2 §7.4.7.1). Default
false — nur Standard-Bits werden announced. Wird vom DCPS-
Factory gesetzt, sobald eine PolicyEngine konfiguriert ist
. Diese Flagge ist auch ohne security-Feature
verfuegbar, damit Tests die Bit-Praesenz pruefen koennen, ohne
das ganze Crypto-Crate zu aktivieren.
wlp_period: DurationWLP-Tick-Periode (Writer-Liveliness-Protocol, RTPS 2.5 §8.4.13).
Duration::ZERO → Default participant_lease_duration / 3
(Spec-Empfehlung: drei Misses bevor der Reader den Writer als
not-alive markiert). Direkter Override ermoeglicht aggressive
Tests.
participant_lease_duration: DurationLease-Duration die im SPDP-Beacon als
PARTICIPANT_LEASE_DURATION annonciert wird (Spec-Default 100 s).
Wird auch als Basis fuer den AUTOMATIC-WLP-Tick genutzt
(wlp_period = participant_lease_duration / 3 wenn
wlp_period == Duration::ZERO).
user_data: Vec<u8>USER_DATA-Bytes des Participants (DDS 1.4 §2.2.3.1
UserDataQosPolicy). Werden im SPDP-Beacon als PID_USER_DATA
(DDSI-RTPS §9.6.3.2) annonciert und auf Empfaengerseite in
ParticipantBuiltinTopicData.user_data exponiert. Default leer.
observability: SharedSinkObservability-Sink. Default ist null_sink() — jeder Event-Emit
ist dann ein direkter Return ohne Allokation auf der Konsumenten-
Seite. Konsumenten injizieren z.B.
zerodds_foundation::observability::StderrJsonSink (JSON-Lines
fuer Vector/fluentd/Datadog) oder eine eigene OTLP-Bridge.
recv_thread_priority: Option<i32>Sprint D.5d Hebel C — RT-Pinning + Priority. Linux-only; auf macOS/Windows sind die Hooks no-op.
SCHED_FIFO-Prioritaet (1-99) fuer die drei Recv-Worker (SPDP-MC,
Metatraffic, User-Data). None = Default-Scheduler (CFS).
Some(80) ist Spec-Empfehlung fuer Echtzeit-Pfade. Erfordert
CAP_SYS_NICE oder RLIMIT_RTPRIO-erlaubten User.
tick_thread_priority: Option<i32>Wie Self::recv_thread_priority, aber fuer den Tick-Worker.
recv_thread_cpus: Option<Vec<usize>>CPU-Affinity-Maske fuer die Recv-Worker. None = keine
Affinity (Kernel scheduled frei). Liste von CPU-Indizes, z.B.
vec![2, 3] fuer Cores 2+3. Wird via sched_setaffinity
gesetzt; alle drei Recv-Threads teilen sich dieselbe Maske.
tick_thread_cpus: Option<Vec<usize>>Wie Self::recv_thread_cpus, aber fuer den Tick-Worker.
data_representation_offer: Vec<i16>D.5g — Default DataRepresentation-Liste die in SEDP-PublicationData und SEDP-SubscriptionData annonciert wird, wenn nicht per-Writer/ Reader (UserWriterConfig/UserReaderConfig) ueberschrieben.
Wichtig: Per Spec strict (XTypes 1.3 §7.6.3.1.2) ist das
erste Element der Writer’s “offered” und muss in Reader’s
“accepted”-Liste sein damit Match passiert. Default
[XCDR1, XCDR2] =Legacy-first → max Interop mit RTI Connext
Shapes Demo (XCDR1-only). Pure-XCDR2-Deployments koennen das
auf [XCDR2] oder [XCDR2, XCDR1] umstellen fuer Bandbreiten-
Effizienz und @appendable/@mutable-Support.
Empty (vec![]) wird per Spec als [XCDR1] interpretiert.
data_rep_match_mode: DataRepMatchModeD.5g — Default Match-Mode fuer DataRepresentation-Negotiation.
Strict (XTypes 1.3 §7.6.3.1.2 normativ): writer.first ∈
reader.list = match. Tolerant (Industry-Norm): any-overlap
= match, picks first-overlap als wire-format.
Default Tolerant weil Cyclone DDS und FastDDS so matchen —
maximiert Interop. Strict-Setting nur fuer formale Spec-
Compliance-Tests sinnvoll.
Trait Implementations§
Source§impl Clone for RuntimeConfig
impl Clone for RuntimeConfig
Source§fn clone(&self) -> RuntimeConfig
fn clone(&self) -> RuntimeConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more