Questions regarding using Firebase in SasS Offering

170 views
Skip to first unread message

Rafael Ubaldo

unread,
Apr 3, 2017, 8:49:30 PM4/3/17
to Firebase Google Group
I am considering Firebase and Google Cloud Platform as the backbone infrastructure for my startup. My goal is to build the infrastructure for a web/mobile app on the Firebase platform to get to market as fast as possible. 

I am trying to evaluation smart usage of Firebase in my stack in the following context: 

Organizations, companies, and or individuals will sign-up to use my app. They will have custom content and product listing managed through a Dashboard area in my app. Their customers will also have accounts dashboards to track the status of their orders, etc.

Consideration: 
  • I need real-time content and per-user activity feeds/notifications. It would appear I can use Firebase to deliver presence functionality and basically skip playing with web sockets entirely (?). 
    • Example: Users can have notification and action feed synchronized and brokered through Firebase (?). I like the integration with Google Cloud Messaging (for offline users and device notifications). Does Firebase have solutions to handle offline vs. online presence solutions to handle the per-user notification differently?
    • Example: Users viewing a current listing of feed/posts on screen can review real-time updates as those change and comments are added. I could potential subscribe/unsubscribe to a listing of posts as the user scrolls (?). How efficient is that in Firebase? 
  • Users pools and groups will need to be established with varying permissions. Can Firebase Auth handle this efficiently? What's the best way to handle RBAC on Firebase? 
  • Is it advisable to create a separate database per customer? Is there anyway to provision Firebase projects and database from my code pipeline or using an API? Say like XYZ signs up and I create them a database and charge them for the resources they use independently.  
  • Considering scenarios to have our service as a Google Cloud Platform ad on for more advanced customer. Anyone have war stories with this?
Any suggestion and or advice would be appreciated.

Regards,
Rafael Ubaldo

 

Kato Richardson

unread,
Apr 4, 2017, 12:37:31 PM4/4/17
to Firebase Google Group
Hi Rafael,

Great questions. More inline.

On Mon, Apr 3, 2017 at 3:52 PM, Rafael Ubaldo <rafael...@mac.com> wrote:
I am considering Firebase and Google Cloud Platform as the backbone infrastructure for my startup. My goal is to build the infrastructure for a web/mobile app on the Firebase platform to get to market as fast as possible. 

Your app looks like a great fit so far.
 
    • Example: Users can have notification and action feed synchronized and brokered through Firebase (?). I like the integration with Google Cloud Messaging (for offline users and device notifications). Does Firebase have solutions to handle offline vs. online presence solutions to handle the per-user notification differently?
Not sure what that means. You can use our presence tools together with Cloud Messaging. The easiest way to connect the two is through Cloud Functions for Firebase.
    • Example: Users viewing a current listing of feed/posts on screen can review real-time updates as those change and comments are added. I could potential subscribe/unsubscribe to a listing of posts as the user scrolls (?). How efficient is that in Firebase? 
It's really all about the byte counts. More bytes means slower. Less bytes means faster. In my experience, Firebase is generally sub 40 ms in the US assuming 1KB of data in the payload. It's around 100-500ms worldwide with the same assumptions.

  • Users pools and groups will need to be established with varying permissions. Can Firebase Auth handle this efficiently? What's the best way to handle RBAC on Firebase? 
That's not a function of Firebase Auth. Role management is done with a combination of security rules and database data (i.e. store the relationships in the DB and add security rules to enforce based on that data). Or via some other implementation you design and build.
 
  • Is it advisable to create a separate database per customer?
Probably not, although you probably want to use multiple dbs for your various tenants as your app expands. You'll have to decide how best to load balance those (probably based on customer size and estimated daily active users). 
  • Is there anyway to provision Firebase projects and database from my code pipeline or using an API?
No. You have to manually create projects/dbs.

I hope that helps!

☼, Kato
Reply all
Reply to author
Forward
0 new messages