We use LogEntry::request to save a virgin request for future logging. However,
when that request is adapted and replaced, the adapted request has all the
stats while the saved virgin request lacks them. We have already copied error
details from the adapted to logged/virgin request. Now we copy the DNS wait
time (%dt) as well.
TODO: Move statistics to a stand-alone history object that adapted and
virgin requests can share. Longer term, we should separate HttpRequest
from Master Transaction so that we can store virgin request details without
implicitly storing not-yet-collected master transaction stats.
}
#endif
+ // Adapted request, if any, inherits and then collects all the stats, but
+ // the virgin request gets logged instead; copy the stats to log them.
+ // TODO: avoid losses by keeping these stats in a shared history object?
if (aLogEntry->request) {
+ aLogEntry->request->dnsWait = request->dnsWait;
aLogEntry->request->errType = request->errType;
aLogEntry->request->errDetail = request->errDetail;
}