-
-
Notifications
You must be signed in to change notification settings - Fork 14
Open
Description
Prerequisites
- I have written a descriptive issue title
- I have searched existing issues to ensure the feature has not already been requested
🚀 Feature Proposal
Cache fs.stats result of files to improve performance. For this we could use an lru. If we know that the exposed files and folders are not changed we can store them without issues. But if we know that the files are getting modified it would make sense to use fs.watch and invalidate the lru. But it would be preferable to assume that e.g. fastify-static is running on a system were the files are not changed.
Motivation
I think the performance bottleneck of this library is the fs.stars call. By caching we could improve the performance.
Example
No response
Metadata
Metadata
Assignees
Labels
No labels