Commit Graph

830 Commits

Author SHA1 Message Date
weichinweng
d61f3f9ce1 Fix bluetooth can't turn off during network reset (2/3)
Remove disable Bluetooth action from AdapterService and move to
BluetoothManagerService.
Add factory reset reason into Bluetooth enable/disable reason list.

Bug: 110181479
Test: manual
Change-Id: I4bff3c3bb75fbb0d1e13c459c0d9d3fd3b8b3195
Merged-In: I4bff3c3bb75fbb0d1e13c459c0d9d3fd3b8b3195
2020-03-09 15:35:29 +08:00
Alex Lin
97dad931df [DO NOT MERGE] Add country blacklist support
Adding a country blacklist, except for pixel2(walleye, taimen) will still uses whitelist
Bug: 144702079
Test: manually tested

Change-Id: I21c146556e5406ecf5c72f74767ea8d5fc643aec
2019-12-16 12:30:39 -08:00
TreeHugger Robot
cb0b5e206d Merge "Revert "DO NOT MERGE - Add AUTOMOTIVE_USER_SETUP_IN_PROGRESS to Settings"" into qt-qpr1-dev 2019-12-11 16:57:54 +00:00
Jian Jin
db70de3656 Revert "DO NOT MERGE - Add AUTOMOTIVE_USER_SETUP_IN_PROGRESS to Settings"
This reverts commit ba4b561c3e.

Reason for revert: Move to CarSettings

Change-Id: I91fd1fa7dee2400095a014c189a40706b853c471
2019-12-11 00:35:05 +00:00
TreeHugger Robot
f345ab53bc Merge "DO NOT MERGE - Add AUTOMOTIVE_USER_SETUP_IN_PROGRESS to Settings" into qt-qpr1-dev 2019-12-10 22:27:32 +00:00
Jian Jin
ba4b561c3e DO NOT MERGE - Add AUTOMOTIVE_USER_SETUP_IN_PROGRESS to Settings
Bug: 144846684
Test: SettingsProviderTest
Change-Id: Iebc53c70ea401c6ba244ed43db7a1d73f3a894df
2019-12-09 14:07:26 -08:00
Chris Wren
bc487b5759 track and report packages with undecorated remoteviews
print query results with:
  adb shell dumpsys notification --remote-view-stats

test the pulled atom with:
  make statsd_testdrive
  ./out/host/linux-x86/bin/statsd_testdrive 10066

Bug: 144855217
Test: atest frameworks/base/services/tests/uiservicestests/src/com/android/server/notification
Change-Id: I6dcc9871f78298a8b213a051223c7316f8feefc5
Merged-In: I773378fc7cfb47a9f9c7495404ddafa63f39cfaf
2019-12-09 15:48:14 -05:00
Edgar Wang
53cd712dfe Add log metrics for Tap Gesture
Bug: 138296598
Test: rebuild
Change-Id: I468eee30b58921d4c0378278672a19b3fa7754ca
Merged-In: I0ffaf58fa5fbe8af9f0959f653dc213e3c3d7435
2019-11-01 00:56:14 +08:00
Beverly
1742455882 Add motion sense tap gesture + touch counts
AWARE_TAP_PAUSE_GESTURE_COUNT is the number of times the user
has used the Motion Sense tap gesture to pause media.  This number
is used to determine whether to show the "Tap to pause media"
contextual tooltip.

AWARE_TAP_PAUSE_TOUCH_COUNT is the number of times the user has
touched the device to pause media instead of using the Motion Sense
tap gesture (Motion Sense and tap gesture must be active for this value
to increment). This number is also used to determine whether to show the
"Tap to pause media" contextual tip.

We back up these counts so that users moving to new devices with Motion
Sense will not be given these contextual tips again if they already know
how to use the feature.

Test: manual
Bug: 138296598
Change-Id: I702719fb7cec8b6be9dff91d212a00fb26129957
Merged-In: I702719fb7cec8b6be9dff91d212a00fb26129957
(cherry picked from commit a6e468831a)
2019-10-21 17:36:15 +00:00
Edgar Wang
f37615e4f8 Add log metrics for Aware Display Settings
Bug: 136610131
Test: rebuild
Merged-In: I5b96a3a04a1d2c1ba01b9ec1f707dec040a331c3
Change-Id: Ibfdcba4be652cf7885f46e7549c344e12ae11127
2019-09-20 15:35:15 +08:00
Mady Mellor
fd48588768 Merge "qt-r1-bubbles-dev @ build 5835883" into qt-qpr1-dev 2019-09-16 21:55:51 +00:00
Varun Shah
6947f255e4 Merge "Use language tags to store Configuration's locale list." into qt-dev
am: 6dfa267f91

Change-Id: Ia7f30abab7396bc36eb2d69990129143601b028b
2019-09-10 23:29:10 -07:00
Varun Shah
5e67462971 Use language tags to store Configuration's locale list.
Instead of storing each Locale within a Configuration object's locale
list by its language, country, variant, and script to proto, store the
entire locale list by its language tags representation which accurately
describes each locale.

Bug: 140197723
Test: atest ConfigurationTest
Test: atest UsageStatsDatabaseTest
Test: manually with bad data
Merged-In: I53946ed4e31de0ffe9c84875c391a7dec6f5375a
Change-Id: Idaae690f79a5c680ad0059a52be62160d9dfb5e7
2019-09-10 19:53:57 +00:00
Colin Cross
18bf694f3c Merge "Revert "Use language tags to store Configuration's locale list."" into qt-dev
am: dd67a548b2

Change-Id: I0aaee5386c85bf33b292cfa9241c3a0c62dedd29
2019-09-10 12:29:07 -07:00
Varun Shah
68cdb74d91 Revert "Use language tags to store Configuration's locale list."
This reverts commit ff43f4e6a6.

Reason for revert: b/140813780

Change-Id: Id5988b9ec959ca9b294f6bd5caa30c8156238d0a
2019-09-10 18:30:47 +00:00
Varun Shah
ec466c0a8e Merge "Use language tags to store Configuration's locale list." into qt-dev
am: bdfd7d6adb

Change-Id: I2ed88e4ce5bd3a00cc9ea951815c17c57a6599a2
2019-09-10 10:10:25 -07:00
Varun Shah
ff43f4e6a6 Use language tags to store Configuration's locale list.
Instead of storing each Locale within a Configuration object's locale
list by its language, country, variant, and script to proto, store the
entire locale list by its language tags representation which accurately
describes each locale.

Bug: 140197723
Test: atest ConfigurationTest
Test: atest UsageStatsDatabaseTest
Test: manually with bad data
Change-Id: Id0e63ae4a7be578d1e93838b371320f86a787e0e
2019-09-09 22:41:54 +00:00
Frank Li
48e0f97d54 Merge changes from topic "DNS telemetry" into qt-r1-dev
am: 412c59128e

Change-Id: I8d479c2054a894da6f700cd38bfd78cdc96f1558
2019-07-25 20:50:47 -07:00
Bernie Innocenti
fa499f9259 Add NS_R_INTERNAL_ERROR item into NsRcode
Bug: 119862317
Test: ./out/host/linux-x86/bin/statsd_testdrive 116

Merged-In: I023ff5dc0ae2efe45f81494929640c9b96821a0d
Merged-In: I0cf28032f8079c64253ed3f90fcf9d4705a5b492
(cherry picked from commit 83ef1697e3)

Change-Id: I106f73e8b0251bc7a64c68dfb450269ac7cd4feb
2019-07-25 21:57:44 +00:00
Frank Li
be8ecaa59e Refine the proto dns_resolver.proto
1. refine the enum type Transport
   The name of 1st enum value is TRANSPORT_UNKNOWN
2. remove the wrong character "CR"

Bug: 119862317
Test: ./out/host/linux-x86/bin/statsd_testdrive 116

Merged-In: Iaf7abac6170d5818a263392731069d7bf021d981
Merged-In: I8f0e7449036062ecc3827e477ced325d84c1bf54
(cherry picked from commit aee26c026c)

Change-Id: Ie33a2ea58d6f39345d0f1d4141eea8b9c458dcfc
2019-07-25 21:57:26 +00:00
Lyn Han
b739fa6a9e Global bubble settings
Background: Bubble settings have the following levels
- Global (developer options flag)
- App-level
- Channel-level

Issue: Global settings do not propagate to the work profile user because we are
storing NOTIFICATION_BUBBLES in the Secure Settings table instead of the
Global Settings table. Settings are global XOR per-user.

This change
- Sets default value for NOTIFICATION_BUBBLES in global settings table.
- Adds Global.NOTIFICATIONS_BUBBLES to frameworks/base/api/test-current.txt
- Keeps old upgrade steps as no-op to keep db versioning stable.

Bug: 136034310
Test: RunSettingsRoboTests ROBOTEST_FILTER="Bubble"
Change-Id: I21d3dae75e2a4ab0fac10f3d7ea7eed16e0f5d6c
2019-07-10 11:00:51 -07:00
Beverly
e6727ee6da Add gesture touch counts
Test: manual
Bug: 136229528
Change-Id: I805dfbba821c798c59c0d232e60f41890bc9b20d
2019-06-28 14:23:58 -04:00
Mehdi Alizadeh
873f1727e5 Adds metrics categories for gesture navigation dialogs
Bug: 135211145
Test: Builds
Change-Id: I0bc0749bbbb9b78d3d125e1a0f1e9bc35b645db2
2019-06-24 20:31:11 +00:00
Aran Ink
5590c56102 Fix conflict between metrics_constants and settings_enums.
Change-Id: I483bf6b26f2f258f2e2f6f3d839deee4953c203d
Test: Automated tests pass.
Fixes: 135720071
(cherry picked from commit 08659ccdb7)
2019-06-21 19:36:20 +00:00
TreeHugger Robot
41d0b1abc8 Merge "Expose BIND_NOT_PERCEPTIBLE service flag" into qt-dev 2019-06-20 05:34:34 +00:00
Amith Yamasani
5016a7891a Expose BIND_NOT_PERCEPTIBLE service flag
Using this flag when binding to a service will
allow the bound process to be held at a low
oom_adj of 250, so that it can be expunged to
reclaim memory if a more user-visible app needs
it.

Use for bindings such as job services and other
connections that the caller can easily recover
from and restart if necessary.

Adjust the lmk thresholds to use this oom_adj
as one of the levels, so they're killed before
perceptible apps (such as foreground services).

Bug: 135219821
Test: CtsAppTestCases
      Manually check notification listener oom_adj
      and dumpsys activity services output

Change-Id: I9f6d0891d842e4d12f7995b9b1a8f57b0903a16d
2019-06-19 14:40:57 -07:00
Andrew Sapperstein
aad89bd490 Add metrics for mainline modules license UI.
Bug: 135183006
Test: none
Change-Id: Id5f0ed37f64545d7e1b73f9aad61a0357460eea5
2019-06-18 14:25:07 -07:00
Ryan Savitski
cfff472c8e Merge "userdebug: support perfetto traces as a section in incident reports" into qt-dev 2019-06-13 23:42:09 +00:00
Yiwei Zhang
4836fb16c9 Game Driver: Add settings global for prerelease driver opt in option
Bug: 134881329
Test: build, flash and boot
Change-Id: I8c3ba687f3c85f3fe093cdf7086adf9b8109713d
2019-06-09 15:23:17 -07:00
Ryan Savitski
cc7d9973c6 userdebug: support perfetto traces as a section in incident reports
This set of patches adds a way for the perfetto command line client to
save a trace to a hardcoded location,
/data/misc/perfetto-traces/incident-trace, and call into incidentd to
start a report, which will include said trace in a new section.

This is not a long-term solution, and is structured to minimize changes
to perfetto and incidentd. The latter is currently architected in a way
where it can only pull pre-defined information out of the system, so
we're resorting to persisting the intermediate results in a hardcoded
location.

This will introduce at most two more linked files at the same time.

Bug: 130543265
Tested: manually on crosshatch-userdebug
Merged-In: Iaaa312d2d9da73ca329807211227a8c7a049102c
Change-Id: Iaaa312d2d9da73ca329807211227a8c7a049102c
(cherry picked from commit 09a847902f)
2019-06-07 18:13:56 +01:00
Hongyi Zhang
700137e637 Add Usage info for LocationManager's APIs
All new code in LMS wrapped with try/catch and swallowing exceptions
to make sure new code never crashes LocationManagerService.

Bug: 133906682,133190291
Test: Tested with (statsd_testdrive + gnss test apk). Work as intended.
Change-Id: I989b1361c029e76d35861cf23d5c3d152f0bf81a
2019-05-30 03:41:17 +00:00
Kweku Adams
44bb9d7f6b Merge "Changing default limits, clarify flags, fix bug." into qt-dev 2019-05-29 16:54:52 +00:00
Kweku Adams
1d0d4bffa5 Changing default limits, clarify flags, fix bug.
1. Lower job count limits to values that should be more reasonable. The
following defaults have changed:
-- MAX_JOB_COUNT_ACTIVE = 20/window = 120/hr = 1/session
  (down from 200/window = 1200/hr = 10/session)
-- MAX_JOB_COUNT_WORKING = 120/window = 60/hr = 12/session
  (down from 1200/window = 600/hr = 120/session)
-- MAX_JOB_COUNT_FREQUENT = 200/window = 25/hr = 25/session
  (down from 1800/window = 225/hr = 225/session)
-- MAX_JOB_COUNT_RARE = 48/window = 2/hr = 16/session
  (down from 2400/window = 100/hr = 800/session)

2. Increase timing session coalescing duration to enable coalescing.
-- TIMING_SESSION_COALESCING_DURATION_MS = 5 seconds (up from 0ms)

3. Separate allowed time flag from rate limiting period flag so they can
be changed independently.

4. Fix bug: If an app reached the job count quota limit for its bucket,
QuotaController would set an alarm only 10 minutes (allowed time) into
the future to determine if the app was back in quota. This would result
in unnecessary wakeup alarms. Now, QC will set an alarm for when the
app will be under quota.

5. Expand some comments, clarify some constants, and simplify some code.

Bug: 132227621
Test: atest com.android.server.job.controllers.QuotaControllerTest
Test: CtsJobSchedulerTestCases
Change-Id: I6f3f3a5eff7f64b429820d7370d82c1b4573f23b
2019-05-28 15:55:05 -07:00
Hyunyoung Song
eada1380b1 Merge "Add navigation mode to Settings.Secure" into qt-dev 2019-05-26 07:30:42 +00:00
Hyunyoung Song
83972396f2 Add navigation mode to Settings.Secure
Bug: 132443163
Test: builds
Change-Id: I90c3fd843dc111ca6fcd7f618f01c321fd055f83
2019-05-25 21:22:00 -07:00
Kunhung Li
286c52f8c2 Add live wallpaper metrics to atoms.proto
Resue StyleUIChanged message to append live wallpaper events.

Test: make statsd_testdrive && statsd_testdrive 179
Bug: 133209268
Bug: 127745228
Change-Id: I864d8e35bd071f7bcd2249ef20446a42a680dc6d
2019-05-24 01:42:15 +00:00
Salvador Martinez
20d1db4ebb Add metrics constants for dark ui dialog
This just adds some constants needed for a new dialog that shows
up on the first time dark theme is toggled.

Test: none, is a metrics change
Bug: 132695689
Change-Id: Ic7527879003a7d883e74cb00792e69655e5ec9ad
2019-05-21 15:20:11 -07:00
Kweku Adams
d48eef0d22 Add throttling by job run session.
A session is considered a period of time when jobs for an app ran.
Overlapping jobs are counted as part of the same session. This adds a
way to limit the number of job sessions an app can run. This includes a
mechanism to coalesce sessions -- if a second session started soon after
one just ended, they will only be counted as one session.

