Overview of route maps

For more granular control over the traffic routing logic, you can upload a custom route map file mapping IP addresses from incoming requesters to specific targets corresponding to answers in a DNS record.

Then, you can create a Filter Chain, including the Pulsar Route Map filter, within a DNS record to apply the route map file to the routing logic.

Using route maps, you can define which locations are accessible to requesting clients based on a declarative data model. The model is an overlay to direct traffic based on specific mappings, overriding the default routing behavior. For example, one could use route maps to target individual IP prefixes to make targeted micro-corrections for precise BGP traffic steering.

Note: Route maps are only active when they are applied to a DNS record whose Filter Chain configuration contains the Route map filter.




How it works

When a client requests the location of foo.example.com, the IBM® NS1 Connect® name servers steer the request using the following logic:

  • First, it determines the client IP address based on the EDNS client subnet information (by default). If unavailable, the recursor’s address is used (per RFC).
  • Next, the server finds a matching network segment (IP range) in the route map associated with the record. If there are multiple segment matches, it uses the one with the longest matching prefix. The matching segment determines one or more targets to use in subsequent steps. For this example, assume the matching network segment is d.e.f.0/24 with targets: hkg and sin.
  • Finally, it references each target specified in the map file and searches for answers with the matching target metadata (hkg). If there are no matching answers for the first target listed in the route map file, the server will search for answers matching the next listed target ("sin"). In the example illustrated above, the resulting DNS answers are 2.2.2.2 and 1.1.1.1.

It is possible to attach multiple route maps to the same record. In this case, the filter attempts to find a match within the first listed route map. If there is no exact match or the match doesn’t contain a target, it references the following map (and so on) until it locates the matching IP range with associated targets and answers.