RTI Connext .NET API (legacy)
Version 6.1.1
|
This QoS policy specifies whether or not RTI Connext will store and deliver previously published data samples to new DDS::DataReader entities that join the network later. More...
#include <managed_infrastructure.h>
Static Public Member Functions | |
static System::String ^ | get_durability_qos_policy_name () |
Stringified human-readable name for DDS::DurabilityQosPolicy. More... | |
Public Attributes | |
DurabilityQosPolicyKind | kind |
The kind of durability. More... | |
System::Int32 | writer_depth |
<<extension>> Indicates the number of samples per instance that a durable DDS::DataWriter will send to a late-joining DDS::DataReader. More... | |
Static Public Attributes | |
static const System::Int32 | AUTO_WRITER_DEPTH |
A special value used as the default value for DDS::DurabilityQosPolicy::writer_depth. More... | |
Properties | |
System::Boolean | direct_communication [get, set] |
<<extension>> Indicates whether or not a TRANSIENT or PERSISTENT DDS::DataReader should receive samples directly from a TRANSIENT or PERSISTENT DDS::DataWriter More... | |
This QoS policy specifies whether or not RTI Connext will store and deliver previously published data samples to new DDS::DataReader entities that join the network later.
It is possible for a DDS::DataWriter to start publishing data before all (or any) DDS::DataReader entities have joined the network.
Moreover, a DDS::DataReader that joins the network after some data has been written could potentially be interested in accessing the most current values of the data, as well as potentially some history.
This policy makes it possible for a late-joining DDS::DataReader to obtain previously published samples.
By helping to ensure that DataReaders get all data that was sent by DataWriters, regardless of when it was sent, using this QoS policy can increase system tolerance to failure conditions.
Note that although related, this does not strictly control what data RTI Connext will maintain internally. That is, RTI Connext may choose to maintain some data for its own purposes (e.g., flow control) and yet not make it available to late-joining readers if the DURABILITY policy is set to VOLATILE_DURABILITY_QOS.
For the purpose of implementing the DURABILITY QoS kind TRANSIENT or PERSISTENT, RTI Connext behaves as if for each Topic that has DDS::DurabilityQosPolicy::kind of TRANSIENT_DURABILITY_QOS or PERSISTENT_DURABILITY_QOS there is a corresponding "built-in" DDS::DataReader and DDS::DataWriter configured with the same DURABILITY kind. In other words, it is as if somewhere in the system, independent of the original DDS::DataWriter, there is a built-in durable DDS::DataReader subscribing to that Topic and a built-in durable DataWriter re-publishing it as needed for the new subscribers that join the system. This functionality is provided by the RTI Persistence Service.
The Persistence Service can configure itself based on the QoS of your application's DDS::DataWriter and DDS::DataReader entities. For each transient or persistent DDS::Topic, the built-in fictitious Persistence Service DDS::DataReader and DDS::DataWriter have their QoS configured from the QoS of your application's DDS::DataWriter and DDS::DataReader entities that communicate on that DDS::Topic.
For a given DDS::Topic, the usual request/offered semantics apply to the matching between any DDS::DataWriter in the domain that writes the DDS::Topic and the built-in transient/persistent DDS::DataReader for that DDS::Topic; similarly for the built-in transient/persistent DDS::DataWriter for a DDS::Topic and any DDS::DataReader for the DDS::Topic. As a consequence, a DDS::DataWriter that has an incompatible QoS will not send its data to the RTI Persistence Service, and a DDS::DataReader that has an incompatible QoS will not get data from it.
Incompatibilities between local DDS::DataReader and DDS::DataWriter entities and the corresponding fictitious built-in transient/persistent entities cause the REQUESTED_INCOMPATIBLE_QOS_STATUS and OFFERED_INCOMPATIBLE_QOS_STATUS to change and the corresponding Listener invocations and/or signaling of DDS::Condition objects as they would with your application's own entities.
The value of DDS::DurabilityServiceQosPolicy::service_cleanup_delay controls when RTI Persistence Service is able to remove all information regarding a data instances.
Information on a data instance is maintained until the following conditions are met:
1. The instance has been explicitly disposed (instance_state = NOT_ALIVE_DISPOSED),
and
2. All samples for the disposed instance have been acknowledged, including the dispose sample itself,
and
3. A time interval longer that DDS::DurabilityServiceQosPolicy::service_cleanup_delay has elapsed since the moment RTI Connext detected that the previous two conditions were met. (Note: Only values of zero or DDS::Duration_t::DURATION_INFINITE are currently supported for the service_cleanup_delay)
The utility of DDS::DurabilityServiceQosPolicy::service_cleanup_delay is apparent in the situation where an application disposes an instance and it crashes before it has a chance to complete additional tasks related to the disposition. Upon restart, the application may ask for initial data to regain its state and the delay introduced by the service_cleanup_delay will allow the restarted application to receive the information on the disposed instance and complete the interrupted tasks.
The value offered is considered compatible with the value requested if and only if the inequality offered kind >= requested kind evaluates to 'TRUE'. For the purposes of this inequality, the values of DURABILITY kind are considered ordered such that VOLATILE_DURABILITY_QOS < TRANSIENT_LOCAL_DURABILITY_QOS < TRANSIENT_DURABILITY_QOS < PERSISTENT_DURABILITY_QOS.
DurabilityQosPolicyKind DDS::DurabilityQosPolicy::kind |
The kind of durability.
[default] VOLATILE_DURABILITY_QOS
Referenced by RTI.Connext.Queuing.QueueConsumer< TRep >::QueueConsumer().
System::Int32 DDS::DurabilityQosPolicy::writer_depth |
<<extension>> Indicates the number of samples per instance that a durable DDS::DataWriter will send to a late-joining DDS::DataReader.
The default value, DDS::DurabilityQosPolicy::AUTO_WRITER_DEPTH, makes this parameter equal to the following:
The writer_depth
must be <= DDS::HistoryQosPolicy::depth.
writer_depth
applies only to non-volatile DataWriters (those for which the kind is TRANSIENT_LOCAL, TRANSIENT, or PERSISTENT).
When DDS::BatchQosPolicy::enable is set to true, writer_depth
acts as a minimum number of samples per instance that will be sent to late joiners, as opposed to the maximum. As long as a batch contains a single sample that falls within the writer_depth
for the instance to which it belongs, then the entire batch will be sent. This means that batches sent to late-joining DataReaders may contain more samples per instance than is specified by the writer_depth
QoS setting.
When a DataWriter responds to a TopicQuery, the samples that are evaluated against the TopicQuery filter are only those samples that fall within the writer_depth
, not the DDS::HistoryQosPolicy::depth.
Setting writer_depth
on the DataReader side will be ignored.
|
getset |
<<extension>> Indicates whether or not a TRANSIENT or PERSISTENT DDS::DataReader should receive samples directly from a TRANSIENT or PERSISTENT DDS::DataWriter
When direct_communication is set to true, a TRANSIENT or PERSISTENT DDS::DataReader will receive samples from both the original DDS::DataWriter configured with TRANSIENT or PERSISTENT durability and the DDS::DataWriter created by the persistence service. This peer-to-peer communication pattern provides low latency between end-points.
If the same sample is received from the original DDS::DataWriter and the persistence service, the middleware will discard the duplicate.
When direct_communication is set to false, a TRANSIENT or PERSISTENT DDS::DataReader will only receive samples from the DDS::DataWriter created by the persistence service. This brokered communication pattern provides a way to guarantee eventual consistency.
[default] true