From: MaxHearnden Date: Mon, 22 Sep 2025 14:59:23 +0000 (+0100) Subject: Reorder rules in dnsdist recursive/authoritative example X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F16149%2Fhead;p=thirdparty%2Fpdns.git Reorder rules in dnsdist recursive/authoritative example RDRule is likely to be cheaper to evaluate than a NetmaskGroupRule and so evaluating RDRule first will allow NetmaskGroupRule to sometimes be shortcutted. Co-authored-by: Remi Gacogne Signed-off-by: MaxHearnden --- diff --git a/docs/guides/recursion.rst b/docs/guides/recursion.rst index a9b9d10f7..6e97cc731 100644 --- a/docs/guides/recursion.rst +++ b/docs/guides/recursion.rst @@ -207,7 +207,7 @@ This is where several settings from the existing Authoritative Server recursive_ips:addMask('NETWORKMASK1') -- These network masks are the ones from allow-recursion in the Authoritative Server recursive_ips:addMask('NETWORKMASK2') - addAction(AndRule({NetmaskGroupRule(recursive_ips), RDRule()}), PoolAction('recursor')) + addAction(AndRule({RDRule(), NetmaskGroupRule(recursive_ips)}), PoolAction('recursor')) addAction(AllRule(), PoolAction('auth')) This configuration will route all recursive queries from the netmasks