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

Skip to content
Commit 8d246298 authored by Luke Huang's avatar Luke Huang
Browse files

Subsampling DNS events to reduce logs

Currently, each device generates about 4000 queries per day.
Reduce the number of events by subsampling events based on
how interesting they are:
- if return_code == 0 -> log 1 in 100 events (random sampling)
- if return_code == EAI_NODATA -> log 1 in 10 events (random sampling)
- else -> log 100%
Also allow to use experiment flag to update sub-sampling denom.

Example for dumpsys dnsresolver:
  NetId: 100
    DnsEvent subsampling map: default:1 0:100 7:10

Bug: 119862317
Test: manual test with using setprop to change subsampling map
      atest
Change-Id: Ie0a433a91f629dd32b1d0787a5b45926415faab0
parent 27371178
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