- Mar 25, 2024
-
-
mmanjuna authored
This problem occurs only when the timestamp of broadcast and the notification event is exactly the same. Though ideally they need to occur one after the other, it is quite possible that they can occur immediately with the same timestamp. Hence, we see flaky behaviour. Fix is to process the events even if broadcast event's timestamp is equal to the notification event. Bug: 330844354 Test: atest tests/tests/app.usage/src/android/app/usage/cts/BroadcastResponse StatsTest.java Change-Id: I69398c1d15ed7a4ae39c31a2b56f19ef0b858614
-
- Jan 09, 2024
-
-
Sudheer Shanka authored
Bug: 317897994 Test: manual Change-Id: I96329b87ea52de04a786d99cc33596e003061802
-
- Dec 27, 2023
-
-
Sudheer Shanka authored
These are used with RingBuffer but they are being removed during code shrinking. Bug: 317897994 Test: manual (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:cb279f32eda6554607ec9ab674fe3ae804224037) Merged-In: I21c0298a088092cef148253be3efed65e01a90d2 Change-Id: I21c0298a088092cef148253be3efed65e01a90d2
-
- Dec 12, 2023
-
-
Xin Guan authored
Bug: 296061232 Test: CtsUsageStatsTestCases:android.app.usage.cts.UsageStatsTest Change-Id: I5031f9fc45c4518acdeb69e073b6625f789a01b9
-
- Dec 07, 2023
-
-
Xin Guan authored
Also dump the flag value out and minor fix. Bug: 194321117 Test: manual Change-Id: I8816493ae82d83e9d6e4a7d28484201d57b3e888
-
- Nov 28, 2023
-
-
Xin Guan authored
Introduce a new dimension to the user interaction event by offering additional user interaction details. Bug: 296061232 Test: atest CtsUsageStatsTestCases:android.app.usage.cts.UsageStatsTest atest FrameworksCoreTests:android.app.usage.UsageStatsPersistenceTest atest FrameworksServicesTests:com.android.server.usage.UsageStatsDatabaseTest Change-Id: I75446f219ae859853b4243d74db50f83b2fba31e
-
- Nov 20, 2023
-
-
Xin Guan authored
Make sure the whole list has been transferred Bug: 301254110 Test: atest CtsUsageStatsTestCases Test: atest FrameworksCoreTests:android.app.usage.* Change-Id: Ia90f5869c4f5255cc9e9d059b81c40f7e85c23b1
-
- Nov 10, 2023
-
-
Xin Guan authored
Make sure informing the callbacks without holding the main lock of the UsageStatsService. Bug: 310142962 Bug: 302675504 Test: build/trace. Change-Id: I4e9701b6a5c1657dc4303e22de5d148a68248398
-
- Nov 02, 2023
-
-
Xin Guan authored
Add a new queryEvents API to provide more flexibility for applications to query specific types of events. Bug: 194321117 Change-Id: I2bdeae6dffced1cc6f7a76cebe881e6c199a4582 Test: atest CtsUsageStatsTestCases:android.app.usage.cts.UsageStatsTest
-
Xin Guan authored
Revert submission 25109517-usageevents_filter_query Reason for revert: build breakage Reverted changes: /q/submissionid:25109517-usageevents_filter_query Change-Id: Ibadb44bd0b388d4ea5dc012227d43a3254be3899
-
Xin Guan authored
Add a new queryEvents API to provide more flexibility for applications to query specific types of events. Bug: 194321117 Test: atest CtsUsageStatsTestCases:android.app.usage.cts.UsageStatsTest Change-Id: Ib25bb52d1ba488ad0ab14a7392cb97715691956c
-
- Oct 20, 2023
-
-
Xin Guan authored
Use a dedicated thread with default priority to handle the usage stats event processing. Bug: 303798680 Bug: 302675504 Test: atest CtsUsageStatsTestCases Test: atest FrameworksCoreTests:android.app.usage.* Change-Id: I0bdd65d5ef1ed61ab5b8fdf4f1a3a257f1b37111
-
- Oct 16, 2023
-
-
Xin Guan authored
Fall back to the previous behavior when the new REPORT_USAGE_STATS flag is default to ensure no app compact breakage. Bug: 305648037 Test: share a picture in photo, make sure no crash. atest CtsUsageStatsTest Change-Id: I3311ed93bc66cf749092b1add4cf6cba36ecfdd2
-
- Oct 14, 2023
-
-
Xin Guan authored
The android.bg thread could be busy at other tasks and blocked the user state changing intent broadcasting. Bug: 303798680 Test: atest CtsUsageStatsTestCases Change-Id: I185c76eb2211106b5debbe03fdd67ff82622d85b
-
- Oct 13, 2023
-
-
Varun Shah authored
- Add a new flag for the permission. - Add FlaggedApi annotation to new permission. - Update APIs to check flag enablement. Bug: 304478692 Bug: 296056771 Test: atest UsageStatsTest Change-Id: I59b0634d4cbc956ecfb5eb63dd1100515427d62f
-
- Oct 06, 2023
-
-
Xin Guan authored
Use dedicated IoThread for bg/fg proc status updates and launch time prediction. Avoid holding the main lock for launch time prediction Bug: 302675504 Test: atest CtsUsageStatsTestCases Test: atest FrameworksCoreTests:android.app.usage.* Change-Id: I88f8d3d160db6404282ea73374e6a2c8d05f05cf
-
- Oct 04, 2023
-
-
Xin Guan authored
Bug: 302675504, 278941014 Test: atest CtsUsageStatsTestCases Test: atest FrameworksCoreTests:android.app.usage.* Change-Id: I92430c1be15176e2a6e841f0fbf7066b965f8556
-
- Oct 03, 2023
-
-
Xin Guan authored
Revert back to the original parameter check for reportChooserSelection to ensure no application behavior breakage. Bug: 301564659 Test: atest CtsUsageStatsTest Change-Id: If7f72724395a14222cf75c1281c078a2a85468a3
-
Xin Guan authored
Use a dedicated thread with default priority to handle the usage stats event processing. Also offload IOs to the dedicated IoThread and post processing the launch time estimation. Bug: 302675504 Test: atest CtsUsageStatsTestCases Test: atest FrameworksCoreTests:android.app.usage.* Change-Id: Ib0bb490279c1dcbd71cabfc3a1f7d97c638eb9b6
-
- Sep 25, 2023
-
-
Xin Guan authored
Avoid unnecessary IOs and additional memory overhead for usage statistica queries. Also dump the pending usage events for unlocked user(s). Bug: 301449929 Test: atest CtsUsageStatsTestCases atest FrameworksCoreTests:android.app.usage.UsageStatsPersistenceTest atest FrameworksServicesTests:com.android.server.usage.UsageStatsDatabaseTest Change-Id: Ia68e78a96dd1f66d19744acfb85b74e890608df7
-
- Sep 21, 2023
-
-
Xin Guan authored
Adding a few tracing point to the code paths related to the user unlocking. Bug: 300285947 Test: verify it's available in the trace Change-Id: I2a1368c4022f174c115f0269ad6c100caa5e5817
-
- Sep 13, 2023
-
-
Varun Shah authored
This will help address some of the flaky behavior in CTS tests. Bug: 295216985 Test: atest UsageStatsTest Change-Id: Iab86e890c0aacfed3556e14b7b93949edd96f935
-
- Sep 08, 2023
-
-
Varun Shah authored
This will help address some of the flaky behavior in CTS tests. Bug: 295216985 Test: atest UsageStatsTest Change-Id: Iab86e890c0aacfed3556e14b7b93949edd96f935
-
- Aug 30, 2023
-
-
alukin authored
Fixing getTotalBytes by calling a new API in Vold. 1. Returned the original implementation of rounding logic. Now it only rounds the bytes by increasing the size, and never by decreasing. 2. Returned the original logic for all the device sizes <= 512GB to prevent any potential regressions. 3. For devices with larger capacities now calling vold (one-time call, then the value is stored in memory) to get the block device size. It's a very precise number of bytes, so only doing a small rounding (up to 3GB) to try to bring the totalBytes to a nice-looking value, otherwise just return as is. Should be tested together with a Settings UI fix: I3dcc9698403612f961cf0de41925dcbcb43e260b Verified on multiple devices with storage <= 512GB: b/290892417#comment26. Also verified for 1TB devices: personally and in b/295265657#comment10 Bug: 290892417 Bug: 295358118 Test: verified manually + manually verified calling of new API Test: atest FileUtilsTest Test: atest StorageHostTest Change-Id: I01d72ede6c3ac62198d04829866655ba5a92dc45 (cherry picked from commit be2ec6d9)
-
- Aug 25, 2023
-
-
Varun Shah authored
Add requirement of either being the system or having the REPORT_USAGE_STATS permission in order to call any report events related APIs. This includes the reportChooserSelection and reportUserInteraction APIs. Also add the permission to Shell so the APIs can be tested via CTS. Bug: 296056771 Bug: 218679369 Test: atest CtsUsageStatsTest Change-Id: I3b28e00b9da73cd4bc051f3c5e03e29a734a1df0
-
- Aug 22, 2023
-
-
alukin authored
Fixing getTotalBytes by calling a new API in Vold. 1. Returned the original implementation of rounding logic. Now it only rounds the bytes by increasing the size, and never by decreasing. 2. Returned the original logic for all the device sizes <= 512GB to prevent any potential regressions. 3. For devices with larger capacities now calling vold (one-time call, then the value is stored in memory) to get the block device size. It's a very precise number of bytes, so only doing a small rounding (up to 3GB) to try to bring the totalBytes to a nice-looking value, otherwise just return as is. Should be tested together with a Settings UI fix: I3dcc9698403612f961cf0de41925dcbcb43e260b Verified on multiple devices with storage <= 512GB: b/290892417#comment26. Also verified for 1TB devices: personally and in b/295265657#comment10 Bug: 290892417 Bug: 295358118 Test: verified manually + manually verified calling of new API Test: atest FileUtilsTest Test: atest StorageHostTest Change-Id: I01d72ede6c3ac62198d04829866655ba5a92dc45
-
- Aug 09, 2023
-
-
Songchun Fan authored
codePath can be null for apps uninstalled with DELETE_KEEP_DATA. The downstream code would crash if there's a null inside the codePaths array passed into Installer.getAppSize. Also makes sure that the correct storageUuid and data dir is preserved in the PackageInfo query result. BUG: 288142708 Test: manually tested with test code and verified it doesn't crash Test: to be added in cts Change-Id: If7cb1c3cba7a66994780a65c7aa3884889e16c65
-
- Aug 07, 2023
-
-
Sudheer Shanka authored
Bug: 294627012 Test: n/a Change-Id: I429278e5d2093fc6f96e8f06f8f0d84b7369e6cb
-
- Jul 22, 2023
-
-
Sudheer Shanka authored
Bug: 291793661 Test: atest tests/tests/app.usage/src/android/app/usage/cts/BroadcastResponseStatsTest.java Change-Id: I837eaaefa0d900a5b25e8a861f3b67aa4509f08f
-
- Jun 27, 2023
-
-
Suprabh Shukla authored
The only added value in this subclass comes from the added methods to binary search on its keys. Pulling these methods up to the base class LongSparseArray so they can be useful for all its instances. Renamed variables and methods to be more generic and replaced the handwritten binary search with an equivalent call to Arrays.binarySearch to reduce maintenance overhead. All occurrences of TimeSparseArray have been replaced with LongSparseArray. No behavior change is expected. Test: Builds, boots. Test: atest FrameworksCoreTests:LongSparseArrayTest Bug: 282264041 Change-Id: I6e87560ad5afe85118c9ffaac9ea8a506a181af0
-
- Jun 23, 2023
-
-
Kweku Adams authored
Some classes of devices will not have auto power save modes enabled. On those devices, we should skip tests that require the modes be enabled. Bug: 240108412 Bug: 240630396 Test: Manually go through CTS-V "Ignore Battery Optimizations Test" Test: atest CtsUsageStatsTestCases:UsageStatsTest Change-Id: Icc64fbe75213386a1f41fae258e50c4032920b0a (cherry picked from commit ba3b5d7e) Merged-In: Icc64fbe75213386a1f41fae258e50c4032920b0a
-
- Jun 19, 2023
-
-
mrulhania authored
iris permissions clean-up, reference: ag/23421539 Bug: 283977848 Test: presubmit Change-Id: If307e06953d8c87bd7a50e4057f5adba764277fa
-
- Jun 16, 2023
-
-
Varun Shah authored
As a privacy improvement, do not store usage stats data that is older than 2 years. Previously, stats were kept for 3 years. This will also help reduce the storage taken up by stats and improve the performance of query stats API calls which require files to be read from disk since the number of files read are significantly less. Bug: 148524623 Test: atest UsageStatsDatabaseTest Change-Id: I159914a87ba4137f0f3d869c69abf3b16ae77657
-
- May 16, 2023
-
-
Varun Shah authored
Bug: 253403242 Test: atest UsageStatsTest Change-Id: Id356794f8fdfe077ae223c83a4df9b9185e497b3
-
- May 06, 2023
-
-
Varun Shah authored
When CHOOSER_ACTION events are reported via reportChooserSelection, make sure the package name is not null and is also a valid, installed package. Bug: 229633537 Bug: 253403242 Test: atest UsageStatsTest Change-Id: Ib28014f2d21b451d2f7f6e7136f500fc49d0779b
-
- May 04, 2023
-
-
Daniel Chapin authored
Revert submission 22788860-b229633537 Reason for revert: Droidfood blocking bug: b/280401153 Reverted changes: /q/submissionid:22788860-b229633537 (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:8765c548cc444284e2e039987ffce7d846719fee) Merged-In: I584678ebe28fb8c6e0131f6205fcc7f878f32a81 Change-Id: I584678ebe28fb8c6e0131f6205fcc7f878f32a81
-
- May 03, 2023
-
-
Daniel Chapin authored
Revert submission 22788860-b229633537 Reason for revert: Droidfood blocking bug: b/280401153 Reverted changes: /q/submissionid:22788860-b229633537 (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:8765c548cc444284e2e039987ffce7d846719fee) Merged-In: I584678ebe28fb8c6e0131f6205fcc7f878f32a81 Change-Id: I584678ebe28fb8c6e0131f6205fcc7f878f32a81
-
- May 02, 2023
-
-
Daniel Chapin authored
Revert submission 22788860-b229633537 Reason for revert: Droidfood blocking bug: b/280401153 Reverted changes: /q/submissionid:22788860-b229633537 (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:8765c548cc444284e2e039987ffce7d846719fee) Merged-In: I584678ebe28fb8c6e0131f6205fcc7f878f32a81 Change-Id: I584678ebe28fb8c6e0131f6205fcc7f878f32a81
-
Daniel Chapin authored
Revert submission 22788860-b229633537 Reason for revert: Droidfood blocking bug: b/280401153 Reverted changes: /q/submissionid:22788860-b229633537 Change-Id: I584678ebe28fb8c6e0131f6205fcc7f878f32a81
-