Skip to content
Snippets Groups Projects
Commit 1853a8c1 authored by Vladimír Čunát's avatar Vladimír Čunát
Browse files

client-subnet WIP: mainly cache changes

Status: all deckard tests succeed (non-ECS).

Design plan:

- It was decided to deviate from rfc7871, as full
implementation would be potentially very cache-hungry
(there are very many meaningful IP prefixes).
Instead, a geo DB will be used to partition IPs into discrete
categories.  That's what the authoritative NSs use AFAIK.

- For now the granularity would be a country, as used by
https://www.maxmind.com/en/geoip2-databases

- Cache deduplicates equal records for different locations.
That's implemented by splitting the mapping into two:
usual key + location -> hash, and usual key + hash -> RRdata.
Timestamp and TTL of the RRset is stored in the first part,
and the stored RRs have TTLs zeroed.
(All this forced changes in lib/cache.h API.)
parent ce28b173
Branches
Tags
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment