UDPv6 Transport
[Built-in Transport Plugins]

Built-in transport plug-in using UDP/IPv6 (NDDS_TRANSPORT_CLASSID_UDPv6). More...

Classes

struct  NDDS_Transport_UDPv6_Property_t
 Configurable IPv6/UDP Transport-Plugin properties. More...

Defines

#define NDDS_TRANSPORT_CLASSID_UDPv6   (5)
 Builtin IPv6 UDP/IP Transport-Plugin class ID.
#define NDDS_TRANSPORT_UDPV6_ADDRESS_BIT_COUNT   (128)
 Default value of NDDS_Transport_Property_t::address_bit_count.
#define NDDS_TRANSPORT_UDPV6_PROPERTIES_BITMAP_DEFAULT   (0)
 Default value of NDDS_Transport_Property_t::properties_bitmap.
#define NDDS_TRANSPORT_UDPV6_GATHER_SEND_BUFFER_COUNT_MAX_DEFAULT   (16)
 Default value of NDDS_Transport_Property_t::gather_send_buffer_count_max.
#define NDDS_TRANSPORT_UDPV6_SOCKET_BUFFER_SIZE_OS_DEFAULT   (-1)
 Used to specify that os default be used to specify socket buffer size.
#define NDDS_TRANSPORT_UDPV6_MESSAGE_SIZE_MAX_DEFAULT   (9216)
 Default value of NDDS_Transport_Property_t::message_size_max.
#define NDDS_TRANSPORT_UDPV6_MULTICAST_TTL_DEFAULT   (1)
 Default value of NDDS_Transport_UDPv6_Property_t::multicast_ttl.
#define NDDS_TRANSPORT_UDPV6_BLOCKING_NEVER
 Value for NDDS_Transport_UDPv6_Property_t::send_blocking to specify non-blocking sockets.
#define NDDS_TRANSPORT_UDPV6_BLOCKING_ALWAYS
 [default] Value for NDDS_Transport_UDPv6_Property_t::send_blocking to specify blocking sockets.
#define NDDS_TRANSPORT_UDPV6_PROPERTY_DEFAULT
 Use this to initialize a NDDS_Transport_UDPv6_Property_t structure.

Functions

NDDS_Transport_Plugin * NDDS_Transport_UDPv6_new (const struct NDDS_Transport_UDPv6_Property_t *property_in)
 Create an instance of a UDPv6 Transport Plugin.
RTI_INT32 NDDS_Transport_UDPv6_string_to_address_cEA (NDDS_Transport_Plugin *self, NDDS_Transport_Address_t *address_out, const char *address_in)
 Realization of NDDS_Transport_String_To_Address_Fcn_cEA for IP transports.
RTI_INT32 NDDS_Transport_UDPv6_get_receive_interfaces_cEA (NDDS_Transport_Plugin *self, RTI_INT32 *found_more_than_provided_for_out, RTI_INT32 *interface_reported_count_out, NDDS_Transport_Interface_t interface_array_inout[], RTI_INT32 interface_array_size_in)
 Realization of NDDS_Transport_Get_Receive_Interfaces_Fcn_cEA for IP transports.
NDDS_Transport_Plugin * NDDS_Transport_UDPv6_create (NDDS_Transport_Address_t *default_network_address_out, const struct DDS_PropertyQosPolicy *property_in)
 Create an instance of a UDPv6 Transport Plugin, using PropertyQosPolicy.

Detailed Description

Built-in transport plug-in using UDP/IPv6 (NDDS_TRANSPORT_CLASSID_UDPv6).

This transport plugin uses UDPv6 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.

The user can configure an instance of this plugin to only use unicast or only use multicast, see NDDS_Transport_UDPv6_Property_t::unicast_enabled and NDDS_Transport_UDPv6_Property_t::multicast_enabled.

In addition, the user 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 "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 it with the DDSDomainParticipant if this transport is specified in the DDS_TransportBuiltinQosPolicy.

To specify the properties of the builtin UDPv6 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 that are 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_UDPv6_new() should be called. The instance should be registered with RTI Connext, see NDDSTransportSupport::register_transport. In some configurations, you may have to disable the builtin UDPv6 transport plugin instance (DDS_TransportBuiltinQosPolicy, DDS_TRANSPORTBUILTIN_UDPv6), to avoid port conflicts with the newly created plugin instance.

UDPv6 Transport Property Names in Property QoS Policy of Domain Participant

The following table lists the predefined property names that can be set in DDS_PropertyQosPolicy of a DDSDomainParticipant to configure the builtin UDPv6 transport plugin.

Property Names for UDPv6 Transport Plugin
Property Name Description

dds.transport.UDPv6.builtin.parent.address_bit_count See NDDS_Transport_Property_t::address_bit_count
dds.transport.UDPv6.builtin.parent.properties_bitmap See NDDS_Transport_Property_t::properties_bitmap
dds.transport.UDPv6.builtin.parent.gather_send_buffer_count_max See NDDS_Transport_Property_t::gather_send_buffer_count_max
dds.transport.UDPv6.builtin.parent.message_size_max See NDDS_Transport_Property_t::message_size_max
dds.transport.UDPv6.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.UDPv6.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.UDPv6.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.UDPv6.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.UDPv6.builtin.send_socket_buffer_size See NDDS_Transport_UDPv6_Property_t::send_socket_buffer_size
dds.transport.UDPv6.builtin.recv_socket_buffer_size See NDDS_Transport_UDPv6_Property_t::recv_socket_buffer_size
dds.transport.UDPv6.builtin.unicast_enabled See NDDS_Transport_UDPv6_Property_t::unicast_enabled
dds.transport.UDPv6.builtin.multicast_enabled See NDDS_Transport_UDPv6_Property_t::multicast_enabled
dds.transport.UDPv6.builtin.multicast_ttl See NDDS_Transport_UDPv6_Property_t::multicast_ttl
dds.transport.UDPv6.builtin.multicast_loopback_disabled See NDDS_Transport_UDPv6_Property_t::multicast_loopback_disabled
dds.transport.UDPv6.builtin.ignore_loopback_interface See NDDS_Transport_UDPv6_Property_t::ignore_loopback_interface
dds.transport.UDPv6.builtin.ignore_nonrunning_interfaces See NDDS_Transport_UDPv6_Property_t::ignore_nonrunning_interfaces
dds.transport.UDPv6.builtin.no_zero_copy See NDDS_Transport_UDPv6_Property_t::no_zero_copy
dds.transport.UDPv6.builtin.send_blocking See NDDS_Transport_UDPv6_Property_t::send_blocking
dds.transport.UDPv6.builtin.enable_v4mapped See NDDS_Transport_UDPv6_Property_t::enable_v4mapped
dds.transport.UDPv6.builtin.transport_priority_mask See NDDS_Transport_UDPv6_Property_t::transport_priority_mask
dds.transport.UDPv6.builtin.transport_priority_mapping_low See NDDS_Transport_UDPv6_Property_t::transport_priority_mapping_low
dds.transport.UDPv6.builtin.transport_priority_mapping_high See NDDS_Transport_UDPv6_Property_t::transport_priority_mapping_high

See also:
NDDSTransportSupport::set_builtin_transport_property()

Define Documentation

#define NDDS_TRANSPORT_CLASSID_UDPv6   (5)

Builtin IPv6 UDP/IP Transport-Plugin class ID.

#define NDDS_TRANSPORT_UDPV6_ADDRESS_BIT_COUNT   (128)

#define NDDS_TRANSPORT_UDPV6_PROPERTIES_BITMAP_DEFAULT   (0)

#define NDDS_TRANSPORT_UDPV6_GATHER_SEND_BUFFER_COUNT_MAX_DEFAULT   (16)

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 NDDS, 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_UDPV6_SOCKET_BUFFER_SIZE_OS_DEFAULT   (-1)

Used to specify that os default be used to specify socket buffer size.

#define NDDS_TRANSPORT_UDPV6_MESSAGE_SIZE_MAX_DEFAULT   (9216)

#define NDDS_TRANSPORT_UDPV6_MULTICAST_TTL_DEFAULT   (1)

#define NDDS_TRANSPORT_UDPV6_BLOCKING_NEVER

Value for NDDS_Transport_UDPv6_Property_t::send_blocking to specify non-blocking sockets.

#define NDDS_TRANSPORT_UDPV6_BLOCKING_ALWAYS

[default] Value for NDDS_Transport_UDPv6_Property_t::send_blocking to specify blocking sockets.

#define NDDS_TRANSPORT_UDPV6_PROPERTY_DEFAULT

Value:

{ \
    { NDDS_TRANSPORT_CLASSID_UDPv6, \
        NDDS_TRANSPORT_UDPV6_ADDRESS_BIT_COUNT, \
        NDDS_TRANSPORT_UDPV6_PROPERTIES_BITMAP_DEFAULT, \
        NDDS_TRANSPORT_UDPV6_GATHER_SEND_BUFFER_COUNT_MAX_DEFAULT, \
        NDDS_TRANSPORT_UDPV6_MESSAGE_SIZE_MAX_DEFAULT, \
        NULL, 0, /* allow_interfaces_list */ \
        NULL, 0, /* deny_interfaces_list */ \
        NULL, 0, /* allow_multicast_interfaces_list */ \
        NULL, 0, /* deny_multicast_interfaces_list */ \
    }, \
    NDDS_TRANSPORT_UDPV6_MESSAGE_SIZE_MAX_DEFAULT, \
    NDDS_TRANSPORT_UDPV6_MESSAGE_SIZE_MAX_DEFAULT, \
    1, /* use unicast */   \
    NDDS_TRANSPORT_UDPV6_USE_MULTICAST_DEFAULT, /* use multicast */ \
    NDDS_TRANSPORT_UDPV6_MULTICAST_TTL_DEFAULT, \
    0, /* multicast loopback enabled */ \
    -1, /* (auto-)ignore loopback */ \
    0, /* do not ignore non-RUNNING */ \
    0, /* no_zero_copy */ \
    NDDS_TRANSPORT_UDPV6_BLOCKING_DEFAULT, \
    0,  /* enable_v4mapped */ \
    0, 0, 0xff /* no mapping to IPV6_TCLASS by default */ }
Use this to initialize a NDDS_Transport_UDPv6_Property_t structure.


Function Documentation

NDDS_Transport_Plugin* NDDS_Transport_UDPv6_new ( const struct NDDS_Transport_UDPv6_Property_t property_in  ) 

Create an instance of a UDPv6 Transport Plugin.

An application may create and register multiple instances of this Transport Plugin with RTI Connext. This may be to partition 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_UDPv6_Property_t::parent:

The format of a string in these lists is assumed to be in standard IPv6 dot notation, possibly containing wildcards. For example:

  • 10.10.30.232
  • 10.10.*.*
  • 192.168.1.*
  • etc. Strings not in the correct format will be ignored.

Parameters:
property_in <<in>> Desired behavior of this transport. May be NULL for default property.
Returns:
A UDPv6 Transport Plugin instance on success; or NULL on failure.

RTI_INT32 NDDS_Transport_UDPv6_string_to_address_cEA ( NDDS_Transport_Plugin *  self,
NDDS_Transport_Address_t address_out,
const char *  address_in 
)

Realization of NDDS_Transport_String_To_Address_Fcn_cEA for IP transports.

Converts a host name string to a IPv6 address.

Parameters:
self NOT USED. May be NULL.
address_out <<out>> The corresponding numerical value in IPv6 format.
address_in <<in>> The name of the IPv6 address. It can be a dot notation name or a host name. If NULL, then the IP address of the localhost will be returned.
See also:
NDDS_Transport_String_To_Address_Fcn_cEA for complete documentation.

RTI_INT32 NDDS_Transport_UDPv6_get_receive_interfaces_cEA ( NDDS_Transport_Plugin *  self,
RTI_INT32 *  found_more_than_provided_for_out,
RTI_INT32 *  interface_reported_count_out,
NDDS_Transport_Interface_t  interface_array_inout[],
RTI_INT32  interface_array_size_in 
)

Realization of NDDS_Transport_Get_Receive_Interfaces_Fcn_cEA for IP transports.

Retrieves a list of available IPv6 network interfaces. The addresses returned from IPv6 plugin will be full 128-bit addresses.

See also:
NDDS_Transport_Get_Receive_Interfaces_Fcn_cEA for complete documentation.

NDDS_Transport_Plugin* NDDS_Transport_UDPv6_create ( NDDS_Transport_Address_t default_network_address_out,
const struct DDS_PropertyQosPolicy property_in 
)

Create an instance of a UDPv6 Transport Plugin, using PropertyQosPolicy.

An application may create and register multiple instances of this Transport Plugin with RTI Connext. This may be to partition 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_UDPv6_Property_t::parent:

The format of a string in these lists is assumed to be in standard IPv6 dot notation, possibly containing wildcards. For example:

  • *:*:*:*:*:*:*:*
  • FE80:aBc::202:*:*
  • *:aBC::*2:*:2*
  • etc. Strings not in the correct format will be ignored.

Parameters:
default_network_address_out <<out>> Network address to be used when registering the transport.
property_in <<in>> Desired behavior of this transport, through the property field in DDS_DomainParticipantQos.
Returns:
A UDPv6 Transport Plugin instance on success; or NULL on failure.


RTI Connext C++ API Version 4.5f Copyright © 17 Mar 2012 Real-Time Innovations, Inc