ADC Backends

Nova ADC nodes use Backends to discover what servers to send the traffic to once processed. In it's most simple form a backend is one or more IP addresses that Nova load balances to. These can also be discovered in more advanced ways.

Simple Backend

The default backend for most Nova clients, the Simple Backend is a list of IP addresses and ports to send traffic to from a Nova ADC. In the example of a webserver, this would be a list of backends like so:

We also allow specifying weights and backup/primary servers on Simple Backends.

DNS resolved Backend

DNS backends allow you to use hostnames to resolve backend servers. The main difference between this backend and using a hostname in the simple backend is the lifetime of the result. In AWS, Azure, and other use cases the IP address of a hostname may change - and this backend mode makes the ADC recheck the DNS name every health check interval.

This allows for dynamic backends in your configuration. The other options from the Simple Backend still apply.

You will also configure resolvers for this backend, where you specify which DNS servers to use in order to perform the lookups. Note that in cloud environments you must use the appropriate ones to have internal traffic routing.

You can configure the number of seconds to cache replies for, allowing you to set a TTL.

Cloud API Backend

Cloud API backends vary by the cloud provider but the general idea is to use an API to discover which servers to send traffic to, as opposed to IP addresses or hostnames.

An example of this is in Amazon AWS. If you have autoscaling enabled for a set of servers they may scale up or scale down and the ADC will not know of the change in servers.

With Nova you can instead direct traffic to an AWS AMI ID. This means it will auto discover any servers and dynamically adjust your traffic as you scale.

Cloud Method
AWS EC2 Based on AMI ID.
DigitalOcean Based on attached Tags.

Service Discovery Backend

Service discovery is typically an API to a platform like Docker in order to discover the backends. We support using SRV records which is common on platforms like Kubernetes. TTL class SRV priority weight port target

Where the description of the fields is as follows:

  • _service: standard network service name (taken from /etc/services) or a port number
  • _proto: standard protocol name (“tcp” or “udp”)
  • name: name of the service — the name used in the query
  • TTL: validity period for the response (this field is ignored by HAProxy as HAProxy maintains its own expiry data which is defined in the configuration) class: DNS class (“IN”)
  • SRV: DNS record type (“SRV”)
  • priority: priority of the target host. Lower value = higher preference (this field is ignored by HAProxy, but may become used later for indicating active / backup state)
  • weight: relative weight in case of records with the same priority. Higher number = higher preference
  • port: port on which the service is configured
  • target: canonical hostname of the machine providing the service, ending in a dot

You can see an example of this below:

dig -t srv


;; ANSWER SECTION: 30 IN SRV 10 25 8080 30 IN SRV 10 25 8080 30 IN SRV 10 25 8080 30 IN SRV 10 25 8080

;; ADDITIONAL SECTION: 30 IN A 30 IN A 30 IN A 30 IN A    

Using this system you can have Docker, Kubernetes, Consul, Rancher and more tell the ADC automatically what systems are online for a Backend.