HA by default and per-machine tuning: how WPECS turns delivery know-how into platform behaviour
Install the same Kafka or MySQL and the reliability of what a senior engineer delivers can be worlds apart from what a newcomer delivers. The difference comes down to two things: how high availability is set up and how parameters are configured. WPECS makes both the default.
High availability by default
In WPECS, when there are enough hosts, solutions are highly available by default, with nothing extra to tick:
| Component | Default HA layout |
|---|---|
| Nginx / HAProxy | Keepalived VIP primary/backup, with dual-NIC dual VIPs and policy routing |
| MySQL | Dual primary plus VIP |
| Redis | Primary/replica with Sentinel, or Cluster |
| MongoDB | Replica set |
| Hadoop / HBase | NameNode and ResourceManager standby with ZKFC and 3 JournalNodes; a standby HBase Master |
| Apache Doris | 3 FEs plus N BEs |
| Nacos | 3-node Raft |
| Kafka | Multiple replicas (ZooKeeper or KRaft mode) |
| MinIO / FastDFS | Distributed erasure coding / two trackers with storage in the same group |
| ClickHouse / PostgreSQL | Keeper with replicas / streaming replication |
For components with a VIP, the top of the deployment page lists the addresses to use through the VIP, and multi-node components get generated cluster connection strings (such as ZooKeeper and Kafka bootstrap addresses), which also appear in the maintenance manual and delivery report. Clients connect to a single address.
Per-machine adaptive tuning
Memory parameters show as "auto" in the form by default (0 or empty) and are calculated per machine at deployment time:
- Subtract the system reserve to get the memory budget this machine can give to components;
- share it by the resource weights of co-located components, including components from other deployments on the same machine, so the total never overcommits;
- apply component-specific ratios with lower and upper bounds, so small machines never get unusable values and large machines never get wasteful ones;
- size thread counts by CPU cores, and tune IO parameters for SSDs or spinning disks.
Take ZooKeeper: the heap defaults to 60% of the machine's memory budget, at least 1 GB (512 MB on hosts with under 4 GB) and at most 2 GB (adjustable in advanced settings; 4 GB is recommended for large clusters with many Kafka partitions or HBase regions); a manual value may not exceed half of the machine's memory; the heap is fixed (Xms equals Xmx) with a G1 pause target of 100 ms; and jute.maxbuffer defaults to 4 MB on both the server and zkCli.
Every calculated value is written to the deployment log with a "tuning" prefix. Any parameter you fill in yourself wins: automatic is the default, not a requirement.
Kernel profiles
The node initialization component picks a kernel profile based on the kind of load on each host; database hosts, for example, get transparent huge pages disabled, swappiness=1 and the performance CPU governor. It also sets up log rotation and cleanup so disks do not fill up with logs a few months later.
Firewall policies
You choose a firewall policy at deployment time: allow only gateway ports (with traffic open inside the cluster, the default), allow all component ports, allow the cluster plus specific IPs, or leave the firewall alone. WPECS only adds rules and never deletes existing ones, and the policy can be reapplied or changed later under Upgrade / scaling / backup, Firewall policy. If a VIP is still unreachable with the host firewall open, check whether switches, cloud security groups or the virtualization platform allow the VIP (OpenStack, for example, needs allowed-address-pairs).
Rolling upgrades and scaling
The point of high availability is to change things without downtime. WPECS rolling upgrades:
- download the new version first while the old service keeps running;
- upgrade node by node with a health check after each, rolling back automatically on failure;
- upgrade node 1 last, optionally back up first, and keep the evidence for database components that fail so a person can decide what to do;
- roll membership configuration when scaling out, remove only trailing nodes when scaling in, and check quorum so a cluster is never shrunk below the point where it can elect a leader.
Backup and restore
Operations policies support cron-scheduled inspections (with notification on low scores) and backups (mysqldump, Redis RDB, snapshots and more, kept by count and age); runs missed while the platform was down are made up once it is back. MySQL, PostgreSQL, MongoDB, Redis (standalone), TDengine, EMQX and Grafana support one-click data restore, and other components support configuration restore. The current data is backed up before restoring, a health check runs afterwards, and you must type the deployment name to confirm; if you are unhappy with the result, restoring the backup taken "before restore" puts everything back.
In short
HA layouts, parameter formulas, kernel profiles and change procedures used to live in senior engineers' heads and their personal scripts. WPECS writes them into its component standard and its defaults, so every delivery starts from the same baseline. Learn more on the WPECS product page.