Fixes performance regression on pnpm installs#6760
Conversation
This reverts commit 994888e.
| const data = Buffer.from(memory); | ||
|
|
||
| return {data, compressionMethod}; | ||
| return {data, compressionMethod, shouldBeCached: true}; |
There was a problem hiding this comment.
I'd prefer shouldBeCached to be a class property than something returned by getFileSource, especially since it never changes (and probably doesn't have a good reason to ever change?).
There was a problem hiding this comment.
I was thinking that backend could decide whether to cache on per file basis.
E.g for big compressed files. Or frequently requested files. You decide.
There was a problem hiding this comment.
Please reply if you want per file or per class. I'll change tomorrow.
There was a problem hiding this comment.
Let's go with a class property. I think if we were to implement such a dynamic caching logic there's a good chance the checks you mention would live inside the ZipFS rather than the backend.
b121b19 to
086fc57
Compare
What's the problem this PR addresses?
Fixes #6758
Checklist