Commit Graph

2689 Commits

Author SHA1 Message Date
TreeHugger Robot
64712431fb [automerger skipped] Merge "DO NOT MERGE - Merge qt-qpr1-dev-plus-aosp@6304901 into stage-aosp-master" into stage-aosp-master am: 4c1f620af6 -s ours
am skip reason: subject contains skip directive

Change-Id: Ia1f95f590e25c34b4bb6dcf91c06f46a1494c523
2020-03-20 18:31:59 +00:00
android-build-team Robot
63bf691794 Snap for 6315035 from f7d2d9ea601092c7a4c233fefc0ac2cd7d0b9c75 to mainline-release
Change-Id: Ib791564e5501a27725b0618e203fe53edba3a2cb
2020-03-20 07:01:46 +00:00
android-build-team Robot
3b3529b5f4 Snap for 6314400 from 975130e08acdfb708338c99f92e45dd52b793afb to rvc-release
Change-Id: I9395826c82efad441bd953a3c757b4c9f0da081b
2020-03-20 02:08:32 +00:00
Xin Li
7b8a4a253f DO NOT MERGE - Merge qt-qpr1-dev-plus-aosp@6304901 into stage-aosp-master
Bug: 151763422
Change-Id: I62d3293f617f630d3d2a3d5f67b764bf272769bf
2020-03-19 10:10:35 -07:00
Lorenzo Colitti
26a948dd18 [automerger skipped] Make Ethernet interfaces more testable. am: 8723291cee -s ours am: 5fbe4c856a -s ours
am skip reason: Change-Id I86eef7a93267f800dbfc8eafd307effa76a344ca with SHA-1 013187d3e3 is in history

Change-Id: I7257757ec5e2ac358746bc3c262917f45fac96fa
2020-03-19 15:00:06 +00:00
Lorenzo Colitti
3e3c154772 [automerger skipped] Make Ethernet interfaces more testable. am: 8723291cee am: fc3330912a -s ours
am skip reason: Change-Id I86eef7a93267f800dbfc8eafd307effa76a344ca with SHA-1 013187d3e3 is in history

Change-Id: Ia18110f4eb32f3539533919e65741ef17a66fa05
2020-03-19 14:59:45 +00:00
Lorenzo Colitti
5fbe4c856a [automerger skipped] Make Ethernet interfaces more testable. am: 8723291cee -s ours
am skip reason: Change-Id I86eef7a93267f800dbfc8eafd307effa76a344ca with SHA-1 013187d3e3 is in history

Change-Id: I3673d68d69670828a6ecb96073a0d9d2c3d7eca1
2020-03-19 14:44:23 +00:00
Lorenzo Colitti
8723291cee Make Ethernet interfaces more testable.
This CL adds a setIncludeTestInterfaces method to EthernetManager
that, when called, causes the Ethernet service to recognize and
manage test interfaces created by TestNetworkManager.

Bug: 150644681
Test: Tested by EthernetTetheringTest in same topic
Change-Id: I86eef7a93267f800dbfc8eafd307effa76a344ca
Merged-In: I86eef7a93267f800dbfc8eafd307effa76a344ca
(cherry picked from commit 3410fb0aa92bbd4f9d7dc031e89f6f528ff34245)
2020-03-19 12:30:39 +00:00
Lorenzo Colitti
7867c10d42 Merge "Make Ethernet interfaces more testable." am: e7ff9d5e6d am: 6b37362b14 am: ddc85d466f
Change-Id: Idcb7b2bfef2848d5f90b22b8ff27a087072676ae
2020-03-19 11:49:12 +00:00
Lorenzo Colitti
1543b82a6d Merge "Make Ethernet interfaces more testable." am: e7ff9d5e6d am: 6b37362b14
Change-Id: I4b262fb9cf66a7e1f859e03c7df0fd337658c376
2020-03-19 11:47:03 +00:00
Lorenzo Colitti
ddc85d466f Merge "Make Ethernet interfaces more testable." am: e7ff9d5e6d am: 6b37362b14
Change-Id: I5a73dc5ad6576573bcac6c7ac6f1270dfbb97470
2020-03-19 11:46:55 +00:00
Lorenzo Colitti
6b37362b14 Merge "Make Ethernet interfaces more testable." am: e7ff9d5e6d
Change-Id: I456acb05d548b3d0281e500cfd91d888441d7f94
2020-03-19 11:30:33 +00:00
Lorenzo Colitti
e7ff9d5e6d Merge "Make Ethernet interfaces more testable." 2020-03-19 11:12:09 +00:00
junyulai
c547019027 [automerger skipped] [SM07] Make combine subtype configurable from Settings am: 3faf37539a am: b072165901 -s ours am: 7cacfd59be -s ours
am skip reason: Change-Id Ic94da540afa479ed18f1b6fbda4ae3216c37476b with SHA-1 1e30781571 is in history

