Status Update
Comments
mo...@tothenew.com <mo...@tothenew.com> #2
I am not sure I understand the use case. how can the benchmark be code to real world scenario when it's not possible to do right now ? which scenario is it ?
In any case, since this would be for benchmarking, this would clearly not be available through the public DSL. We should find a semi-private way of doing this (maybe the private variant API object could offer that functionality for instance or a property).
mo...@tothenew.com <mo...@tothenew.com> #3
We want benchmarks to measure code after Progaurd / R8, but it's not possible to turn that on for androidTests in library modules at the moment (to my knowledge?)
Benchmarks are also a public facing thing, but we have a plugin to help configure gradle builds for our users, so if support for this ends up in a private API, we could try to keep those usages localized to our code perhaps.
Description
Devices/Android versions reproduced on: see each ANR report
Got a bunch of ANR cluster reports in Play Console after releasing an update that uses EncryptedSharedPreferences:
Code
SharedPreferences by EncryptedSharedPreferences.create(
mContext,
"$ENCRYPT_FILE_PREFIX$file",
MasterKey.Builder(mContext)
.setKeyScheme(MasterKey.KeyScheme.AES256_GCM)
.build(),
EncryptedSharedPreferences.PrefKeyEncryptionScheme.AES256_SIV,
EncryptedSharedPreferences.PrefValueEncryptionScheme.AES256_GCM)
library version androidx.security:security-crypto:1.1.0-alpha03 (we need to support from 21)
Many ANR on Samsung's 9 OS devices
```
#00 pc 000000000005589c /system/lib/libc.so (__ioctl+8)
#00 pc 0000000000022363 /system/lib/libc.so (ioctl+38)
#00 pc 000000000003d863 /system/lib/libbinder.so (android::IPCThreadState::talkWithDriver(bool)+206)
#00 pc 000000000003e339 /system/lib/libbinder.so (android::IPCThreadState::waitForResponse(android::Parcel*, int*)+240)
#00 pc 000000000003729d /system/lib/libbinder.so (android::BpBinder::transact(unsigned int, android::Parcel const&, android::Parcel*, unsigned int)+36)
#00 pc 00000000000cacd3 /system/lib/libandroid_runtime.so (android_os_BinderProxy_transact(_JNIEnv*, _jobject*, int, _jobject*, _jobject*, int)+82)
at android.os.BinderProxy.transactNative (Native method)
at android.os.BinderProxy.transact (Binder.java:1145)
at android.security.IKeystoreService$Stub$Proxy.exist (IKeystoreService.java:932)
at android.security.KeyStore.contains (KeyStore.java:366)
at android.security.keystore.AndroidKeyStoreSpi.engineContainsAlias (AndroidKeyStoreSpi.java:1037)
at java.security.KeyStore.containsAlias (KeyStore.java:1293)
at d.r.a.c.b
at d.r.a.c.b
at d.r.a.b$b.b
at d.r.a.b$b.a