10.4. DataWriter profiles¶
The DataWriter profiles allow for configuring DataWriters from an XML file.
These profiles are defined within the <data_writer> XML tags.
10.4.1. DataWriter XML attributes¶
The <data_writer> element has two attributes defined: profile_name and is_default_profile.
Name |
Description |
Use |
|---|---|---|
|
Sets the name under which the |
Mandatory |
|
Sets the |
Optional |
10.4.2. DataWriter configuration¶
The DataWriter configuration is performed through the XML elements listed in the following table.
Name |
Description |
Values |
Default |
|---|---|---|---|
|
TopicType configuration of the DataWriter. |
||
|
DataWriter QoS configuration. |
||
|
It configures some time related parameters of the DataWriter. |
||
|
List of input unicast locators. It expects a LocatorListType. |
|
|
|
List of input multicast locators. It expects a LocatorListType. |
|
|
|
List of External Locators to announce for the communication with this DataWriter. |
||
|
Whether to ignore locators received on announcements from other entities when they don’t match with any of the locators announced by this DataWriter. |
|
false |
|
Memory allocation kind for DataWriter’s history. See HistoryQosPolicyKind. |
|
|
|
Additional configuration properties. |
||
|
Used for |
|
-1 |
|
Sets the |
|
-1 |
|
Sets the limits of the collection of matched DataReaders. See ParticipantResourceLimitsQos. |
Example
<?xml version="1.0" encoding="UTF-8" ?>
<dds xmlns="http://www.eprosima.com">
<profiles>
<data_writer profile_name="datawriter_profile_name">
<topic>
<historyQos>
<kind>KEEP_LAST</kind>
</historyQos>
</topic>
<qos>
<!-- QOS -->
</qos>
<times> <!-- writerTimesType -->
<initial_heartbeat_delay>
<nanosec>12</nanosec>
</initial_heartbeat_delay>
<heartbeat_period>
<sec>3</sec>
</heartbeat_period>
<nack_response_delay>
<nanosec>5</nanosec>
</nack_response_delay>
<nack_supression_duration>
<sec>0</sec>
</nack_supression_duration>
</times>
<unicastLocatorList>
<!-- LOCATOR_LIST -->
<locator>
<udpv4>
<address>192.168.0.1</address>
</udpv4>
</locator>
</unicastLocatorList>
<multicastLocatorList>
<!-- LOCATOR_LIST -->
<locator>
<udpv4>
<address>192.168.0.1</address>
</udpv4>
</locator>
</multicastLocatorList>
<external_unicast_locators>
<!-- EXTERNAL_LOCATOR_LIST -->
<udpv4 externality="1" cost="0" mask="24">
<address>100.100.100.10</address>
<port>12345</port>
</udpv4>
</external_unicast_locators>
<ignore_non_matching_locators>true</ignore_non_matching_locators>
<historyMemoryPolicy>DYNAMIC</historyMemoryPolicy>
<!-- PROPERTIES_POLICY -->
<propertiesPolicy>
<properties>
<property>
<name>PropertyName</name>
<value>PropertyValue</value>
</property>
</properties>
</propertiesPolicy>
<userDefinedID>55</userDefinedID>
<entityID>66</entityID>
<matchedSubscribersAllocation>
<initial>0</initial>
<maximum>0</maximum>
<increment>1</increment>
</matchedSubscribersAllocation>
<!-- reader_filters_allocation cannot be configured using XML (yet) -->
</data_writer>
</profiles>
</dds>
Note
LOCATOR_LISTmeans a LocatorListType is expected.EXTERNAL_LOCATOR_LISTmeans a ExternalLocatorListType is expected.PROPERTIES_POLICYmeans that the label is a PropertiesPolicyType block.For
QOSdetails, please refer to QoS.TOPIC_TYPEis detailed in section TopicType.
10.4.2.1. WriterTimes¶
These parameters are included within RTPSReliableWriterQos in the WriterTimes structure.
Name |
Description |
Values |
Default |
|---|---|---|---|
|
Initial heartbeat delay. |
12 ms |
|
|
Periodic heartbeat period. |
3 s |
|
|
Delay to apply to the response of an ACKNACK message. |
5 ms |
|
|
This time allows the DataWriter to ignore NACK messages for a given period of time right after the data has been sent. |
0 ms |