]> git.ipfire.org Git - thirdparty/pdns.git/commit
Rework domain id generation. 15103/head
authorMiod Vallat <miod.vallat@open-xchange.com>
Thu, 30 Jan 2025 15:40:01 +0000 (16:40 +0100)
committerMiod Vallat <miod.vallat@open-xchange.com>
Thu, 30 Jan 2025 17:48:02 +0000 (18:48 +0100)
commit8c97604512c046fc96afb9288da17f7edb1dcd89
treee98f469964ce40824bb51baa0c24dd63fb9cba43
parentdb18c3a1789e248c3995c79ebfc5c46739b77eb7
Rework domain id generation.

These changes make the internal state (TDI_t) the reference for domain
ids, which are generated on the fly as domains are added.

Routines iterating over domains make sure to keep this state updated, so
that, at any time, any domain in existence has an entry in the state and
thus an immutable (once discovered) id.

While there, implement getDomainInfo() as a wrapper over
getAllDomains(), returning only the domain we are looking for.

Fixes #14563
modules/tinydnsbackend/tinydnsbackend.cc
modules/tinydnsbackend/tinydnsbackend.hh