mirror of
https://github.com/logos-messaging/logos-delivery.git
synced 2026-05-30 18:49:26 +00:00
26 lines
757 B
Nim
26 lines
757 B
Nim
## Persistence backend for SDS outgoing buffer and causal history.
|
|
##
|
|
## TODO (raised in PR review): this surface is duplicating concerns that
|
|
## should come from the SDS module itself. Once the SDS module exposes a
|
|
## complete persistence contract, drop this file and import that surface
|
|
## instead of re-declaring it here.
|
|
|
|
import message
|
|
|
|
type
|
|
SdsPersistenceKind* {.pure.} = enum
|
|
InMemory
|
|
Sqlite
|
|
|
|
SdsPersistence* = ref object of RootObj
|
|
kind*: SdsPersistenceKind
|
|
|
|
method storeOutgoing*(self: SdsPersistence, msg: SdsMessage) {.base.} =
|
|
discard
|
|
|
|
method markAcknowledged*(self: SdsPersistence, messageId: SdsMessageID) {.base.} =
|
|
discard
|
|
|
|
method unackedOlderThan*(self: SdsPersistence, ageMs: int): seq[SdsMessage] {.base.} =
|
|
discard
|