Change-Id: I549da7cb25b1c44594542f528b0ab7b1e4f12a5e
2020-03-19 10:01:32 +00:00
junyulai
75b9985b7b [automerger skipped] [SM05] Enable record mobile network stats by collapsed rat type am: 0a59b1e599 am: ab08ed986a -s ours am: a534cbb409 -s ours
am skip reason: Change-Id If330e85330a4ff713dd420c98d42fa741eabd90a with SHA-1 dddf7d0a9a is in history

Change-Id: Iaa2fc4829906ed688c8ce98c1d7b6cae092abe74
2020-03-19 10:01:29 +00:00
junyulai
1b7096ae27 [automerger skipped] [SM04] Support fetching data with NetworkTemplate with subType am: 97ea6b222d am: 2f3c57ee95 -s ours am: 4eb7ef04cb -s ours
am skip reason: Change-Id Ie2d229be0b6bd239f799989c070475c73a096d71 with SHA-1 00d94e3335 is in history

Change-Id: I5a872bb77589bee31d219be1161e78cf7cef1858
2020-03-19 10:01:26 +00:00
junyulai
b56c78c25d [automerger skipped] [SM02] Support record mobile network stats by collapsed rat type am: 383c8e8556 am: 3968b6ddb8 -s ours am: e4a78f7f73 -s ours
am skip reason: Change-Id Ic6b2f10f2c8b082820e0662eb9cee70d70d28cd6 with SHA-1 825f0828ac is in history

Change-Id: I5eb9f9c3513eebd2a26bca53a943d0e25b0c3557
2020-03-19 10:01:23 +00:00
junyulai
3815d37747 [SM07] Make combine subtype configurable from Settings am: 3faf37539a am: b072165901
Change-Id: I65470e2ce4aae26308a395ce1e5465ac27914f60
2020-03-19 09:40:53 +00:00
junyulai
b8fc0b631d [SM05] Enable record mobile network stats by collapsed rat type am: 0a59b1e599 am: ab08ed986a
Change-Id: Ie23c2131349412d9dae04db122d7b3d14047b87f
2020-03-19 09:40:51 +00:00
junyulai
b58185d835 [SM04] Support fetching data with NetworkTemplate with subType am: 97ea6b222d am: 2f3c57ee95
Change-Id: Ib47b320e467daed3c8fb746ed99dd34657d1799b
2020-03-19 09:40:48 +00:00
junyulai
8fbcf8b99b [SM02] Support record mobile network stats by collapsed rat type am: 383c8e8556 am: 3968b6ddb8
Change-Id: I3a8965424f1f28d1fa63bb469c10c735af67eb31
2020-03-19 09:40:45 +00:00
junyulai
7cacfd59be [automerger skipped] [SM07] Make combine subtype configurable from Settings am: 3faf37539a am: b072165901 -s ours
am skip reason: Change-Id Ic94da540afa479ed18f1b6fbda4ae3216c37476b with SHA-1 1e30781571 is in history

Change-Id: Ife89c4526d5e5f79c09fce585b2f124ea06ff28a
2020-03-19 09:40:00 +00:00
junyulai
a534cbb409 [automerger skipped] [SM05] Enable record mobile network stats by collapsed rat type am: 0a59b1e599 am: ab08ed986a -s ours
am skip reason: Change-Id If330e85330a4ff713dd420c98d42fa741eabd90a with SHA-1 dddf7d0a9a is in history

Change-Id: I5f7e58d16e30eae69c45a505ea2ee9e4a9802d91
2020-03-19 09:39:55 +00:00
junyulai
4eb7ef04cb [automerger skipped] [SM04] Support fetching data with NetworkTemplate with subType am: 97ea6b222d am: 2f3c57ee95 -s ours
am skip reason: Change-Id Ie2d229be0b6bd239f799989c070475c73a096d71 with SHA-1 00d94e3335 is in history

Change-Id: Ibdeeda75e0bd4f641b349b145b0c849bf2cb94c1
2020-03-19 09:39:51 +00:00
junyulai
e4a78f7f73 [automerger skipped] [SM02] Support record mobile network stats by collapsed rat type am: 383c8e8556 am: 3968b6ddb8 -s ours
am skip reason: Change-Id Ic6b2f10f2c8b082820e0662eb9cee70d70d28cd6 with SHA-1 825f0828ac is in history

Change-Id: Idf27a0112486d2e0c5b3be419c01228820d8835e
2020-03-19 09:39:49 +00:00
junyulai
b072165901 [SM07] Make combine subtype configurable from Settings am: 3faf37539a
Change-Id: I0c3f4a02f16eb6a4d9e48fa775bf456707d2b1bb
2020-03-19 09:31:02 +00:00
junyulai
ab08ed986a [SM05] Enable record mobile network stats by collapsed rat type am: 0a59b1e599
Change-Id: If4bcfaefd2244be67449066ef54a6bdc0c00eb86
2020-03-19 09:31:00 +00:00
junyulai
2f3c57ee95 [SM04] Support fetching data with NetworkTemplate with subType am: 97ea6b222d
Change-Id: I3927277c41ba4b0cb5dc3a0309a5d4ca8f4d1dbc
2020-03-19 09:30:56 +00:00
junyulai
3968b6ddb8 [SM02] Support record mobile network stats by collapsed rat type am: 383c8e8556
Change-Id: Ia7dd0ae44fe951c00e365b94ac3b8a93230c96ab
2020-03-19 09:30:51 +00:00
junyulai
8270ea0a34 [SM07] Make combine subtype configurable from Settings am: 1e30781571 am: 28255c9992
Change-Id: I138ae4305d68b78323c2af9bfc081f42e661cdd9
2020-03-19 06:53:43 +00:00
junyulai
0488bfb9c0 [SM05] Enable record mobile network stats by collapsed rat type am: dddf7d0a9a am: f09a3e232f
Change-Id: I4e700b60a23665e7e50261b6392392c67ea9c49d
2020-03-19 06:53:40 +00:00
junyulai
180663d4d4 [SM04] Support fetching data with NetworkTemplate with subType am: 00d94e3335 am: 5341a72f55
Change-Id: I2f0f04c34faf58bc15572bc41f80b9c411db0242
2020-03-19 06:53:37 +00:00
junyulai
e00a0fdcbc [SM02] Support record mobile network stats by collapsed rat type am: 825f0828ac am: ad8e8bddfe
Change-Id: I10acd170e902344b1b9063fe2a4da60c5d037e5d
2020-03-19 06:53:35 +00:00
junyulai
28255c9992 [SM07] Make combine subtype configurable from Settings am: 1e30781571
Change-Id: Ic8426ae36b5aaadfdd3292a3b70fc9b290443d5c
2020-03-19 06:37:59 +00:00
junyulai
f09a3e232f [SM05] Enable record mobile network stats by collapsed rat type am: dddf7d0a9a
Change-Id: I492dd32dc6b6af061da02a450c8c6abff0e8bf5e
2020-03-19 06:37:56 +00:00
junyulai
5341a72f55 [SM04] Support fetching data with NetworkTemplate with subType am: 00d94e3335
Change-Id: Ie22a2255f1d32b6c0b21a4c33bd6778255e4cbb5
2020-03-19 06:37:51 +00:00
junyulai
ad8e8bddfe [SM02] Support record mobile network stats by collapsed rat type am: 825f0828ac
Change-Id: Ie512faaa0799b3f352c3d646e30bd92e525d9d2c
2020-03-19 06:37:48 +00:00
junyulai
3faf37539a [SM07] Make combine subtype configurable from Settings
Note that enabling/disabling would not take effect until device
reboot. This will be addressed in follow-up patch.

