Skip to content
«interface»SolidSyslogStructuredDataMetaSdCore«interface»SolidSyslogAtomicCounter

File SolidSyslogMetaSd.h

FileList > Core > Interface > SolidSyslogMetaSd.h

  • #include "SolidSyslogExternC.h"
  • #include "SolidSyslogSdValueFunction.h"
  • #include <stdint.h>

Classes

Type Name
struct SolidSyslogMetaSdConfig
Wiring for the "meta" SD-ELEMENT (RFC 5424 §7.3).

Detailed Description

A StructuredData source for the RFC 5424 §7.3 "meta" SD-ELEMENT (IANA SD-ID, so no enterprise-number suffix), emitted on every message the owning logger formats.

It always carries sequenceId, taken from one Increment of the injected AtomicCounter per message, and optionally sysUpTime and language. The two optional PARAMs are independently omitted when their config member is NULL, so a bare meta element is just [meta sequenceId="..."].

Public Types Documentation

SolidSyslogSysUpTimeFunction

Returns system uptime in hundredths of a second (RFC 3418 TimeTicks): monotonic, and wrapping to zero only at 2^32 hundredths.

typedef uint32_t(* SolidSyslogSysUpTimeFunction) (void);

A source counter that rolls over sooner must carry the phase across, or the value steps backwards mid-range. Feeds the meta element's sysUpTime PARAM.


Public Functions Documentation

SolidSyslogMetaSd_Create

Create a meta SD source, emitted on every message the owning logger formats.

struct SolidSyslogStructuredData * SolidSyslogMetaSd_Create (
    const struct SolidSyslogMetaSdConfig * config
) 

Never returns NULL: a NULL config, a NULL Counter, or an exhausted pool reports via SolidSyslog_Error and returns the shared no-op NullSd, so callers need not null-check the result.


SolidSyslogMetaSd_Destroy

Release the SD's pool slot.

void SolidSyslogMetaSd_Destroy (
    struct SolidSyslogStructuredData * base
) 

Does not touch the injected Counter; the caller owns it.



The documentation for this class was generated from the following file Core/Interface/SolidSyslogMetaSd.h