Firebase is Google's new and improved mobile development platform in the cloud. It is a platform available for different platforms (Android, iOS, web), with what of this form present a serious alternative to other options for saving time in development as Xamarin .
Firebase was created by Google, its main function is to develop and facilitate the creation of mobile apps , firebase started thanks to Google that I bought it in 2014 and it was improving thanks to the purchase of divshot.
What services do you offer us?
The services offered by firebase are the following:
- Google Analytics for firebase
- Firebase Realtime Database Firebase Hosting
- Cloud Functions for Firebase (Beta)
- Firebase Crash
Now let's see, one by one, the most outstanding services offered by Firebase to work in a more simple in our application.
The firebase database stores and synchronizes the data with our database, all this is hosted in the cloud (internet) these data that are in the cloud are stored in JSON and rules can be added to allow requests with token or only from a URL and the data of the base are synchronized with all the clients in time This really helps a lot when the app does not have an Internet connection.
The firebase application responds even if it does not have internet this is thanks to the SDK (software development kit) Firebase database Realtime makes our data persist on the disk, when the connection returns the device recognizes it and saves it in the current service
It is a service that simplifies us the beginning of session and the management of it in our application. If we use it in applications Web or Android Studio is extremely easy to configure, with a simple method we can save a user with your password and mail. Firebase saves connection data in the cloud securely so that applications log in with the saved account
The firebase storage service is called Cloud Storage is a service that stores powerful objects SDK (software development kit) of firebase for cloud Storage give you Google security when downloading or uploading a file, regardless of the network quality you have, It is very good for applications that require saving user files. It also helps us if we want to upload static since there is a button from the interface or we can program something. In the application that I am currently developing it helps me upload photos of restaurants and access to them at any time.
With a static collection we can upload an application and this will automatically have SSL and HTTP2.No need to configure nothing so that the content is safe. If we have an app with Angular or Firebase we can make a build from our computers and upload these generated files and they will work for us without problems. If we need a Backend we would have to upload it to another place or make use of Cloud Functions.
When you upload a file it is stored in the SSD cache, this is very good if the content has to be delivered. will deliver quickly.
How can we implement the Hosting in our Firebase?
To implement the Hosting, the first thing you have to do is go to the Firebase Hosting page. This can be found inside your project then you start once you have to have installed the following CLI (This is a line tool of command), Node.js and rpm once this is done you start the node.js acedes to your firebase that you have already activated with the command firebase login once activated you have to go to the root of your project directory that you have to do this you have to put the firebase init command. This command will create a file firebase.json this file is file configuration of Hosting thanks to the CLI you can customize the configuration of the hosting that we will create. Once the previous command has been made you have to implement it in your firebase site to do this we put the command firebase deploy with this command implements an update in the Hosting once this is already implemented in our project then you have to be able to edit what you want and store what you want
Cloud Functions (BETA)
Cloud Functions is a fairly recent Firebase product that aims to transform our code of the backend in small pieces of it (functions). These functions are created in NodeJS and are uploaded asynchronously from our application. When created generate a URL that we can call from AJAX to run the code relevant. Firebase provides us with some triggers to communicate with certain functions of their products.
The code we make is stored in the Google cloud and can be run in a managed environment. help you do not need to manage your own server
Test lab for Android
This section is my favorite, because, like any Android developer when implementing changes in my app I have to try them a thousand times to cover any possible error, which in many cases can reach overwhelm. This service offers us the possibility to test the tests of our application in the environments that we configure (Device, IOS version), so it does a great part of the work.
All these tests on Android are done with a matrix created by you so you can validate your application.
With this utility we can detect the errors that appear in our iOS and Android applications as well as be able to eradicate them in time. This tool will soon give way to Fabric's Crashlytics, which will be integrated as one more tool. Today we can use both but my recommendation is that you use Crashlytics because it is the tool that will be established in the future.
For you to report errors on the server it is recommended to use Google StackDriver Error Reporting this will help to support Node.js, python, java, etc errors
This tool will help you measure the performance of your application and the time that users spend during the different processes of the same in order that you can detect problems in loading time and prevent them before they cause any other kind of problem or that users delete your application.
Performance monitoring helps you improve the performance of your iOS and Android applications, also with the SDK (software development kit) of Performance Monitoring you can collect the data of your application and then be able to review and analyze the data in console (firebase console)
This service will allow us to manage the sending of notifications in a safe and free way to our users with the difference that these can be programmed according to different parameters.
This addition will allow us to basically modify the behavior and appearance of our application that is in the cloud without our users having to touch anything and not download any updates for example:
You can change the values say the design or modify a font etc.
With dynamic links we can ensure that despite the redirections involved in the process of installing an application from an ad, we reach the desired view, thus gaining an experience that the user will appreciate.
If a user opens a dynamic link on iOS or Android this can lead directly to linked content This would be the same if you open in a desktop browser. Dynamic links always work until there is to install the application
How does dynamic link work?
The operation of the dynamic link to create it the first thing you have to do is form URL and that URL has to be added to the parameters of the dynamic link, with those parameters we specify the links that you want to open that if you first have to have installed in your application because if it is not installed will take you to the play store for you to install and so you can perform dynamic link.
Through this service we can place mobile advertising on different sides of our application. Many free applications such as some games have implemented this system of advertising or similar. Our ads can be video or an image
If you use Admob with Google Analytics firebase we will obtain an additional function that will be of analysis and also the usage data in the application, this would help a lot so that we can analyze ad
Languages compatible with Firebase
The languages supported by Firebase are the following:
- iOS (Swift and Objective C)
- Android (Java and Kotlin).
- Python and Java applications.
- C ++ and Unity.
Firebase usage cost
- Spark (Free)
- Flame (€ 25/month)
- Glaze (Price according to your needs)