-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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/real rabin #1545
Feat/real rabin #1545
Conversation
Is the block splitter to be used for parallel GetDag as well? (ah ic, GetBlocks already does every blocks concurrently) |
soooooo excited for this. |
@whyrusleeping we should drastically improve docker container space + transport usage after this lands :) ❤️ high priority. |
This LGTM. trying it out |
We should probably add a flag to the commands that use importer to try out rabin |
still to do:
|
it's not wired up anywhere yet... if this is already changing all of the interfaces, we should go for the r := bytes.NewReader(buf)
return r, nil for now, but that way we dont have to change the interfaces a ton of times. |
the |
I added an option to add that lets us specify a chunker:
|
b799a16
to
3f33df1
Compare
} | ||
default: | ||
return nil, fmt.Errorf("unrecognized chunker option: %s", chunker) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is pretty cool, i like being able to specify options. should it be on the chunker or separate? i.e.:
ipfs add -s=rabin-1000-10000
ipfs add -s=rabin --rabin-min=1000 --rabin-max=10000
less typing, but also more clear.
i do like being able to express it in one string, but dont like the non-self-description. it may be worth expressing all chunckers in one string:
ipfs add -s=rabin-min:1000-max:10000
not sure. maybe the min:
and max:
parts could be optional?
btw, we can probably put the "string -> splitter with options" conversion in the splitter package, and use it in other tools. easy place to plug in other splitters over time.
also, "splitter" or "chunker" ? (last chance to rename). i like both.
@whyrusleeping could you:
This LGTM and RFM! solid work! 👍 |
@whyrusleeping also:
|
52aacb6
to
6a30a20
Compare
License: MIT Signed-off-by: Jeromy <[email protected]> implement rabin fingerprinting as a chunker for ipfs License: MIT Signed-off-by: Jeromy <[email protected]> vendor correctly License: MIT Signed-off-by: Jeromy <[email protected]> refactor chunking interface a little License: MIT Signed-off-by: Jeromy <[email protected]> work chunking interface changes up into importer License: MIT Signed-off-by: Jeromy <[email protected]> move chunker type parsing into its own file in chunk License: MIT Signed-off-by: Jeromy <[email protected]>
6a30a20
to
39a2339
Compare
@whyrusleeping thouhgs on this? |
@jbenet oh, thats just the random orientation of the data causing bad chunking boundaries, i can stop that from being a failure. |
License: MIT Signed-off-by: Jeromy <[email protected]>
will randomness still make it fail sometimes? |
|
LGTM RFM |
Feat/real rabin This commit was moved from ipfs/kubo@e8d6f79
This PR changes the chunking interface to allow it to return errors and also implements rabin chunking using a modified version of the implementation here: https://github.com/restic/chunker