#include <managed_infrastructure.h>
Static Public Member Functions | |
static System::String^ | get_resourcelimits_qos_policy_name () |
Stringified human-readable name for DDS::ResourceLimitsQosPolicy. | |
Public Attributes | |
System::Int32 | max_samples |
Represents the maximum samples the middleware can store for any one DDS::DataWriter (or DDS::DataReader). | |
System::Int32 | max_instances |
Represents the maximum number of instances a DDS::DataWriter (or DDS::DataReader) can manage. | |
System::Int32 | max_samples_per_instance |
Represents the maximum number of samples of any one instance a DDS::DataWriter (or DDS::DataReader) can manage. | |
System::Int32 | initial_samples |
<<eXtension>> Represents the initial samples the middleware will store for any one DDS::DataWriter (or DDS::DataReader). | |
System::Int32 | initial_instances |
<<eXtension>> Represents the initial number of instances a DDS::DataWriter (or DDS::DataReader) will manage. | |
System::Int32 | instance_hash_buckets |
<<eXtension>> Number of hash buckets for instances. | |
Properties | |
static System::Int32 | LENGTH_UNLIMITED [get] |
A special value indicating an unlimited quantity. |
For the reliability protocol (and DDS::DurabilityQosPolicy), this QoS policy determines the actual maximum queue size when the DDS::HistoryQosPolicy is set to DDS::HistoryQosPolicyKind::KEEP_ALL_HISTORY_QOS.
In general, this QoS policy is used to limit the amount of system memory that RTI Data Distribution Service can allocate. For embedded real-time systems and safety-critical systems, pre-determination of maximum memory usage is often required. In addition, dynamic memory allocation could introduce non-deterministic latencies in time-critical paths.
This QoS policy can be set such that an entity does not dynamically allocate any more memory after its initialization phase.
If DDS::DataWriter objects are communicating samples faster than they are ultimately taken by the DDS::DataReader objects, the middleware will eventually hit against some of the QoS-imposed resource limits. Note that this may occur when just a single DDS::DataReader cannot keep up with its corresponding DDS::DataWriter. The behavior in this case depends on the setting for the RELIABILITY. If reliability is DDS::ReliabilityQosPolicyKind::BEST_EFFORT_RELIABILITY_QOS, then RTI Data Distribution Service is allowed to drop samples. If the reliability is DDS::ReliabilityQosPolicyKind::RELIABLE_RELIABILITY_QOS, RTI Data Distribution Service will block the DDS::DataWriter or discard the sample at the DDS::DataReader in order not to lose existing samples.
The constant DDS::LENGTH_UNLIMITED may be used to indicate the absence of a particular limit. For example setting DDS::ResourceLimitsQosPolicy::max_samples_per_instance to DDS::LENGTH_UNLIMITED will cause RTI Data Distribution Service not to enforce this particular limit.
If these resource limits are not set sufficiently, under certain circumstances the DDS::DataWriter may block on a write() call even though the DDS::HistoryQosPolicy is DDS::HistoryQosPolicyKind::KEEP_LAST_HISTORY_QOS. To guarantee the writer does not block for DDS::HistoryQosPolicyKind::KEEP_LAST_HISTORY_QOS, make sure the resource limits are set such that:
max_samples >= max_instances * max_samples_per_instance
The setting of RESOURCE_LIMITS max_samples_per_instance
must be consistent with the HISTORY depth
. For these two QoS to be consistent, it must be true that depth <= max_samples_per_instance.
System::Int32 DDS::ResourceLimitsQosPolicy::max_samples |
Represents the maximum samples the middleware can store for any one DDS::DataWriter (or DDS::DataReader).
Specifies the maximum number of data samples a DDS::DataWriter (or DDS::DataReader) can manage across all the instances associated with it.
For unkeyed types, this value has to be equal to max_samples_per_instance if max_samples_per_instance is not equal to DDS::LENGTH_UNLIMITED.
When batching is enabled, the maximum number of data samples a DDS::DataWriter can manage will also be limited by DDS::DataWriterResourceLimitsQosPolicy::max_batches.
[default] DDS::LENGTH_UNLIMITED
[range] [1, 100 million] or DDS::LENGTH_UNLIMITED, >= initial_samples, >= max_samples_per_instance, >= DDS::DataReaderResourceLimitsQosPolicy::max_samples_per_remote_writer or >= DDS::RtpsReliableWriterProtocol_t::heartbeats_per_max_samples
For DDS::DataWriterQos max_samples >= DDS::DataWriterProtocolQosPolicy::rtps_reliable_writer.heartbeats_per_max_samples if batching is disabled.
System::Int32 DDS::ResourceLimitsQosPolicy::max_instances |
Represents the maximum number of instances a DDS::DataWriter (or DDS::DataReader) can manage.
[default] DDS::LENGTH_UNLIMITED
[range] [1, 1 million] or DDS::LENGTH_UNLIMITED, >= initial_instances
System::Int32 DDS::ResourceLimitsQosPolicy::max_samples_per_instance |
Represents the maximum number of samples of any one instance a DDS::DataWriter (or DDS::DataReader) can manage.
For unkeyed types, this value has to be equal to max_samples or DDS::LENGTH_UNLIMITED.
[default] DDS::LENGTH_UNLIMITED
[range] [1, 100 million] or DDS::LENGTH_UNLIMITED, <= max_samples or DDS::LENGTH_UNLIMITED, >= DDS::HistoryQosPolicy::depth
System::Int32 DDS::ResourceLimitsQosPolicy::initial_samples |
<<eXtension>> Represents the initial samples the middleware will store for any one DDS::DataWriter (or DDS::DataReader).
Specifies the initial number of data samples a DDS::DataWriter (or DDS::DataReader) will manage across all the instances associated with it.
[default] 32
[range] [1,100 million], <= max_samples
System::Int32 DDS::ResourceLimitsQosPolicy::initial_instances |
<<eXtension>> Represents the initial number of instances a DDS::DataWriter (or DDS::DataReader) will manage.
[default] 32
[range] [1,1 million], <= max_instances
System::Int32 DDS::ResourceLimitsQosPolicy::instance_hash_buckets |
<<eXtension>> Number of hash buckets for instances.
The instance hash table facilitates instance lookup. A higher number of buckets decreases instance lookup time but increases the memory usage.
[default] 1 [range] [1,1 million]