RTI Connext Traditional C++ API
Version 7.0.0
|
Transport plug-in using UDP/IPv4 (NDDS_TRANSPORT_CLASSID_UDPv4) More...
Classes | |
struct | NDDS_Transport_UDPv4_Property_t |
Configurable IPv4/UDP Transport-Plugin properties. More... | |
Functions | |
NDDS_Transport_Plugin * | NDDS_Transport_UDPv4_new (const struct NDDS_Transport_UDPv4_Property_t *property_in) |
Create an instance of a UDPv4 Transport Plugin. More... | |
NDDS_Transport_Plugin * | NDDS_Transport_UDPv4_create (NDDS_Transport_Address_t *default_network_address_out, const struct DDS_PropertyQosPolicy *property_in) |
Create an instance of a UDPv4 Transport Plugin, using the PropertyQosPolicy. More... | |
NDDS_Transport_Plugin * | NDDS_Transport_UDPv4_create_from_properties_with_prefix (NDDS_Transport_Address_t *default_network_address_out, const struct DDS_PropertyQosPolicy *property_in, const char *propertyPrefix) |
Create an instance of a UDPv4 Transport Plugin, using the PropertyQosPolicy. Same as NDDS_Transport_UDPv4_create but with a prefix for the input properties. It is used to create pluggable transports that use an underlying UDP transport. More... | |
Transport plug-in using UDP/IPv4 (NDDS_TRANSPORT_CLASSID_UDPv4)
This transport plugin uses UDPv4 sockets to send and receive messages. It supports both unicast and multicast communications in a single instance of the plugin. By default, this plugin will use all interfaces that it finds enabled and "UP" at instantiation time to send and receive messages.
You can configure an instance of this plugin to only use unicast or only use multicast, see NDDS_Transport_UDPv4_Property_t::unicast_enabled and NDDS_Transport_UDPv4_Property_t::multicast_enabled.
In addition, you can configure an instance of this plugin to selectively use the network interfaces of a node (and restrict a plugin from sending multicast messages on specific interfaces) by specifying the NDDS_Transport_Property_t::max_interface_count and the "white" and "black" lists in the base property's fields (NDDS_Transport_Property_t::allow_interfaces_list, NDDS_Transport_Property_t::deny_interfaces_list, NDDS_Transport_Property_t::allow_multicast_interfaces_list, NDDS_Transport_Property_t::deny_multicast_interfaces_list).
RTI Connext can implicitly create this plugin and register with the DDSDomainParticipant if this transport is specified in DDS_TransportBuiltinQosPolicy.
To specify the properties of the builtin UDPv4 transport that is implicitly registered, you can either:
Note that all properties should be set before the transport is implicitly created and registered by RTI Connext. Any properties set after the builtin transport is registered will be ignored. See Built-in Transport Plugins for details on when a builtin transport is registered. To explicitly create an instance of this plugin, NDDS_Transport_UDPv4_new() should be called. The instance should be registered with RTI Connext, see NDDSTransportSupport::register_transport. In some configurations one may have to disable the builtin UDPv4 transport plugin instance (DDS_TransportBuiltinQosPolicy, DDS_TRANSPORTBUILTIN_UDPv4), to avoid port conflicts with the newly created plugin instance.
The following table lists the predefined property names that can be set in the DDS_DomainParticipantQos::property to configure the builtin UDPv4 transport plugin.
Property Name | Description |
---|---|
dds.transport.UDPv4.builtin.parent.classid | See NDDS_Transport_Property_t::classid Should be set to "NDDS_TRANSPORT_CLASSID_UDPv4" |
dds.transport.UDPv4.builtin.parent.address_bit_count | See NDDS_Transport_Property_t::address_bit_count |
dds.transport.UDPv4.builtin.parent.properties_bitmap | See NDDS_Transport_Property_t::properties_bitmap |
dds.transport.UDPv4.builtin.parent.gather_send_buffer_count_max | See NDDS_Transport_Property_t::gather_send_buffer_count_max |
dds.transport.UDPv4.builtin.parent.message_size_max | See NDDS_Transport_Property_t::message_size_max |
dds.transport.UDPv4.builtin.parent.allow_interfaces | See NDDS_Transport_Property_t::allow_interfaces_list and NDDS_Transport_Property_t::allow_interfaces_list_length. Interfaces should be specified as comma-separated strings, with each comma delimiting an interface. For example, 127.0.0.1,eth0 |
dds.transport.UDPv4.builtin.parent.deny_interfaces | See NDDS_Transport_Property_t::deny_interfaces_list and NDDS_Transport_Property_t::deny_interfaces_list_length. Interfaces should be specified as comma-separated strings, with each comma delimiting an interface. For example: 127.0.0.1,eth0 |
dds.transport.UDPv4.builtin.parent.allow_multicast_interfaces | See NDDS_Transport_Property_t::allow_multicast_interfaces_list and NDDS_Transport_Property_t::allow_multicast_interfaces_list_length. Interfaces should be specified as comma-separated strings, with each comma delimiting an interface. For example: 127.0.0.1,eth0 |
dds.transport.UDPv4.builtin.parent.deny_multicast_interfaces | See NDDS_Transport_Property_t::deny_multicast_interfaces_list and NDDS_Transport_Property_t::deny_multicast_interfaces_list_length. Interfaces should be specified as comma-separated strings, with each comma delimiting an interface. For example: 127.0.0.1,eth0 |
dds.transport.UDPv4.builtin.parent.max_interface_count | See NDDS_Transport_Property_t::max_interface_count |
dds.transport.UDPv4.builtin.parent.thread_name_prefix | See NDDS_Transport_Property_t::thread_name_prefix |
dds.transport.UDPv4.builtin.send_socket_buffer_size | See NDDS_Transport_UDPv4_Property_t::send_socket_buffer_size |
dds.transport.UDPv4.builtin.recv_socket_buffer_size | See NDDS_Transport_UDPv4_Property_t::recv_socket_buffer_size |
dds.transport.UDPv4.builtin.unicast_enabled | See NDDS_Transport_UDPv4_Property_t::unicast_enabled |
dds.transport.UDPv4.builtin.multicast_enabled | See NDDS_Transport_UDPv4_Property_t::multicast_enabled |
dds.transport.UDPv4.builtin.multicast_ttl | See NDDS_Transport_UDPv4_Property_t::multicast_ttl |
dds.transport.UDPv4.builtin.multicast_loopback_disabled | See NDDS_Transport_UDPv4_Property_t::multicast_loopback_disabled |
dds.transport.UDPv4.builtin.ignore_loopback_interface | See NDDS_Transport_UDPv4_Property_t::ignore_loopback_interface |
dds.transport.UDPv4.builtin.ignore_nonrunning_interfaces | See NDDS_Transport_UDPv4_Property_t::ignore_nonrunning_interfaces |
dds.transport.UDPv4.builtin.ignore_nonup_interfaces | [DEPRECATED] See NDDS_Transport_UDPv4_Property_t::ignore_nonup_interfaces |
dds.transport.UDPv4.builtin.no_zero_copy | [DEPRECATED] See NDDS_Transport_UDPv4_Property_t::no_zero_copy |
dds.transport.UDPv4.builtin.send_blocking | See NDDS_Transport_UDPv4_Property_t::send_blocking |
dds.transport.UDPv4.builtin.transport_priority_mask | See NDDS_Transport_UDPv4_Property_t::transport_priority_mask |
dds.transport.UDPv4.builtin.transport_priority_mapping_low | See NDDS_Transport_UDPv4_Property_t::transport_priority_mapping_low |
dds.transport.UDPv4.builtin.transport_priority_mapping_high | See NDDS_Transport_UDPv4_Property_t::transport_priority_mapping_high |
dds.transport.UDPv4.builtin.send_ping | See NDDS_Transport_UDPv4_Property_t::send_ping |
dds.transport.UDPv4.builtin.force_interface_poll_detection | See NDDS_Transport_UDPv4_Property_t::force_interface_poll_detection |
dds.transport.UDPv4.builtin.interface_poll_period | See NDDS_Transport_UDPv4_Property_t::interface_poll_period |
dds.transport.UDPv4.builtin.reuse_multicast_receive_resource | See NDDS_Transport_UDPv4_Property_t::reuse_multicast_receive_resource |
dds.transport.UDPv4.builtin.protocol_overhead_max | See NDDS_Transport_UDPv4_Property_t::protocol_overhead_max |
dds.transport.UDPv4.builtin.disable_interface_tracking | See NDDS_Transport_UDPv4_Property_t::disable_interface_tracking |
dds.transport.UDPv4.builtin.public_address | See NDDS_Transport_UDPv4_Property_t::public_address |
dds.transport.UDPv4.builtin.join_multicast_group_timeout | See NDDS_Transport_UDPv4_Property_t::join_multicast_group_timeout |
#define NDDS_TRANSPORT_UDPV4_ADDRESS_BIT_COUNT (32) |
Default value of NDDS_Transport_Property_t::address_bit_count.
#define NDDS_TRANSPORT_UDPV4_WAN_ADDRESS_BIT_COUNT (128) |
Default value of NDDS_Transport_Property_t::address_bit_count for UDPv4 asymmetric transport.
#define NDDS_TRANSPORT_UDPV4_PROPERTIES_BITMAP_DEFAULT NDDS_TRANSPORT_UDP_PROPERTIES_BITMAP_DEFAULT |
Default value of NDDS_Transport_Property_t::properties_bitmap.
#define NDDS_TRANSPORT_UDPV4_GATHER_SEND_BUFFER_COUNT_MAX_DEFAULT NDDS_TRANSPORT_UDP_GATHER_SEND_BUFFER_COUNT_MAX_DEFAULT |
Default value of NDDS_Transport_Property_t::gather_send_buffer_count_max.
This is also the maximum value that can be used when instantiating the UDP transport.
16 is sufficient for RTI Connext, but more may improve discovery and reliable performance. Porting note: find out what the maximum gather buffer count is on your OS!
#define NDDS_TRANSPORT_UDPV4_SOCKET_BUFFER_SIZE_OS_DEFAULT NDDS_TRANSPORT_UDP_SOCKET_BUFFER_SIZE_OS_DEFAULT |
Used to specify that os default be used to specify socket buffer size.
#define NDDS_TRANSPORT_UDPV4_SEND_SOCKET_BUFFER_SIZE_DEFAULT NDDS_TRANSPORT_UDP_SEND_SOCKET_BUFFER_SIZE_DEFAULT |
#define NDDS_TRANSPORT_UDPV4_RECV_SOCKET_BUFFER_SIZE_DEFAULT NDDS_TRANSPORT_UDP_RECV_SOCKET_BUFFER_SIZE_DEFAULT |
#define NDDS_TRANSPORT_UDPV4_PAYLOAD_SIZE_MAX (65507) |
Maximum value of NDDS_Transport_Property_t::message_size_max.
#define NDDS_TRANSPORT_UDPV4_MESSAGE_SIZE_MAX_DEFAULT NDDS_TRANSPORT_UDPV4_PAYLOAD_SIZE_MAX |
Maximum value of NDDS_Transport_Property_t::message_size_max.
#define NDDS_TRANSPORT_UDPV4_MULTICAST_TTL_DEFAULT NDDS_TRANSPORT_UDP_MULTICAST_TTL_DEFAULT |
Default value of NDDS_Transport_UDPv4_Property_t::multicast_ttl.
#define NDDS_TRANSPORT_UDPV4_BLOCKING_NEVER |
Value for NDDS_Transport_UDPv4_Property_t::send_blocking to specify non-blocking sockets.
#define NDDS_TRANSPORT_UDPV4_BLOCKING_ALWAYS |
[default] Value for NDDS_Transport_UDPv4_Property_t::send_blocking to specify blocking sockets.
#define NDDS_TRANSPORT_UDPV4_BLOCKING_DEFAULT NDDS_TRANSPORT_UDP_BLOCKING_DEFAULT |
Default value for NDDS_Transport_UDPv4_Property_t::send_blocking to specify blocking sockets.
#define NDDS_TRANSPORT_UDPV4_PROPERTY_DEFAULT |
Use this to initialize a NDDS_Transport_UDPv4_Property_t structure.
#define NDDS_Transport_UDPv4_string_to_address_cEA NDDS_Transport_UDP_string_to_address_cEA |
Realization of NDDS_Transport_String_To_Address_Fcn_cEA for IP transports.
Converts a host name string to a IPv4 address.
self | NOT USED. May be NULL. |
address_out | <<out>> The corresponding numerical value in IPv4 format. |
address_in | <<in>> The name of the IPv4 address. It can be a dot notation name or a host name. If NULL, then the IP address of the localhost will be returned. |
NDDS_Transport_Plugin* NDDS_Transport_UDPv4_new | ( | const struct NDDS_Transport_UDPv4_Property_t * | property_in | ) |
Create an instance of a UDPv4 Transport Plugin.
An application may create and register multiple instances of this Transport Plugin with RTI Connext. Multiple instances of the plugin may be useful for partitioning the network interfaces across multiple RTI Connext domains. However, note that the underlying transport, the operating system's IP layer, is still a "singleton." For example, if a unicast transport has already bound to a port, and another unicast transport tries to bind to the same port, the second attempt will fail.
The transport plugin honors the interface/multicast "white" and "black" lists specified in the NDDS_Transport_UDP_Property_t::parent:
The format of a string in these lists is assumed to be in standard IPv4 dot notation, possibly containing wildcards. For example:
property_in | <<in>> Desired behavior of this transport. May be NULL for default property. |
NDDS_Transport_Plugin* NDDS_Transport_UDPv4_create | ( | NDDS_Transport_Address_t * | default_network_address_out, |
const struct DDS_PropertyQosPolicy * | property_in | ||
) |
Create an instance of a UDPv4 Transport Plugin, using the PropertyQosPolicy.
An application may create and register multiple instances of this Transport Plugin with RTI Connext. Multiple instances of the plugin may be useful for partitioning the network interfaces across multiple RTI Connext domains. However, note that the underlying transport, the operating system's IP layer, is still a "singleton." For example, if a unicast transport has already bound to a port, and another unicast transport tries to bind to the same port, the second attempt will fail.
The transport plugin honors the interface/multicast "white" and "black" lists specified in the NDDS_Transport_UDPv4_Property_t::parent:
The format of a string in these lists is assumed to be in standard IPv4 dot notation, possibly containing wildcards. For example:
default_network_address_out | <<out>> Network address to be used when registering the transport. |
property_in | <<in>> Desired behavior of this transport as defined in the DDS_DomainParticipantQos::property. |
NDDS_Transport_Plugin* NDDS_Transport_UDPv4_create_from_properties_with_prefix | ( | NDDS_Transport_Address_t * | default_network_address_out, |
const struct DDS_PropertyQosPolicy * | property_in, | ||
const char * | propertyPrefix | ||
) |
Create an instance of a UDPv4 Transport Plugin, using the PropertyQosPolicy. Same as NDDS_Transport_UDPv4_create but with a prefix for the input properties. It is used to create pluggable transports that use an underlying UDP transport.
default_network_address_out | <<out>> Network address to be used when registering the transport. |
property_in | <<in>> Desired behavior of this transport as defined in the DDS_DomainParticipantQos::property. |
propertyPrefix | a prefix for the properties. Expected UDP properties have the form prefix.property_name |