Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clan cache warmup #520

Closed
fcaps opened this issue Dec 3, 2023 · 0 comments
Closed

Clan cache warmup #520

fcaps opened this issue Dec 3, 2023 · 0 comments
Assignees

Comments

@fcaps
Copy link
Collaborator

fcaps commented Dec 3, 2023

as described in PR #519
clans (getAllClans()) could benefit a warmup like we did it for leaderboardCacheCrawler.js.
warmup a single clan is too much, since the call is ~500ms and this i can take a cache-looser.

Acceptance Criteria:

  • cache will be generated at server start/restart
  • will be scheduled to refresh it every (ttl - 1min), currently this would be 59min
  • should not run in parallel with other JavaApi calls if possible (ddos ourself if the list of crawlers getting bigger)
  • should not crash the server if the JavaApi is not reachable or and exception is happening.
  • should log if a cache was getting refreshed or when something failed
@fcaps fcaps self-assigned this Dec 5, 2023
@beckpaul beckpaul assigned beckpaul and unassigned fcaps Dec 5, 2023
@beckpaul beckpaul pinned this issue Dec 6, 2023
@beckpaul beckpaul unpinned this issue Dec 6, 2023
fcaps pushed a commit that referenced this issue Dec 6, 2023
* create crawler

* Add crawler to cron scheduler

* change indentation for a sane line length

* cleanup - add comment

* cleanup wordpress cache job

* more clean

* add opts to cache service - logging for testing

* undo opts to cache service

* remove logging

* change ttl on clanService
@fcaps fcaps closed this as completed Dec 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants