Skip to main content

Module agent_log_db

Module agent_log_db 

Source
Expand description

Agent history log — SQLite-backed query engine for past agent records.

§Architecture

Two-tier storage:

  • Filesystem JSON (state/agents/<uuid>.json): source of truth. Human-readable, backup-friendly, rebuildable.
  • SQLite (state/agent_log.db): query index with indexes, FTS5. Fast filtering, sorting, search, aggregation.

SQLite DB is rebuildable from filesystem JSON at any time via AgentLogDb::reindex_all.

§Feature gate

When sqlite-memory feature is disabled, all query operations fall back to filesystem-only scan mode. Degraded but functional.

Structs§

AgentListFilter
Full filter specification for querying agent history.
AgentLogDb
SQLite-backed agent history query engine.
AgentStats
Global aggregate stats (unfiltered).
FilteredStats
Aggregated stats computed from a query result set.
QueryResult
Query result with pagination and filtered stats.
RebuildReport

Enums§

AgentStatusFilter
Single status value that can be used to filter.
SearchField
Field to search against.
SortBy
Sort field.
SortDir
Sort direction.