Brief Dive Into Firebase – Unified App Development Platform

During IO 2016 Google launched next generation of Firebase. Firebase started as a cloud based real time database service provider, now offers variety of services along with the required infrastructure support for Android, iOS, and mobile web platforms.  Since Facebook has announced Parse’s exit there is a growing interest for Google’s Firebase. Through Firebase, Google is trying to build closer relationship with developer community  by helping them to develop apps faster, improve quality of apps, and monetize apps. Firebase is Google’s Mobile backend as a service (MBaaS) for apps across three major platforms. Google is trying to bring more users into mobile app market through heavy user engagements. This is possible with the combination of Firebase’s Analytics, Cloud Messaging, Notification, Dynamic Links, App Indexing, etc. Let’s look at them one by one.

Overview_Firebase

Test Lab

Buying stack of devices and testing on them is a huge pain for android developers. Firebase has come up with the idea of providing cloud based testing platform called Test Lab. This feature is available under Blaze (pay as you go)pricing plan. Test Lab offers variety of target devices and testing methods to test Android applications.  Espresso, Robotium and Robo tests are available. These tests are initiated through Test Lab console or command line interface or Android Studio. Test results are accessible from Test Lab UI and  Google cloud command line. A small exercise is available on how to use Test Lab.

Crash Reporting

For crash reporting solution, most of the mobile apps  depend on third party libraries such as Fabric’s Crashlytics and AppCrash . Google has introduced new crash reporting solution which is available for both iOS and Android. Sebastiano Gottardo’s medium post highlights the key differences between Firebase’s Crash Reporting  and Crashlytics. Crash Reporting is still in beta version and therefore expected to have plenty of improvement.

Firebase Cloud Messaging (FCM)

Google Cloud Messaging (GCM) is integrated into Firebase to form Firebase Cloud Messaging as a part of unification. FCM is a free and cross-platform (Android, iOS, and Web) cloud to device push messaging service. FCM is built for scale, sending nearly 170 billion messages per day to two billion devices. Instant messaging services can use FCM with each message can transfer 4KB of data to user client. Moving forward existing GCM client applications (Android, and iOS )need to migrate to FCM. Apurv Pandey’s blog provides detailed analysis and comparison of FCM with GCM.

Firebase Analytics (FA)

Firebase Analytics is a free, unlimited, mobile app/web user and event based analytical solution. James Keener’s blog brings out the noteworthy features (User Based Reporting and  Audience) of FA that are relevant to mobile apps.For web platform Google Analytics 360 (GA) is still the best available analytical solution. Andy Gibson’s blog makes the case of choosing FA vs GA by bringing the key differences between them. Sebastiano’s answer in Stack Overflow brings greater clarity on FA vs GA. FA User Based Reporting and Audiences integrated with other Firebase services such as BigQuery for custom analysis, Crash Reporting for understanding crashes for different versions or regions , and  Notifications bring deeper insights into users and their pattern of engagements.

Notifications, Dynamic Links, App Indexing, AdWords and  Invites

Firebase Notification is similar to FCM, built on top of FCM APIs. Notifications helps to re-engage users and target messages to Audiences in Analytics.  Send to a user segment, send to a topic and send to a single device are the three types of target available in Notification. A sample project from Firebase helps to understand how to send notification.

Composing Notification Message

Google’s App  indexing is a powerful way of reaching into the app when a user searches for related content on Google search.  Its key capabilities include promoting the app in Google’s search results, adding install card next to the website on search result, auto completion to add the app  while searching relevant content. The codelab exercise walks through App Indexing API for android app.

Google’s AdWords is now available in Firebase platform. Linking Firebase with AdWords makes the the app reach larger customer base.

Firebase Dynamic Links direct the users to install the app from web, based on the content  and  also, to navigate to the desired feature or content within the app that brought the users to the app in first place. Hence, apps can be more interesting and engaging with the users instead of showing uninterested content. Dynamic Links helps in custom first user experience, dynamically control the user experience across Android, iOS, desktop and mobile web, and track the features that are adding to app growth. Deep linking technology provider Branch has an interesting comparison between Dynamic Links and their Branch Links.

Built on Dynamic Links, Firebase Invites help the users to share the content like promotional code or app details via SMS or email.

User Authentication and Hosting

Firebase simplifies authentication for  both developers and users. Also, it provides authentication through federated identity providers like Google, Facebook and Twitter, etc. Firebase’s video explains more on that.

Firebase Hosting is a developer oriented, fast, secure and reliable static web hosting provider. Firebase’s Chris Raynor explains about Hosting features. Examples of Firebase Hosting: Colin’s blog desiredpersona-Host Jekyll on Google Firebase Hosting and  Firecasts episode -Deploying to Firebase Hosting from GitHub.

AdMob

For greater revenue generation from the app and to bring AdMob closer to developers, Google integrated AdMob with Firebase. Video tutorials on AdMob are available from Firebase.

Note: 1) Firebase paid products are Realtime Database, Firebase Storage, Hosting, and Test Lab. 2) Analytics, App Indexing, Authentication, Dynamic Links, Cloud Messaging, Notifications, Invites, Crash Reporting, &, Remote Config are available under free spark plan.

In conclusion, Firebase has brought features like Test Lab and Crash Reporting on board to help developers for improving the app quality. Firebase offers many unlimited services for free and hence it’s advantageous for budding apps. Firebase is an excellent example of Sundar Pichai’s vision of providing scalable, integrated and developer friendly solution platform benefiting wider section.

 

Learning Dependency Injection in Android

Recently I came across ‘ Dependency Injection’ (DI) which is a well-known design pattern in software development/testing framework.  James Shore in his article Dependency Injection Demystified says, “Dependency Injection” is a 25-dollar term for a 5-cent concept. But the devil is in the implementation. For android like framework, interaction between the objects are far complex […]

Android books for beginners

Here are the set of books for beginners to start off with Android app development. Android in Practice by Charlie Collins, Michael Galpin, Matthias Kaeppler, 2011 Pros: Most of the android books explain ‘how’ rather than ‘why’. As a beginner to android it’s very important to understand the reasons behind the implementations and more importantly […]