[ 
https://issues.apache.org/jira/browse/TS-4262?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15467452#comment-15467452
 ] 

Alan M. Carroll commented on TS-4262:
-------------------------------------

I'm not convinced this is inaccurate. The two lines mentioned are, AFAICT, in 
different functions and there are many conditions that can fail between the 
first and the second. In particular, {{dns_total_lookups}} is incremented when 
the lookup is passed to the DNS layer. {{dns_in_flight_stat}} is incremented 
when the DNS request is actually shipped off. In particular, if there are 
multiple requests for the same FQDN then all of them will count as look ups but 
only one will become in flight. Moving the code as suggested will therefore 
undercount the total number of requests. I think it is more accurate as is and 
the differences noted reflect lookup requests that didn't hit the cache or 
create an in flight DNS request.

> Some imprecise statistics of stats_over_http plugin
> ---------------------------------------------------
>
>                 Key: TS-4262
>                 URL: https://issues.apache.org/jira/browse/TS-4262
>             Project: Traffic Server
>          Issue Type: Bug
>          Components: Plugins
>    Affects Versions: 5.3.2
>            Reporter: taoyunxing
>            Assignee: Alan M. Carroll
>             Fix For: 7.0.0
>
>
> I found the statistics of HostDB and DNS are not precise, see the following:
> {code}
> proxy.process.hostdb.total_lookups      286951594
> proxy.process.hostdb.total_hits             277568738
> proxy.process.dns.total_dns_lookups    23238887
> proxy.process.dns.lookup_successes    8952696
> proxy.process.dns.lookup_failures         332447
> {code}
> calculation:
> {code}
> 286951594 - 277568738 = 9382856
>     8952696 +      332447 = 9285143
>     9382856 -     9285143 = 97713
> {code}
> I have two question:
> 1.why ?
> proxy.process.hostdb.total_lookups - proxy.process.hostdb.total_hits != 
> proxy.process.dns.lookup_successes + proxy.process.dns.lookup_failures
> 2.why?
> proxy.process.dns.lookup_successes + proxy.process.dns.lookup_failures != 
> proxy.process.dns.total_dns_lookups
> anyone can show me the reason? thanks in advance!



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to