Bug: 132227621
Test: atest com.android.server.job.controllers.QuotaControllerTest
Test: atest CtsJobSchedulerTestCases
Change-Id: Id2ac4037731f57547d00985e8d549b9e990a5f3e
2019-05-17 16:13:45 -07:00
Michael Groover
8958c9b3d2 Merge "Remove keys from adb_keys after period of inactivity" into qt-dev 2019-05-10 22:54:54 +00:00
Michael Groover
209bb31383 Remove keys from adb_keys after period of inactivity
Previously the feature to revoke 'always allow' adb grants
after a period of activity would not use the adb_keys file
and instead would just check the last connection time of
an 'always allow' key to determine if it should be allowed
without user interaction. However this bypassed the adbd
SIGNATURE check the verifies the system possesses the
corresponding private key. This change resolves this by
writing 'always allow' keys to the adb_keys file and
running a periodic job to remove any keys from this file
that have not been used within the expiration window. This
change also adds support for a 'connected key' message
from adbd so that the framework can be notified when a
key passes the SIGNATURE check.

Bug: 124076524
Test: atest AdbDebuggingManagerTest
Change-Id: I4c252f4ddd77f56a30b807d645cdab12a03d9bc5
2019-05-09 16:01:02 -07:00
tmfang
fb4dbb7812 Add logging enums for slice converter exceptions
- [Refactor] Also remove ACTION_DISPLAY_WHITE_BALANCE_SETTING_CHANGED
to Action enum.

Test: Rebuild rom
Bug: 131449561

Change-Id: I4edfdf275b7858a57cb12a1b4e3c03d2ec37e181
2019-05-09 10:32:17 +08:00
Aaron Heuckroth
00ff1180b2 Add secure settings for Global Actions Panel.
Test: Automated tests pass.
Fixes: 131751030

Change-Id: I969a56ecc0b9310ed32cd5bd5d8ad0c2499ae63b
2019-05-07 14:59:28 -04:00
Frank Li
94a58df81e Merge "Extend NetworkDnsEventReported and add new DnsCallReported to log per-query information" into qt-dev 2019-05-07 14:50:11 +00:00
TreeHugger Robot
cc1159a166 Merge "Add Locale#script to Configuration proto." into qt-dev 2019-05-06 18:29:30 +00:00
TreeHugger Robot
0ff00cf351 Merge "Metrics constants for new screen" into qt-dev 2019-05-03 17:03:49 +00:00
Jorim Jaggi
b2b421287b Merge "Trace opening/closing apps" into qt-dev 2019-05-03 14:01:15 +00:00
Julia Reynolds
c0fb5c1851 Metrics constants for new screen
Test: make
Bug: 128445911
Change-Id: I8577ed12b6c60e7a8996ec313d22b2adcba12b6a
2019-05-03 09:45:39 -04:00
lifr
a2e19c0f91 Extend NetworkDnsEventReported and add new DnsCallReported to log per-query information
NetworkDnsEventReported -The message represents the entire lookup operation,
which may result one or more queries to the recursive DNS resolvers.

DnsCallReported - Those DNS queries are individually logged in DnsCallReported
to enable computing error rates and network latency and timeouts broken up by
query type, transport, network interface, etc

Test: make statsd_testdrive
     ./out/host/linux-x86/bin/statsd_testdrive 116 => pass
Bug: 129253665

Change-Id: Ib75affea5d849437a293affbe294732153511d97
Merged-In: Ib75affea5d849437a293affbe294732153511d97
2019-05-03 02:58:09 +00:00
Varun Shah
95fabaf389 Add Locale#script to Configuration proto.
Read/Write Locale#script along with language, country, and variant
for the Configuration proto.

Bug: 131507134
Test: atest UsageStatsDatabaseTest
Test: atest LocaleListTest [unit-test, cts, gts]
Change-Id: I09b7d3b2e6c6d339cbb75bf19f89251b777bbbe6
2019-05-02 11:56:50 -07:00
Joe Onorato
a902e88286 Merge "Update owners files" into qt-dev 2019-05-01 21:38:58 +00:00