Comment

Comment by SgtBastard

>A load balancer only works together with servers running the same code.

Uh - what?

>A load balancer balances traffic between servers

Correct.

> of the same service or mononlith

Incorrect.

Load balancers used to work solely at Layer 4, in which case you’d be correct that any 80/443 traffic would be farmed across servers that would necessarily need to run the same code base.

But modern load balancers (NGINX et al) especially in a service mesh / Kubernetes context, balance load at endpoint level. A high traffic endpoint might have dozens of pods running on dozens of K8s hosts having traffic routes to them by their ingress controller. A low traffic endpoint’s pod might only be running on few or one (potentially different) hosts.

The load balancer internally makes these decisions.

I hope this clears up your misunderstanding.

parent SgtBastard 3 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton