Free email course on building IoT with Cloud IoT CoreCloud IoT Core
Free email course on  
Connectivity in IoT
Thanks for signing up! You'll get the first email soon.
Oops! Something went wrong while submitting the form.
< Back to Blog

Since its founding, Firebase has had a profound impact on the database community, and we’ve used it ourselves here at Leverege. Firebase allows for the automatic synchronization of data across any number of connections, meaning there’s no need to poll a database service. When data is updated, all of the clients are notified of the change.

Despite this advancement, Firebase isn’t perfect and we’ve run into some issues here and there. For instance, in the case of large datasets Firebase requires sharding in order to store data and remain performant. However, this is addressed with Google’s new product Cloud FireStore, which is intended to be a more robust, full-featured version of Firebase. Here’s what we’ve learned while using it:

Cloud Firestore

One major improvement that Firestore supports over Firebase is the automatic scaling with no need for sharding. In its current state, Firebase’s performance tops out at 100,000 connections or 1,000 writes/second. It’s also recommended that Firebase be sharded into multiple databases, which significantly grows the complexity of the system.

Firestore, on the other hand, does not have this limitation, and in theory automatically scales to whatever number of connections and writes are necessary for your system. 

In addition, Firestore allows for data storage when applications go offline, even in a web environment, which can allow applications to be more fault tolerant when network connectivity is limited. Firebase is capable of this on Android and iOS clients, but only Firestore is capable of functioning offline in every environment. This simplifies code differences between platforms, and ensures that cached data can always be utilized during breaks in network connection.

Finally, Firestore features more robust transactions and querying systems than Firebase, making it more synchronized and more efficient to search. Beyond Firebase’s functionality, Firestore allows for atomic batch operations, which ensures that a group of changes take place as a single transaction. Additionally, Firestore supports shallow queries, better indexing, and filter chaining, all things that Firebase is not capable of due to its structure as a JSON tree.

The only downside to Firestore that we’ve encountered right now is that it’s in Beta, so it should be avoided in production environments. However, Firestore is a more stable, scalable, and ultimately well-thought-out database than Firebase, and is already shaping up to be a powerhouse in the database ecosystem as we move into the future.

Have Questions? Talk to an Expert

James Schaefer

James is the Director of Engineering at Leverege. He graduated from NC State University in 2016 with degrees in Computer Science and Textile Engineering. His writing focuses on development and security.

SHARE

Liked this post? You're gonna love these!

Leveraging Computer Vision for Asset Tracking Solutions
November 28, 2018
Top 3 Best Practices for Designing Geofencing Applications
November 16, 2018
Market Research for Indoor Asset Tracking Solutions
November 15, 2018

Talk with Leverege

What type of use case are you building for? Whichever it is we are looking forward to learning more about your needs.

Have Questions?

Our team of experts is here to help!

Thanks for your submission! Our team is looking forward to connecting with you and will be in touch very soon!
Oops! Something went wrong while submitting the form.