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

✨ (All GET routes in countries.js) Added route caching #100

Merged
merged 3 commits into from
Mar 23, 2022

Conversation

TimAagaard
Copy link
Contributor

Added route caching for 24 hours on all GET routes in countries.js. Added caching configurations in /config/apicache.js
that are determined by NODE_ENV. Added default NODE_ENV = 'local' to .env - this enables caching with all debug output.
If NODE_ENV is set to 'test', caching is disabled (this prevents unit tests from using the cache). Any other value of
NODE_ENV will result in the production config being used.

Closes #94

TimAagaard and others added 3 commits March 19, 2022 14:14
Added route caching for 24 hours on all GET routes in countries.js. Added caching configurations in /config/apicache.js
that are determined by NODE_ENV. Added default NODE_ENV = 'local' to .env - this enables caching with all debug output.
If NODE_ENV is set to 'test', caching is disabled (this prevents unit tests from using the cache). Any other value of
NODE_ENV will result in the production config being used.

Closes MartinsOnuoha#94
@MartinsOnuoha MartinsOnuoha self-requested a review March 23, 2022 05:34
@MartinsOnuoha MartinsOnuoha merged commit ded456f into MartinsOnuoha:master Mar 23, 2022
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

Successfully merging this pull request may close these issues.

Cache all GET requests
2 participants