per-request verbose logging and debug log improvements
- Mar 26, 2020
-
-
Vladimír Čunát authored
-
Petr Špaček authored
-
- Mar 25, 2020
-
-
Petr Špaček authored
This new approach uses per-request variables in Lua and creates new callback for each DEBUG_IF call instead of each request.
-
Petr Špaček authored
Intended usage: Quick resolution attempt with an empty cache. export QNAME=... export QTYPE=... sudo -E docker run -e QNAME -e QTYPE krestest:latest '-n' '-c' '/etc/knot-resolver/kresd.conf'
-
Petr Špaček authored
It creates new callback functions for every request which uses "callback chaining" but these should be rare.
-
Petr Špaček authored
It seems there is no reason to keep this function private in policy module.
-
Petr Špaček authored
It did not log through request->trace_log and is not very useful anyway.
-
Petr Špaček authored
-
Petr Špaček authored
-
Petr Špaček authored
DEBUG_IF accepts user-supplied function which decides which requests should be logged.
-
Petr Špaček authored
-
Petr Špaček authored
Attempt to avoid duplicating ten lines in debug_logfinish_cb lead me to splitting kr_log_qverbose_impl into two functions kr_log_q and kr_log_req. This is another minor change to API exposed to modules.
-
Petr Špaček authored
Formerly both logs used slightly different formats and duplicated code. From now on verbose log and request tracing are generated using the same code. This required a small change to request trace_log_f definition so it might affect external modules.
-
Petr Špaček authored
-
Petr Špaček authored
We de-randomize qname letter case very early so kr_pkt_text() should see all lowercase. Any uppercase means mismatch. I've considered moving debug print to an earlier place but this way it is more visible so I like more.
-
Petr Špaček authored
-
-