Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ArchiveRunner ¶
type ArchiveRunner interface {
Run() error
}
ArchiveRunner compresses old flat files on a schedule.
type DB ¶
type DB interface {
Healthy(ctx context.Context) bool
Counts(ctx context.Context) (total, embedded int64, err error)
GetUnembedded(ctx context.Context) ([]domain.Entry, error)
}
DB is the subset of database operations the server requires.
type DiskMonitor ¶
DiskMonitor exposes disk health state.
type EmbedHealthChecker ¶
EmbedHealthChecker reports embedding service health.
type EmbedPool ¶
type EmbedPool interface {
Enqueue(id uuid.UUID, content string)
StartWorkers(ctx context.Context, n int)
Wait()
}
EmbedPool manages async embedding jobs.
type HealthResponse ¶
type HealthResponse struct {
Status string `json:"status"`
Ollama string `json:"ollama"`
Postgres string `json:"postgres"`
EntryCount int64 `json:"entry_count"`
EmbeddedCount int64 `json:"embedded_count"`
DiskFreeBytes int64 `json:"disk_free_bytes"`
DiskTotalBytes int64 `json:"disk_total_bytes"`
DiskWarning bool `json:"disk_warning"`
}
HealthResponse is the /health endpoint response body.
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server is the Eidetic HTTP server.
func New ¶
func New( cfg *config.Config, handler *mcp.Handler, db DB, embedPool EmbedPool, embedHealth EmbedHealthChecker, diskMon DiskMonitor, archiver ArchiveRunner, ) *Server
New assembles the server from its dependencies. The MCP handler and all tool wiring must be done by the caller (main.go); the server only dispatches HTTP.
Click to show internal directories.
Click to hide internal directories.