google 分析是否添加唤醒锁权限?
Does google analytics add wakelock permission?
所以我刚刚将 Google 分析添加到我的应用程序的活动中。将新的 .apk 上传到 Play 商店时,它告诉我该应用现在还需要 1 个权限:WAKE_LOCK.
现在我 100% 确定此权限不在我的清单中,因此必须由 Google Analytics 添加。有没有办法禁用它?还是会破坏 google 分析?
提前致谢!
On Google Play devices, a background service is almost always running as "Google Play Services", so WAKE_LOCK is not required.
On non-Google Play devices, WAKE_LOCK helps keeping the dispatching process / service of Google Analytics alive so it has more chances to report / upload data.
尝试使用 "tools" 命名空间,然后明确删除 "WAKE_LOCK" 权限。我已经写了一个完整的解释 但是,总而言之:
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools">
...
...
<uses-permission android:name="android.permission.WAKE_LOCK" tools:node="remove" />
是的 android.permission.WAKE_LOCK 肯定是由 Google 添加的。他们对 Fit API 不久前添加了 GPS 做了同样的事情。跛脚
所以我刚刚将 Google 分析添加到我的应用程序的活动中。将新的 .apk 上传到 Play 商店时,它告诉我该应用现在还需要 1 个权限:WAKE_LOCK.
现在我 100% 确定此权限不在我的清单中,因此必须由 Google Analytics 添加。有没有办法禁用它?还是会破坏 google 分析?
提前致谢!
On Google Play devices, a background service is almost always running as "Google Play Services", so WAKE_LOCK is not required.
On non-Google Play devices, WAKE_LOCK helps keeping the dispatching process / service of Google Analytics alive so it has more chances to report / upload data.
尝试使用 "tools" 命名空间,然后明确删除 "WAKE_LOCK" 权限。我已经写了一个完整的解释
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools">
...
...
<uses-permission android:name="android.permission.WAKE_LOCK" tools:node="remove" />
是的 android.permission.WAKE_LOCK 肯定是由 Google 添加的。他们对 Fit API 不久前添加了 GPS 做了同样的事情。跛脚