From 724639d0433682d15b1a588c6ce48c41d5b7c840 Mon Sep 17 00:00:00 2001 From: Jack Gerrits Date: Tue, 26 Nov 2024 18:40:32 -0500 Subject: [PATCH 1/2] Specify well known topic types for direct agent channel --- docs/design/02 - Topics.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/docs/design/02 - Topics.md b/docs/design/02 - Topics.md index 7d7149c37c9..2d035318a0f 100644 --- a/docs/design/02 - Topics.md +++ b/docs/design/02 - Topics.md @@ -51,3 +51,16 @@ Agents are able to handle certain types of messages. This is an internal detail > [!NOTE] > This might be revisited based on scaling and performance considerations. + +## Well known topic types + +Agents should subscribe via a prefix subscription to the `{AgentType}:` topic as a direct message channel for the agent type. + +For this subscription source should map directly to agent key. + +This subscription will therefore receive all events for the following well known topics: + +- `{AgentType}:` - General purpose direct messages. These should be routed to the approriate message handler. +- `{AgentType}:rpc_request` - RPC request messages. These should be routed to the approriate RPC handler. +- `{AgentType}:rpc_response={request_id}` - RPC response messages. These should be routed back to the response future of the caller. +- `{AgentType}:error={request_id}` - Error message that corresponds to the given request. From 19fdafea875bb32b95bf77e00d47c20c21388688 Mon Sep 17 00:00:00 2001 From: Jack Gerrits Date: Tue, 26 Nov 2024 18:42:12 -0500 Subject: [PATCH 2/2] casing --- docs/design/02 - Topics.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/design/02 - Topics.md b/docs/design/02 - Topics.md index 2d035318a0f..bf3ed8d9dca 100644 --- a/docs/design/02 - Topics.md +++ b/docs/design/02 - Topics.md @@ -62,5 +62,5 @@ This subscription will therefore receive all events for the following well known - `{AgentType}:` - General purpose direct messages. These should be routed to the approriate message handler. - `{AgentType}:rpc_request` - RPC request messages. These should be routed to the approriate RPC handler. -- `{AgentType}:rpc_response={request_id}` - RPC response messages. These should be routed back to the response future of the caller. -- `{AgentType}:error={request_id}` - Error message that corresponds to the given request. +- `{AgentType}:rpc_response={RequestId}` - RPC response messages. These should be routed back to the response future of the caller. +- `{AgentType}:error={RequestId}` - Error message that corresponds to the given request.