Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reduce number of GetSize query to database #32

Closed
kaloyan-raev opened this issue Mar 30, 2022 · 6 comments
Closed

Reduce number of GetSize query to database #32

kaloyan-raev opened this issue Mar 30, 2022 · 6 comments
Assignees

Comments

@kaloyan-raev
Copy link
Member

The IPFS node is bombarded with GetSize requests from the IPFS network. These calls come from the IPFS discovery process when someone is looking for a specific IPFS hash.

We could reduce the pressure on the DB by enabling the bloom filter feature of IPFS. This can be done by setting the BloomFilterSize config to a positive value.

@kaloyan-raev
Copy link
Member Author

PR #17

BloomFilterSize can now be configured with env var.

@kaloyan-raev kaloyan-raev self-assigned this Apr 1, 2022
@kaloyan-raev
Copy link
Member Author

We have an issue with the bloom filter when running more than one IPFS node connected to the same Storj datastore.

When a new file is uploaded to one of the IPFS nodes then its bloom filter is updated with the new content, but the bloom filter of the rest of the nodes is not updated. So when a Get request comes to one of the other IPFS nodes, the request first hits its not-yet-updated bloom filter, and it returns "not found" for the content that has just been uploaded..

@kaloyan-raev kaloyan-raev reopened this Apr 5, 2022
@kaloyan-raev kaloyan-raev transferred this issue from storj/ipfs-demo Apr 7, 2022
@kaloyan-raev
Copy link
Member Author

New solution for CockroachDB: #45

@kaloyan-raev
Copy link
Member Author

It seems we also need to either disable or update the Arc cache.

Others are also trying to disable it: ipfs/kubo#6586

@kaloyan-raev
Copy link
Member Author

Patch to disable the ARC cache: #46

@kaloyan-raev kaloyan-raev reopened this Apr 26, 2022
@kaloyan-raev
Copy link
Member Author

Patch for properly decoding the CID before adding it to the bloom filter: #48

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant