-
Notifications
You must be signed in to change notification settings - Fork 5
Frequently Asked Questions
We know that SDK size impact is an important factor, and we continue to do everything we can to pack iProov's advanced technologies into as small a payload as possible. We get asked this question quite a bit, and it's a hard one to answer.
The short answer: It depends. Approximately 500 KB in typical cases.
The long answer:
When assessing the size impact, a key aspect will be to consider how many (if any) dependencies are shared between the iProov SDK and your app.
The iProov Android SDK has the following dependency tree:
+--- io.socket:socket.io-client:0.9.0
| \--- io.socket:engine.io-client:0.9.0
| \--- com.squareup.okhttp3:okhttp:3.8.1
| \--- com.squareup.okio:okio:1.13.0
+--- com.android.support:appcompat-v7:28.0.0
| \--- (Dependency tree truncated)
+--- com.android.support:exifinterface:28.0.0
\--- com.android.support:support-annotations:28.0.0
So if for example your app already uses OkHttp (or another library which depends on OkHttp, such as Retrofit), or the Support Libraries, or uses Jetifier to convert to AndroidX, it will cause a difference in the size impact that the SDK will have on your app.
In addition, app downloads from Google Play are compressed, which further reduces the SDK size impact.
Since the size impact of the iProov SDK depends heavily upon the configuration of your existing app, it is impossible to provide an accurate determination of size impact across all possible scenarios.
However, to provide a rough estimate, we followed the following procedure:
A. Produce a basic app with the iProov SDK included, and generate an APK
B. Modify the same app to remove the iProov SDK, and generate an APK
We then analyzed both SDKs using the built-in Android Studio tools, which showed that the addition of the iProov SDK added approximately 500 KB to the download size of the APK.
NOTE: This does not include the addition of the optional iProov Firebase module (not required by most customers). The Firebase module itself is extremely lightweight and just acts as a thin wrapper around Firebase, so almost the entire size impact of adding Firebase will come from Google's Firebase library itself.
These calculations were performed in February 2020 using Android Studio 3.5.3 and are correct as of iProov SDK 5.0.0.
On some very low-end devices, the system performance is insufficient to provide a smooth iProov experience. We are always looking at optimizing the Android SDK experience on low-end devices.
You should also ensure you are not running the SDK with the Android Studio debugger attached as this has a significant performance impact. You should also check the Known Issues page
iProov Android SDK 6.0+ uses AndroidX, therefore if using the latest versions of the Android SDK, you must use AndroidX.
If you are still using Android Support Libraries, you must continue to use iProov Android SDK 5.x (deprecated). We would encourage you to move to AndroidX as soon as possible.
For most cases, leave this value as null
(default).
In some cases, you might want the iProov Activity to be started using startActivityForResult()
instead of startActivity()
. Typically, this is because your Activity has launchMode="singleInstance"
set in the manifest, due to a strange side-effect of how singleInstance
Activities are handled in Android. Note: This is strongly discouraged by both Google and iProov!
If you must use singleInstance
for whatever reason, then ensure that you pass your calling Activity as the context to IProov.launch()
and set a value for options.ui.activityCompatibilityRequestCode
, which will be the requestCode
for the result. This allows you to identify (and ignore) the result from iProov (which is always zero) in onActivityResult()
if you have already implemented it.