Beamlens.Skill.Ecto (beamlens v0.3.1)

View Source

Ecto database monitoring skill.

Experimental

This skill is experimental. The API may change in future releases.

Monitors query performance, connection pool health, and database-specific insights. Requires configuration with a Repo module.

Usage

Define a skill module for your Repo:

defmodule MyApp.EctoSkill do
  use Beamlens.Skill.Ecto, repo: MyApp.Repo
end

Then configure in your supervision tree:

children = [
  {Beamlens, skills: [:beam, MyApp.EctoSkill]}
]

PII Safety

Query text from pg_stat_statements uses parameterized SQL ($1, $2 placeholders). Functions querying pg_stat_activity (locks, long_running) exclude query text entirely.

PostgreSQL Features

With {:ecto_psql_extras, "~> 0.8"} installed, additional callbacks are available for index analysis, cache hit ratios, locks, and bloat.

Summary

Functions

callback_docs()

callbacks(repo)

description()

snapshot(repo)

system_prompt()

title()