Skip to main content

redis

Multi-purpose key-value store. Holds the kill-switch flag, the BFF session store (Phase 5+), the Celery broker / result backend, the semantic LLM cache, the HierarchicalRAG index, the MetadataPrefetcher cache, and the per-cell pub/sub fan-out for WebSocket progress streams.

Identity

FieldValue
Service idredis
Rolecache
Imageredis:7-alpine (compose master) / redis-stack:7.4.0-v3 (local — adds RedisJSON + RedisSearch)
Port6379
Storage2 Gi PVC (cell-local); ElastiCache (AWS) / Memorystore (GCP) / Azure Cache (Azure) in cloud templates

Deployment surfaces

SurfaceWhere
Composeservice redis in alphaswarm_platform/compose/docker-compose.yml; redis-stack in deployments/compose/docker-compose.local.yml
Kustomizedeployments/kubernetes/base/redis-master/ — single master per cell; base-services/redis-shared/ — shared replica set
Terraform modulealphaswarm_platform/terraform/modules/storage/ — managed cache per cloud

Key namespaces

PrefixOwnerPurpose
alphaswarm:kill_switchWorkloadRuntime, TerraformRuntimeGlobal halt flag — every state-mutating runtime checks before acting
celery:*Celery brokerQueue names per family (default, backtest, agents, ...)
bff:session:*alphaswarm-cp BFFPhase 5 session store (sid → IdP token)
m2m:tokens:*alphaswarm-cp auth brokerM2M token cache
cache:llm:*alphaswarm-coreSemantic LLM cache
cache:metadata:*MetadataPrefetcherEntity dropdown cache
rag:*HierarchicalRAGEmbedding index
pubsub:progress:<task_id>alphaswarm._progressWebSocket fan-out frames

Dependencies

Upstream: none.

Downstream: every runtime pod (alphaswarm-core, alphaswarm-worker, alphaswarm-beat, alphaswarm-cp, bots).

Operations

  • Eviction policy: allkeys-lru for caches; noeviction for Celery to avoid silent task drops.
  • HA: in-cell single master; cloud templates use managed Redis with multi-AZ replicas.
  • Kill-switch: the key is intentionally simple — set to any truthy value halts; the runtime polls every state-mutating action.
  • Persistence: AOF every second + RDB snapshot every 5 min.

See also