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

We should cache data from the LoL API to reduce call times #23

Closed
PeteyPii opened this issue Nov 19, 2014 · 1 comment
Closed

We should cache data from the LoL API to reduce call times #23

PeteyPii opened this issue Nov 19, 2014 · 1 comment
Labels

Comments

@PeteyPii
Copy link
Owner

Commonly, a user will group themselves with another player many times so we could reduce the number of times we ask for recent games by using some sort of cache. The cache must be able to be reset so that we can update a player's newest stats.

@PeteyPii
Copy link
Owner Author

A simple cache is implemented. There's a temporary (short-lifed) cache for recent games API calls and then a more permanent (long-lifed) cache for summoner ID look-ups. The temporary cache is reset after the stats of all groups has been updated, but this might need to be changed in the future to after every group in the case of there being a lot more groups.

I've gotten amazing results from doing this, the API calls are 10x faster (due to not beeing throttled as much by calling the Riot API too much), however, many of my groups are very similar (good for the cache) so your results may vary.

22c1790

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant