RemoteBackupChangeLogDAOImpl

internal class RemoteBackupChangeLogDAOImpl(queries: RemotebackupChangeLogQueries, readDispatcher: ReadDispatcher, writeDispatcher: WriteDispatcher, mapper: RemoteBackupChangeLogMapper = RemoteBackupChangeLogMapper) : RemoteBackupChangeLogDAO

Constructors

Link copied to clipboard
constructor(queries: RemotebackupChangeLogQueries, readDispatcher: ReadDispatcher, writeDispatcher: WriteDispatcher, mapper: RemoteBackupChangeLogMapper = RemoteBackupChangeLogMapper)

Functions

Link copied to clipboard
open suspend override fun deleteChanges(changes: List<ChangeLogEntry>)

Delete the given changelog changes after they were successfully synced.

Link copied to clipboard
open suspend override fun getLastPendingChangesBatch(limit: Long): ChangeLogSyncBatch

Get a transactional snapshot of the latest limit pending changes and their conversations' last-read timestamps.

Link copied to clipboard
open suspend override fun getPendingChanges(): List<ChangeLogEntry>

Get all pending changes ordered deterministically for replay.

Link copied to clipboard
open suspend override fun logConversationClear(conversationId: QualifiedIDEntity, timestampMs: Long)

Log a conversation clear event. This clears all existing entries for the conversation and adds a single clear event.

Link copied to clipboard
open suspend override fun logConversationDelete(conversationId: QualifiedIDEntity, timestampMs: Long)

Log a conversation deletion event. This clears all existing entries for the conversation and adds a single delete event.

Link copied to clipboard
open suspend override fun logMessageDelete(conversationId: QualifiedIDEntity, messageId: String, timestampMs: Long)

Log a message deletion event.

Link copied to clipboard
open suspend override fun logMessageUpsert(conversationId: QualifiedIDEntity, messageId: String, timestampMs: Long, messageTimestampMs: Long)

Log a message upsert (create or edit) event.

Link copied to clipboard
open suspend override fun logReactionsSync(conversationId: QualifiedIDEntity, messageId: String, timestampMs: Long)

Log a reactions sync event. This means "sync all reactions for this message" - when any reaction changes.

Link copied to clipboard
open suspend override fun logReadReceiptsSync(conversationId: QualifiedIDEntity, messageId: String, timestampMs: Long)

Log a read receipts sync event. This means "sync all read receipts for this message" - when any receipt changes.

Link copied to clipboard
open override fun observeLastPendingChangesBatch(limit: Long): <Error class: unknown class><ChangeLogSyncBatch>

Observe transactional snapshots of the latest limit pending changes and their conversations' last-read timestamps.