op-dispute-mon: Use game data from previous update cycle if update fails #12481
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Cache the game data from previous update cycles and use it for any games that fail to update in this cycle. Updating game data is an all or nothing thing to avoid getting a mix of old and new data in the same game.
A new metric is added to report the time the least recently updated game was updated. Metrics could already alert on the number of failed games being > 0 for some period so no new alerts strictly needed. The new metric would allow for extra tolerance in a situation where there were a lot of errors, allowing some failure every update cycle so long as it wasn't always on the same game. Mostly the new metric is just useful to show on dashboards and more meaningful that the current "Last Output Fetch" time.
Tests
Added unit tests and ran locally to confirm behaviour.
Metadata
fixes #12454