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

Simplify fetcher setup #485

Merged
merged 3 commits into from
Oct 13, 2023
Merged

Simplify fetcher setup #485

merged 3 commits into from
Oct 13, 2023

Conversation

hsanjuan
Copy link
Contributor

@hsanjuan hsanjuan commented Oct 12, 2023

The default fetcher already uses the same PrototypeChooser that we were setting explicitally (https://github.com/ipfs/boxo/blob/main/fetcher/impl/blockservice/fetcher.go#L127).

The default fetcher already uses the same Reifier that we were setting explicitally
(https://github.com/ipfs/boxo/blob/main/fetcher/impl/blockservice/fetcher.go#L127).
gateway/blocks_backend.go Outdated Show resolved Hide resolved
@hsanjuan
Copy link
Contributor Author

Ok, I got confused. We need to add dagpb support on top of the default PrototypeChooser using dagpb.AddSupportToChooser. But yeah given the default is already defined we can just use it rather than rewriting it.

@codecov
Copy link

codecov bot commented Oct 13, 2023

Codecov Report

Merging #485 (2f47153) into main (6602207) will increase coverage by 0.59%.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main     #485      +/-   ##
==========================================
+ Coverage   65.15%   65.75%   +0.59%     
==========================================
  Files         204      207       +3     
  Lines       25112    25135      +23     
==========================================
+ Hits        16362    16527     +165     
+ Misses       7273     7149     -124     
+ Partials     1477     1459      -18     
Files Coverage Δ
gateway/blocks_backend.go 43.04% <100.00%> (+0.21%) ⬆️

... and 22 files with indirect coverage changes

@hacdias hacdias merged commit 38b183c into main Oct 13, 2023
14 checks passed
@hacdias hacdias deleted the use-default-fetcher branch October 13, 2023 14:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants