Optimize LRUMemoryCache deletion strategy.
The following discussion from !475 (merged) should be addressed:
-
@arberx started a discussion: (+1 comment) If I'm reading this correctly, this operation could be optimized to delete to a certain size.
In its current form, where deletion only happens until there's enough space for the current blob being written, we could run into a situation in which we're deleting on every write.
Optimal solution should be to delete to a certain capacity (80%).