Struct SolidSyslogSender¶
#include <SolidSyslogSenderDefinition.h>
struct SolidSyslogSender
{
bool (*Send)(struct SolidSyslogSender* base, const void* buffer, size_t size);
void (*Disconnect)(struct SolidSyslogSender* base);
};
Detailed Description¶
The contract an implementer fills in.
The library composes one sender per destination and calls it from the servicing pass; a sender is not a process-singleton (dual-SIEM and failover stacks hold several).
Public Attributes Documentation¶
Disconnect¶
Drop the underlying connection, leaving the sender reusable: the next Send reconnects.
Must be idempotent (safe when already disconnected). The library calls this to reset a stale connection, not on every send failure, so it is not on the hot path.
Send¶
Deliver one fully-framed message, buffer [0..size).
Return true only once it is on the wire (or genuinely unrecoverable and safe to drop): the Service loop marks the record sent and moves on. Return false to keep the record in the Store for a later retry, which is what a slow or down destination reports. May connect lazily, which can block on the transport; buffer is read during the call and need not outlive it. Called on the servicing thread, so it need not be reentrant. Report a run of failed sends once, when it starts, re-armed by the next send that succeeds: the library's reports of its own events pass through Send too, so a sender that reported every failure would raise one for each report of the one before.
The documentation for this class was generated from the following file Core/Interface/SolidSyslogSenderDefinition.h