Test: 1. atest NetworkStatsServieTest SettingsBackupTest
      2. adb shell settings put global netstats_combine_subtype_enabled 1|0
Bug: 146415925

Change-Id: Ic94da540afa479ed18f1b6fbda4ae3216c37476b
Merged-In: Ic94da540afa479ed18f1b6fbda4ae3216c37476b
(cherry picked from commit 550d61b8fa and
 fix merge conflict in SettingsBackupTest)
2020-03-19 10:10:07 +08:00
junyulai
0a59b1e599 [SM05] Enable record mobile network stats by collapsed rat type
Switch on the recording in device side. Metrics will be
collected in follow-up patches which can be independently
enabled/disabled.

This change also fix the fail in NetworkStatsCollectionTest
which caused by enabling this feature, where the rounding
problem happened when records are distributed into smaller
buckets and categorized into more NetworkIdentity.

Test: atest FrameworksNetTests
Bug: 129082217
Change-Id: If330e85330a4ff713dd420c98d42fa741eabd90a
Merged-In: If330e85330a4ff713dd420c98d42fa741eabd90a
(cherry picked from commit ff1d70e364)
2020-03-19 10:10:07 +08:00
junyulai
97ea6b222d [SM04] Support fetching data with NetworkTemplate with subType
Add a NetworkTemplate build function that allows user to specify
subType. NetworkStats corresponding to the same group would
be retrieved.

Test: atest FrameworksNetTests
Bug: 129082217

Change-Id: Ie2d229be0b6bd239f799989c070475c73a096d71
Merged-In: Ie2d229be0b6bd239f799989c070475c73a096d71
(cherry picked from commit ec1c5fe86c)
2020-03-19 10:10:07 +08:00
junyulai
383c8e8556 [SM02] Support record mobile network stats by collapsed rat type
Previously network stats could be recorded by different rat type.
However, the feature was disabled by ag/173504 since rat type
frequently flapping between HSPA+ and UMTS.

Given that this feature might be useful for collecting metrics,
re-implement it based on current architecture and reduce the
overhead introduced by frequently flapping by:
  1. only react when rat type changes between 2G/3G/4G/5G.
  2. reduce the number of records by only recording a subset
     of rat type that represented for a given network class.
  3. enforce 1 second rate limit if flapping too much.

Note that the feature is still disabled but will be enabled
in follow-up patches.

Test: manual test
Bug: 129082217
Change-Id: Ic6b2f10f2c8b082820e0662eb9cee70d70d28cd6
Merged-In: Ic6b2f10f2c8b082820e0662eb9cee70d70d28cd6
(cherry picked from commit 20f4805aad)
2020-03-19 10:10:07 +08:00
junyulai
1e30781571 [SM07] Make combine subtype configurable from Settings
Note that enabling/disabling would not take effect until device
reboot. This will be addressed in follow-up patch.

Test: 1. atest NetworkStatsServieTest SettingsBackupTest
      2. adb shell settings put global netstats_combine_subtype_enabled 1|0
Bug: 146415925

Change-Id: Ic94da540afa479ed18f1b6fbda4ae3216c37476b
Merged-In: Ic94da540afa479ed18f1b6fbda4ae3216c37476b
(cherry picked from commit c4f77ac90bf2e48a655ad19b162fe74a23bf3fb0)
2020-03-19 01:40:55 +00:00
Lorenzo Colitti
013187d3e3 Make Ethernet interfaces more testable.
This CL adds a setIncludeTestInterfaces method to EthernetManager
that, when called, causes the Ethernet service to recognize and
manage test interfaces created by TestNetworkManager.

