activist
activist copied to clipboard
Implement Caching for Improved Response Times
Terms
- [X] I have searched open and closed feature requests
- [X] I agree to follow activist's Code of Conduct
Description
This is an issue to implement caching for frequently requested data. Django Rest Framework (DRF) offers built-in caching mechanisms that can help achieve this performance improvement. By caching data at the server level, the load will reduce on the database and significantly improve the user experience.
Contribution
Happy to support someone on this issue or work on it myself
I could do this as well, since it's potentially related to issue #360 concerning the implementation of viewsets. The cleaner approach would be to create a mixin class to inherit in all viewsets. The more labor-intensive way would be to add a decorator to each individual view; the advantage would be more granular control & the ability to exclude some views from caching for security reasons. Any thoughts?
@kurtisolo sure, assigning this to you. I like the decorator approach, since as you mentioned we get more granular control.
Hey there @kurtisolo 👋 Hope all's well :) Let us know how you're doing with this issue 😊 We also have the dev sync/Code Night on Saturday, so we could also discuss there if you're free! Details for that will be in the Development channel on Matrix :)
Hey @kurtisolo 👋 Hope you're well! 😊 Checking in to see if you still have interest in working on this. Would be great to have you at another dev sync at some point if you'd have interest. The last one for the year is the 16th, and after that we'll take a break for the New Year and start again on the 18th of January 🥳
I'm back :D give me some time and I'll work on this ASAP
Welcome back, @kurtisolo! Super happy to have you 😊
I'm thinking about implementing python-memcached, it's simple to use. What do you think? Redis could be also a valid option but for this purpose i think it's a overkill..
Looking into this a bit, we are trying to type most of what we're writing, so that would normally be a Redis use case, right? I see that it's easy to migrate from Memcached, so no stress if we do one first and migrate the other. Discussions have often been centered around Redis for this though :)