BMBros / TriviaAPI

1 stars 0 forks source link

Use Firebase realtime DB? #4

Open sdg9 opened 7 years ago

sdg9 commented 7 years ago

@wsguede

https://firebase.google.com/docs/database/

Use cases

  1. User
    1. User logs in
    2. User receives question prompt
    3. User answers question
    4. User awaits for next question
    5. User loses connection, reconnects, and "restores" session
    6. Users see score screen or previous/current score?
  2. Admin
    1. Admin logs in
    2. Admin views data
    3. Admin marks answers correct/incorrect
    4. Admin shows score screen

Firebase would solve 1.2 - 1.4 really well, without requiring custom websockets. It also would in effect act as a free db. There may not be much/any server side logic required otherwise.

While this would save a lot of DIY work, may not be ideal if goal is to learn spring and DIY.

sdg9 commented 7 years ago

Roll 20 uses firebase (or at least they used to) in place of rolling their own db + websockets.

We actually don't need a ton of complex logic and this may provide an easy and free solution to much of our required infrastructure.