Working with pluggable transports.
More...
- To change the com.rti.dds.domain.DomainParticipantQos.transport_builtin Qos Policy:
DomainParticipantQos participant_qos = new DomainParticipantQos();
factory.get_default_participant_qos(participant_qos);
participant_qos.transport_builtin.mask = TransportBuiltinKind.SHMEM |
TransportBuiltinKind.UDPv4;
The behavior of the automatically registered builtin transports can be altered by changing their properties.
- Get the property of the desired builtin transport plugin, say UDPv4Transport
UDPv4Transport.Property_t property = new UDPv4Transport.Property_t();
TransportSupport.get_builtin_transport_property(participant, property);
- Change the property fields as desired. Note that the properties should be changed carefully, as inappropriate values may prevent communications. For example, the UDPv4Transport properties can be changed to support large messages (assuming the underlying operating system's UDPv4 stack supports the large message size). Note: if message_size_max is increased from the default for any of the built-in transports, then the DDS_ReceiverPoolQosPolicy.buffer_size on the DomainParticipant should also be changed.
property.message_size_max = 65535;
property.recv_socket_buffer_size = 65535;
property.send_socket_buffer_size = 65535;
- Set the property of the desired builtin transport plugin, say UDPv4Transport
TransportSupport.set_builtin_transport_property(participant, property);
- Enable the participant to turn on communications with other participants in the domain using the new properties for the automatically registered builtin transport plugins.