-
Notifications
You must be signed in to change notification settings - Fork 19
FAQ
- When do we increase the minimum Android version required for the SDK?
- Which version of the SDK do we support?
- Can the Emarsys Mobile SDK be integrated with React Native apps?
- The Firebase dependencies are outdated in the Emarsys SDK. When will you release a new version with up-to-date dependencies?
- The default EmarsysMessagingService that ships with the Emarsys SDK does not suite our requirements, we need extra features. How can these features be included in the service?
- I get a 'Could not find firebase-core' error in gradle when trying to integrate the SDK.
- Push messages don't arrive to the device
- Missing Push tokens
- Missing messageOpen events
- What happens with the SDK events when the device is offline?
- What data is collected automatically by the Emarsys SDK?
Trying to support reaching a large portion of the Android device base while also increasing the quality and efficiency of the SDK by incorporating newer and newer platform features is a delicate balancing act. We track our own SDK user base and if the share of a given API level falls below 3%, we may increase the minimum API level and cease supporting devices running an API level having less than 3% share. When this happens we issue a notice at least 3 month in advance about the planned change in platform support. To be transparent, we publish updates of the device level statistics from our user base here.
Android version distribution 2020.12:
Version | Percentage |
---|---|
10.0.0 | 57.13% |
9.0.0 | 19.90% |
8.0.0 | 7.34% |
8.1.0 | 3.85% |
7.0.0 | 3.71% |
11.0.0 | 2.73% |
6.0.1 | 1.39% |
5.1.1 | 1.04% |
7.1.1 | 1.04% |
6.0.0 | 0.81% |
7.1.2 | 0.49% |
5.0.2 | 0.23% |
5.1.0 | 0.15% |
5.0.1 | 0.06% |
5.0.0 | 0.05% |
Android version distribution 2020.05:
Version | Percentage |
---|---|
9.0.0 | 36.82% |
10.0.0 | 23.01% |
8.0.0 | 10.77% |
8.1.0 | 7.52% |
7.0.0 | 6.67% |
6.0.0 | 5.81% |
6.0.1 | 3.52% |
7.1.1 | 2.24% |
5.1.1 | 1.40% |
7.1.2 | 0.82% |
5.1.0 | 0.59% |
5.0.2 | 0.31% |
5.0.0 | 0.12% |
5.0.1 | 0.11% |
4.4.2 | 0.10% |
Android version distribution 2019.08:
Version | Percentage |
---|---|
9.0.0 | 40.64% |
8.1.0 | 14.29% |
8.0.0 | 11.63% |
7.0.0 | 9.45% |
6.0.1 | 6.38% |
7.1.1 | 4.99% |
6.0.0 | 3.39% |
5.1.1 | 3.00% |
7.1.2 | 2.56% |
5.1.0 | 1.41% |
5.0.2 | 0.71% |
4.4.2 | 0.48% |
4.4.4 | 0.34% |
5.0.0 | 0.29% |
5.0.1 | 0.16% |
We only offer support for the latest version of the SDK. If you run an earlier version of the SDK and report a bug, we will fix the bug only if it is still reproducible with the latest SDK version and ask you to upgrade to the newest version when released with the bug fix. In order to minimise disturbance when upgrading to a new version, we have a comprehensive regression test suite and we do our utmost best to maintain backward compatibility. In the rare case when maintaining backward compatibility is not possible, we will provide clear indication of the functionality impacted and suggestions to mitigate the problem.
As React Native gives good support for building wrappers around platform native SDKs, using our Emarsys Mobile SDK in this way is doable, and we have an example repository here but we can not currently offer help to debug problems specific to using the Emarsys Mobile SDK in React Native applications.
The Firebase dependencies are outdated in the Emarsys SDK. When will you release a new version with up-to-date dependencies?
We are trying our best to keep our dependencies up-to-date by periodically releasing new SDK versions with updated dependency versions.
If it is urgent and you cannot wait till the new release, you can manually exclude the transitive dependencies in your module-level gradle file and add the Firebase dependencies manually.
You should replace the + signs with the most recent concrete versions.
dependencies {
implementation('com.emarsys:emarsys-sdk:+', {
exclude group: 'com.google.firebase', module: 'firebase-core'
exclude group: 'com.google.firebase', module: 'firebase-messaging'
})
implementation 'com.google.firebase:firebase-core:+'
implementation 'com.google.firebase:firebase-messaging:+'
}
The default EmarsysMessagingService
that ships with the Emarsys SDK does not suite our requirements, we need extra features. How can these features be included in the service?
The main purpose of the default FCM services in the SDK is to provide an implementation that works for you out of the box when integrating the SDK. We try to keep the services generic so that they suite the default use cases of our customers. If you have special requirements, we suggest implementing your own Firebase services based on our default implementation. When implementing your own FCM service, make sure to handle messageOpens correctly.
Here is a detailed example of how your implementation should look like:
public class CustomMessagingService extends FirebaseMessagingService {
@Override
public void onNewToken(String token) {
super.onNewToken(token);
Emarsys.Push.setPushToken(token);
}
@Override
public void onMessageReceived(RemoteMessage remoteMessage) {
super.onMessageReceived(remoteMessage);
boolean handledByEmarsysSDK = EmarsysMessagingServiceUtils.handleMessage(
this,
remoteMessage);
if (!handledByEmarsysSDK) {
//handle your custom push message here
}
}
}
Emarsys SDK handles push messages received from Emarsys by default, if you have the same implementation as in the above example, otherwise you have to track message opens by calling trackMessageOpen
method and also make sure of displaying the push.
In addition make sure that in AndroidManifest.xml
you register your own custom messaging service instead of the Emarsys one, see the example here.
This is not a Emarsys, but a Firebase issue, consult the Firebase documentation to solve the problem.
Did you download google-services.json
? If not please follow the Firebase documentation to setup your app with Firebase first.
Make sure the connection to Firebase is not limited by company firewall rules.
Make sure you see push tokens in your SDK Logs inside Mobile Engage UI
Make sure you registered our EmarsysMessagingService
in your AndroidManifest.xml
.
Make sure you registered our EmarsysMessagingService
in your AndroidManifest.xml
.
Emarsys SDK features an offline queue. All SDK events including e.g. logins, logouts, custom events, Predict related view and click events and requests enter this queue first. As long as the device is online, this queue is processed and events get sent to the backend continuously. While the device is offline, the queue stores the SDK events temporarily and when the SDK detects that network connectivity is back, it restarts the event sending. The events stay in the queue until response from the server is received, so the SDK can resend events in case a network error or a timeout occurs during sending or the server responds with a recoverable error code. If the server responds with a non-recoverable error code, e.g. authentication failure, the event is discarded.
For globally available features:
- app:start event whenever the mobile app is launched
- anonymous login and device info when the SDK sees a mobile device for the first time
- device info includes device platform, device language, device timezone, device model, application version, os version, Emarsys SDK version, push token if available
- push: open and action button click events
- in-app: view and action button click events
- trackDeepLink events but only in case your Activity has no onNewIntent overriden
For features requiring pilot agreement:
- geofence: enter events