New Unixfs implementations
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 25/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Da chiarire
- Stato di attività
- Ferma
- Stack tecnologico
- go
- Ambito
- backend, data, distributed-systems
Direzione di ricerca
Inizia esaminando il livello intermedio proposto blocks.Block e i formati unixfs.proto e dag-pb.proto, quindi traccia come verrebbe rappresentato uno stream CAR ordinato basato su io.Reader. L’issue elenca diverse possibili implementazioni, ma non indica file o test del repository, quindi ambito e criteri di completamento devono essere concordati prima di iniziare il lavoro.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Dedicated unixfs implementations are often much more performant and efficient.
See for example two of mines:
- https://github.com/Jorropo/linux2ipfs (blazingly fast file adder / fastest
ipfs addimplementation that exists) - https://github.com/Jorropo/go-featheripfs (high performance very high efficiency ordered car ->
io.Readerfile with incremental verification and data streaming)
I think it is more sustainable to maintain a handful of dedicated implementations that individually do one job well (something like feather and something that would maintain state to support unordered dags are really different).
Unified middle layer
The way I have been writing my implementations is by jugling bytes unixfs.proto and dag-pb.proto by hand everywhere.
This is kinda meh looking because of all the little details that have to be checked.
I really think we need some efficient middle layer that takes in blocks.Block parse them, do sanity checks and return some representation that looks like internal unixfs (so one node per block, and full support for all schenanigans you would want to do but with error checking):
package unixfs
type Type uint8
const (
_ Type = iota
Directory
File
Metadata
Symlink
HAMTShard
)
type Node struct{
Type Type
Data []byte // for files
Entries []Entry
DagSize uint64
HashType uint64 // for HAMT dirs
Fanout uint64 // for HAMT dirs
}
type Entry struct{
Link
Name string // for directories
}
type Link struct{
Type Type // Indicative, not actually
Cid cid.Cid
FileSize uint64 // for files
DagSize uint64
}
func (*Node) UnmarshalIPFS(blocks.Block) error
func (*Node) MarshalIPFS() (blocks.Block, error)
func (*Node) Encode() (Link, blocks.Block, error)
// File operations
func (*Node) ParseFile(Link, blocks.Block) error
func (*Node) AddFileSegments(Link...) error
func (*Node) FileSize() uint64
// Directory operations
func (*Node) ParseDirectory(Link, blocks.Block) error
func (*Node) AddChildrenNode(Link...) error
// other types ...
This would not includes helper functions for more advanced stuff like HAMT, chunking, ... we will most likely need thoses too but the goal here is to provide a thin wrapper around the protobuf that add the repetitive input validation.
Impls
List of implementations we need:
- Efficient state-light streaming decoder with incremental verification. (I'll probably use feather after refactoring it to use the unified lower layer and adding the missing features)
The goal is to incremental verify ordered.carfiles from saturn on the cheap resource wise. (and other ordered blocks sources)- Capable of streaming the verification of an ordered stream of block (such as a car file red from
io.Reader) incrementally (while streaming the result out). - Interface must implement
io.Readerfor reading from files without any background goroutine (efficiency). - It must support incrementally verifying requests mapping to https://github.com/ipfs/boxo/pull/176 sementics.
- Capable of streaming the verification of an ordered stream of block (such as a car file red from
- Decoder with incremental verification and output stream with random walk BFS input.
- Streaming data in order can have a high cost, however if we are cleaver we can use
.WriteAtto write blocks in any order as long as we receive roots before leaves (or cache leaves but then incremental verification is not possible)
- Streaming data in order can have a high cost, however if we are cleaver we can use
- MFS rewrite.
- Some write opperation helpers (concatenate, chunking, ...)
- ... ?
- Lingua principale
- Go
- Stelle
- 326
- Fork
- 165
- Metriche di merge delle PR
- Nessuna PR unita negli ultimi 30g
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Ha un modello di pull request
- Nessuna guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di ipfs/boxo
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
-
Difficoltà 4/5 3-5 giorni Idoneità per principianti 46/100
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 55/100
-
need/triage
Difficoltà 5/5 Più di una settimana Idoneità per principianti 38/100
-
dif/medium effort/hours kind/enhancement P3 topic/devexp
Difficoltà 5/5 Più di una settimana Idoneità per principianti 35/100
Issue simili
-
affects-8.5 component/session severity/moderate sig/transaction type/bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
I maintainer di solito rispondono entro 1 giorno
-
enhancement good first issue
Difficoltà 2/5 1-3 ore Idoneità per principianti 85/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
harvester/harvester#12311 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
verifyrun --bracket-digest --credit: relative --witness is could-not-check, absolute path creditsApertabug effort:s impact:low raised-by:desk risk:low
Difficoltà 2/5 1-3 ore Idoneità per principianti 62/100
medici-finance/assay#6580 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 80/100
blinklabs-io/gouroboros#3026 ·
I maintainer di solito rispondono entro 1 giorno