On big websites, the QR Codes cache directory may become huge, having tens of thousands or even hundreds of thousands of cached file. This have a big impact on performance.

We need to use a multilevel directories system and segment the cache directory. How do we do that?

Comments

IncrediblyKenzi’s picture

Status: Active » Needs review

I'd like to follow imagecache's lead on this one.. I don't think they do segmentation. To my knowledge, this only affects filesystems that use a linked list to store file data.. In the case of more modern filesystems (ext3 with dir_index turned on and ext4, for example), files are stored as a sorted hashtable, which means it accesses file data at O(log(n)) complexity. No change should be needed if that's the case.