chore(serverinfo): drop POLL_INTERVAL 30s -> 4s - #3
Merged
Conversation
Matches the landing-page poll cadence (data-poll-interval=4000ms in _data/site.yaml). At 30s, every 7th browser fetch hit fresh upstream data and the other 6 returned a stale cached JSON, so player counts and round durations stepped 30s at a time on the page. DD-side cost is negligible: - /world/Topic ?status is a sync proc, sub-millisecond per call - 7.5x more calls = ~0.025% of one core on DD main thread - One additional 700-byte atomic file write every 4s The public-log-parser also polls this same file (every 60s per its config) for ongoing-round protection; its semantics are unchanged. Companion change: ReduxStation/website#8 adds a 1Hz client-side ticker so the displayed round_duration increments smoothly between the 4s server polls. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
What
`docker-compose.yml` `serverinfo-updater.POLL_INTERVAL` 30 -> 4.
Why
Matches the landing-page `data-poll-interval=4000` so every browser
fetch hits fresh upstream data instead of the same cached JSON for 7
out of 8 polls.
Cost analysis
~0.025% of one DD-main-thread core at 4s cadence.
cache, not disk per write.
ongoing-round protection semantics unchanged.
Companion
`ReduxStation/website#8` — 1Hz client-side ticker on `round_duration`
so the displayed clock doesn't step 4s at a time even with this
shorter interval.
Deploy