Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3862b3d7 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Fix AppOps estimation call time out." into rvc-dev am: d26ded47 am:...

Merge "Fix AppOps estimation call time out." into rvc-dev am: d26ded47 am: 9662b11f am: 29b40f3e am: 8b649397

Original change: https://googleplex-android-review.googlesource.com/c/platform/frameworks/base/+/11675077

Change-Id: If89359068cf7079c8e88456fb67d337fe436ac1a
parents 78b91089 8b649397
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -3319,8 +3319,8 @@ public class StatsPullAtomService extends SystemService {
                        public void run() {
                            try {
                                estimateAppOpsSamplingRate();
                            } catch (Exception e) {
                                Slog.e(TAG, "AppOps sampling ratio estimation failed");
                            } catch (Throwable e) {
                                Slog.e(TAG, "AppOps sampling ratio estimation failed: ", e);
                                synchronized (mAppOpsSamplingRateLock) {
                                    mAppOpsSamplingRate = min(mAppOpsSamplingRate, 10);
                                }
@@ -3361,7 +3361,7 @@ public class StatsPullAtomService extends SystemService {
                        Instant.now().minus(1, ChronoUnit.DAYS).toEpochMilli(),
                        Long.MAX_VALUE).setFlags(
                        OP_FLAGS_PULLED).build();
        appOps.getHistoricalOps(histOpsRequest, mContext.getMainExecutor(), ops::complete);
        appOps.getHistoricalOps(histOpsRequest, AsyncTask.THREAD_POOL_EXECUTOR, ops::complete);
        HistoricalOps histOps = ops.get(EXTERNAL_STATS_SYNC_TIMEOUT_MILLIS,
                TimeUnit.MILLISECONDS);
        List<AppOpEntry> opsList =