From de42d51361e316a4525440ad953e3a42ea6432b7 Mon Sep 17 00:00:00 2001 From: Sarah Boyce <42296566+sarahboyce@users.noreply.github.com> Date: Mon, 13 Feb 2023 21:09:19 +0100 Subject: [PATCH] [4.2.x] Fixed #29994 -- Added warning about performance of FileBasedCache with a large number of files. Co-authored-by: sheenarbw <699166+sheenarbw@users.noreply.github.com> Co-authored-by: Mariusz Felisiak Backport of 1eb94bc8dab46dfa117d21ef4f3b52aebb593615 from main --- docs/topics/cache.txt | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/topics/cache.txt b/docs/topics/cache.txt index 4cf644307c1..a94f59bbe89 100644 --- a/docs/topics/cache.txt +++ b/docs/topics/cache.txt @@ -375,6 +375,14 @@ the user ``apache``. content, which your site will trust, but also remotely execute arbitrary code, as the data is serialized using :mod:`pickle`. +.. warning:: + + Filesystem caching may become slow when storing a large number of files. If + you run into this problem, consider using a different caching mechanism. + You can also subclass + :source:`FileBasedCache ` and + improve the culling strategy. + .. _local-memory-caching: Local-memory caching