Revert submission 19682544-usage-stats
Reason for revert: b/243572246
Bug: 243572246
Reverted Changes:
Ib8b1bdff0:Add GET_USAGE_STATS to RUNTIME_AND_APPOP_PERMISSIO...
I1ac0ca320:Add test for app op permission mappings
Change-Id: I9f2da8d32a88566fc39ad3272fe4caa69d8d5aca
We use to set Activity#mIsInPictureInPictureMode to be true when app
requests Activity#enterPictureInPictureMode and therefore when they
receive the onPause callback, Activity#isInPictureInPictureMode can be
true. With the new auto-enter-pip API, this code path is no more
relevant and here we add extra info to PauseActivityItem to set the same
flag when WM puts the Activity into PiP mode due to auto-enter.
Video: http://recall/-/aaaaaabFQoRHlzixHdtY/yXi24xi6TgYGhoqB31Oov
Bug: 239618513
Test: follow the reproduce steps in bug, see video
Test: atest PinnedStackTests
Change-Id: I81ece7d3aad8eb868d95f106f6825612e0741a19
Adding identification for process starts when the trigger was a
push_message.
When the push_message was over quota it may be deferred, but counting it
separately is still useful, as it could still cause cold process starts.
Test: Manual:
Run `./out/host/linux-x86/bin/statsd_testdrive 169`
Then use a sample app to send it an FCM message when it is not running.
Bug: 242928495
Change-Id: I55c56601af4eb60173ae039d8de7f9e7916c81e8
* changes:
Applying package visibility rules to the broadcast of overlay changed
Do not split intents into multiple ones
Do not split the suspended packages intent into multiple ones
AppOpsManager currently has multiple arrays which are all related:
- sOpToSwitch
- sOpToString
- sOpNames
- sOpPerms
- sOpRestrictions
- sOpAllowSystemRestrictionBypass
- sOpDefaultMode
- sOpDisableReset
- sOpRestrictRead
Despite being different arrays, they're essentially a single list of
objects with each field sliced into a different array.
As the entries in these arrays grows, they are are difficult to keep
track of. To simplify things, we can simply join them all into a single
list of objects. Because there are so many fields, we use the builder
pattern to prevent the array from becoming unreadable.
Test: presubmit
Bug: 242097113
No-Typo-Check: typo EMERGECY is preexisting and non-trivial to fix
Change-Id: I1c54a18fc8ca2de6c5ab4a2ae62d1943fcbaea62
Previously, we splitted the intent into multiple ones to prevent
from the disclosure of information of packages. This approach impacts
system health. A lots of intents were sent when hundreds of packages
information stored in the intent extras.
This cl stopped splitting of intent. Instead, it passes a filter to the
am#broadcastIntent api for intent broadcast to filter the intent extras
by using the rules of package visibility when passing the intent to the
receiver.
Bug: 238448280
Test: atest AppEnumerationTests
Test: atest SuspendPackagesTest
Test: atest SuspendPackageHelperTest
Change-Id: I6c4051168b855155b49b0bd6b19e0de7dc826df7
34b3e4b51c
Test: NotificationChannelGroupTest
Test: NotificationManagerServiceTest
Test: PreferencesHelperTest (new test for revert:
testGetNotificationChannelGroup)
Test: long press on a conversation notification in the shade
Bug: 215072888
Change-Id: Ib9c671b0fd1f97e01ef02957839ebad2cadb5e44
Revert submission 19246592-accessibility-tool-only
Reason for revert: Jank regression b/242267091
Reverted Changes:
I0685e6dd4:CTS tests for the accessibilityDataPrivate propert...
I1c02af88c:Limit off-label accessibility access using a new p...
Change-Id: I701b811fd4fb2634872a759134356736a7e8b7dd
The cameraserver has a need for attributing connect calls to particular
processes. This patch introduces pids as a property of an
AttributionSource.
Test: Smoke test on cuttlefish
Bug: 190657833
Bug: 199526514
Change-Id: I6cdffed62447bbb741290dd9c2e5937254d02e3c
This API is not used: marked as @hide with a commented out @SystemApi;
the AIDL server is not implemented in AOSP nor internally. There is one
extra client from the SEPolicy: wpantund; but there is no build rule for
this binary, and no reference for it in AOSP. This API appears be an
artifact from the initial import of Android Things back in 2017.
I confirmed with the previous owners that there is no intention to use
this API in the future (see bug).
This changes reduces the size of framework.jar by 77kb on
bramble-userdebug.
Bug: 235018188
Test: TH
Change-Id: Id66f5ed23ed26c7185f36454f168e34997be3f8f
- Adds hidden API on ActivityManager
- Checks if feature is supported
- Adds shell command to check if user is visible
- Includes (visible) on 'cmd user list -v'
Test: atest CtsMultiUserTestCases:android.multiuser.cts.UserManagerTest#testIsUserVisible_backgroundUserOnSecondaryDisplay
Test: m update-api
Test: adb shell cmd user is-user-visible --display 0 cur
Bug: 239982558
Change-Id: Ie7fe8c832ef2a3ffe4869a67fd35a0da363d0039
This class contains structured data about a timeout. In this context a timeout is something about to become an ANR (as long as it passes the various ANR deduping/skipping checks). Types of timeout include input dispatch timeout, broadcast receiver timeout etc.
It wraps the ANR subject and contains useful metadata like the value of the system uptime clock when the timeout actually triggered. This is foundational work so that ANR stack latency can be measured and tracked. It will also enable us to log more useful ANR information in perfetto traces.
go/timeout-record
Bug: b/239390223
Test: atest FrameworkServicesTests
Change-Id: I6541b13b4862f6878383d17ba96058b39d36718c
This API will be used on automotives that support multiple displays
to start a passenger user on secondary displays. Once a user is
started this way, it will be "visible"
(i.e. UserManager.isUserVisible() will return true).
This CL provides the very minimum support to such API
(A.K.A. "My Dog, it's full of TODOs!" :-), so it can unblock other
efforts (like changing WindowManager to allow activities to be
launched).
Bug: 239982558
Test: adb shell am start-user --display 42 10
Test: adb shell dumpsys user | egrep '(Users on secondary|isUserVisible)'
Change-Id: I21dc85720da7d0adc24ca9f4573b85ef5a380239
Bug: 236932163
This change adds a work-around to PropertyInvalidatedCache for
failures to set a system property. Such failures cause fatal crashes
in Android but it is believed that a simple retry will succeed.
(Note: the failures have only been reported on partner devices and
cannot be reproduced on Pixel phones, so no root-cause is available
yet.)
RuntimeExceptions (thrown from android_os_SystemProperties.cpp) are
caught and retried. The retry limit is 5 times with a 200ms delay
between attempts. This means that the maximum delay is 1s, whcih
should avoid triggering an ANR.
In addition to automated testing, a manual test was created with
ambush code in the system property component of libc. The ambush code
injected an error into the set-property logic for cache keys. It was
observed that the system recovered properly.
Test: atest:
* FrameworksCoreTests:PropertyInvalidatedCacheTests
* FrameworksCoreTests:IpcDataCacheTest
Change-Id: I3a124b185c7499a45b27df7cbf889ae6d1d33377
(cherry picked from commit 9b0f81025c)