dnstap-read: please modify to print query/response timestamps with milliseconds
Description
Desire to be able to use dnstap-read to track latency - milliseconds not just by seconds. Simple function call change in print_yaml from using existing libisc function isc_time_formatISO8601 to existing isc_time_formatISO8601ms in 2 places. Am using this in a version modified from 9.16.6.
Request
diff --git a/bin/tools/dnstap-read.c b/bin/tools/dnstap-read.c
index 5b15fa8153..2663668c08 100644
--- a/bin/tools/dnstap-read.c
+++ b/bin/tools/dnstap-read.c
@@ -230,13 +230,13 @@ print_yaml(dns_dtdata_t *dt) {
if (!isc_time_isepoch(&dt->qtime)) {
char buf[100];
- isc_time_formatISO8601(&dt->qtime, buf, sizeof(buf));
+ isc_time_formatISO8601ms(&dt->qtime, buf, sizeof(buf));
printf(" query_time: !!timestamp %s\n", buf);
}
if (!isc_time_isepoch(&dt->rtime)) {
char buf[100];
- isc_time_formatISO8601(&dt->rtime, buf, sizeof(buf));
+ isc_time_formatISO8601ms(&dt->rtime, buf, sizeof(buf));
printf(" response_time: !!timestamp %s\n", buf);
}
Links / references
Edited by Mark Andrews