node

package
v0.4.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 15, 2023 License: Apache-2.0, MIT Imports: 47 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var BootstrapPeers []peer.AddrInfo

Functions

This section is empty.

Types

type EstuaryBlockstore

type EstuaryBlockstore interface {
	blockstore.Blockstore
	DeleteMany(context.Context, []cid.Cid) error
}

type Node

type Node struct {
	Dht      *dht.IpfsDHT
	Provider *batched.BatchProvidingSystem
	FullRT   *fullrt.FullRT
	FilDht   *dht.IpfsDHT
	Host     host.Host

	StorageDir string
	//Lmdb      *lmdb.Blockstore
	Datastore datastore.Batching

	Blockstore      *sanitycheck.Blockstore
	Bitswap         *bitswap.Bitswap
	NotifBlockstore *NotifyBlockstore

	Wallet *wallet.LocalWallet

	Bwc     *metrics.BandwidthCounter
	Peering *peering.EstuaryPeeringService
	Config  *config.Node
}

func Setup

func Setup(ctx context.Context, init NodeInitializer, checkFn sanitycheck.CheckFn) (*Node, error)

func (*Node) Origins added in v0.4.0

func (n *Node) Origins() ([]*peer.AddrInfo, error)

type NodeInitializer

type NodeInitializer interface {
	BlockstoreWrap(blockstore.Blockstore) (blockstore.Blockstore, error)
	KeyProviderFunc(context.Context) (<-chan cid.Cid, error)
	Config() *config.Node
}

type NotifyBlockstore

type NotifyBlockstore struct {
	EstuaryBlockstore
	// contains filtered or unexported fields
}

func NewNotifBs

func NewNotifBs(bstore EstuaryBlockstore) *NotifyBlockstore

func (*NotifyBlockstore) Put

func (nb *NotifyBlockstore) Put(ctx context.Context, blk blocks.Block) error

func (*NotifyBlockstore) PutMany

func (nb *NotifyBlockstore) PutMany(ctx context.Context, blks []blocks.Block) error

func (*NotifyBlockstore) WaitFor

func (nb *NotifyBlockstore) WaitFor(ctx context.Context, c cid.Cid) <-chan blocks.Block

Directories

Path Synopsis
modules

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL