Skip to content

Horizontal vs vertical scaling on Jelastic PaaS — when to add nodes, when to resize

The rules of thumb for deciding whether your next scaling event should add a node or grow the existing one — with the failure modes that come from picking the wrong axis.

Your application layer on Jelastic is sitting at two nodes, each at 70% CPU at peak, and Friday’s marketing push is forty-eight hours away. The dashboard offers two buttons — “Add Node” and “Change Cloudlets” — and the team is split. Half want to add a third node “for headroom.” Half want to bump the existing two from 16 to 32 cloudlets “because that’s faster to do.” Both can be correct. Both can be wrong. The question is what’s actually constraining the system, not which button is closer to the cursor.

What’s happening

Horizontal scaling (more nodes) and vertical scaling (bigger nodes) solve different problems even though they both reduce the per-request load on any single process. The decision tree comes down to four signals, not just CPU%.

Add a node when:

  • The workload is stateless and parallelizable — HTTP request handlers, queue workers, anything where N+1 instances genuinely share load. App tiers behind a load balancer are the canonical case.
  • You need availability — one node means one fault domain. Two nodes is the minimum for “we can lose one and not page anyone.” Three is the minimum for “we can lose one during maintenance and still tolerate a fault.”
  • The bottleneck is connection concurrency, not raw compute — each Node.js or Python process has a practical concurrency ceiling that more RAM doesn’t fix. More processes, on more nodes, does.
  • You’re approaching the cloudlet ceiling of a single node — Jelastic node sizes top out, and once you’re past that, vertical isn’t an option even if you wanted it.

Resize the node when:

  • The workload is stateful or has expensive warm caches — a Postgres primary, a Redis with 40 GB of working set, a JVM that needs 12 GB of heap to avoid GC pauses. Adding a second primary doesn’t make sense; adding a replica is a different conversation about read scaling.
  • The bottleneck is single-thread CPU or single-process memory — long-running aggregations, batch jobs that can’t be sharded, AI inference workers holding a large model in RAM.
  • You’d otherwise add a node for a single workload spike that disappears in two hours — provisioning, warming, and de-provisioning a fresh node has fixed overhead. Resizing existing nodes for the duration, then resizing back, is often cheaper in operator time.
  • The application doesn’t actually scale horizontally — legacy monoliths with in-process session state, file system caches that assume one host, or licensed software with per-instance fees. The honest answer is to grow vertically until you can rewrite the part that doesn’t scale out.

The trap on Jelastic specifically is that “Change Cloudlets” is fast and reversible, so teams default to vertical scaling for problems that need horizontal scaling — and end up with one expensive node carrying availability risk that two cheaper nodes wouldn’t have.

How to verify

Look at three numbers before you scale, not just CPU:

# 1. P95 latency vs P50 latency — if P95 is climbing but P50 is flat,
#    you have a queueing problem (add nodes), not a per-request CPU problem
curl -s http://localhost:9090/api/v1/query \
  --data-urlencode 'query=histogram_quantile(0.95, sum(rate(http_request_duration_seconds_bucket[5m])) by (le))'

# 2. Per-process memory headroom — a Node.js process at 1.4 GB on a node
#    with 2 GB available is going to OOM during a spike. Vertical scale.
ps -eo pid,rss,comm --sort=-rss | head -20

# 3. Active connections vs configured worker pool — if you're saturating
#    the worker count (PHP-FPM pm.max_children, Node cluster workers,
#    Puma threads), more nodes give you more workers. More RAM does not.
echo 'show pools' | psql -h pgbouncer -p 6432 pgbouncer

If P95 is bad and P50 is fine, you have a concurrency problem: scale horizontally. If P50 and P95 are both bad and CPU on each request is high, you have a per-request CPU problem: scale vertically. If memory per process is the issue, vertical. If memory across processes (more workers) is the issue, horizontal.

The fix

Three rules we apply on managed PaaS estates:

  1. Default to horizontal for the application tier. Web frontends, API workers, queue consumers, anything stateless. Minimum two nodes for any production environment, always. Vertical scaling of a stateless tier should be the exception, not the default.
  2. Default to vertical for the data tier. Postgres primary, Redis, Elasticsearch master nodes. Horizontal scaling here means adding replicas (read scaling, HA), not splitting writes — and that’s a deliberate architecture call, not a Friday-afternoon resize.
  3. Set the cloudlet ceiling before you hit it. Decide what the maximum node size is for each layer in advance. When the existing two nodes can’t be resized further, the only path is horizontal — and you don’t want to be making that architectural decision under load.

If your stack is sitting on Jelastic and the wrong scaling axis is being picked because nobody’s owning the rules, our Cloud PaaS team builds the scaling matrix per layer and runs it under environment management. Start a scoping call and we’ll walk through your current topology.