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

feat: fetch only the root block #48

Merged
merged 2 commits into from
Dec 13, 2023
Merged

feat: fetch only the root block #48

merged 2 commits into from
Dec 13, 2023

Conversation

bajtos
Copy link
Member

@bajtos bajtos commented Dec 12, 2023

SPARK is about retrieval testing not load testing.

Currently, more than 90% of retrievals fail on timeout or server errors. There is little value in checking whether we can download the entire CAR file; it's more important to know whether SPs are advertising FIL+ deals to IPNI and accepting HTTP-based retrieval requests.

SPARK is also currently unable to fetch and verify CAR files larger than 200MB, which further reduces the value of fetching full CAR files.

Let's fetch the root block for the time being.

  • This should significantly reduce the load on "good" SPs.
  • It provides enough data to help "bad" SPs fix their setup.

/cc @rvagg @hannahhoward @willscott @gruns do you have any thoughts on this?

See also:

SPARK is about retrieval testing not load testing.

Currently, more than 90% of retrievals fail on timeout or server errors.
There is little value in checking whether we can download the entire
CAR file, it's more important to know whether SPs are advertising FIL+
deals to IPNI and accept HTTP-based retrieval requests.

SPARK is also not able to fetch and verify CAR files larger than 200MB,
which further reduced the value of fetching full CAR files.

Let's fetch the root block for the time being.
- This should significantly reduce the load on "good" SPs.
- It provides enough data allowing "bad" SPs to fix their setup.

Signed-off-by: Miroslav Bajtoš <oss@bajtos.net>
Signed-off-by: Miroslav Bajtoš <oss@bajtos.net>
@rvagg
Copy link

rvagg commented Dec 13, 2023

Seems reasonable to me. Depending on whether you think it adds value you could alternatively fetch either entity or all and use lassie's max-blocks feature to halt the retrieval when you get a certain distance into it. Then you could test whether they're able to respond with DAGs or not. But, it'll look like a cancellation on the server side, and you'll probably have to do some manual checking on your side because Lassie (I think) will return it as an error because it's a premature halt.

I could imagine that ipfs/specs#445 might be an interesting thing to add into the mix if we ever got that done for SPs; a shallow fetch that avoids the costly raw blocks but shows they can respond with non-trivial data.

@bajtos bajtos merged commit a3ddc5d into main Dec 13, 2023
1 check passed
@bajtos bajtos deleted the retrieve-single-block branch December 13, 2023 09:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: ✅ done
Development

Successfully merging this pull request may close these issues.

3 participants