You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now all the pointers to the path are held in memory, and if the application terminates it's wiping the memory but not the files from disk. There are two options that I can come up with from the top of my head:
Have the application scan the directory and look for available files instead of holding the references in memory. Cleaning up the file system can be handled by a cronjob
Same as 1) but files get deleted when maximum amount of files is reached and a new file gets uploaded (Like a FIFO buffer).
Store all references in a database and handle the lifecycle completely in Picasso (e.g. with Celery/Redis)
Your description sounds more like option 3 but I am more leaning towards 2 because it doesn't require any more infrastructure and is probably the simplest to implement. Additionally, it has the least amount of surprise for the user, IMHO. It only does something when the user interacts with it and no magic in the background is cleaning up the files.
Uploaded pictures are dumped into a temp directory and never managed past that point. They should be cleaned up at some interval.
The text was updated successfully, but these errors were encountered: