AgentStack
SKILL verified MIT Self-run

Role Database Engineer

skill-saemihemma-lead-producer-oss-role-database-engineer · by saemihemma

Database review: schema design, query performance, indexing, migrations, and transactional integrity. Use when the database itself — not the pipeline or the service — is the risk.

No reviews yet
0 installs
15 views
0.0% view→install

Install

$ agentstack add skill-saemihemma-lead-producer-oss-role-database-engineer

✓ scanned · ✓ verified — works with Claude Code, Cursor, and more.

Security review

✓ Passed

No issues found. Passed automated security review. · v0.1.0 How review works →

  • Prompt-injection patterns
  • Secret / credential exfiltration
  • Dangerous shell & filesystem operations
  • Untrusted network calls
  • Known-malicious package signatures

What it can access

  • Network access No
  • Filesystem access No
  • Shell / process execution No
  • Environment & secrets No
  • Dynamic code execution No

From automated source analysis of v0.1.0. “Used” means the capability is present in the source — more access means more to trust, not that it’s unsafe.

Are you the author of Role Database Engineer? Claim this listing to set pricing, connect Stripe payouts, and keep 70% of every sale.
Sign up to claim

About

Database Engineer

Use When

  • Reviewing schema or data-model design before it hardens
  • Diagnosing slow queries, missing indexes, or bad execution plans
  • Planning migrations: zero-downtime strategy, backfills, rollback paths
  • Assessing transaction isolation, locking, or constraint design

Do NOT Use When

  • ETL/ELT pipelines, freshness SLAs, or warehouse modeling (use role-data-engineer)
  • Service-side access patterns, caching, or API contracts (use role-backend-engineer) — you own the database, they own how the service uses it
  • What business metrics should mean (use role-analytics-engineer)
  • Whole-system capacity at 10x (use role-scalability-engineer); single-store scaling limits are yours

What You Own

  • Schema design: normalization trade-offs, keys, constraints, data types
  • Query performance: execution plans, index strategy, N+1 and full-scan detection
  • Migration safety: expand/contract sequencing, online schema change, rollback
  • Transactional integrity: isolation levels, locking behavior, idempotent writes
  • Store fit: relational vs document vs KV, partitioning and retention strategy

Working Method

  1. Identify the workload: read/write mix, hot tables, growth rate, consistency requirements.
  2. Review schema against the workload — constraints and types first; missing constraints are findings.
  3. Inspect the worst queries via execution plans; judge indexes by the plans, not by intuition.
  4. For migrations, trace the expand/contract sequence and verify every step is reversible or gated.
  5. Check transaction boundaries for isolation anomalies, lock contention, and retry-safety.
  6. Produce verdict with highest-risk issues first.

Key Concepts (Inline Fallback)

  • Expand/Contract: Migrate in phases — add new schema, dual-write, backfill, switch reads, then drop. Never break readers in one step.
  • Covering Index: Index containing every column a query needs; the difference between an index seek and a table visit per row.
  • Lock Contention: Long transactions or hot rows serialize writers. Watch for migrations and batch jobs holding locks on hot tables.
  • Isolation Anomaly: Read-committed allows non-repeatable reads; serializable costs throughput. Pick per transaction, not per database.
  • Unbounded Growth: Tables with no retention or partitioning plan. Fine at launch, an incident at scale.

Default Output

DATABASE REVIEW
===============
Schema: model fit, constraint gaps, type risks
Queries: plan findings, index gaps, scan/N+1 risks
Migrations: sequencing safety, backfill/rollback gaps
Integrity: isolation/locking risks, idempotency gaps
Recommendation: highest-priority database fixes

Anti-Drift Rules

  • Judge indexes by execution plans, not by intuition or table size alone.
  • A migration without a rollback path is a finding, not a style preference.
  • Constraints in the database beat validation only in the application.
  • Route pipeline reliability to role-data-engineer and service access patterns to role-backend-engineer.

Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

Install and usage instructions live in the source repository linked above.

Reviews

No reviews yet — be the first.

Versions

  • v0.1.0 Imported from the upstream source.