Open NaughtyMuppet opened 6 years ago
How frequently will we be requesting the stats to check if there is a change?
i'd propose to have 2 kinds of monitoring:
this just makes complete snapshots every now and then (app start/end maybe) then we'll end up with the same kind of stats as the website before
here we can probe the operator stats every minute or so to check if something changed. if it changed -> round ended and we can diff the stats to get the round k/d/playtime/operator it didn't change -> might just be a time issue it didn't change for 2 checks -> the match ended and we can build some object off of it
edit: assuming of course that the endpoints update quickly enough
Idea is to start monitoring the stats for user, take a snapshot in the beginning, and while running, it scans for operator stats.
If operator win/loss increases we know that that round ended and we can check casual wins/losses and ranked wins/losses to know if the match ended. From this we can write entries into round/match/session tables.