Skip to content
This repository has been archived by the owner on Jun 27, 2023. It is now read-only.

Switch to Dagpb and incorporate LinkSystem changes #12

Merged
merged 5 commits into from
Mar 17, 2021

Conversation

acruikshank
Copy link
Contributor

Motivation

It appears we will be using go-codecs-dagpb instead of go-ipld-prime-proto as our ipld implemenation of protobuf nodes. Also the LinkSystem changes in go-ipld-prime will be landing soon. This PR supports both of those changes.

This PR will cease to be a draft when the LinkSystem changes land and this package depends on a release tag of go-ipld-prime.

Proposed Changes

  1. Switch dependency from go-ipld-prime-proto to go-codecs-dagpb with necessary changes.
  2. Switch dependency to linksystem branch of go-ipld-prime and make necessary changes.
  3. Replace AddDagPBSupportToChooser from go-ipld-prime-proto with DefaultPrototypeChooser implementation.
  4. Make the prototype chooser configurable to support custom chooser for ADLs and whatnot.

@willscott willscott requested a review from mvdan March 8, 2021 20:53
@acruikshank acruikshank marked this pull request as ready for review March 15, 2021 21:11
fetcher.go Outdated
if ok {
switch c.Cid.Prefix().Codec {
case 0x70:
return dagpb.Type.PBNode, nil
Copy link

Choose a reason for hiding this comment

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

you can use ipld/go-codec-dagpb@b641b0f now.

you also don't need the raw special case, as basicnode.Prototype.Any will already work fine for raw nodes, picking Bytes.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I made this change.

@acruikshank acruikshank merged commit b9a3f1a into main Mar 17, 2021
Jorropo pushed a commit to ipfs/go-libipfs-rapide that referenced this pull request Mar 23, 2023
Switch to Dagpb and incorporate LinkSystem changes

This commit was moved from ipfs/go-fetcher@b9a3f1a
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants