| Fast DDS Version 3.3.0 Fast DDS

Loading...
Searching...
No Matches
TCPTransportDescriptor Struct Reference
eProsima Fast DDS API Reference » RTPS » Common Module. » Transport Module.

TCP Transport configuration. More...

`#include <TCPTransportDescriptor.hpp>`

Inheritance diagram for TCPTransportDescriptor:
[legend]

## Classes

struct | TLSConfig
| TLS Configuration. More...

## Public Member Functions

void | add_listener_port (uint16_t port)
| Add listener port to the listening_ports list.
FASTDDS_EXPORTED_API | TCPTransportDescriptor ()
| Constructor.
FASTDDS_EXPORTED_API | TCPTransportDescriptor (const TCPTransportDescriptor &t)
| Copy constructor.
FASTDDS_EXPORTED_API TCPTransportDescriptor & | operator= (const TCPTransportDescriptor &t)
| Copy assignment.
virtual | ~TCPTransportDescriptor ()=default
| Destructor.
FASTDDS_EXPORTED_API bool | operator== (const TCPTransportDescriptor &t) const
| Comparison operator.
Public Member Functions inherited from SocketTransportDescriptor
FASTDDS_EXPORTED_API | SocketTransportDescriptor (uint32_t maximumMessageSize, uint32_t maximumInitialPeersRange)
| Constructor.
FASTDDS_EXPORTED_API | SocketTransportDescriptor (const SocketTransportDescriptor &t)=default
| Copy constructor.
FASTDDS_EXPORTED_API SocketTransportDescriptor & | operator= (const SocketTransportDescriptor &t)=default
| Copy assignment.
virtual FASTDDS_EXPORTED_API | ~SocketTransportDescriptor ()=default
| Destructor.
virtual FASTDDS_EXPORTED_API uint32_t | min_send_buffer_size () const override
| Returns the minimum size required for a send operation.
bool FASTDDS_EXPORTED_API | operator== (const SocketTransportDescriptor &t) const
| Comparison operator.
Public Member Functions inherited from PortBasedTransportDescriptor
FASTDDS_EXPORTED_API | PortBasedTransportDescriptor (uint32_t maximumMessageSize, uint32_t maximumInitialPeersRange)
| Constructor.
FASTDDS_EXPORTED_API | PortBasedTransportDescriptor (const PortBasedTransportDescriptor &t)=default
| Copy constructor.
FASTDDS_EXPORTED_API PortBasedTransportDescriptor & | operator= (const PortBasedTransportDescriptor &t)=default
| Copy assignment.
virtual FASTDDS_EXPORTED_API | ~PortBasedTransportDescriptor ()=default
| Destructor.
bool FASTDDS_EXPORTED_API | operator== (const PortBasedTransportDescriptor &t) const
| Comparison operator.
virtual FASTDDS_EXPORTED_API const ThreadSettings & | get_thread_config_for_port (uint32_t port) const
| Get the ThreadSettings for a specific port.
virtual FASTDDS_EXPORTED_API bool | set_thread_config_for_port (const uint32_t &port, const ThreadSettings &thread_settings)
FASTDDS_EXPORTED_API const ThreadSettings & | default_reception_threads () const
| Returns the ThreadSettings for the default reception threads.
virtual FASTDDS_EXPORTED_API void | default_reception_threads (const ThreadSettings &default_reception_threads)
| Set the ThreadSettings for the default reception threads.
FASTDDS_EXPORTED_API const ReceptionThreadsConfigMap & | reception_threads () const
| Returns the ThreadSettings for the user-configured reception threads.
virtual FASTDDS_EXPORTED_API bool | reception_threads (const ReceptionThreadsConfigMap &reception_threads)
| Set the ThreadSettings for the user-configured reception threads.
Public Member Functions inherited from TransportDescriptorInterface
FASTDDS_EXPORTED_API | TransportDescriptorInterface (uint32_t maximumMessageSize, uint32_t maximumInitialPeersRange)
| Constructor.
FASTDDS_EXPORTED_API | TransportDescriptorInterface (const TransportDescriptorInterface &t)
| Copy constructor.
FASTDDS_EXPORTED_API TransportDescriptorInterface & | operator= (const TransportDescriptorInterface &t)
| Copy assignment.
virtual FASTDDS_EXPORTED_API | ~TransportDescriptorInterface ()=default
| Destructor.
virtual FASTDDS_EXPORTED_API TransportInterface * | create_transport () const =0
| Factory method pattern.
virtual FASTDDS_EXPORTED_API uint32_t | max_message_size () const
| Returns the maximum size expected for received messages.
virtual FASTDDS_EXPORTED_API uint32_t | max_initial_peers_range () const
| Returns the maximum number of opened channels for each initial remote peer (maximum number of guessed initial peers to try to connect).
FASTDDS_EXPORTED_API bool | operator== (const TransportDescriptorInterface &t) const
| Comparison operator.
FASTDDS_EXPORTED_API void | lock ()
| Lock internal mutex (for Fast-DDS internal use).
FASTDDS_EXPORTED_API void | unlock ()
| Unlock internal mutex (for Fast-DDS internal use).

## Public Attributes

std::vector< uint16_t > | listening_ports
| List of ports to listen as server.
uint32_t | keep_alive_frequency_ms
| Frequency of RTCP keep alive requests (ms).
uint32_t | keep_alive_timeout_ms
| Time since sending the last keep alive request to consider a connection as broken (ms).
uint16_t | max_logical_port
| Maximum number of logical ports to try during RTCP negotiation.
uint16_t | logical_port_range
| Maximum number of logical ports per request to try during RTCP negotiation.
uint16_t | logical_port_increment
| Increment between logical ports to try during RTCP negotiation.
uint32_t | tcp_negotiation_timeout
| Time to wait for logical port negotiation (ms).
bool | enable_tcp_nodelay
| Enables the TCP_NODELAY socket option.
bool | calculate_crc
| Enables the calculation and sending of CRC on message headers.
bool | check_crc
| Enables checking the CRC of incoming message headers.
bool | apply_security
| Enables the use of TLS (Transport Layer Security).
TLSConfig | tls_config
| Configuration of the TLS (Transport Layer Security).
ThreadSettings | keep_alive_thread
| Thread settings for keep alive thread.
ThreadSettings | accept_thread
| Thread settings for the accept connections thread.
bool | non_blocking_send
| Whether to use non-blocking calls to send().
Public Attributes inherited from SocketTransportDescriptor
uint32_t | sendBufferSize
| Length of the send buffer.
uint32_t | receiveBufferSize
| Length of the receive buffer.
std::vector< std::string > | interfaceWhiteList
| Allowed interfaces in an IP or device name string format.
NetmaskFilterKind | netmask_filter
| Transport's netmask filter configuration.
std::vector< AllowedNetworkInterface > | interface_allowlist
| Allowed interfaces in an IP or device name string format, each with a specific netmask filter configuration.
std::vector< BlockedNetworkInterface > | interface_blocklist
| Blocked interfaces in an IP or device name string format.
uint8_t | TTL
| Specified time to live (8bit - 255 max TTL).
Public Attributes inherited from TransportDescriptorInterface
uint32_t | maxMessageSize
| Maximum size of a single message in the transport.
uint32_t | maxInitialPeersRange
| Number of channels opened with each initial remote peer.

## Additional Inherited Members

Public Types inherited from PortBasedTransportDescriptor
using | ReceptionThreadsConfigMap = std::map<uint32_t, ThreadSettings>
Protected Attributes inherited from PortBasedTransportDescriptor
ThreadSettings | default_reception_threads_
| Thread settings for the default reception threads.
ReceptionThreadsConfigMap | reception_threads_
| Thread settings for the specific reception threads, indexed by port.

## Detailed Description

TCP Transport configuration.

- `listening_ports:` list of ports to listen as server.
- `keep_alive_frequency_ms:` frequency of RTCP keep alive requests (in ms).
- `keep_alive_timeout_ms:` time since sending the last keep alive request to consider a connection as broken (in ms).
- `max_logical_port:` maximum number of logical ports to try during RTCP negotiation.
- `logical_port_range:` maximum number of logical ports per request to try during RTCP negotiation.
- `logical_port_increment:` increment between logical ports to try during RTCP negotiation.
- `enable_tcp_nodelay:` enables the TCP_NODELAY socket option.
- `calculate_crc:` true to calculate and send CRC on message headers.
- `check_crc:` true to check the CRC of incoming message headers.
- `apply_security:` true to use TLS (Transport Layer Security).
- `tls_config:` Configuration for TLS.
- `non_blocking_send:` do not block on send operations. When it is set to true, send operations will return immediately if the buffer might get full, but no error will be returned to the upper layer. This means that the application will behave as if the datagram is sent and lost.
- `tcp_negotiation_timeout:` time to wait for logical port negotiation (in ms).

## Constructor & Destructor Documentation

## ◆ TCPTransportDescriptor() [1/2]

FASTDDS_EXPORTED_API TCPTransportDescriptor | ( |  | ) |

Constructor.

## ◆ TCPTransportDescriptor() [2/2]

FASTDDS_EXPORTED_API TCPTransportDescriptor | ( | const TCPTransportDescriptor & | t | ) |

Copy constructor.

## ◆ ~TCPTransportDescriptor()

virtual ~TCPTransportDescriptor | ( |  | ) |

virtual default

Destructor.

## Member Function Documentation

## ◆ add_listener_port()

void add_listener_port | ( | uint16_t | port | ) |

inline

Add listener port to the listening_ports list.

## ◆ operator=()

FASTDDS_EXPORTED_API TCPTransportDescriptor & operator= | ( | const TCPTransportDescriptor & | t | ) |

Copy assignment.

## ◆ operator==()

FASTDDS_EXPORTED_API bool operator== | ( | const TCPTransportDescriptor & | t | ) | const

Comparison operator.

## Member Data Documentation

## ◆ accept_thread

ThreadSettings accept_thread

Thread settings for the accept connections thread.

## ◆ apply_security

bool apply_security

Enables the use of TLS (Transport Layer Security).

## ◆ calculate_crc

bool calculate_crc

Enables the calculation and sending of CRC on message headers.

## ◆ check_crc

bool check_crc

Enables checking the CRC of incoming message headers.

## ◆ enable_tcp_nodelay

bool enable_tcp_nodelay

Enables the TCP_NODELAY socket option.

## ◆ keep_alive_frequency_ms

uint32_t keep_alive_frequency_ms

Frequency of RTCP keep alive requests (ms).

## ◆ keep_alive_thread

ThreadSettings keep_alive_thread

Thread settings for keep alive thread.

## ◆ keep_alive_timeout_ms

uint32_t keep_alive_timeout_ms

Time since sending the last keep alive request to consider a connection as broken (ms).

## ◆ listening_ports

std::vector<uint16_t> listening_ports

List of ports to listen as server.

## ◆ logical_port_increment

uint16_t logical_port_increment

Increment between logical ports to try during RTCP negotiation.

## ◆ logical_port_range

uint16_t logical_port_range

Maximum number of logical ports per request to try during RTCP negotiation.

## ◆ max_logical_port

uint16_t max_logical_port

Maximum number of logical ports to try during RTCP negotiation.

## ◆ non_blocking_send

bool non_blocking_send

Whether to use non-blocking calls to send().

When set to true, calls to send() will return immediately if the send buffer might get full. This may happen when receive buffer on reader's side is full. No error will be returned to the upper layer. This means that the application will behave as if the datagram is sent but lost (i.e. throughput may be reduced). This value is specially useful on high-frequency writers.

When set to false, which is the default, calls to send() will block until the send buffer has space for the datagram. This may cause application lock.

## ◆ tcp_negotiation_timeout

uint32_t tcp_negotiation_timeout

Time to wait for logical port negotiation (ms).

If a logical port is under negotiation, it waits for the negotiation to finish up to this timeout before trying to send a message to that port. Zero value means no waiting (default).

## ◆ tls_config

TLSConfig tls_config

Configuration of the TLS (Transport Layer Security).

The documentation for this struct was generated from the following file:

- include/fastdds/rtps/transport/TCPTransportDescriptor.hpp