Scope message bus topics by agent name for multi-instance isolation#272
Merged
rockfordlhotka merged 7 commits intomainfrom Apr 14, 2026
Merged
Conversation
…268) Append .{agentName} suffix to all user proxy and subagent topics so multiple RockBot instances can share the same RabbitMQ broker without message collisions. Follows the existing A2A scoping pattern. Agent name is now configurable via Agent:Name (defaults to "RockBot"). UserProxyOptions gains an AgentName property so the Blazor and CLI proxies publish/subscribe to the correct scoped topics. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Proves two agent instances (AgentAlpha, AgentBeta) sharing a single message bus receive only their own messages with no cross-contamination. Tests cover user proxy topics (user.message, user.response) and subagent topics (subagent.progress, subagent.result). InProcess bus tests always run; RabbitMQ variants are gated by ROCKBOT_RABBITMQ_HOST. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
When topic names change (e.g. after the agent-name scoping upgrade), existing durable queues have mismatched x-dead-letter-routing-key arguments. RabbitMQ rejects the re-declaration with 406 PRECONDITION_FAILED. The subscriber now catches this specific error, deletes the stale queue on a fresh channel, and re-creates it with the correct arguments. This makes the upgrade self-healing — no manual queue cleanup needed. Bump version to 0.8.1. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
When Telemetry.ServiceName is not explicitly overridden, it now defaults to the Agent:Name value (e.g. "RockBot", "RockBot-Bob"). This lets Grafana dashboards differentiate between instances without extra config. If Telemetry__ServiceName is set explicitly in the ConfigMap it still takes precedence — the default only applies when it equals "rockbot". Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Move wisp-first guidance into common-directives.md so both the primary agent and subagents default to spawn_wisps for any multi-step workflow. Direct tool calls are reserved for single-call tasks or genuinely dynamic workflows requiring real-time judgment between steps. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
.{agentName}suffix to all user proxy and subagent topics so multiple RockBot instances can share the same RabbitMQ broker without message collisionsAgent:Nameconfig (defaults to"RockBot")agent.task.{agentName})Closes #268
Changes
UserProxyOptions.AgentNameadded so Blazor/CLI proxies target the correct agentdiscovery.announce,agent.task.status, per-proxy response topics) are unchangedMigration
"RockBot")Agent__Name=RockBot-Bobon both agent and proxy podsTest plan
dotnet build RockBot.slnx— 0 errorsdotnet test RockBot.slnx— all tests pass (0 failures)Agent:Namevalues on same RabbitMQ🤖 Generated with Claude Code