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

blockstore: add option to deduplicate by CID #127

Merged
merged 1 commit into from
Jul 1, 2021
Merged

blockstore: add option to deduplicate by CID #127

merged 1 commit into from
Jul 1, 2021

Conversation

mvdan
Copy link
Contributor

@mvdan mvdan commented Jul 1, 2021

(see commit message)

@mvdan
Copy link
Contributor Author

mvdan commented Jul 1, 2021

FYI @aarshkshah1992 I verified that #125 passes with this option. Thanks again for providing reproducible tests.

And a test that uses duplicate hashes as well as duplicate CIDs.

We reuse the same insertion index, since it's enough for this purpose.
There's no need to keep a separate map or set of CIDs.

While at it, make the index package not silently swallow errors,
and improve the tests to handle errors more consistently.

Fixes #123.
Fixes #125.
Copy link

@dirkmc dirkmc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

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

Successfully merging this pull request may close these issues.

3 participants