repo.stat reads entire of blockstore into memory #180
Labels
exp/wizard
Extensive knowledge (implications, ramifications) required
help wanted
Seeking public contribution on this issue
P2
Medium: Good to have, but can wait until someone steps up
status/ready
Ready to be worked
In IPFS repo.stat takes about 5s per call for me. I found that that the entire blockstore is read into memory every time this function is called to get the count and size:
js-ipfs-repo/src/index.js
Lines 301 to 317 in 3611043
This needs to be streamed and/or calculated once, cached, and kept up to date.
The text was updated successfully, but these errors were encountered: