|
DelegateMQ
|
Linux TCP transport implementation for DelegateMQ. More...
#include <LinuxTcpTransport.h>
Public Types | |
| enum class | Type { SERVER , CLIENT , SERVER , CLIENT } |
| enum class | Type { SERVER , CLIENT , SERVER , CLIENT } |
Public Member Functions | |
| TcpTransport () | |
| ~TcpTransport () | |
| int | Create (Type type, const char *addr, uint16_t port) |
| void | Close () |
| virtual int | Send (xostringstream &os, const DmqHeader &header) override |
| virtual int | Receive (xstringstream &is, DmqHeader &header) override |
| void | SetTransportMonitor (ITransportMonitor *tm) |
| void | SetSendTransport (ITransport *st) |
| void | SetRecvTransport (ITransport *rt) |
| TcpTransport () | |
| ~TcpTransport () | |
| int | Create (Type type, LPCSTR addr, USHORT port) |
| void | Close () |
| virtual int | Send (xostringstream &os, const DmqHeader &header) override |
| virtual int | Receive (xstringstream &is, DmqHeader &header) override |
| void | SetTransportMonitor (ITransportMonitor *tm) |
| void | SetSendTransport (ITransport *st) |
| void | SetRecvTransport (ITransport *rt) |
Public Member Functions inherited from ITransport | |
Linux TCP transport implementation for DelegateMQ.
This class implements the ITransport interface using standard Linux BSD sockets. It supports both CLIENT and SERVER modes for reliable, stream-based communication.
Key Features:
TCP_NODELAY to disable Nagle's algorithm, optimized for the small, frequent packets typical of RPC/delegate calls.select() with a 1-second timeout in the receive loop to allow for cooperative multitasking and clean shutdowns without busy waiting.TransportMonitor to handle sequence tracking and ACK generation.
|
strong |
|
strong |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inlineoverridevirtual |
Receive data from a remote
| [out] | is | The received incoming data bytes, not including the header. |
| [out] | header | Incoming delegate message header. |
Implements ITransport.
|
inlineoverridevirtual |
Receive data from a remote
| [out] | is | The received incoming data bytes, not including the header. |
| [out] | header | Incoming delegate message header. |
Implements ITransport.
|
inlineoverridevirtual |
Send data to a remote
| [in] | os | Output stream to send. |
| [in] | header | The header to send. |
Implements ITransport.
|
inlineoverridevirtual |
Send data to a remote
| [in] | os | Output stream to send. |
| [in] | header | The header to send. |
Implements ITransport.
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |
|
inline |