I am going to take a crack at building a penny auction site for a specific niche using angular JS. I am trying to plan the countdown timers and i've been itching for a reason to try out firebase.
I had the idea yesterday to have each auction somehow have a countdown in the actual database, because with 2 way data binding, peoples clientside will always stay updated.
When the firebase changes, all the connected clients instantly change. So my question is this... How could I do a server side countdown within a particular record.
So say I had a record for item x and it had all that items information and one of the array keys is "countdown: 59:01:00". What is a realistic and scalable way to countdown from 59:01:00 to 00:00:00 on the SERVER side.
I was thinking maybe a cronjob that runs every 1 second? But then with hundreds of database entries running hundreds of countdowns each second, the server would probably crash.
Any good ideas?