pub struct DataWriterQos {
pub reliability: Reliability,
pub history: History,
pub resource_limits: ResourceLimits,
pub writer_data_lifecycle: WriterDataLifecycle,
pub durability: DurabilityKind,
pub durability_service: DurabilityService,
pub deadline: Option<Duration>,
pub liveliness: Liveliness,
pub user_data: Vec<u8>,
pub data_representation: Vec<i16>,
pub data_tags: Vec<(String, String)>,
}Expand description
The QoS of a crate::DataWriter that can be set for now.
Fields§
§reliability: ReliabilityRELIABILITY; RELIABLE by default.
history: HistoryHISTORY; KEEP_LAST(1) by default. The depth is for each instance.
resource_limits: ResourceLimitsRESOURCE_LIMITS.
writer_data_lifecycle: WriterDataLifecycleWRITER_DATA_LIFECYCLE.
durability: DurabilityKindDURABILITY; VOLATILE by default. A TRANSIENT_LOCAL writer keeps the samples its HISTORY and RESOURCE_LIMITS allow, also once they are acknowledged, and sends them to the TRANSIENT_LOCAL readers matched later; for now it keeps them also for instances it has unregistered.
A TRANSIENT writer does the same, and its samples outlive it:
deleting it leaves them with the participant, which keeps what
Self::durability_service allows and goes on sending them to
late readers until it is deleted itself. A PERSISTENT writer also
keeps them in a file, and a PERSISTENT writer of the same topic
and type created later, by this program or another, takes them up
again, also after a restart (see
crate::ParticipantConfig::persistence_directory).
durability_service: DurabilityServiceDURABILITY_SERVICE, for a TRANSIENT or PERSISTENT writer.
deadline: Option<Duration>DEADLINE period (DDS 1.4, 2.2.3.7); None, infinite, by default.
Each period in which a registered instance is not written counts
in crate::DataWriter::offered_deadline_missed_status; a
disposed instance is not counted until it is written again.
liveliness: LivelinessLIVELINESS (DDS 1.4, 2.2.3.11). The participant asserts AUTOMATIC
writers; a MANUAL_BY_PARTICIPANT or MANUAL_BY_TOPIC writer is
asserted by writing or by assert_liveliness, and is lost
(crate::DataWriter::liveliness_lost_status) when its lease
passes without that.
user_data: Vec<u8>USER_DATA (DDS 1.4, 2.2.3.1): octets the writer announces to the
other participants, for the application. Empty by default. ROS 2
reads typehash=...; here.
data_representation: Vec<i16>DATA_REPRESENTATION (DDS-XTypes 1.3, 7.6.3.1): the writer
serializes its samples in the first
(data_representation::XCDR or data_representation::XCDR2)
and offers it to readers. Empty, the default, is XCDR, which every
reader accepts; it is then not announced.
DATA_TAGS (DataTagQosPolicy, DDS Security 1.2, 7.2.5 and 9.7): (name, value) tags of every sample the writer writes, announced with it. With DDS Security, the permissions must allow publishing with them (10.4.1.5.3.4.1.5). Empty by default.