Skip to content

Dag creation #9

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

Open
wants to merge 17 commits into
base: main
Choose a base branch
from
Open

Dag creation #9

wants to merge 17 commits into from

Conversation

Goddhi
Copy link

@Goddhi Goddhi commented Mar 24, 2025

Implementation of DAG in Golang for Storacha go-w3up
Adder Package Implementation
The adder package provides functionality to add files and directories to content-addressed storage by chunking data, constructing a Directed Acyclic Graph (DAG), and integrating with a Mutable File System for retrieval. The go-w3s-client provides a reference implementation for building the DAG in this repo.

@jamiechicago312 jamiechicago312 requested a review from volmedo April 4, 2025 16:41
@jamiechicago312
Copy link

Pulling @volmedo to review! Thank you!

Copy link
Member

@volmedo volmedo left a comment

Choose a reason for hiding this comment

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

looking good, left some comments.

Comment on lines +1 to +5
<<<<<<< HEAD
dist/
=======
go.sum
>>>>>>> dag_repo/main
Copy link
Member

Choose a reason for hiding this comment

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

I guess you forgot to remove the merge conflict marks 🙂

Copy link
Member

Choose a reason for hiding this comment

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

some more merge conflict marks in this file, please resolve

Comment on lines +146 to +147
adder.mu.Lock()
defer adder.mu.Unlock()
Copy link
Member

Choose a reason for hiding this comment

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

do we need a mutex for this? It looks to me the kind of job that sync.Once would be more suited for.

Comment on lines +24 to +32
const (
DefaultChunkSize = "size-1048576" // 1MB chunks

MaxLinks = 1048576

UseRawLeaves = true

LiveCacheSize = uint64(256 << 10) // 256KB
)
Copy link
Member

Choose a reason for hiding this comment

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

do these need to be exported?

Copy link
Member

Choose a reason for hiding this comment

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

please remove this file from your PR. It looks like it's overwriting the existing README.md.

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.

4 participants