Skip to content

[proposal] High availability strategy for Redis and RabbitMQ (investigation) #32

Description

@henzigo

Context

Redis and RabbitMQ run single-replica. A node failure means losing the cache and the
message broker until rescheduling; a drain means a full outage of both. Redis persistence is
intentionally disabled (appendonly no, save "") but that decision is undocumented.

Proposal (investigation, decision record as output)

Primary direction: adopt existing, maintained charts/operators instead of extending our own
templates.
The helmfile composition makes this natural — a third-party chart is just another
release in helmfile.yaml.gotmpl (like shopsys-infra today), values stay in our
environments layering, and we stop maintaining Redis/RabbitMQ manifests ourselves.

Candidates to evaluate:

RabbitMQ

  • RabbitMQ Cluster Operator
    (official, free) — cluster CRD, quorum queues, rolling upgrades; needs the operator as a
    cluster-wide prerequisite
  • Bitnami rabbitmq chart — ⚠️ see the Bitnami caveat below
  • keep our StatefulSet only if the decision is "single replica is fine"

Redis

  • Bitnami redis chart (master-replica + Sentinel) — ⚠️ Bitnami caveat below
  • OT-ContainerKit Redis Operator or
    Spotahome redis-operator
  • keep our Deployment if the decision is "ephemeral single-replica cache is fine"
    (then just document it — cheapest correct outcome)

⚠️ Bitnami caveat (2025): Bitnami moved its free public images to the unmaintained
bitnamilegacy registry; the charts default to images that now require a Bitnami Secure
Images subscription. Evaluating Bitnami charts must include the image-source question
(subscription, legacy tags, or overriding with upstream redis/rabbitmq images — which the
charts support but which loses part of their value).

Evaluation criteria

  • migration path from today's installs: resource names/labels differ (redis,
    rabbitmq, PVC rabbitmq-data-rabbitmq-0) → RabbitMQ data migration or blue/green
    switchover needed; Service names/DSNs consumed by the app must stay stable
    (redis:6379, rabbitmq:5672) or be remapped via values
  • operational cost: operator lifecycle vs chart-only; upgrades; monitoring integration
    (we already scrape exporters — [observability] ServiceMonitors, logging annotations and deploy metadata #39)
  • parity constraints: management ingress + IP whitelist, prometheus-exporter labels,
    the deploy-order guarantee (infra release ready before migration hook) must hold for
    whatever replaces shopsys-infra
  • does the shop actually need HA here? (failure-mode analysis first — the outcome may be
    "document and accept single replica", which keeps our small templates and costs nothing)

Deliverable: decision record in docs/ + follow-up implementation issues per outcome.

Tasks

  • Failure-mode analysis (what breaks for the shop when redis/rabbitmq are down N minutes)
  • Evaluate RabbitMQ Cluster Operator and a Redis chart/operator against the criteria above
    (incl. the Bitnami image-source question)
  • Migration/switchover plan sketch for existing installs
  • Decision record + follow-ups

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions