Use pull model to get the statistics from DohFrontend
As we are adding more fields in Stats, usig lock would become more expensive. Change DohFrontend to fetch the stats by mpsc channel. Besides, this change also contains some cleanups and minor fixes: - Replace mpsc::channel with mpsc::unbounded_channel - Rename connections to connections_accepted in Stats - Change the return type of ClientMap::get_or_create() Bug: 1895315 Test: cd packages/modules/DnsResolver && atest Change-Id: I184d45c148b15389af26ad482b947def0a222e6a
Loading
Please register or sign in to comment