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

Multidimensional encoding #622

Draft
wants to merge 17 commits into
base: master
Choose a base branch
from
Draft

Multidimensional encoding #622

wants to merge 17 commits into from

Conversation

cskiraly
Copy link
Contributor

This adds multidimensional encoding capabilities to the manifest.

In this patch set

  • the manifest is changed to recursive, containing another manifest instead of just a few encoding parameters
  • encoding is done recursively, each step adding a layer of RS coding
  • the "steps" parameter, which previously defined both the interleaving used, and the number of times the encoding had to be applied, is now split into two parameters: interleaving, and steps
  • the default interleaving is to keep the old behaviour, i.e. interleaving=steps
  • a workaround is included to handle empty block decoding (Hardcoded empty block hash? #620)

The concept of recursive manifest is questionable. It might be better to support multiple K,M parameters in a single manifest, describing the whole multi-d RS encoding structure without recursion. This would allow to handle originalBlockCount and padding blocks better.
It should be relatively easy to convert this implementation to a non-recursive version. ID mapping changes, but operations are the same, and encoding is done dimension-by-dimension anyway.

@dryajov
Copy link
Contributor

dryajov commented Nov 15, 2023

can you rebase this with master?

We can protect in multiple dimensions, which require
the manifest to describe all dimensions, either directly,
or by making the structure recursive.
Here we make it recursive.

Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
there was a different CID for something declared an empty block
(used for padding), and the block with all 0s. This becomes a
problem after decode, where the docoder returns a block with all 0s.

This is a workaround, not a real solution.

Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
@cskiraly
Copy link
Contributor Author

cskiraly commented Nov 15, 2023

rebased on master now

Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Since repostore is not reference counting, and a single parity
is often the same as one of the blocks, test easily delete more
blocks than intended. Better to use M=2

Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
Signed-off-by: Csaba Kiraly <csaba.kiraly@gmail.com>
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.

None yet

2 participants