I am trying to figure out the best alternative to use some sort of memory caching for a Django application with a postgress database deployed on DigitalOcean App Platform.
I cannot see any documentation of how to include memcached or any other in-memory management tool as part of the App Platform deployment.
Any Ideas will be appreciated
This textbox defaults to using Markdown to format your answer.
You can type !ref in this text area to quickly search our full set of tutorials, documentation & marketplace offerings and insert the link!
These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.
Sign up for Infrastructure as a Newsletter.
Working on improving health and education, reducing inequality, and spurring economic growth? We'd like to help.
Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.
Hi @mariorossell
Memcached
is an in-memory data storage system. You can runMemcached
as an internal service in the App Platform. It is an internal service therefore there will be no HTTP route or PORT set.A sample code for a
Memcached
service can be seen like belowOther services can access the Memcached service using <servicename>:<internal_ports> like below for the above sample Memcached service.
After successful deployment, to connect other services with Memcached service, run the below command in the service console from whom you want to connect Memcached with.
Note: App Platform instances are ephemeral and can be redeployed at any time which would cause the contents of the Memcached server to be lost.
Other than
Memcached
for in-memory data storage, we also provideRedis
as a managed database in the Digital Ocean. You can view the below links for information related to how to createRedis Database
and how to manage databases in the App Platfrom.Redis Database in Digital Ocean How to manage Database in App Platform link
I’m a little late to reply, but for posterity, the MemCachier Add-On from the DigitalOcean Marketplace is now available, enabling you to provision a Memcached-compliant cache for your App Platform app with one click.