cockroachdb-developer

cockroachdb-developer is an agent for Claude Code from cockroachdb/claude-plugin. It costs 68 tokens per session (2,276 once invoked), scanned A, original, Apache-2.0.

An expert assistant for building applications that use CockroachDB, a distributed SQL database compatible with many PostgreSQL tools.

In plain words
What is it for?
Use it to design schemas, configure drivers and ORMs, write transaction retry logic, optimize queries, and migrate applications from PostgreSQL or Oracle.
Why use it?
It helps prevent application bugs caused by distributed transactions, poorly distributed keys, incorrect database settings, or inefficient queries.

Agent for Claude Code ✓ vendor

Written for Claude Code: shipped in a Claude Code plugin. Also seen: model in frontmatter.

Part of the cockroachdb plugin — 34 skills, 3 agents, 2 hooks, 2 MCP servers shipped together

Good fit Use it to design schemas, configure drivers and ORMs, write transaction retry logic, optimize queries, and migrate applications from PostgreSQL or Oracle.

Compare 6 agents from other repositories ↓
Install with agentmods
npx agentmods add agents/cockroachdb/claude-plugin/cockroachdb-developer
About the project

CockroachDB Plugin for Claude Code connects Claude Code to CockroachDB clusters, which are distributed databases, so the agent can work with schemas, SQL queries, and database operations. It is intended for developers, database administrators, and operators working with self-hosted or CockroachDB Cloud deployments. The catalogue entries provide its MCP connections, specialized agents, skills, and safety hooks.

cockroachdb/claude-plugin · 4 stars · on GitHub

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Clone the repo
git clone --depth 1 https://github.com/cockroachdb/claude-plugin

Made for: Claude Code.

Or install cockroachdb, the plugin that ships this one along with the rest of its 34 skills, 3 agents, 2 hooks, 2 MCP servers.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for cockroachdb-developer

README.md
[![agentmods](https://agentmods.dev/badge/agents/cockroachdb/claude-plugin/cockroachdb-developer/github.svg)](https://agentmods.dev/agents/cockroachdb/claude-plugin/cockroachdb-developer)
Your own site
<a href="https://agentmods.dev/agents/cockroachdb/claude-plugin/cockroachdb-developer"><img src="https://agentmods.dev/badge/agents/cockroachdb/claude-plugin/cockroachdb-developer/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for cockroachdb-developer

Your own site · 80×15
<a href="https://agentmods.dev/agents/cockroachdb/claude-plugin/cockroachdb-developer"><img src="https://agentmods.dev/badge/agents/cockroachdb/claude-plugin/cockroachdb-developer.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 68 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,276 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00068 $0.02276
Opus 5.5 $0.00027 $0.00910
Sonnet 5.5 $0.00014 $0.00455
Haiku 4.5 $0.00007 $0.00228

Measured 20d ago against content hash ff2baff15c60, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

cockroachdb-developer scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 20d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

agents/cockroachdb-developer.md · 196 lines

How it starts

The opening of the file, as written. The whole thing — 196 lines — stays where its author put it; the contents beside it link to each section on GitHub.

You are a CockroachDB application development expert. You help developers build correct, performant, and resilient applications on CockroachDB.

1. Primary Key Strategy

NEVER use SERIAL, BIGSERIAL, or sequences as single-column primary keys. They create write hotspots because all inserts land on one range/node.

Correct patterns:

  • UUID PRIMARY KEY DEFAULT gen_random_uuid() for most tables
  • Composite keys with well-distributed first column (tenant_id, region) for multi-tenant apps
  • Hash-sharded indexes when sequential ordering is required (timestamps, counters)

JPA/Hibernate identity generators:

  • Use @GeneratedValue(strategy = GenerationType.AUTO) with UUID type -- Hibernate maps to UUIDv4 generator
  • NEVER use @GeneratedValue(strategy = GenerationType.IDENTITY) -- disables batch INSERTs in Hibernate
  • If numeric PKs are required, use a custom generator with unordered_unique_rowid() batched in the JVM
  • Set @GenericGenerator(strategy = "org.hibernate.id.UUIDGenerator") explicitly for clarity

2. Transaction Retry Logic

CockroachDB uses serializable isolation (1SR). Explicit transactions may fail with SQLSTATE 40001 (serialization_failure). ALWAYS implement client-side retry.

Key rules:

  • Retry the ENTIRE transaction (BEGIN to COMMIT), not individual statements
  • NEVER use SAVEPOINT-based retry -- CockroachDB aborts the entire txn on 40001
  • Use exponential backoff with jitter: min(2^attempt + random(0,1000)ms, maxBackoff)
  • Classify errors: 40001 = retry, 40003 = ambiguous (retry if idempotent), others = propagate
  • Implicit (single-statement) transactions are auto-retried server-side (if result < 16KiB)

Spring Boot pattern:

@Aspect
@Order(Ordered.HIGHEST_PRECEDENCE)
public class RetryableAspect {
    @Around("@annotation(transactional)")
    public Object retry(ProceedingJoinPoint pjp, Transactional transactional) throws Throwable {
        for (int attempt = 1; attempt <= MAX_RETRIES; attempt++) {
            try { return pjp.proceed(); }
            catch (TransientDataAccessException ex) {
                if (!"40001".equals(((SQLException) ex.getMostSpecificCause()).getSQLState())) throw ex;
                Thread.sleep(Math.min((long)(Math.pow(2, attempt) + Math.random() * 1000), 15000));
            }
        }
        throw new ConcurrencyFailureException("Max retries exceeded");
    }
}

Read the full file on GitHub · 196 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 20d ago Changed ff2baff15c60
  2. 2mo ago First seen · 196 lines · 68 tokens per session scan A 9c2ad4260e30

Subscribe to this mod's changes

cockroachdb-developer is an agent published in the GitHub repository cockroachdb/claude-plugin (4 stars, last pushed 20d ago), licensed Apache-2.0. It adds 68 tokens to every session and 2,276 once invoked, about $0.0003 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.

Related

Other agents, from other repositories

supabase-architect

Projeta schema + RLS + topologia realtime antes da primeira migration. Entrega plano arquitetural (schema, RLS, realtime, branching). Use ao iniciar app Supabase. Não escreve código. (pesado).

luanpdd/kit-mcp · 50 tokens

evolution-go-integrator

Gera tabelas orgwhatsappconfigs + whatsappmessages, webhook Edge Function e send queue pgmq para WhatsApp (Evolution Go ou Meta Cloud API) em Supabase B2B multi-tenant. (pesado — despacha.

luanpdd/kit-mcp · 53 tokens

cqrs-specialist

Use for event-driven and CQRS work: command/outbox writes, idempotent projectors, and read-model handlers. Domain-neutral; never catches errors inside a transaction boundary.

mnzralee/claude-multi-agent-architecture · 0 tokens

database-session-scaffolder

Copies the databasesession package into the target Database Session directory and ensures the parent extras/init.py re-exports DatabaseSession. Invoke with: @database-session-scaffolder.

voro6yov/spec-driven-development · 49 tokens

backend-architect

Design RESTful APIs, microservice boundaries, and database schemas. Reviews system architecture for scalability and performance bottlenecks. Use PROACTIVELY when creating new backend services or APIs.

einverne/dotfiles · 41 tokens

backend

A back-end development agent for the server-side parts of an application, including APIs, databases, authentication, and infrastructure. An API lets software exchange data, while authentication checks identity and authorization controls access.

workdd/my_claude_code_setting · 89 tokens