client: Unbreak retrieval
This commit is contained in:
@@ -2,7 +2,7 @@ package modules
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"github.com/filecoin-project/lotus/lib/bufbstore"
|
||||
blockstore "github.com/ipfs/go-ipfs-blockstore"
|
||||
"github.com/libp2p/go-libp2p-core/host"
|
||||
"go.uber.org/fx"
|
||||
@@ -50,7 +50,12 @@ func ClientImportMgr(mds dtypes.ClientMultiDstore, ds dtypes.MetadataDS) dtypes.
|
||||
}
|
||||
|
||||
func ClientBlockstore(imgr dtypes.ClientImportMgr) dtypes.ClientBlockstore {
|
||||
return blockstore.NewIdStore(imgr.Blockstore)
|
||||
// TODO: This isn't.. the best
|
||||
// - If it's easy to pass per-retrieval blockstores with markets we don't need this
|
||||
// - If it's not easy, we need to store this in a separate datastore on disk
|
||||
defaultWrite := blockstore.NewBlockstore(datastore.NewMapDatastore())
|
||||
|
||||
return blockstore.NewIdStore(bufbstore.NewTieredBstore(imgr.Blockstore, defaultWrite))
|
||||
}
|
||||
|
||||
// RegisterClientValidator is an initialization hook that registers the client
|
||||
|
||||
Reference in New Issue
Block a user