Last modified August 1, 2019 by Gordon Glauser

Android SDK upgrade guide

This guide provides information about how you can upgrade to the latest Swrve Android SDK. For information about the changes that have been made in each Android SDK release, see Android SDK release notes.

Upgrading using Maven

If you’re integrating the Android SDK libraries using Maven from the Swrve repository on Jcenter, update the build.gradle to use the latest version (for example, compile 'com.swrve.sdk.android:swrve-google:6.2.0'). For more information, see the Android integration guide.


Version 6.2

If you are upgrading from a version prior to 6.0, see below. Otherwise, there are no code changes required to upgrade to Swrve Android SDK v6.2.


Version 6.1.1

If you are upgrading from a version prior to 6.0, see below. Otherwise, there are no code changes required to upgrade to Swrve Android SDK v6.1.1.


Version 6.1

If you are upgrading from a version prior to 6.0, see below. Otherwise, there are no code changes required to upgrade to Swrve Android SDK v6.1.


Version 6.0.2

If you are upgrading from a version prior to 6.0, see below. Otherwise, there are no code changes required to upgrade to Swrve Android SDK v6.0.2.


Version 6.0.1

If you are upgrading from a version prior to 6.0, see below. Otherwise, there are no code changes required to upgrade to Swrve Android SDK v6.0.1.

If you are in the process of upgrading to Android SDK v6.0, please use v6.0.1 instead, as it addresses an important fix to an issue with user identity that was introduced in version 6.0. Do not use Android SDK v6.0.

Version 6.0

This section provides information for upgrading to Swrve Android SDK v6.0.

Removed Summary
swrve-google flavor of SDK If you are currently using the swrve-google flavor of the SDK, you must migrate to swrve-firebase. For more information, see How do I migrate from Google Cloud Messaging to Firebase?
Empty constructor for SwrveNotifcationConfig.Builder(). You must now pass small notification icons and NotificationChannel into the SwrveNotifcationConfig.Builder() constructor.
SwrveNotifcationConfig title Removed the configuration of notification title from SwrveNotifcationConfig.
userId property from SwrveConfig To set a custom user ID, use our new Identify API call. For more information, see the Android integration guide.
Default configurations of how notifications are displayed using <meta-data> properties in the AndroidManifest.xml. Use the SwrveNotificationConfig instead.
Configuration of default channel via SwrveConfig This has been added to the SwrveNotificationConfig.
SwrveFirebaseInstanceIdService The SwrveFirebaseInstanceIdService class was deprecated in SDK version 5.3 and has been completely removed in 6.0. Remove this from your AndroidManifest.xml if you haven’t already.
SwrveSDK.setPushNotificationListener The SwrveSDK.setPushNotificationListener method was deprecated in SDK version 5.3 and has been completely removed in 6.0. Use SwrveConfig.setNotificationListener instead.
Removed configuration of HTTP from SwrveConfig The SDK now only supports HTTPS.
Moved To
SwrveAdmMessageReceiver Moved from com.swrve.sdk.adm.SwrveAdmMessageReceiver to com.swrve.sdk.SwrveAdmMessageReceiver. Update your AndroidManifest.xml.
SwrveAdmIntentService Moved from com.swrve.sdk.adm.SwrveAdmIntentService to com.swrve.sdk.SwrveAdmIntentService. Update your AndroidManifest.xml.
SwrveFirebaseMessagingService Moved from com.swrve.sdk.firebase.SwrveFirebaseMessagingService to com.swrve.sdk.SwrveFirebaseMessagingService. Update your AndroidManifest.xml.

Version 5.3.2

There are no code changes required to upgrade to Swrve Android SDK v5.3.2.


Version 5.3.1

There are no code changes required to upgrade to Swrve Android SDK v5.3.1.


Version 5.3

This section provides information for upgrading to Swrve Android SDK v5.3.

Firebase Messaging Upgrade

SwrveFirebaseInstanceIdService is now deprecated. No additional steps are required, as this upgrade simply removes it from your manifest.

Migrating from GCM to FCM

In line with Google’s decision to remove support for Google Cloud Messaging (GCM) by April 2019, we have deprecated the swrve-google flavor of the Android SDK in version 5.3 and will remove support for it in version 6.0 later this year. You must migrate your app to use Firebase Cloud Messaging (FCM). For information on how to migrate from GCM to FCM, see the FAQ article How do I migrate from Google Cloud Messaging to Firebase? or contact your Customer Success Manager at support@swrve.com if you require further assistance.


Version 5.2

This section provides information for upgrading to Swrve Android SDK v5.2.

OTT Platform Support

Swrve Android SDK 5.2 includes support for Android TV and Amazon Fire TV platforms. There are no additional installation or integration steps, however you must update the Android API level to 21 (the minimum required to run Android TV).


Version 5.1.1

There are no code changes required to upgrade to Swrve Android SDK v5.1.


Version 5.1

There are no code changes required to upgrade to Swrve Android SDK v5.1.


Version 5.0

This section provides information for upgrading to Swrve Android SDK v5.0.

API Changes

With the release of Swrve’s Android SDK version 5.0, we have made major changes to the APIs to ensure internal consistency and improve SDK integration. For a complete list of the changes you need to make, see the Android SDK 5.0 Upgrade Guide.


Previous versions

If you are upgrading from a version older than 5.0, please refer to the Android SDK 5.0 Upgrade Guide and Android Integration Guide.