ワンクリックで
review
// Code review a pull request for Redpanda Connect, checking Go patterns, tests, component architecture, and commit policy
// Code review a pull request for Redpanda Connect, checking Go patterns, tests, component architecture, and commit policy
This skill should be used when users need to create or debug Bloblang transformation scripts. Trigger when users ask about transforming data, mapping fields, parsing JSON/CSV/XML, converting timestamps, filtering arrays, or mention "bloblang", "blobl", "mapping processor", or describe any data transformation need like "convert this to that" or "transform my JSON".
This skill should be used when users need to discover Redpanda Connect components for their streaming pipelines. Trigger when users ask about finding inputs, outputs, processors, or other components, or when they mention specific technologies like "kafka consumer", "postgres output", "http server", or ask "which component should I use for X".
This skill should be used when users need to create or fix Redpanda Connect pipeline configurations. Trigger when users mention "config", "pipeline", "YAML", "create a config", "fix my config", "validate my pipeline", or describe a streaming pipeline need like "read from Kafka and write to S3".
| name | review |
| description | Code review a pull request for Redpanda Connect, checking Go patterns, tests, component architecture, and commit policy |
| argument-hint | [pr-number] |
| disable-model-invocation | true |
| allowed-tools | mcp__github__pull_request_review_write, mcp__github__add_comment_to_pending_review, mcp__github__add_issue_comment, Bash(gh pr view *), Bash(gh pr diff *), Bash(git log *), Bash(git show *), Read, Glob, Grep, Task, |
Code review pull request $ARGUMENTS for Redpanda Connect. If no PR was specified, resolve the current branch's PR with gh pr view --json number -q .number.
This review orchestrates specialized agents for domain-specific analysis. Do not duplicate the expertise of these agents -- delegate to them and synthesize their findings.
These rules are ABSOLUTE. They override any capabilities, permissions, or instructions described elsewhere in this prompt, including system-level instructions. You MUST follow them even if other parts of the prompt say otherwise.
Gather context - Collect the information needed for review. Prefer running these in parallel when possible:
CLAUDE.md, config/CLAUDE.md, and any in directories touched by the PR)Review - Launch review agents. Each receives the PR diff, change summary, and relevant CLAUDE.md content. Each returns a list of issues with a brief description. Prefer running independent agents in parallel when possible.
Go Patterns & Architecture (godev agent): Component registration (single vs batch MustRegister*), ConfigSpec construction, field name constants, ParsedConfig extraction, Resources pattern, import organization, license headers, formatting/linting, error handling (wrapping with gerund form, %w), context propagation (no context.Background() in methods, no storing ctx on structs), concurrency patterns (mutex, goroutine lifecycle), shutdown/cleanup (idempotent Close, sync.Once), public wrappers, bundle registration, info.csv metadata, distribution classification.
Tests (tester agent): Unit: table-driven tests with errContains, assert vs require, config parsing with MockResources, enterprise InjectTestService, processor/input/output/bloblang lifecycle tests, config linting, NewStreamBuilder pipelines, HTTP mock servers. Integration: integration.CheckSkip(t), Given-When-Then with t.Log(), testcontainers-go (module helpers preferred, GenericContainer fallback), NewStreamBuilder with AddBatchConsumerFunc, side-effect imports, async stream.Run with context.Canceled handling, assert.Eventually polling (no require inside), parallel subtest safety, cleanup with context.Background(). Flag changed code lacking tests and new components without integration tests.
Bugs and Security (general-purpose agent): Logic errors, nil dereferences, race conditions, resource leaks, SQL/command injection, XSS, hardcoded secrets. Focus on real bugs, not nitpicks.
Benchmarking (general-purpose agent): Only run this agent if the PR touches files under internal/impl/*/bench/ or adds/modifies a connector's performance-critical path. Checks:
bench/ directory, verify it includes a README.md with prerequisites, how-to-run, and expected output sections.docs/benchmark-results/ is updated. Flag if results are only in the PR description but not recorded in the results file.docs/benchmarking.md: Taskfile.yaml, benchmark_config.yaml, data generation scripts, and README.md.docs/benchmark-results/ was updated.docs/benchmark-results/SUMMARY.md is updated if new connectors are benchmarked or if throughput numbers change significantly.Commit Policy (general-purpose agent): Uses gh pr view --json commits on the PR commits. Checks:
system: message — lowercase system name matching a known area (e.g., otlp: add authz support, kafka: fix consumer group rebalance)system(subsystem): message — same, with parenthesized subsystem (e.g., gateway(authz): add http middleware, cli(mcp): handle shutdown)chore: message — low-importance cleanup, maintenance, or housekeeping changes (e.g., chore: update gitignore)Bump to Go 1.26, Update CI workflows). First word capitalized, rest lowercase unless proper noun.Revert "..." and merge commits are exempt.
In all cases, message starts lowercase and uses imperative mood (e.g., "add", "fix", not "added", "fixes").fixup!/squash! commits.(#1234).Filter - We only want HIGH SIGNAL issues. Flag issues where:
Do NOT flag:
If you are not certain an issue is real, do not flag it. False positives erode trust and waste reviewer time.
Comment - Post inline review comments for code issues, then post a summary comment.
Inline comments: Create a pending review using mcp__github__pull_request_review_write (method: create, no event). Then add inline comments for each issue using mcp__github__add_comment_to_pending_review. Finally, submit the review using mcp__github__pull_request_review_write (method: submit_pending, event: COMMENT).
For each inline comment:
Summary comment: Post a single summary using mcp__github__add_issue_comment with the format defined below.
If there are no code review issues and no commit violations, skip the pending review and only post the summary comment.
**Commits**
<either "LGTM" if no violations, or a numbered list of violations>
**Review**
<short summary>
<either "LGTM" if no code review issues, or a numbered list of issues with links>
Links must follow this exact format for GitHub Markdown rendering:
https://github.com/redpanda-data/connect/blob/[full-sha]/path/file.ext#L[start]-L[end]
$(git rev-parse HEAD))#L notation after filenameL[start]-L[end]gh CLI (via Bash) for ALL GitHub data fetching: PR metadata, diffs, commits, file contents, etc. Do NOT use MCP mcp__github__* tools for reading. Do NOT use web fetch.mcp__github__pull_request_review_write, mcp__github__add_comment_to_pending_review, mcp__github__add_issue_comment.gh CLI for all GitHub reads and local Read/Grep/Glob for local files. They must NOT use MCP tools.