Skip to content

File SolidSyslogStore.h

FileList > Core > Interface > SolidSyslogStore.h

  • #include "SolidSyslogExternC.h"
  • #include <stdbool.h>
  • #include <stddef.h>

Detailed Description

The store role: retain unsent records (Write) and replay them in order via a read cursor (ReadNextUnsent / MarkSent), so a send failure never drops a stored record - it stays for retry.

These calls dispatch to the injected store's vtable, so behaviour - capacity, discard policy, durability - is that store's.

Public Functions Documentation

SolidSyslogStore_GetTotalBytes

Configured capacity in bytes.

size_t SolidSyslogStore_GetTotalBytes (
    struct SolidSyslogStore * store
) 


SolidSyslogStore_GetUsedBytes

Bytes currently occupied by retained records.

size_t SolidSyslogStore_GetUsedBytes (
    struct SolidSyslogStore * store
) 


SolidSyslogStore_HasUnsent

bool SolidSyslogStore_HasUnsent (
    struct SolidSyslogStore * store
) 

SolidSyslogStore_IsHalted

True once a Halt-policy store has filled and stopped accepting writes.

bool SolidSyslogStore_IsHalted (
    struct SolidSyslogStore * store
) 


SolidSyslogStore_IsTransient

bool SolidSyslogStore_IsTransient (
    struct SolidSyslogStore * store
) 

SolidSyslogStore_MarkSent

Confirm the last ReadNextUnsent delivered and advance the cursor.

void SolidSyslogStore_MarkSent (
    struct SolidSyslogStore * store
) 


SolidSyslogStore_ReadNextUnsent

Read the oldest unsent record without consuming it, then MarkSent to advance.

bool SolidSyslogStore_ReadNextUnsent (
    struct SolidSyslogStore * store,
    void * data,
    size_t maxSize,
    size_t * bytesRead
) 

The two form one read cursor, see SolidSyslogStoreDefinition.h for the protocol.


SolidSyslogStore_Write

Retain data (size bytes) as an unsent record.

bool SolidSyslogStore_Write (
    struct SolidSyslogStore * store,
    const void * data,
    size_t size
) 

False means not retained, see the Write vtable slot in SolidSyslogStoreDefinition.h for what that implies.



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