bneradt commented on a change in pull request #8480:
URL: https://github.com/apache/trafficserver/pull/8480#discussion_r740618900



##########
File path: iocore/hostdb/HostDB.cc
##########
@@ -1109,11 +1109,20 @@ HostDBContinuation::dnsEvent(int event, HostEnt *e)
   }
   EThread *thread = mutex->thread_holding;
   if (event != DNS_EVENT_LOOKUP) {
-    // This was an event_interval or an event_immediate
-    // Either we timed out, or remove_trigger_pending gave up on us
+    // Event should be immediate or interval.
     if (!action.continuation) {
-      // give up on insert, it has been too long
-      hostDB.pending_dns_for_hash(hash.hash).remove(this);
+      // Nothing to do, give up.
+      if (event == EVENT_INTERVAL) {
+        // Timeout - clear all queries queued up for this FQDN because none of 
the other ones have sent an
+        // actual DNS query. If the request rate is high enough this can cause 
a persistent queue where the
+        // DNS query is never sent and all requests timeout, even if it was a 
transient error.
+        // See issue #8417.
+        remove_trigger_pending_dns();
+      } else {
+        // "local" signal to give up, usually due this being one of those 
"other" queries.

Review comment:
       nit: "usually due _**to**_ this..."




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to