Closed geerlingguy closed 1 year ago
Making some headway on this:
Have to get all timey-wimey and use some javascript wizardry to keep that countdown fresh though.
Gonna be a little rough doing it all real time :/
Disabling the button game on the production servers for now (one less thing to keep running).
At this point, very likely not gonna happen before go-live.
And at this point, very likely to happen after go-live. Need to gather some requirements.
New frontend for timer countdown bit, at least...
Just did a load test with the whole thing running, and got at least 1000 votes per second throughput with the frontend updating every second:
Thread Stats Avg Stdev Max +/- Stdev
Latency 2.18ms 4.07ms 60.89ms 93.96%
Req/Sec 711.21 130.47 1.07k 71.00%
Latency Distribution
50% 0.93ms
75% 2.17ms
90% 4.49ms
99% 20.83ms
7088 requests in 5.01s, 1.49MB read
Non-2xx or 3xx responses: 4070
Requests/sec: 1415.13
Transfer/sec: 305.36KB
And I also traverse the dom like a madman to get all the classes set correctly via Javascript (and otherwise, the page refreshes and shows the latest data if JS is broken):
I've also added a 'force reset timer' functionality that turns a room 'on' again and saves a vote so you can see it's back active. This should be helpful for debugging, and for the case where someone's buttons just stop working, for whatever reason. They could kinda 'pause' the game for that room.
I don't have any other pause functionality, though. The game will continue pretty much forever, until all rooms are counted down to 0.
I added functionality to force reset ALL live
room's timers:
UPDATE: Here are the requirements:
time_seconds
) time, and the number of button presses for the room.UPDATE
the room and setcolor
=red
andtime_expired
=1
.refresh_timer_data()
intimers.js
before go-live!