Repository navigation
Each cluster now has a placement mode and policy, and BetterDB holds a slot move back while the cluster is unhealthy. Large clusters are cheaper to watch: cluster-wide checks and topology reads run once per cluster, and one failover sends one cluster.failover event instead of one per node. Cluster alerts now name the node at fault, and the Cluster page has a Disagreements tab for nodes that see the cluster differently.
Upgrade notes
- Placement mode: clusters you already had start in Recommend, so their plans and the run button stay. Clusters added after the upgrade start in Observe, which hides plans and refuses runs with
403 observe_mode. Switch the mode on the Cluster page's Slot placement card. Moves still needBETTERDB_SLOT_MIGRATION=true. - New settings:
CLUSTER_NODE_COMMAND_TIMEOUT_MS(default5000),LATENCY_REGRESSION_IGNORE_COMMANDS(unset keeps the built-in list, empty turns the filter off),LATENCY_REGRESSION_EXTRA_IGNORE_COMMANDS(default empty) andPLACEMENT_ACTION_RETENTION_DAYS(default 90). - Fewer events: one failover now sends one
cluster.failoverper cluster, and a single-connection setup gets one webhook per outage instead of two. Cluster-wide alerts are raised once per cluster and stored under the seed connection, so a list filtered to another node's connection no longer shows them. - Partial joins: a node only part of the cluster knows now raises
partial_membershipafter 90 s instead oftopology_divergenceafter 60 s. Update anything that matches on the old type. - Latency regressions no longer report admin and monitoring commands such as
infoandcluster|nodes. Open events for them stay until you resolve them. - Helm: unknown
service.*keys now failhelm installandhelm upgrade, and Service annotation and label values must be strings (use--set-string). - npm package:
@betterdb/monitornow needs Node.js 22 or later. The agent and MCP images move fromnode:20-alpinetonode:26-alpine, and the agent image no longer ships npm. - Storage: on startup BetterDB adds the
placement_policies,placement_actions,placement_stepsandplacement_lockstables and ananomaly_events.nodecolumn.activity_eventsis upgraded to acceptsystemandanonymousactors, which rebuilds the table on SQLite. - No new ACL permissions are needed.
Slot placement (#763, #764, #769, #770, #773, #774)
- Modes and support: each cluster runs in Observe or Recommend. The Slot placement card shows shard balance against the median and lists every reason a cluster can't take slot moves, such as a managed provider, missing slot stats, version or ACL. Approve and Auto are shown but can't be picked yet. MCP tool
get_placement_statusreturns the same. - Policy: admins edit a per-cluster policy from Edit policy: resolve ratio, node CPU limit, and excluded shards and slots. Saves are versioned and logged as
placement.policy. - Sustained load: a shard triggers only when its load stays high for most of
sustainMinutes, so short peaks don't. This only decides when a plan is offered; nothing moves on its own. The card shows a Sustained badge or the warm-up time. - Safety gate: a move waits while a node is failed or suspect, a migration is running, or there are open failover, fork, latency or replication events, and the card says what it waits for. A blocked run answers
403withblockedBy: "gate". - Hash tags: a hot shard now says when one hash tag or one crowded slot holds the load, since moving slots can't split those keys. No LFU policy is needed.
- Stored actions: slot moves, their steps and per-node cluster locks are now stored, so two moves never touch the same nodes at once and the hourly budget holds across restarts.
Cluster health
- Disagreements tab (#746, #747, #748): the Cluster page summarises where node views disagree, one line per disagreement with the count of views on each side and one row per shard. Ask every node reads every node's view once instead of a sample. MCP tool
get_topology_disagreementsreturns the summary. - Partially known nodes (#740, #741):
partial_membershipnames the peers that know the node and those that don't, plus theCLUSTER MEETcommand that repairs it. BetterDB never runs it. - Node at fault (#744, #745, #750): cluster anomaly events carry a
nodeobject (id, address, role, shard, zone). It is sent inanomaly.detected, failover, data loss, retry amplification and replication webhooks, in Slack and Discord messages and in MCP results. Alerts link to the node on the Cluster page, where an admin can Connect to this node if BetterDB doesn't collect it yet.
Large clusters (#738, #752, #759, #761, #766, #767, #768)
- Every primary is checked: past 64 primaries they are read in rotation instead of being skipped.
betterdb_anomaly_fanout_sweep_secondsshows how long a full sweep takes. - Once per cluster: one connection per cluster runs the cluster-wide checks. With more than nine connections the others read
CLUSTER NODESin turns, and the reader reads it every 5 seconds instead of every poll. - Hung nodes: a node that accepts connections but stops answering no longer stalls polling. Per-node commands time out after
CLUSTER_NODE_COMMAND_TIMEOUT_MS, the node is skipped for 30 s, and a silent database raisesinstance.downwithDatabase ping timed out.
Other changes
- Helm chart (#756): the chart is now released with every app release at the same version, to both the classic repo at
https://docs.betterdb.com/chartsandoci://ghcr.io/betterdb-inc/charts. 0.57.0 is the first release in the classic repo since 0.51.1. New Service options:nodePort,annotations,labels,loadBalancerClass,loadBalancerSourceRangesandexternalTrafficPolicy. - OpenEverest (#760): BetterDB can be added as an OpenEverest plugin for Valkey instances, with read-only agent connections. It ships separately as agent 1.9.0 and the
betterdb-openeverestchart 0.1.0; see docs/install/openeverest.md. The same PR fixes cluster mode detection in the classic agent. - npm package startup (#775):
npx @betterdb/monitorfailed withCannot find package 'better-auth'in every release since #432. It now starts, and--no-setupwithout a saved config starts on defaults. MCPstart_monitorandstop_monitoralso work again. - Agent reconnects (#754): a reconnected agent is no longer dropped when its old socket closes later. Two agents sharing a token now leave one connected instead of swapping.
- Rebalance targets (#743): a target with
maxmemory 0gets amemory_unlimitedwarning instead of "memory room is not known". - Security (#775): patched dependency and image findings (effect, glob, minimatch, hono, follow-redirects, openssl and others). Known issue: musl CVE-2026-107891 remains in all Alpine images until a fixed Alpine stable release ships.