api

package
v1.7.5 Latest Latest
Warning

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

Go to latest
Published: Aug 8, 2023 License: Apache-2.0, MIT Imports: 36 Imported by: 3

Documentation

Index

Constants

View Source
const (
	StageIdle = SyncStateStage(iota)
	StageHeaders
	StagePersistHeaders
	StageMessages
	StageSyncComplete
	StageSyncErrored
	StageFetchingMessages
)
View Source
const (
	PermRead  auth.Permission = "read" // default
	PermWrite auth.Permission = "write"
	PermSign  auth.Permission = "sign"  // Use wallet keys for signing
	PermAdmin auth.Permission = "admin" // Manage permissions
)
View Source
const LookbackNoLimit = abi.ChainEpoch(-1)

Variables

View Source
var (
	FullAPIVersion0 = newVer(1, 5, 0)
	FullAPIVersion1 = newVer(2, 3, 0)

	MinerAPIVersion0  = newVer(1, 5, 0)
	WorkerAPIVersion0 = newVer(1, 7, 0)

	BoostAPIVersion0 = newVer(1, 0, 0)
)

semver versions of the rpc api exposed

View Source
var DefaultPerms = []auth.Permission{PermRead}
View Source
var EmptyVesting = MsigVesting{
	InitialBalance: types.EmptyInt,
	StartEpoch:     -1,
	UnlockDuration: -1,
}
View Source
var ErrNotSupported = errors.New("method not supported")

Functions

func GetInternalStructs

func GetInternalStructs(in interface{}) []interface{}

GetInternalStructs extracts all pointers to 'Internal' sub-structs from the provided pointer to a proxy struct

Types

type APIVersion

type APIVersion struct {
	Version string

	// APIVersion is a binary encoded semver version of the remote implementing
	// this api
	//
	// See APIVersion in build/version.go
	APIVersion Version
}

APIVersion provides various build-time information

func (APIVersion) String

func (v APIVersion) String() string

type ActiveSync

type ActiveSync struct {
	WorkerID uint64
	Base     *types.TipSet
	Target   *types.TipSet

	Stage  SyncStateStage
	Height abi.ChainEpoch

	Start   time.Time
	End     time.Time
	Message string
}

type ActorState

type ActorState struct {
	Balance types.BigInt
	Code    cid.Cid
	State   interface{}
}

type BlockMessages

type BlockMessages struct {
	BlsMessages   []*types.Message
	SecpkMessages []*types.SignedMessage

	Cids []cid.Cid
}

BlsMessages[x].cid = Cids[x] SecpkMessages[y].cid = Cids[BlsMessages.length + y]

type BlockTemplate

type BlockTemplate struct {
	Miner            address.Address
	Parents          types.TipSetKey
	Ticket           *types.Ticket
	Eproof           *types.ElectionProof
	BeaconValues     []types.BeaconEntry
	Messages         []*types.SignedMessage
	Epoch            abi.ChainEpoch
	Timestamp        uint64
	WinningPoStProof []builtin.PoStProof
}

type Boost

type Boost interface {
	Common
	Net

	// MethodGroup: Boost
	BoostIndexerAnnounceAllDeals(ctx context.Context) error                                                                                     //perm:admin
	BoostIndexerAnnounceLatest(ctx context.Context) (cid.Cid, error)                                                                            //perm:admin
	BoostIndexerAnnounceLatestHttp(ctx context.Context, urls []string) (cid.Cid, error)                                                         //perm:admin
	BoostOfflineDealWithData(ctx context.Context, dealUuid uuid.UUID, filePath string, delAfterImport bool) (*ProviderDealRejectionInfo, error) //perm:admin
	BoostDeal(ctx context.Context, dealUuid uuid.UUID) (*smtypes.ProviderDealState, error)                                                      //perm:admin
	BoostDealBySignedProposalCid(ctx context.Context, proposalCid cid.Cid) (*smtypes.ProviderDealState, error)                                  //perm:admin
	BoostDummyDeal(context.Context, smtypes.DealParams) (*ProviderDealRejectionInfo, error)                                                     //perm:admin
	BoostDagstoreRegisterShard(ctx context.Context, key string) error                                                                           //perm:admin
	BoostDagstoreDestroyShard(ctx context.Context, key string) error                                                                            //perm:admin
	BoostDagstoreInitializeShard(ctx context.Context, key string) error                                                                         //perm:admin
	BoostDagstoreInitializeAll(ctx context.Context, params DagstoreInitializeAllParams) (<-chan DagstoreInitializeAllEvent, error)              //perm:admin
	BoostDagstoreRecoverShard(ctx context.Context, key string) error                                                                            //perm:admin
	BoostDagstoreGC(ctx context.Context) ([]DagstoreShardResult, error)                                                                         //perm:admin
	BoostDagstorePiecesContainingMultihash(ctx context.Context, mh multihash.Multihash) ([]cid.Cid, error)                                      //perm:read
	BoostDagstoreListShards(ctx context.Context) ([]DagstoreShardInfo, error)                                                                   //perm:admin
	BoostMakeDeal(context.Context, smtypes.DealParams) (*ProviderDealRejectionInfo, error)                                                      //perm:write

	// MethodGroup: Blockstore
	BlockstoreGet(ctx context.Context, c cid.Cid) ([]byte, error)  //perm:read
	BlockstoreHas(ctx context.Context, c cid.Cid) (bool, error)    //perm:read
	BlockstoreGetSize(ctx context.Context, c cid.Cid) (int, error) //perm:read

	// RuntimeSubsystems returns the subsystems that are enabled
	// in this instance.
	RuntimeSubsystems(ctx context.Context) (lapi.MinerSubsystems, error) //perm:read

	// MethodGroup: LegacyMarket
	MarketListRetrievalDeals(ctx context.Context) ([]retrievalmarket.ProviderDealState, error)                                                                                           //perm:read
	MarketSetRetrievalAsk(ctx context.Context, rask *retrievalmarket.Ask) error                                                                                                          //perm:admin
	MarketGetRetrievalAsk(ctx context.Context) (*retrievalmarket.Ask, error)                                                                                                             //perm:read
	MarketSetAsk(ctx context.Context, price types.BigInt, verifiedPrice types.BigInt, duration abi.ChainEpoch, minPieceSize abi.PaddedPieceSize, maxPieceSize abi.PaddedPieceSize) error //perm:admin
	MarketGetAsk(ctx context.Context) (*storagemarket.SignedStorageAsk, error)                                                                                                           //perm:read
	MarketListDataTransfers(ctx context.Context) ([]DataTransferChannel, error)                                                                                                          //perm:write
	MarketDataTransferUpdates(ctx context.Context) (<-chan DataTransferChannel, error)                                                                                                   //perm:write
	MarketRestartDataTransfer(ctx context.Context, transferID datatransfer.TransferID, otherPeer peer.ID, isInitiator bool) error                                                        //perm:write
	MarketCancelDataTransfer(ctx context.Context, transferID datatransfer.TransferID, otherPeer peer.ID, isInitiator bool) error                                                         //perm:write
	MarketImportDealData(ctx context.Context, propcid cid.Cid, path string) error                                                                                                        //perm:write
	MarketListIncompleteDeals(ctx context.Context) ([]storagemarket.MinerDeal, error)                                                                                                    //perm:read
	MarketPendingDeals(ctx context.Context) (lapi.PendingDealInfo, error)                                                                                                                //perm:write
	SectorsRefs(context.Context) (map[string][]lapi.SealedRef, error)                                                                                                                    //perm:read

	PiecesListPieces(ctx context.Context) ([]cid.Cid, error)                                 //perm:read
	PiecesListCidInfos(ctx context.Context) ([]cid.Cid, error)                               //perm:read
	PiecesGetPieceInfo(ctx context.Context, pieceCid cid.Cid) (*piecestore.PieceInfo, error) //perm:read
	PiecesGetCIDInfo(ctx context.Context, payloadCid cid.Cid) (*piecestore.CIDInfo, error)   //perm:read
	PiecesGetMaxOffset(ctx context.Context, pieceCid cid.Cid) (uint64, error)                //perm:read

	// MethodGroup: Actor
	ActorSectorSize(context.Context, address.Address) (abi.SectorSize, error) //perm:read

	// MethodGroup: Deals
	DealsConsiderOnlineStorageDeals(context.Context) (bool, error)      //perm:admin
	DealsSetConsiderOnlineStorageDeals(context.Context, bool) error     //perm:admin
	DealsConsiderOnlineRetrievalDeals(context.Context) (bool, error)    //perm:admin
	DealsSetConsiderOnlineRetrievalDeals(context.Context, bool) error   //perm:admin
	DealsPieceCidBlocklist(context.Context) ([]cid.Cid, error)          //perm:admin
	DealsSetPieceCidBlocklist(context.Context, []cid.Cid) error         //perm:admin
	DealsConsiderOfflineStorageDeals(context.Context) (bool, error)     //perm:admin
	DealsSetConsiderOfflineStorageDeals(context.Context, bool) error    //perm:admin
	DealsConsiderOfflineRetrievalDeals(context.Context) (bool, error)   //perm:admin
	DealsSetConsiderOfflineRetrievalDeals(context.Context, bool) error  //perm:admin
	DealsConsiderVerifiedStorageDeals(context.Context) (bool, error)    //perm:admin
	DealsSetConsiderVerifiedStorageDeals(context.Context, bool) error   //perm:admin
	DealsConsiderUnverifiedStorageDeals(context.Context) (bool, error)  //perm:admin
	DealsSetConsiderUnverifiedStorageDeals(context.Context, bool) error //perm:admin

	// MethodGroup: Misc
	OnlineBackup(context.Context, string) error //perm:admin
}

func PermissionedBoostAPI

func PermissionedBoostAPI(a Boost) Boost

type BoostStruct

type BoostStruct struct {
	CommonStruct

	NetStruct

	Internal struct {
		ActorSectorSize func(p0 context.Context, p1 address.Address) (abi.SectorSize, error) `perm:"read"`

		BlockstoreGet func(p0 context.Context, p1 cid.Cid) ([]byte, error) `perm:"read"`

		BlockstoreGetSize func(p0 context.Context, p1 cid.Cid) (int, error) `perm:"read"`

		BlockstoreHas func(p0 context.Context, p1 cid.Cid) (bool, error) `perm:"read"`

		BoostDagstoreDestroyShard func(p0 context.Context, p1 string) error `perm:"admin"`

		BoostDagstoreGC func(p0 context.Context) ([]DagstoreShardResult, error) `perm:"admin"`

		BoostDagstoreInitializeAll func(p0 context.Context, p1 DagstoreInitializeAllParams) (<-chan DagstoreInitializeAllEvent, error) `perm:"admin"`

		BoostDagstoreInitializeShard func(p0 context.Context, p1 string) error `perm:"admin"`

		BoostDagstoreListShards func(p0 context.Context) ([]DagstoreShardInfo, error) `perm:"admin"`

		BoostDagstorePiecesContainingMultihash func(p0 context.Context, p1 multihash.Multihash) ([]cid.Cid, error) `perm:"read"`

		BoostDagstoreRecoverShard func(p0 context.Context, p1 string) error `perm:"admin"`

		BoostDagstoreRegisterShard func(p0 context.Context, p1 string) error `perm:"admin"`

		BoostDeal func(p0 context.Context, p1 uuid.UUID) (*smtypes.ProviderDealState, error) `perm:"admin"`

		BoostDealBySignedProposalCid func(p0 context.Context, p1 cid.Cid) (*smtypes.ProviderDealState, error) `perm:"admin"`

		BoostDummyDeal func(p0 context.Context, p1 smtypes.DealParams) (*ProviderDealRejectionInfo, error) `perm:"admin"`

		BoostIndexerAnnounceAllDeals func(p0 context.Context) error `perm:"admin"`

		BoostIndexerAnnounceLatest func(p0 context.Context) (cid.Cid, error) `perm:"admin"`

		BoostIndexerAnnounceLatestHttp func(p0 context.Context, p1 []string) (cid.Cid, error) `perm:"admin"`

		BoostMakeDeal func(p0 context.Context, p1 smtypes.DealParams) (*ProviderDealRejectionInfo, error) `perm:"write"`

		BoostOfflineDealWithData func(p0 context.Context, p1 uuid.UUID, p2 string, p3 bool) (*ProviderDealRejectionInfo, error) `perm:"admin"`

		DealsConsiderOfflineRetrievalDeals func(p0 context.Context) (bool, error) `perm:"admin"`

		DealsConsiderOfflineStorageDeals func(p0 context.Context) (bool, error) `perm:"admin"`

		DealsConsiderOnlineRetrievalDeals func(p0 context.Context) (bool, error) `perm:"admin"`

		DealsConsiderOnlineStorageDeals func(p0 context.Context) (bool, error) `perm:"admin"`

		DealsConsiderUnverifiedStorageDeals func(p0 context.Context) (bool, error) `perm:"admin"`

		DealsConsiderVerifiedStorageDeals func(p0 context.Context) (bool, error) `perm:"admin"`

		DealsPieceCidBlocklist func(p0 context.Context) ([]cid.Cid, error) `perm:"admin"`

		DealsSetConsiderOfflineRetrievalDeals func(p0 context.Context, p1 bool) error `perm:"admin"`

		DealsSetConsiderOfflineStorageDeals func(p0 context.Context, p1 bool) error `perm:"admin"`

		DealsSetConsiderOnlineRetrievalDeals func(p0 context.Context, p1 bool) error `perm:"admin"`

		DealsSetConsiderOnlineStorageDeals func(p0 context.Context, p1 bool) error `perm:"admin"`

		DealsSetConsiderUnverifiedStorageDeals func(p0 context.Context, p1 bool) error `perm:"admin"`

		DealsSetConsiderVerifiedStorageDeals func(p0 context.Context, p1 bool) error `perm:"admin"`

		DealsSetPieceCidBlocklist func(p0 context.Context, p1 []cid.Cid) error `perm:"admin"`

		MarketCancelDataTransfer func(p0 context.Context, p1 datatransfer.TransferID, p2 peer.ID, p3 bool) error `perm:"write"`

		MarketDataTransferUpdates func(p0 context.Context) (<-chan DataTransferChannel, error) `perm:"write"`

		MarketGetAsk func(p0 context.Context) (*storagemarket.SignedStorageAsk, error) `perm:"read"`

		MarketGetRetrievalAsk func(p0 context.Context) (*retrievalmarket.Ask, error) `perm:"read"`

		MarketImportDealData func(p0 context.Context, p1 cid.Cid, p2 string) error `perm:"write"`

		MarketListDataTransfers func(p0 context.Context) ([]DataTransferChannel, error) `perm:"write"`

		MarketListIncompleteDeals func(p0 context.Context) ([]storagemarket.MinerDeal, error) `perm:"read"`

		MarketListRetrievalDeals func(p0 context.Context) ([]retrievalmarket.ProviderDealState, error) `perm:"read"`

		MarketPendingDeals func(p0 context.Context) (lapi.PendingDealInfo, error) `perm:"write"`

		MarketRestartDataTransfer func(p0 context.Context, p1 datatransfer.TransferID, p2 peer.ID, p3 bool) error `perm:"write"`

		MarketSetAsk func(p0 context.Context, p1 types.BigInt, p2 types.BigInt, p3 abi.ChainEpoch, p4 abi.PaddedPieceSize, p5 abi.PaddedPieceSize) error `perm:"admin"`

		MarketSetRetrievalAsk func(p0 context.Context, p1 *retrievalmarket.Ask) error `perm:"admin"`

		OnlineBackup func(p0 context.Context, p1 string) error `perm:"admin"`

		PiecesGetCIDInfo func(p0 context.Context, p1 cid.Cid) (*piecestore.CIDInfo, error) `perm:"read"`

		PiecesGetMaxOffset func(p0 context.Context, p1 cid.Cid) (uint64, error) `perm:"read"`

		PiecesGetPieceInfo func(p0 context.Context, p1 cid.Cid) (*piecestore.PieceInfo, error) `perm:"read"`

		PiecesListCidInfos func(p0 context.Context) ([]cid.Cid, error) `perm:"read"`

		PiecesListPieces func(p0 context.Context) ([]cid.Cid, error) `perm:"read"`

		RuntimeSubsystems func(p0 context.Context) (lapi.MinerSubsystems, error) `perm:"read"`

		SectorsRefs func(p0 context.Context) (map[string][]lapi.SealedRef, error) `perm:"read"`
	}
}

func (*BoostStruct) ActorSectorSize

func (s *BoostStruct) ActorSectorSize(p0 context.Context, p1 address.Address) (abi.SectorSize, error)

func (*BoostStruct) BlockstoreGet added in v1.5.0

func (s *BoostStruct) BlockstoreGet(p0 context.Context, p1 cid.Cid) ([]byte, error)

func (*BoostStruct) BlockstoreGetSize added in v1.5.0

func (s *BoostStruct) BlockstoreGetSize(p0 context.Context, p1 cid.Cid) (int, error)

func (*BoostStruct) BlockstoreHas added in v1.5.0

func (s *BoostStruct) BlockstoreHas(p0 context.Context, p1 cid.Cid) (bool, error)

func (*BoostStruct) BoostDagstoreDestroyShard added in v1.3.0

func (s *BoostStruct) BoostDagstoreDestroyShard(p0 context.Context, p1 string) error

func (*BoostStruct) BoostDagstoreGC

func (s *BoostStruct) BoostDagstoreGC(p0 context.Context) ([]DagstoreShardResult, error)

func (*BoostStruct) BoostDagstoreInitializeAll

func (s *BoostStruct) BoostDagstoreInitializeAll(p0 context.Context, p1 DagstoreInitializeAllParams) (<-chan DagstoreInitializeAllEvent, error)

func (*BoostStruct) BoostDagstoreInitializeShard

func (s *BoostStruct) BoostDagstoreInitializeShard(p0 context.Context, p1 string) error

func (*BoostStruct) BoostDagstoreListShards

func (s *BoostStruct) BoostDagstoreListShards(p0 context.Context) ([]DagstoreShardInfo, error)

func (*BoostStruct) BoostDagstorePiecesContainingMultihash added in v1.1.0

func (s *BoostStruct) BoostDagstorePiecesContainingMultihash(p0 context.Context, p1 multihash.Multihash) ([]cid.Cid, error)

func (*BoostStruct) BoostDagstoreRecoverShard

func (s *BoostStruct) BoostDagstoreRecoverShard(p0 context.Context, p1 string) error

func (*BoostStruct) BoostDagstoreRegisterShard

func (s *BoostStruct) BoostDagstoreRegisterShard(p0 context.Context, p1 string) error

func (*BoostStruct) BoostDeal

func (*BoostStruct) BoostDealBySignedProposalCid added in v1.1.0

func (s *BoostStruct) BoostDealBySignedProposalCid(p0 context.Context, p1 cid.Cid) (*smtypes.ProviderDealState, error)

func (*BoostStruct) BoostDummyDeal

func (*BoostStruct) BoostIndexerAnnounceAllDeals

func (s *BoostStruct) BoostIndexerAnnounceAllDeals(p0 context.Context) error

func (*BoostStruct) BoostIndexerAnnounceLatest added in v1.7.3

func (s *BoostStruct) BoostIndexerAnnounceLatest(p0 context.Context) (cid.Cid, error)

func (*BoostStruct) BoostIndexerAnnounceLatestHttp added in v1.7.3

func (s *BoostStruct) BoostIndexerAnnounceLatestHttp(p0 context.Context, p1 []string) (cid.Cid, error)

func (*BoostStruct) BoostMakeDeal added in v1.6.1

func (*BoostStruct) BoostOfflineDealWithData

func (s *BoostStruct) BoostOfflineDealWithData(p0 context.Context, p1 uuid.UUID, p2 string, p3 bool) (*ProviderDealRejectionInfo, error)

func (*BoostStruct) DealsConsiderOfflineRetrievalDeals

func (s *BoostStruct) DealsConsiderOfflineRetrievalDeals(p0 context.Context) (bool, error)

func (*BoostStruct) DealsConsiderOfflineStorageDeals

func (s *BoostStruct) DealsConsiderOfflineStorageDeals(p0 context.Context) (bool, error)

func (*BoostStruct) DealsConsiderOnlineRetrievalDeals

func (s *BoostStruct) DealsConsiderOnlineRetrievalDeals(p0 context.Context) (bool, error)

func (*BoostStruct) DealsConsiderOnlineStorageDeals

func (s *BoostStruct) DealsConsiderOnlineStorageDeals(p0 context.Context) (bool, error)

func (*BoostStruct) DealsConsiderUnverifiedStorageDeals

func (s *BoostStruct) DealsConsiderUnverifiedStorageDeals(p0 context.Context) (bool, error)

func (*BoostStruct) DealsConsiderVerifiedStorageDeals

func (s *BoostStruct) DealsConsiderVerifiedStorageDeals(p0 context.Context) (bool, error)

func (*BoostStruct) DealsPieceCidBlocklist

func (s *BoostStruct) DealsPieceCidBlocklist(p0 context.Context) ([]cid.Cid, error)

func (*BoostStruct) DealsSetConsiderOfflineRetrievalDeals

func (s *BoostStruct) DealsSetConsiderOfflineRetrievalDeals(p0 context.Context, p1 bool) error

func (*BoostStruct) DealsSetConsiderOfflineStorageDeals

func (s *BoostStruct) DealsSetConsiderOfflineStorageDeals(p0 context.Context, p1 bool) error

func (*BoostStruct) DealsSetConsiderOnlineRetrievalDeals

func (s *BoostStruct) DealsSetConsiderOnlineRetrievalDeals(p0 context.Context, p1 bool) error

func (*BoostStruct) DealsSetConsiderOnlineStorageDeals

func (s *BoostStruct) DealsSetConsiderOnlineStorageDeals(p0 context.Context, p1 bool) error

func (*BoostStruct) DealsSetConsiderUnverifiedStorageDeals

func (s *BoostStruct) DealsSetConsiderUnverifiedStorageDeals(p0 context.Context, p1 bool) error

func (*BoostStruct) DealsSetConsiderVerifiedStorageDeals

func (s *BoostStruct) DealsSetConsiderVerifiedStorageDeals(p0 context.Context, p1 bool) error

func (*BoostStruct) DealsSetPieceCidBlocklist

func (s *BoostStruct) DealsSetPieceCidBlocklist(p0 context.Context, p1 []cid.Cid) error

func (*BoostStruct) MarketCancelDataTransfer

func (s *BoostStruct) MarketCancelDataTransfer(p0 context.Context, p1 datatransfer.TransferID, p2 peer.ID, p3 bool) error

func (*BoostStruct) MarketDataTransferUpdates

func (s *BoostStruct) MarketDataTransferUpdates(p0 context.Context) (<-chan DataTransferChannel, error)

func (*BoostStruct) MarketGetAsk

func (*BoostStruct) MarketGetRetrievalAsk

func (s *BoostStruct) MarketGetRetrievalAsk(p0 context.Context) (*retrievalmarket.Ask, error)

func (*BoostStruct) MarketImportDealData

func (s *BoostStruct) MarketImportDealData(p0 context.Context, p1 cid.Cid, p2 string) error

func (*BoostStruct) MarketListDataTransfers

func (s *BoostStruct) MarketListDataTransfers(p0 context.Context) ([]DataTransferChannel, error)

func (*BoostStruct) MarketListIncompleteDeals

func (s *BoostStruct) MarketListIncompleteDeals(p0 context.Context) ([]storagemarket.MinerDeal, error)

func (*BoostStruct) MarketListRetrievalDeals

func (s *BoostStruct) MarketListRetrievalDeals(p0 context.Context) ([]retrievalmarket.ProviderDealState, error)

func (*BoostStruct) MarketPendingDeals added in v1.5.0

func (s *BoostStruct) MarketPendingDeals(p0 context.Context) (lapi.PendingDealInfo, error)

func (*BoostStruct) MarketRestartDataTransfer

func (s *BoostStruct) MarketRestartDataTransfer(p0 context.Context, p1 datatransfer.TransferID, p2 peer.ID, p3 bool) error

func (*BoostStruct) MarketSetAsk

func (*BoostStruct) MarketSetRetrievalAsk

func (s *BoostStruct) MarketSetRetrievalAsk(p0 context.Context, p1 *retrievalmarket.Ask) error

func (*BoostStruct) OnlineBackup added in v1.6.1

func (s *BoostStruct) OnlineBackup(p0 context.Context, p1 string) error

func (*BoostStruct) PiecesGetCIDInfo

func (s *BoostStruct) PiecesGetCIDInfo(p0 context.Context, p1 cid.Cid) (*piecestore.CIDInfo, error)

func (*BoostStruct) PiecesGetMaxOffset added in v1.1.0

func (s *BoostStruct) PiecesGetMaxOffset(p0 context.Context, p1 cid.Cid) (uint64, error)

func (*BoostStruct) PiecesGetPieceInfo

func (s *BoostStruct) PiecesGetPieceInfo(p0 context.Context, p1 cid.Cid) (*piecestore.PieceInfo, error)

func (*BoostStruct) PiecesListCidInfos

func (s *BoostStruct) PiecesListCidInfos(p0 context.Context) ([]cid.Cid, error)

func (*BoostStruct) PiecesListPieces

func (s *BoostStruct) PiecesListPieces(p0 context.Context) ([]cid.Cid, error)

func (*BoostStruct) RuntimeSubsystems

func (s *BoostStruct) RuntimeSubsystems(p0 context.Context) (lapi.MinerSubsystems, error)

func (*BoostStruct) SectorsRefs added in v1.5.0

func (s *BoostStruct) SectorsRefs(p0 context.Context) (map[string][]lapi.SealedRef, error)

type BoostStub

type BoostStub struct {
	CommonStub

	NetStub
}

func (*BoostStub) ActorSectorSize

func (s *BoostStub) ActorSectorSize(p0 context.Context, p1 address.Address) (abi.SectorSize, error)

func (*BoostStub) BlockstoreGet added in v1.5.0

func (s *BoostStub) BlockstoreGet(p0 context.Context, p1 cid.Cid) ([]byte, error)

func (*BoostStub) BlockstoreGetSize added in v1.5.0

func (s *BoostStub) BlockstoreGetSize(p0 context.Context, p1 cid.Cid) (int, error)

func (*BoostStub) BlockstoreHas added in v1.5.0

func (s *BoostStub) BlockstoreHas(p0 context.Context, p1 cid.Cid) (bool, error)

func (*BoostStub) BoostDagstoreDestroyShard added in v1.3.0

func (s *BoostStub) BoostDagstoreDestroyShard(p0 context.Context, p1 string) error

func (*BoostStub) BoostDagstoreGC

func (s *BoostStub) BoostDagstoreGC(p0 context.Context) ([]DagstoreShardResult, error)

func (*BoostStub) BoostDagstoreInitializeAll

func (s *BoostStub) BoostDagstoreInitializeAll(p0 context.Context, p1 DagstoreInitializeAllParams) (<-chan DagstoreInitializeAllEvent, error)

func (*BoostStub) BoostDagstoreInitializeShard

func (s *BoostStub) BoostDagstoreInitializeShard(p0 context.Context, p1 string) error

func (*BoostStub) BoostDagstoreListShards

func (s *BoostStub) BoostDagstoreListShards(p0 context.Context) ([]DagstoreShardInfo, error)

func (*BoostStub) BoostDagstorePiecesContainingMultihash added in v1.1.0

func (s *BoostStub) BoostDagstorePiecesContainingMultihash(p0 context.Context, p1 multihash.Multihash) ([]cid.Cid, error)

func (*BoostStub) BoostDagstoreRecoverShard

func (s *BoostStub) BoostDagstoreRecoverShard(p0 context.Context, p1 string) error

func (*BoostStub) BoostDagstoreRegisterShard

func (s *BoostStub) BoostDagstoreRegisterShard(p0 context.Context, p1 string) error

func (*BoostStub) BoostDeal

func (s *BoostStub) BoostDeal(p0 context.Context, p1 uuid.UUID) (*smtypes.ProviderDealState, error)

func (*BoostStub) BoostDealBySignedProposalCid added in v1.1.0

func (s *BoostStub) BoostDealBySignedProposalCid(p0 context.Context, p1 cid.Cid) (*smtypes.ProviderDealState, error)

func (*BoostStub) BoostDummyDeal

func (*BoostStub) BoostIndexerAnnounceAllDeals

func (s *BoostStub) BoostIndexerAnnounceAllDeals(p0 context.Context) error

func (*BoostStub) BoostIndexerAnnounceLatest added in v1.7.3

func (s *BoostStub) BoostIndexerAnnounceLatest(p0 context.Context) (cid.Cid, error)

func (*BoostStub) BoostIndexerAnnounceLatestHttp added in v1.7.3

func (s *BoostStub) BoostIndexerAnnounceLatestHttp(p0 context.Context, p1 []string) (cid.Cid, error)

func (*BoostStub) BoostMakeDeal added in v1.6.1

func (*BoostStub) BoostOfflineDealWithData

func (s *BoostStub) BoostOfflineDealWithData(p0 context.Context, p1 uuid.UUID, p2 string, p3 bool) (*ProviderDealRejectionInfo, error)

func (*BoostStub) DealsConsiderOfflineRetrievalDeals

func (s *BoostStub) DealsConsiderOfflineRetrievalDeals(p0 context.Context) (bool, error)

func (*BoostStub) DealsConsiderOfflineStorageDeals

func (s *BoostStub) DealsConsiderOfflineStorageDeals(p0 context.Context) (bool, error)

func (*BoostStub) DealsConsiderOnlineRetrievalDeals

func (s *BoostStub) DealsConsiderOnlineRetrievalDeals(p0 context.Context) (bool, error)

func (*BoostStub) DealsConsiderOnlineStorageDeals

func (s *BoostStub) DealsConsiderOnlineStorageDeals(p0 context.Context) (bool, error)

func (*BoostStub) DealsConsiderUnverifiedStorageDeals

func (s *BoostStub) DealsConsiderUnverifiedStorageDeals(p0 context.Context) (bool, error)

func (*BoostStub) DealsConsiderVerifiedStorageDeals

func (s *BoostStub) DealsConsiderVerifiedStorageDeals(p0 context.Context) (bool, error)

func (*BoostStub) DealsPieceCidBlocklist

func (s *BoostStub) DealsPieceCidBlocklist(p0 context.Context) ([]cid.Cid, error)

func (*BoostStub) DealsSetConsiderOfflineRetrievalDeals

func (s *BoostStub) DealsSetConsiderOfflineRetrievalDeals(p0 context.Context, p1 bool) error

func (*BoostStub) DealsSetConsiderOfflineStorageDeals

func (s *BoostStub) DealsSetConsiderOfflineStorageDeals(p0 context.Context, p1 bool) error

func (*BoostStub) DealsSetConsiderOnlineRetrievalDeals

func (s *BoostStub) DealsSetConsiderOnlineRetrievalDeals(p0 context.Context, p1 bool) error

func (*BoostStub) DealsSetConsiderOnlineStorageDeals

func (s *BoostStub) DealsSetConsiderOnlineStorageDeals(p0 context.Context, p1 bool) error

func (*BoostStub) DealsSetConsiderUnverifiedStorageDeals

func (s *BoostStub) DealsSetConsiderUnverifiedStorageDeals(p0 context.Context, p1 bool) error

func (*BoostStub) DealsSetConsiderVerifiedStorageDeals

func (s *BoostStub) DealsSetConsiderVerifiedStorageDeals(p0 context.Context, p1 bool) error

func (*BoostStub) DealsSetPieceCidBlocklist

func (s *BoostStub) DealsSetPieceCidBlocklist(p0 context.Context, p1 []cid.Cid) error

func (*BoostStub) MarketCancelDataTransfer

func (s *BoostStub) MarketCancelDataTransfer(p0 context.Context, p1 datatransfer.TransferID, p2 peer.ID, p3 bool) error

func (*BoostStub) MarketDataTransferUpdates

func (s *BoostStub) MarketDataTransferUpdates(p0 context.Context) (<-chan DataTransferChannel, error)

func (*BoostStub) MarketGetAsk

func (s *BoostStub) MarketGetAsk(p0 context.Context) (*storagemarket.SignedStorageAsk, error)

func (*BoostStub) MarketGetRetrievalAsk

func (s *BoostStub) MarketGetRetrievalAsk(p0 context.Context) (*retrievalmarket.Ask, error)

func (*BoostStub) MarketImportDealData

func (s *BoostStub) MarketImportDealData(p0 context.Context, p1 cid.Cid, p2 string) error

func (*BoostStub) MarketListDataTransfers

func (s *BoostStub) MarketListDataTransfers(p0 context.Context) ([]DataTransferChannel, error)

func (*BoostStub) MarketListIncompleteDeals

func (s *BoostStub) MarketListIncompleteDeals(p0 context.Context) ([]storagemarket.MinerDeal, error)

func (*BoostStub) MarketListRetrievalDeals

func (s *BoostStub) MarketListRetrievalDeals(p0 context.Context) ([]retrievalmarket.ProviderDealState, error)

func (*BoostStub) MarketPendingDeals added in v1.5.0

func (s *BoostStub) MarketPendingDeals(p0 context.Context) (lapi.PendingDealInfo, error)

func (*BoostStub) MarketRestartDataTransfer

func (s *BoostStub) MarketRestartDataTransfer(p0 context.Context, p1 datatransfer.TransferID, p2 peer.ID, p3 bool) error

func (*BoostStub) MarketSetAsk

func (*BoostStub) MarketSetRetrievalAsk

func (s *BoostStub) MarketSetRetrievalAsk(p0 context.Context, p1 *retrievalmarket.Ask) error

func (*BoostStub) OnlineBackup added in v1.6.1

func (s *BoostStub) OnlineBackup(p0 context.Context, p1 string) error

func (*BoostStub) PiecesGetCIDInfo

func (s *BoostStub) PiecesGetCIDInfo(p0 context.Context, p1 cid.Cid) (*piecestore.CIDInfo, error)

func (*BoostStub) PiecesGetMaxOffset added in v1.1.0

func (s *BoostStub) PiecesGetMaxOffset(p0 context.Context, p1 cid.Cid) (uint64, error)

func (*BoostStub) PiecesGetPieceInfo

func (s *BoostStub) PiecesGetPieceInfo(p0 context.Context, p1 cid.Cid) (*piecestore.PieceInfo, error)

func (*BoostStub) PiecesListCidInfos

func (s *BoostStub) PiecesListCidInfos(p0 context.Context) ([]cid.Cid, error)

func (*BoostStub) PiecesListPieces

func (s *BoostStub) PiecesListPieces(p0 context.Context) ([]cid.Cid, error)

func (*BoostStub) RuntimeSubsystems

func (s *BoostStub) RuntimeSubsystems(p0 context.Context) (lapi.MinerSubsystems, error)

func (*BoostStub) SectorsRefs added in v1.5.0

func (s *BoostStub) SectorsRefs(p0 context.Context) (map[string][]lapi.SealedRef, error)

type ChainIO

type ChainIO interface {
	ChainReadObj(context.Context, cid.Cid) ([]byte, error)
	ChainHasObj(context.Context, cid.Cid) (bool, error)
}

ChainIO abstracts operations for accessing raw IPLD objects.

type ChainIOStruct

type ChainIOStruct struct {
	Internal struct {
		ChainHasObj func(p0 context.Context, p1 cid.Cid) (bool, error) ``

		ChainReadObj func(p0 context.Context, p1 cid.Cid) ([]byte, error) ``
	}
}

func (*ChainIOStruct) ChainHasObj

func (s *ChainIOStruct) ChainHasObj(p0 context.Context, p1 cid.Cid) (bool, error)

func (*ChainIOStruct) ChainReadObj

func (s *ChainIOStruct) ChainReadObj(p0 context.Context, p1 cid.Cid) ([]byte, error)

type ChainIOStub

type ChainIOStub struct {
}

func (*ChainIOStub) ChainHasObj

func (s *ChainIOStub) ChainHasObj(p0 context.Context, p1 cid.Cid) (bool, error)

func (*ChainIOStub) ChainReadObj

func (s *ChainIOStub) ChainReadObj(p0 context.Context, p1 cid.Cid) ([]byte, error)

type ChannelAvailableFunds

type ChannelAvailableFunds struct {
	// Channel is the address of the channel
	Channel *address.Address
	// From is the from address of the channel (channel creator)
	From address.Address
	// To is the to address of the channel
	To address.Address
	// ConfirmedAmt is the amount of funds that have been confirmed on-chain
	// for the channel
	ConfirmedAmt types.BigInt
	// PendingAmt is the amount of funds that are pending confirmation on-chain
	PendingAmt types.BigInt
	// PendingWaitSentinel can be used with PaychGetWaitReady to wait for
	// confirmation of pending funds
	PendingWaitSentinel *cid.Cid
	// QueuedAmt is the amount that is queued up behind a pending request
	QueuedAmt types.BigInt
	// VoucherRedeemedAmt is the amount that is redeemed by vouchers on-chain
	// and in the local datastore
	VoucherReedeemedAmt types.BigInt
}

type ChannelInfo

type ChannelInfo struct {
	Channel      address.Address
	WaitSentinel cid.Cid
}

type CheckStatus

type CheckStatus struct {
	Code CheckStatusCode
	OK   bool
	Err  string
	Hint map[string]interface{}
}

type CheckStatusCode

type CheckStatusCode int
const (

	// Message Checks
	CheckStatusMessageSerialize CheckStatusCode
	CheckStatusMessageSize
	CheckStatusMessageValidity
	CheckStatusMessageMinGas
	CheckStatusMessageMinBaseFee
	CheckStatusMessageBaseFee
	CheckStatusMessageBaseFeeLowerBound
	CheckStatusMessageBaseFeeUpperBound
	CheckStatusMessageGetStateNonce
	CheckStatusMessageNonce
	CheckStatusMessageGetStateBalance
	CheckStatusMessageBalance
)

type CirculatingSupply

type CirculatingSupply struct {
	FilVested           abi.TokenAmount
	FilMined            abi.TokenAmount
	FilBurnt            abi.TokenAmount
	FilLocked           abi.TokenAmount
	FilCirculating      abi.TokenAmount
	FilReserveDisbursed abi.TokenAmount
}

type CommPRet

type CommPRet struct {
	Root cid.Cid
	Size abi.UnpaddedPieceSize
}

type Common

type Common interface {
	AuthVerify(ctx context.Context, token string) ([]auth.Permission, error) //perm:read
	AuthNew(ctx context.Context, perms []auth.Permission) ([]byte, error)    //perm:admin

	LogList(context.Context) ([]string, error)         //perm:write
	LogSetLevel(context.Context, string, string) error //perm:write

	// Discover returns an OpenRPC document describing an RPC API.
	Discover(ctx context.Context) (apitypes.OpenRPCDocument, error) //perm:read

}

type CommonNet

type CommonNet interface {
	Common
	Net
}

type CommonNetStruct

type CommonNetStruct struct {
	CommonStruct

	NetStruct

	Internal struct {
	}
}

type CommonNetStub

type CommonNetStub struct {
	CommonStub

	NetStub
}

type CommonStruct

type CommonStruct struct {
	Internal struct {
		AuthNew func(p0 context.Context, p1 []auth.Permission) ([]byte, error) `perm:"admin"`

		AuthVerify func(p0 context.Context, p1 string) ([]auth.Permission, error) `perm:"read"`

		Discover func(p0 context.Context) (apitypes.OpenRPCDocument, error) `perm:"read"`

		LogList func(p0 context.Context) ([]string, error) `perm:"write"`

		LogSetLevel func(p0 context.Context, p1 string, p2 string) error `perm:"write"`
	}
}

func (*CommonStruct) AuthNew

func (s *CommonStruct) AuthNew(p0 context.Context, p1 []auth.Permission) ([]byte, error)

func (*CommonStruct) AuthVerify

func (s *CommonStruct) AuthVerify(p0 context.Context, p1 string) ([]auth.Permission, error)

func (*CommonStruct) Discover added in v1.7.3

func (*CommonStruct) LogList

func (s *CommonStruct) LogList(p0 context.Context) ([]string, error)

func (*CommonStruct) LogSetLevel

func (s *CommonStruct) LogSetLevel(p0 context.Context, p1 string, p2 string) error

type CommonStub

type CommonStub struct {
}

func (*CommonStub) AuthNew

func (s *CommonStub) AuthNew(p0 context.Context, p1 []auth.Permission) ([]byte, error)

func (*CommonStub) AuthVerify

func (s *CommonStub) AuthVerify(p0 context.Context, p1 string) ([]auth.Permission, error)

func (*CommonStub) Discover added in v1.7.3

func (*CommonStub) LogList

func (s *CommonStub) LogList(p0 context.Context) ([]string, error)

func (*CommonStub) LogSetLevel

func (s *CommonStub) LogSetLevel(p0 context.Context, p1 string, p2 string) error

type ComputeStateOutput

type ComputeStateOutput struct {
	Root  cid.Cid
	Trace []*InvocResult
}

type ConnMgrInfo

type ConnMgrInfo struct {
	FirstSeen time.Time
	Value     int
	Tags      map[string]int
	Conns     map[string]time.Time
}

type DagstoreInitializeAllEvent

type DagstoreInitializeAllEvent struct {
	Key     string
	Event   string // "start", "end"
	Success bool
	Error   string
	Total   int
	Current int
}

DagstoreInitializeAllEvent represents an initialization event.

type DagstoreInitializeAllParams

type DagstoreInitializeAllParams struct {
	MaxConcurrency int
	IncludeSealed  bool
}

type DagstoreShardInfo

type DagstoreShardInfo struct {
	Key   string
	State string
	Error string
}

DagstoreShardInfo is the serialized form of dagstore.DagstoreShardInfo that we expose through JSON-RPC to avoid clients having to depend on the dagstore lib.

type DagstoreShardResult

type DagstoreShardResult struct {
	Key     string
	Success bool
	Error   string
}

DagstoreShardResult enumerates results per shard.

type DataCIDSize

type DataCIDSize struct {
	PayloadSize int64
	PieceSize   abi.PaddedPieceSize
	PieceCID    cid.Cid
}

type DataSize

type DataSize struct {
	PayloadSize int64
	PieceSize   abi.PaddedPieceSize
}

type DataTransferChannel

type DataTransferChannel struct {
	TransferID  datatransfer.TransferID
	Status      datatransfer.Status
	BaseCID     cid.Cid
	IsInitiator bool
	IsSender    bool
	Voucher     string
	Message     string
	OtherPeer   peer.ID
	Transferred uint64
	Stages      *datatransfer.ChannelStages
}

func NewDataTransferChannel

func NewDataTransferChannel(hostID peer.ID, channelState datatransfer.ChannelState) DataTransferChannel

NewDataTransferChannel constructs an API DataTransferChannel type from full channel state snapshot and a host id

type Deadline

type Deadline struct {
	PostSubmissions      bitfield.BitField
	DisputableProofCount uint64
}

type DealCollateralBounds

type DealCollateralBounds struct {
	Min abi.TokenAmount
	Max abi.TokenAmount
}

type DealInfo

type DealInfo struct {
	ProposalCid cid.Cid
	State       storagemarket.StorageDealStatus
	Message     string // more information about deal state, particularly errors
	DealStages  *storagemarket.DealStages
	Provider    address.Address

	DataRef  *storagemarket.DataRef
	PieceCID cid.Cid
	Size     uint64

	PricePerEpoch types.BigInt
	Duration      uint64

	DealID abi.DealID

	CreationTime time.Time
	Verified     bool

	TransferChannelID *datatransfer.ChannelID
	DataTransfer      *DataTransferChannel
}

type ExtendedPeerInfo

type ExtendedPeerInfo struct {
	ID          peer.ID
	Agent       string
	Addrs       []string
	Protocols   []string
	ConnMgrMeta *ConnMgrInfo
}

type Fault

type Fault struct {
	Miner address.Address
	Epoch abi.ChainEpoch
}

type FileRef

type FileRef struct {
	Path  string
	IsCAR bool
}

type HeadChange

type HeadChange struct {
	Type string
	Val  *types.TipSet
}

type Import

type Import struct {
	Key imports.ID
	Err string

	Root *cid.Cid

	// Source is the provenance of the import, e.g. "import", "unknown", else.
	// Currently useless but may be used in the future.
	Source string

	// FilePath is the path of the original file. It is important that the file
	// is retained at this path, because it will be referenced during
	// the transfer (when we do the UnixFS chunking, we don't duplicate the
	// leaves, but rather point to chunks of the original data through
	// positional references).
	FilePath string

	// CARPath is the path of the CAR file containing the DAG for this import.
	CARPath string
}

type ImportRes

type ImportRes struct {
	Root     cid.Cid
	ImportID imports.ID
}

type InvocResult

type InvocResult struct {
	MsgCid         cid.Cid
	Msg            *types.Message
	MsgRct         *types.MessageReceipt
	GasCost        MsgGasCost
	ExecutionTrace types.ExecutionTrace
	Error          string
	Duration       time.Duration
}

type IpldObject

type IpldObject struct {
	Cid cid.Cid
	Obj interface{}
}

type MarketBalance

type MarketBalance struct {
	Escrow big.Int
	Locked big.Int
}

type MarketDeal

type MarketDeal struct {
	Proposal market.DealProposal
	State    market.DealState
}

type Message

type Message struct {
	Cid     cid.Cid
	Message *types.Message
}

type MessageCheckStatus

type MessageCheckStatus struct {
	Cid cid.Cid
	CheckStatus
}

type MessageMatch

type MessageMatch struct {
	To   address.Address
	From address.Address
}

type MessagePrototype

type MessagePrototype struct {
	Message    types.Message
	ValidNonce bool
}

type MessageSendSpec

type MessageSendSpec struct {
	MaxFee abi.TokenAmount
}

type MethodCall

type MethodCall struct {
	types.MessageReceipt
	Error string
}

type MinerPower

type MinerPower struct {
	MinerPower  power.Claim
	TotalPower  power.Claim
	HasMinPower bool
}

type MinerSectors

type MinerSectors struct {
	// Live sectors that should be proven.
	Live uint64
	// Sectors actively contributing to power.
	Active uint64
	// Sectors with failed proofs.
	Faulty uint64
}

type MiningBaseInfo

type MiningBaseInfo struct {
	MinerPower        types.BigInt
	NetworkPower      types.BigInt
	Sectors           []builtin.SectorInfo
	WorkerKey         address.Address
	SectorSize        abi.SectorSize
	PrevBeaconEntry   types.BeaconEntry
	BeaconEntries     []types.BeaconEntry
	EligibleForMining bool
}

type MpoolChange

type MpoolChange int
const (
	MpoolAdd MpoolChange = iota
	MpoolRemove
)

type MpoolUpdate

type MpoolUpdate struct {
	Type    MpoolChange
	Message *types.SignedMessage
}

type MsgGasCost

type MsgGasCost struct {
	Message            cid.Cid // Can be different than requested, in case it was replaced, but only gas values changed
	GasUsed            abi.TokenAmount
	BaseFeeBurn        abi.TokenAmount
	OverEstimationBurn abi.TokenAmount
	MinerPenalty       abi.TokenAmount
	MinerTip           abi.TokenAmount
	Refund             abi.TokenAmount
	TotalCost          abi.TokenAmount
}

type MsgLookup

type MsgLookup struct {
	Message   cid.Cid // Can be different than requested, in case it was replaced, but only gas values changed
	Receipt   types.MessageReceipt
	ReturnDec interface{}
	TipSet    types.TipSetKey
	Height    abi.ChainEpoch
}

type MsigProposeResponse

type MsigProposeResponse int
const (
	MsigApprove MsigProposeResponse = iota
	MsigCancel
)

type MsigTransaction

type MsigTransaction struct {
	ID     int64
	To     address.Address
	Value  abi.TokenAmount
	Method abi.MethodNum
	Params []byte

	Approved []address.Address
}

type MsigVesting

type MsigVesting struct {
	InitialBalance abi.TokenAmount
	StartEpoch     abi.ChainEpoch
	UnlockDuration abi.ChainEpoch
}

type MultiaddrSlice

type MultiaddrSlice []ma.Multiaddr

func (*MultiaddrSlice) UnmarshalJSON

func (m *MultiaddrSlice) UnmarshalJSON(raw []byte) (err error)

type Net

type Net interface {
	// MethodGroup: Net
	NetConnectedness(context.Context, peer.ID) (network.Connectedness, error)  //perm:read
	NetPeers(context.Context) ([]peer.AddrInfo, error)                         //perm:read
	NetPing(context.Context, peer.ID) (time.Duration, error)                   //perm:read
	NetConnect(context.Context, peer.AddrInfo) error                           //perm:write
	NetAddrsListen(context.Context) (peer.AddrInfo, error)                     //perm:read
	NetDisconnect(context.Context, peer.ID) error                              //perm:write
	NetFindPeer(context.Context, peer.ID) (peer.AddrInfo, error)               //perm:read
	NetPubsubScores(context.Context) ([]lotus_api.PubsubScore, error)          //perm:read
	NetAutoNatStatus(context.Context) (lotus_api.NatInfo, error)               //perm:read
	NetAgentVersion(ctx context.Context, p peer.ID) (string, error)            //perm:read
	NetPeerInfo(context.Context, peer.ID) (*lotus_api.ExtendedPeerInfo, error) //perm:read

	// NetBandwidthStats returns statistics about the nodes total bandwidth
	// usage and current rate across all peers and protocols.
	NetBandwidthStats(ctx context.Context) (metrics.Stats, error) //perm:read

	// NetBandwidthStatsByPeer returns statistics about the nodes bandwidth
	// usage and current rate per peer
	NetBandwidthStatsByPeer(ctx context.Context) (map[string]metrics.Stats, error) //perm:read

	// NetBandwidthStatsByProtocol returns statistics about the nodes bandwidth
	// usage and current rate per protocol
	NetBandwidthStatsByProtocol(ctx context.Context) (map[protocol.ID]metrics.Stats, error) //perm:read

	// ConnectionGater API
	NetBlockAdd(ctx context.Context, acl lotus_api.NetBlockList) error    //perm:admin
	NetBlockRemove(ctx context.Context, acl lotus_api.NetBlockList) error //perm:admin
	NetBlockList(ctx context.Context) (lotus_api.NetBlockList, error)     //perm:read
	NetProtectAdd(ctx context.Context, acl []peer.ID) error               //perm:admin
	NetProtectRemove(ctx context.Context, acl []peer.ID) error            //perm:admin
	NetProtectList(ctx context.Context) ([]peer.ID, error)                //perm:read

	// ID returns peerID of libp2p node backing this API
	ID(context.Context) (peer.ID, error) //perm:read

	// ResourceManager API
	NetStat(ctx context.Context, scope string) (lotus_api.NetStat, error)          //perm:read
	NetLimit(ctx context.Context, scope string) (lotus_api.NetLimit, error)        //perm:read
	NetSetLimit(ctx context.Context, scope string, limit lotus_api.NetLimit) error //perm:admin
}

This interface is a direct copy of the lotus equivalent. We can't just include the lotus equivalent directly because of the way that the generator works (it doesn't pull in types that are outside this directory)

type NetStruct

type NetStruct struct {
	Internal struct {
		ID func(p0 context.Context) (peer.ID, error) `perm:"read"`

		NetAddrsListen func(p0 context.Context) (peer.AddrInfo, error) `perm:"read"`

		NetAgentVersion func(p0 context.Context, p1 peer.ID) (string, error) `perm:"read"`

		NetAutoNatStatus func(p0 context.Context) (lotus_api.NatInfo, error) `perm:"read"`

		NetBandwidthStats func(p0 context.Context) (metrics.Stats, error) `perm:"read"`

		NetBandwidthStatsByPeer func(p0 context.Context) (map[string]metrics.Stats, error) `perm:"read"`

		NetBandwidthStatsByProtocol func(p0 context.Context) (map[protocol.ID]metrics.Stats, error) `perm:"read"`

		NetBlockAdd func(p0 context.Context, p1 lotus_api.NetBlockList) error `perm:"admin"`

		NetBlockList func(p0 context.Context) (lotus_api.NetBlockList, error) `perm:"read"`

		NetBlockRemove func(p0 context.Context, p1 lotus_api.NetBlockList) error `perm:"admin"`

		NetConnect func(p0 context.Context, p1 peer.AddrInfo) error `perm:"write"`

		NetConnectedness func(p0 context.Context, p1 peer.ID) (network.Connectedness, error) `perm:"read"`

		NetDisconnect func(p0 context.Context, p1 peer.ID) error `perm:"write"`

		NetFindPeer func(p0 context.Context, p1 peer.ID) (peer.AddrInfo, error) `perm:"read"`

		NetLimit func(p0 context.Context, p1 string) (lotus_api.NetLimit, error) `perm:"read"`

		NetPeerInfo func(p0 context.Context, p1 peer.ID) (*lotus_api.ExtendedPeerInfo, error) `perm:"read"`

		NetPeers func(p0 context.Context) ([]peer.AddrInfo, error) `perm:"read"`

		NetPing func(p0 context.Context, p1 peer.ID) (time.Duration, error) `perm:"read"`

		NetProtectAdd func(p0 context.Context, p1 []peer.ID) error `perm:"admin"`

		NetProtectList func(p0 context.Context) ([]peer.ID, error) `perm:"read"`

		NetProtectRemove func(p0 context.Context, p1 []peer.ID) error `perm:"admin"`

		NetPubsubScores func(p0 context.Context) ([]lotus_api.PubsubScore, error) `perm:"read"`

		NetSetLimit func(p0 context.Context, p1 string, p2 lotus_api.NetLimit) error `perm:"admin"`

		NetStat func(p0 context.Context, p1 string) (lotus_api.NetStat, error) `perm:"read"`
	}
}

func (*NetStruct) ID

func (s *NetStruct) ID(p0 context.Context) (peer.ID, error)

func (*NetStruct) NetAddrsListen

func (s *NetStruct) NetAddrsListen(p0 context.Context) (peer.AddrInfo, error)

func (*NetStruct) NetAgentVersion

func (s *NetStruct) NetAgentVersion(p0 context.Context, p1 peer.ID) (string, error)

func (*NetStruct) NetAutoNatStatus

func (s *NetStruct) NetAutoNatStatus(p0 context.Context) (lotus_api.NatInfo, error)

func (*NetStruct) NetBandwidthStats

func (s *NetStruct) NetBandwidthStats(p0 context.Context) (metrics.Stats, error)

func (*NetStruct) NetBandwidthStatsByPeer

func (s *NetStruct) NetBandwidthStatsByPeer(p0 context.Context) (map[string]metrics.Stats, error)

func (*NetStruct) NetBandwidthStatsByProtocol

func (s *NetStruct) NetBandwidthStatsByProtocol(p0 context.Context) (map[protocol.ID]metrics.Stats, error)

func (*NetStruct) NetBlockAdd

func (s *NetStruct) NetBlockAdd(p0 context.Context, p1 lotus_api.NetBlockList) error

func (*NetStruct) NetBlockList

func (s *NetStruct) NetBlockList(p0 context.Context) (lotus_api.NetBlockList, error)

func (*NetStruct) NetBlockRemove

func (s *NetStruct) NetBlockRemove(p0 context.Context, p1 lotus_api.NetBlockList) error

func (*NetStruct) NetConnect

func (s *NetStruct) NetConnect(p0 context.Context, p1 peer.AddrInfo) error

func (*NetStruct) NetConnectedness

func (s *NetStruct) NetConnectedness(p0 context.Context, p1 peer.ID) (network.Connectedness, error)

func (*NetStruct) NetDisconnect

func (s *NetStruct) NetDisconnect(p0 context.Context, p1 peer.ID) error

func (*NetStruct) NetFindPeer

func (s *NetStruct) NetFindPeer(p0 context.Context, p1 peer.ID) (peer.AddrInfo, error)

func (*NetStruct) NetLimit added in v1.2.0

func (s *NetStruct) NetLimit(p0 context.Context, p1 string) (lotus_api.NetLimit, error)

func (*NetStruct) NetPeerInfo

func (s *NetStruct) NetPeerInfo(p0 context.Context, p1 peer.ID) (*lotus_api.ExtendedPeerInfo, error)

func (*NetStruct) NetPeers

func (s *NetStruct) NetPeers(p0 context.Context) ([]peer.AddrInfo, error)

func (*NetStruct) NetPing added in v1.2.0

func (s *NetStruct) NetPing(p0 context.Context, p1 peer.ID) (time.Duration, error)

func (*NetStruct) NetProtectAdd added in v1.2.0

func (s *NetStruct) NetProtectAdd(p0 context.Context, p1 []peer.ID) error

func (*NetStruct) NetProtectList added in v1.2.0

func (s *NetStruct) NetProtectList(p0 context.Context) ([]peer.ID, error)

func (*NetStruct) NetProtectRemove added in v1.2.0

func (s *NetStruct) NetProtectRemove(p0 context.Context, p1 []peer.ID) error

func (*NetStruct) NetPubsubScores added in v1.2.0

func (s *NetStruct) NetPubsubScores(p0 context.Context) ([]lotus_api.PubsubScore, error)

func (*NetStruct) NetSetLimit added in v1.2.0

func (s *NetStruct) NetSetLimit(p0 context.Context, p1 string, p2 lotus_api.NetLimit) error

func (*NetStruct) NetStat added in v1.2.0

func (s *NetStruct) NetStat(p0 context.Context, p1 string) (lotus_api.NetStat, error)

type NetStub

type NetStub struct {
}

func (*NetStub) ID

func (s *NetStub) ID(p0 context.Context) (peer.ID, error)

func (*NetStub) NetAddrsListen

func (s *NetStub) NetAddrsListen(p0 context.Context) (peer.AddrInfo, error)

func (*NetStub) NetAgentVersion

func (s *NetStub) NetAgentVersion(p0 context.Context, p1 peer.ID) (string, error)

func (*NetStub) NetAutoNatStatus

func (s *NetStub) NetAutoNatStatus(p0 context.Context) (lotus_api.NatInfo, error)

func (*NetStub) NetBandwidthStats

func (s *NetStub) NetBandwidthStats(p0 context.Context) (metrics.Stats, error)

func (*NetStub) NetBandwidthStatsByPeer

func (s *NetStub) NetBandwidthStatsByPeer(p0 context.Context) (map[string]metrics.Stats, error)

func (*NetStub) NetBandwidthStatsByProtocol

func (s *NetStub) NetBandwidthStatsByProtocol(p0 context.Context) (map[protocol.ID]metrics.Stats, error)

func (*NetStub) NetBlockAdd

func (s *NetStub) NetBlockAdd(p0 context.Context, p1 lotus_api.NetBlockList) error

func (*NetStub) NetBlockList

func (s *NetStub) NetBlockList(p0 context.Context) (lotus_api.NetBlockList, error)

func (*NetStub) NetBlockRemove

func (s *NetStub) NetBlockRemove(p0 context.Context, p1 lotus_api.NetBlockList) error

func (*NetStub) NetConnect

func (s *NetStub) NetConnect(p0 context.Context, p1 peer.AddrInfo) error

func (*NetStub) NetConnectedness

func (s *NetStub) NetConnectedness(p0 context.Context, p1 peer.ID) (network.Connectedness, error)

func (*NetStub) NetDisconnect

func (s *NetStub) NetDisconnect(p0 context.Context, p1 peer.ID) error

func (*NetStub) NetFindPeer

func (s *NetStub) NetFindPeer(p0 context.Context, p1 peer.ID) (peer.AddrInfo, error)

func (*NetStub) NetLimit added in v1.2.0

func (s *NetStub) NetLimit(p0 context.Context, p1 string) (lotus_api.NetLimit, error)

func (*NetStub) NetPeerInfo

func (s *NetStub) NetPeerInfo(p0 context.Context, p1 peer.ID) (*lotus_api.ExtendedPeerInfo, error)

func (*NetStub) NetPeers

func (s *NetStub) NetPeers(p0 context.Context) ([]peer.AddrInfo, error)

func (*NetStub) NetPing added in v1.2.0

func (s *NetStub) NetPing(p0 context.Context, p1 peer.ID) (time.Duration, error)

func (*NetStub) NetProtectAdd added in v1.2.0

func (s *NetStub) NetProtectAdd(p0 context.Context, p1 []peer.ID) error

func (*NetStub) NetProtectList added in v1.2.0

func (s *NetStub) NetProtectList(p0 context.Context) ([]peer.ID, error)

func (*NetStub) NetProtectRemove added in v1.2.0

func (s *NetStub) NetProtectRemove(p0 context.Context, p1 []peer.ID) error

func (*NetStub) NetPubsubScores added in v1.2.0

func (s *NetStub) NetPubsubScores(p0 context.Context) ([]lotus_api.PubsubScore, error)

func (*NetStub) NetSetLimit added in v1.2.0

func (s *NetStub) NetSetLimit(p0 context.Context, p1 string, p2 lotus_api.NetLimit) error

func (*NetStub) NetStat added in v1.2.0

func (s *NetStub) NetStat(p0 context.Context, p1 string) (lotus_api.NetStat, error)

type NodeChainStatus

type NodeChainStatus struct {
	BlocksPerTipsetLast100      float64
	BlocksPerTipsetLastFinality float64
}

type NodePeerStatus

type NodePeerStatus struct {
	PeersToPublishMsgs   int
	PeersToPublishBlocks int
}

type NodeStatus

type NodeStatus struct {
	SyncStatus  NodeSyncStatus
	PeerStatus  NodePeerStatus
	ChainStatus NodeChainStatus
}

type NodeSyncStatus

type NodeSyncStatus struct {
	Epoch  uint64
	Behind uint64
}

type ObjStat

type ObjStat struct {
	Size  uint64
	Links uint64
}

type PCHDir

type PCHDir int
const (
	PCHUndef PCHDir = iota
	PCHInbound
	PCHOutbound
)

type Partition

type Partition struct {
	AllSectors        bitfield.BitField
	FaultySectors     bitfield.BitField
	RecoveringSectors bitfield.BitField
	LiveSectors       bitfield.BitField
	ActiveSectors     bitfield.BitField
}

type PaychStatus

type PaychStatus struct {
	ControlAddr address.Address
	Direction   PCHDir
}

type PaymentInfo

type PaymentInfo struct {
	Channel      address.Address
	WaitSentinel cid.Cid
	Vouchers     []*paych.SignedVoucher
}

type ProviderDealRejectionInfo

type ProviderDealRejectionInfo struct {
	Accepted bool
	Reason   string // The rejection reason, if the deal is rejected
}

ProviderDealRejectionInfo is the information sent by the Storage Provider to the Client when it accepts or rejects a deal.

type PubsubScore

type PubsubScore struct {
	ID    peer.ID
	Score *pubsub.PeerScoreSnapshot
}

type QueryOffer

type QueryOffer struct {
	Err string

	Root  cid.Cid
	Piece *cid.Cid

	Size                    uint64
	MinPrice                types.BigInt
	UnsealPrice             types.BigInt
	PaymentInterval         uint64
	PaymentIntervalIncrease uint64
	Miner                   address.Address
	MinerPeer               retrievalmarket.RetrievalPeer
}

func (*QueryOffer) Order

func (o *QueryOffer) Order(client address.Address) RetrievalOrder

type RetrievalInfo

type RetrievalInfo struct {
	PayloadCID   cid.Cid
	ID           retrievalmarket.DealID
	PieceCID     *cid.Cid
	PricePerByte abi.TokenAmount
	UnsealPrice  abi.TokenAmount

	Status        retrievalmarket.DealStatus
	Message       string // more information about deal state, particularly errors
	Provider      peer.ID
	BytesReceived uint64
	BytesPaidFor  uint64
	TotalPaid     abi.TokenAmount

	TransferChannelID *datatransfer.ChannelID
	DataTransfer      *DataTransferChannel
}

type RetrievalOrder

type RetrievalOrder struct {
	// TODO: make this less unixfs specific
	Root                  cid.Cid
	Piece                 *cid.Cid
	DatamodelPathSelector *textselector.Expression
	Size                  uint64

	FromLocalCAR string // if specified, get data from a local CARv2 file.
	// TODO: support offset
	Total                   types.BigInt
	UnsealPrice             types.BigInt
	PaymentInterval         uint64
	PaymentIntervalIncrease uint64
	Client                  address.Address
	Miner                   address.Address
	MinerPeer               *retrievalmarket.RetrievalPeer
}

type SealingPipelineState

type SealingPipelineState struct {
	TaskJobsCount             map[string]int
	MaxWaitDealsSectors       uint64
	MaxSealingSectors         uint64
	MaxSealingSectorsForDeals uint64
}

type SyncState

type SyncState struct {
	ActiveSyncs []ActiveSync

	VMApplied uint64
}

type SyncStateStage

type SyncStateStage int

func (SyncStateStage) String

func (v SyncStateStage) String() string

type Version

type Version uint32

func (Version) EqMajorMinor

func (ve Version) EqMajorMinor(v2 Version) bool

func (Version) Ints

func (ve Version) Ints() (uint32, uint32, uint32)

Ints returns (major, minor, patch) versions

func (Version) String

func (ve Version) String() string

type VoucherCreateResult

type VoucherCreateResult struct {
	// Voucher that was created, or nil if there was an error or if there
	// were insufficient funds in the channel
	Voucher *paych.SignedVoucher
	// Shortfall is the additional amount that would be needed in the channel
	// in order to be able to create the voucher
	Shortfall types.BigInt
}

VoucherCreateResult is the response to calling PaychVoucherCreate

type VoucherSpec

type VoucherSpec struct {
	Amount      types.BigInt
	TimeLockMin abi.ChainEpoch
	TimeLockMax abi.ChainEpoch
	MinSettle   abi.ChainEpoch

	Extra *paych.ModVerifyParams
}

type Wallet

type Wallet interface {
	WalletNew(context.Context, types.KeyType) (address.Address, error) //perm:admin
	WalletHas(context.Context, address.Address) (bool, error)          //perm:admin
	WalletList(context.Context) ([]address.Address, error)             //perm:admin

	WalletSign(ctx context.Context, signer address.Address, toSign []byte) (*crypto.Signature, error) //perm:admin

	WalletExport(context.Context, address.Address) (*types.KeyInfo, error) //perm:admin
	WalletImport(context.Context, *types.KeyInfo) (address.Address, error) //perm:admin
	WalletDelete(context.Context, address.Address) error                   //perm:admin
}

type WalletStruct

type WalletStruct struct {
	Internal struct {
		WalletDelete func(p0 context.Context, p1 address.Address) error `perm:"admin"`

		WalletExport func(p0 context.Context, p1 address.Address) (*types.KeyInfo, error) `perm:"admin"`

		WalletHas func(p0 context.Context, p1 address.Address) (bool, error) `perm:"admin"`

		WalletImport func(p0 context.Context, p1 *types.KeyInfo) (address.Address, error) `perm:"admin"`

		WalletList func(p0 context.Context) ([]address.Address, error) `perm:"admin"`

		WalletNew func(p0 context.Context, p1 types.KeyType) (address.Address, error) `perm:"admin"`

		WalletSign func(p0 context.Context, p1 address.Address, p2 []byte) (*crypto.Signature, error) `perm:"admin"`
	}
}

func (*WalletStruct) WalletDelete

func (s *WalletStruct) WalletDelete(p0 context.Context, p1 address.Address) error

func (*WalletStruct) WalletExport

func (s *WalletStruct) WalletExport(p0 context.Context, p1 address.Address) (*types.KeyInfo, error)

func (*WalletStruct) WalletHas

func (s *WalletStruct) WalletHas(p0 context.Context, p1 address.Address) (bool, error)

func (*WalletStruct) WalletImport

func (s *WalletStruct) WalletImport(p0 context.Context, p1 *types.KeyInfo) (address.Address, error)

func (*WalletStruct) WalletList

func (s *WalletStruct) WalletList(p0 context.Context) ([]address.Address, error)

func (*WalletStruct) WalletNew

func (s *WalletStruct) WalletNew(p0 context.Context, p1 types.KeyType) (address.Address, error)

func (*WalletStruct) WalletSign

func (s *WalletStruct) WalletSign(p0 context.Context, p1 address.Address, p2 []byte) (*crypto.Signature, error)

type WalletStub

type WalletStub struct {
}

func (*WalletStub) WalletDelete

func (s *WalletStub) WalletDelete(p0 context.Context, p1 address.Address) error

func (*WalletStub) WalletExport

func (s *WalletStub) WalletExport(p0 context.Context, p1 address.Address) (*types.KeyInfo, error)

func (*WalletStub) WalletHas

func (s *WalletStub) WalletHas(p0 context.Context, p1 address.Address) (bool, error)

func (*WalletStub) WalletImport

func (s *WalletStub) WalletImport(p0 context.Context, p1 *types.KeyInfo) (address.Address, error)

func (*WalletStub) WalletList

func (s *WalletStub) WalletList(p0 context.Context) ([]address.Address, error)

func (*WalletStub) WalletNew

func (s *WalletStub) WalletNew(p0 context.Context, p1 types.KeyType) (address.Address, error)

func (*WalletStub) WalletSign

func (s *WalletStub) WalletSign(p0 context.Context, p1 address.Address, p2 []byte) (*crypto.Signature, error)

Directories

Path Synopsis
cmd
cmd

Jump to

Keyboard shortcuts

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