Skip to main content

Load Balancing

FastGateway distributes traffic across backend endpoints using a load balancing algorithm you choose in the route builder.

Configure​

In the route builder, open the Traffic tab and expand the Backend Traffic Policy section. Under Load Balancer, pick an algorithm. When you leave it unset, Envoy Gateway defaults to Least Request.

Algorithms​

AlgorithmDescription
Round RobinDistributes requests evenly across all backends in order
Least RequestSends requests to the backend with the fewest active requests
RandomDistributes requests randomly across backends
Consistent HashRoutes requests to the same backend based on a hash key

Consistent Hash Options​

When you select Consistent Hash, choose how the hash key is derived. This maintains session affinity so the same client reaches the same backend.

TypeDescription
Source IPHash based on the client IP address
HeaderHash based on a specific HTTP header value
CookieHash based on a specific cookie value

For Header, enter the header name to hash on. For Cookie, enter the cookie name and an optional TTL.

Consistent hashing is useful for stateful applications and caching efficiency.

The REST API equivalent is documented in the API Reference.