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

Cache API calls or results #21

Open
wallacio opened this issue Apr 3, 2020 · 1 comment
Open

Cache API calls or results #21

wallacio opened this issue Apr 3, 2020 · 1 comment

Comments

@wallacio
Copy link

wallacio commented Apr 3, 2020

Thanks for writing this plugin, it's going to save me a bunch of time.

This might be more of a generic MODX question but I'm wondering about the possibility of caching results to minimise unnecessary API calls (thinking of both efficiency and expense). Typically, the playlist I'm going to read doesn't change very often so there's little merit in a real-time API call to YouTube.

I suppose it'd be nice to have a cache parameter - either leveraging the MODX cache for the snippet itself, or caching the API results. The latter probably means storing the result from the API request in a table which adds complexity.

Is there an obvious solution to this that I'm missing?

@davidpede
Copy link
Member

Thanks glad you find it useful!

Nothing built in but will look at adding in future release.

In the meantime https://github.com/opengeek/getCache/wiki/Usage should cover what you want todo

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

No branches or pull requests

2 participants