15.2.2. Disabling multicast discoveryΒΆ

If all the peers are known and configured on the initial peer list beforehand, it is possible to disable the multicast meta traffic completely, as all DomainParticipants can communicate among them through unicast.

The complete description of the procedure to disable multicast discovery can be found at Disabling all Multicast Traffic. For convenience, however, this example shows how to disable all multicast traffic configuring one metatraffic unicast locator. Consideration should be given to the assignment of the ports in the metatrafficUnicastLocatorList, avoiding the assignment of ports that are not available or do not match the address-port listed in the intial peers list of the peer participant.


DomainParticipantQos qos;

// configure one metatraffic unicast locator on interface
// on participant ID `1` and domain `0`.
Locator_t meta_unicast_locator;
IPLocator::setIPv4(meta_unicast_locator, "");
meta_unicast_locator.port = 7412;


<?xml version="1.0" encoding="UTF-8" ?>
<profiles xmlns="http://www.eprosima.com/XMLSchemas/fastRTPS_Profiles">
    <participant profile_name="initial_peers_multicast_avoidance" is_default_profile="true" >
                <!-- Choosing a specific unicast address -->