Bug: 150644681
Test: Tested by EthernetTetheringTest in same topic
Change-Id: I86eef7a93267f800dbfc8eafd307effa76a344ca
2020-03-19 09:46:37 +09:00
junyulai
dddf7d0a9a [SM05] Enable record mobile network stats by collapsed rat type
Switch on the recording in device side. Metrics will be
collected in follow-up patches which can be independently
enabled/disabled.

This change also fix the fail in NetworkStatsCollectionTest
which caused by enabling this feature, where the rounding
problem happened when records are distributed into smaller
buckets and categorized into more NetworkIdentity.

Test: atest FrameworksNetTests
Bug: 129082217
Change-Id: If330e85330a4ff713dd420c98d42fa741eabd90a
Merged-In: If330e85330a4ff713dd420c98d42fa741eabd90a
(cherry picked from commit 2d4fa2c0fae8c2d79a25093d9f732a33c2f91dd4)
2020-03-18 08:08:01 +00:00
junyulai
00d94e3335 [SM04] Support fetching data with NetworkTemplate with subType
Add a NetworkTemplate build function that allows user to specify
subType. NetworkStats corresponding to the same group would
be retrieved.

Test: atest FrameworksNetTests
Bug: 129082217

Change-Id: Ie2d229be0b6bd239f799989c070475c73a096d71
Merged-In: Ie2d229be0b6bd239f799989c070475c73a096d71
(cherry picked from commit e19045cc4ab1f2cd133ce5dc0c3a38e3275417ad)
2020-03-18 08:07:12 +00:00
junyulai
825f0828ac [SM02] Support record mobile network stats by collapsed rat type
Previously network stats could be recorded by different rat type.
However, the feature was disabled by ag/173504 since rat type
frequently flapping between HSPA+ and UMTS.

Given that this feature might be useful for collecting metrics,
re-implement it based on current architecture and reduce the
overhead introduced by frequently flapping by:
  1. only react when rat type changes between 2G/3G/4G/5G.
  2. reduce the number of records by only recording a subset
     of rat type that represented for a given network class.
  3. enforce 1 second rate limit if flapping too much.

Note that the feature is still disabled but will be enabled
in follow-up patches.

Test: manual test
Bug: 129082217
Change-Id: Ic6b2f10f2c8b082820e0662eb9cee70d70d28cd6
Merged-In: Ic6b2f10f2c8b082820e0662eb9cee70d70d28cd6
(cherry picked from commit 15ab452e7e3f00289fbedbdb86c512ad560dda7e)
2020-03-18 07:59:44 +00:00
android-build-team Robot
08ae898422 Snap for 6306509 from b1f2e3d0211be00397dcacc36296bf71800d3bbd to mainline-release
Change-Id: I4901b261694118fa1e9e82f927236842c4600e0b
2020-03-18 07:16:05 +00:00
Junyu Lai
65fdfae54a [automerger skipped] Merge "[SP25] Rename functions that add Entry conditionally" am: 338e4c0608 am: f17247045d -s ours am: 1e2d51797a -s ours
am skip reason: Change-Id I9495a198cf247e6c79100f7ac1edcea370b071de with SHA-1 544bc807a4 is in history

Change-Id: I214ca8cb07535dbe33be18aa9a49d31811451ff5
2020-03-18 04:16:40 +00:00
Junyu Lai
9601eb5237 Merge "[SP25] Rename functions that add Entry conditionally" am: 338e4c0608 am: f17247045d
Change-Id: I59d965fa3a67be4994fe19a2f91e30d2ef114f81
2020-03-18 04:02:41 +00:00
Junyu Lai
1e2d51797a [automerger skipped] Merge "[SP25] Rename functions that add Entry conditionally" am: 338e4c0608 am: f17247045d -s ours
am skip reason: Change-Id I9495a198cf247e6c79100f7ac1edcea370b071de with SHA-1 544bc807a4 is in history

Change-Id: I19399123661123386472ff3f39d268d85917cbe1
2020-03-18 04:02:05 +00:00