Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 52cf009b authored by chenbruce's avatar chenbruce
Browse files

Subsampling DNS event for mDNS

Currently, a device generates some mDNS queries when the user uses
mDNS .local resolution.
Using the query info by subsampling events based on how interesting
they are. Because the number of mDNS query is much less than DNS
query, the mDNS subsampling rate is higer than DNS query.
- if return_code == 0,2,7 -> log 1 in 1 event
- if return_code == default -> log 1 in 1 event
Also allow to use experiment flag to update sub-sampling denom.

Example for dumpsys dnsresolver:
  NetId: 100
    DnsEvent subsampling map for MDNS: default:1

Bug: 197092658
Test: cd packages/modules/DnsResolver && atest
      m statsd_testdrive and run "statsd_testdrive 116"
Change-Id: I76073aa9a1cea43bda2675334592ed22e96a238e
parent 9b72daa3
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment