feat(hyperion): multi-tenant DynamoDB runtime + AgentCore/Hyperion extensions - #1
Merged
Merged
Conversation
adhajar-amzn
force-pushed
the
feat/hyperion-multi-tenant
branch
from
March 11, 2026 16:54
8de8cc6 to
81ed699
Compare
…and unit tests Multi-tenant DynamoDB integration layer (src/hyperion/): - TenantConfigLoader: loads tenant_config + channel links + credentials, assembles OpenClawConfig - HyperionDynamoDBClient: DDB operations for all 4 tables with multi-agent composite keys - HyperionPairingStore: pairing code CRUD with 5-min TTL and retry logic - SessionManager: session key parsing, tenant/agent ID extraction, memory namespacing - UserCredentialStore: KMS envelope encryption for per-user API keys AgentCore ACP extension (extensions/agentcore/): - AgentCoreRuntime: implements OC AcpRuntime interface (ensureSession, runTurn, cancel, close) - Pre-turn: loads tenant context + retrieves memory in parallel - Post-turn: fires memory extraction job (fire-and-forget) - Error classification: throttling, resource not found, service unavailable - Config loader: SSM parameter-based configuration with local override support Hyperion gateway plugin (extensions/hyperion/): - Plugin entry that registers createHyperionPluginService() - Creates AWS SDK clients, calls createHyperionRuntime(), stores as global singleton - Stage resolution from plugin config / HYPERION_STAGE / STACK_NAME Nova channel integration: - monitor.ts loads per-tenant config via getHyperionRuntime() on each inbound message Unit tests (158 tests across 6 files): - Vitest 4.x compatible mocks (regular functions for constructors) - Properly typed test helpers, zero as-any casts Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
adhajar-amzn
force-pushed
the
feat/hyperion-multi-tenant
branch
from
March 11, 2026 17:00
81ed699 to
7edb5c3
Compare
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
Adds the multi-tenant infrastructure layer for the Nova Personal Assistant Platform. Replaces filesystem-based config with DynamoDB-backed tenant resolution, enabling 10K+ users on a shared OC Gateway deployment.
src/hyperion/— Core runtime layer: DynamoDB client (4 tables), tenant config loader with LRU cache, channel identity resolver, session manager with composite keys (tenant_{userId}:{agentId}:{rest}), KMS-encrypted credential store with per-agent +__shared__fallback, pairing code generation/redemptionextensions/agentcore/— ACP runtime plugin for Bedrock AgentCore: session management, agent turn dispatch, memory namespace isolation (tenant_{userId}:{agentId})extensions/hyperion/— Gateway plugin that initializes the multi-tenant runtime at startup fromHYPERION_STAGEenv varextensions/nova/src/monitor.ts— Integrates per-tenant config loading in message handler; loads from DynamoDB in multi-tenant mode, falls back to static config + allowlist in single-tenant modeconfig/openclaw.json5— Base gateway config for ECS deployment (bind, auth, trustedProxies, ACP backend, JSON logging)Multi-instance agents
Each user can run multiple independent agent instances (e.g., "Work Assistant", "Personal"). Default
agent_id = "main"for single-instance backwards compatibility. Composite keys (user_id + agent_id) are threaded through all data access, session keys, and memory namespaces.Data flow
Test plan
npx tsc --noEmitpasses (type-check)pnpm test)__shared__)src/hyperion/are tracked as follow-up (TASK-25)🤖 Generated with Claude Code