Skip to content

fix(trogonstack-nats): derive topology from channel contracts - #116

Merged
yordis merged 1 commit into
mainfrom
yordis/docs-nats-channel-principles
Nov 12, 2026
Merged

yordis merged 1 commit into
mainfrom
yordis/docs-nats-channel-principles

Conversation

@yordis

@yordis yordis commented Nov 12, 2026 •

Copy link
Copy Markdown
Member
  • A subject name should identify the message without requiring a request/reply prefix.
  • Channel behavior and provisioned resources should define topology instead of subject spelling.
  • Syntax validation should not be mistaken for proof of stream isolation or responder readiness.

Note

Low Risk
Documentation and example fixture updates only; no application or infrastructure code changes.

Overview
Reframes the nats-design-subject skill so channel behavior (request/reply, live signal, durable event/work) is documented separately from subject spelling, and topology is inferred from contracts plus provisioned resources (e.g. NACK streams), not from tokens like .rpc. or request.

Terminology and examples are aligned across SKILL.md, channel-contract.md, patterns.md, fixtures, and AsyncAPI fragments: RPC → request/reply, health channel gateway.health.v1.check (no required .rpc. segment), and stream name GITHUB_PRIMARY in samples.

Guidance is tightened around comparing request subjects against JetStream stream filters so health/request traffic is not accidentally captured by ingress wildcards, flexible design output instead of a fixed markdown template, and explicit limits that the bundled subject validator does not prove overlap, permissions, or responder readiness.

Reviewed by Cursor Bugbot for commit c6ec902. Bugbot is set up for automated code reviews on this repo. Configure here.

Signed-off-by: Yordis Prieto <yordis.prieto@gmail.com>
@coderabbitai

coderabbitai Bot commented Nov 12, 2026 •

Copy link
Copy Markdown

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The NATS subject-design skill and references update request/reply terminology and subject examples. They also clarify stream-filter and resource-ownership guidance, and revise topology readback and validator-scope instructions.

Changes

NATS Subject Design Guidance

Layer / File(s) Summary
Request/reply contract and subject examples
plugins/trogonstack-nats/skills/nats-design-subject/SKILL.md, plugins/trogonstack-nats/skills/nats-design-subject/references/channel-contract.md, plugins/trogonstack-nats/skills/nats-design-subject/references/patterns.md, plugins/trogonstack-nats/skills/nats-design-subject/references/gateway-asyncapi-fragments.yaml, plugins/trogonstack-nats/skills/nats-design-subject/references/subject-fixtures.yaml
The guidance treats request/reply as message behavior and uses concrete operation subjects. The health request example and related fixtures now use gateway.health.v1.check.
Stream filters and resource ownership
plugins/trogonstack-nats/skills/nats-design-subject/SKILL.md, plugins/trogonstack-nats/skills/nats-design-subject/references/channel-contract.md
The guidance compares request subjects with stream filters. It states that GitOps applies NACK resources, the gateway publishes ingress events, and the request/reply channel has no NACK resource.
Topology output and readback
plugins/trogonstack-nats/skills/nats-design-subject/SKILL.md, plugins/trogonstack-nats/skills/nats-design-subject/references/channel-contract.md
The output guidance requests a traceable topology. The readback example describes request and reply subjects, responder, and storage. The validator limitations now include stream overlap, permissions, responder availability, and deployed topology.

Estimated code review effort: 2 (Simple) | ~12 minutes

Change: Other

Possibly related PRs

Merge Risk: Minimal · up to c6ec9

This is a documentation and example update that clarifies request/reply subject guidance. No actionable merge-blocking risk remains.

Pre-merge checks: Passed 4

Check name Status Explanation
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Title check Passed The title names the main change: deriving topology from channel contracts instead of subject spelling. It has a conventional type prefix and a clear scope. The title uses a "fix" type, but the changes…
Description check Passed The description states three points: subject names should not need a request/reply prefix, channel behavior and provisioned resources should define topology, and syntax validation does not prove strea…
Full details: Title check

Explanation

The title names the main change: deriving topology from channel contracts instead of subject spelling. It has a conventional type prefix and a clear scope. The title uses a "fix" type, but the changeset is documentation only. That mismatch does not make the title unrelated to the changes.

Full details: Description check

Explanation

The description states three points: subject names should not need a request/reply prefix, channel behavior and provisioned resources should define topology, and syntax validation does not prove stream isolation or responder readiness. Each point matches the skill, reference, and fixture changes. The description also lists the Overview of renamed health subject, aligned terminology, and tightened validation guidance.

Finishing Touches

Generate unit tests (beta)

  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

A rabbit checks the subject trail,
Through inbox paths and filters pale.
The health request hops without “.rpc,”
While stream rules mark each message stop.
The burrow maps what’s known and shown,
Then nibbles carrots, pleased with tone.

Recent review info

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 9057f805-197e-4470-ad82-3f86164bb412
Commits

Reviewing files that changed from the base of the PR and between 4ea9ce3 and c6ec902.

Files selected for processing: 5

  • plugins/trogonstack-nats/skills/nats-design-subject/SKILL.md
  • plugins/trogonstack-nats/skills/nats-design-subject/references/channel-contract.md
  • plugins/trogonstack-nats/skills/nats-design-subject/references/gateway-asyncapi-fragments.yaml
  • plugins/trogonstack-nats/skills/nats-design-subject/references/patterns.md
  • plugins/trogonstack-nats/skills/nats-design-subject/references/subject-fixtures.yaml

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

@yordis yordis changed the title docs(trogonstack-nats): derive topology from channel contracts fix(trogonstack-nats): derive topology from channel contracts Nov 12, 2026
@yordis
yordis merged commit 3bc49a9 into main Nov 12, 2026
7 of 10 checks passed
@yordis
yordis deleted the yordis/docs-nats-channel-principles branch November 12, 2026 04:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant