Documentation ¶
Index ¶
- Constants
- Variables
- func APISecret(keystore types.KeyStore, lr lotus_repo.LockedRepo) (*dtypes.APIAlg, error)
- func BasicDealFilter(cfg config.DealmakingConfig, userCmd dtypes.StorageDealFilter) ...
- func ClientBlockstore() dtypes.ClientBlockstore
- func ClientImportMgr(ds lotus_dtypes.MetadataDS, r repo.LockedRepo) (lotus_dtypes.ClientImportMgr, error)
- func ConfigBootstrap(peers []string) func() (dtypes.BootstrapPeers, error)
- func ConnectSealingService(apiInfo string) func(mctx helpers.MetricsCtx, lc fx.Lifecycle) (MinerSealingService, error)
- func ConnectStorageService(apiInfo string) func(mctx helpers.MetricsCtx, lc fx.Lifecycle) (MinerStorageService, error)
- func CreateRetrievalTables(lc fx.Lifecycle, db *RetrievalSqlDB)
- func Datastore(disableLog bool) ...
- func DealDeciderFn(df lotus_dtypes.StorageDealFilter) storageimpl.DealDeciderFunc
- func Graphsync(parallelTransfersForStorage uint64, parallelTransfersForStoragePerPeer uint64, ...) ...
- func HandleBoostLibp2pDeals(lc fx.Lifecycle, h host.Host, prov *storagemarket.Provider, a v1api.FullNode, ...)
- func HandleContractDeals(c *config.ContractDealsConfig) ...
- func HandleLegacyDeals(mctx helpers.MetricsCtx, lc fx.Lifecycle, ...) error
- func HandleMigrateClientFunds(lc fx.Lifecycle, ds lotus_dtypes.MetadataDS, wallet full.WalletAPI, ...)
- func HandleProposalLogCleaner(duration time.Duration) func(lc fx.Lifecycle, plDB *db.ProposalLogsDB)
- func HandleProtocolProxy(lc fx.Lifecycle, pp *protocolproxy.ProtocolProxy)
- func HandleRetrieval(host host.Host, lc fx.Lifecycle, m retrievalmarket.RetrievalProvider)
- func HandleRetrievalGraphsyncUpdates(duration time.Duration, stalledDuration time.Duration) func(lc fx.Lifecycle, db *rtvllog.RetrievalLogDB, ...)
- func HandleRetrievalTransports(lc fx.Lifecycle, l *lp2pimpl.TransportsListener)
- func IndexProvider(cfg config.IndexProviderConfig) ...
- func KeyStore(lr lotus_repo.LockedRepo) (types.KeyStore, error)
- func LockedRepo(lr lotus_repo.LockedRepo) func(lc fx.Lifecycle) lotus_repo.LockedRepo
- func LotusGFMStorageProviderNode(spn gfm_storagemarket.StorageProviderNode) lotus_gfm_storagemarket.StorageProviderNode
- func MemoryConstraints() system.MemoryConstraints
- func MemoryWatchdog(lr lotus_repo.LockedRepo, lc fx.Lifecycle, ...)
- func NewBoostDB(r lotus_repo.LockedRepo) (*sql.DB, error)
- func NewBoostGFMDAGStoreWrapper(w *mdagstore.Wrapper) stores.DAGStoreWrapper
- func NewChainDealManager(a v1api.FullNode) *storagemarket.ChainDealManager
- func NewClientDatastore(ds lotus_dtypes.MetadataDS) dtypes.ClientDatastore
- func NewConsiderOfflineRetrievalDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.ConsiderOfflineRetrievalDealsConfigFunc, error)
- func NewConsiderOfflineStorageDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.ConsiderOfflineStorageDealsConfigFunc, error)
- func NewConsiderOnlineRetrievalDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.ConsiderOnlineRetrievalDealsConfigFunc, error)
- func NewConsiderOnlineStorageDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.ConsiderOnlineStorageDealsConfigFunc, error)
- func NewConsiderUnverifiedStorageDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.ConsiderUnverifiedStorageDealsConfigFunc, error)
- func NewConsiderVerifiedStorageDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.ConsiderVerifiedStorageDealsConfigFunc, error)
- func NewDealsDB(sqldb *sql.DB) *db.DealsDB
- func NewFundsDB(sqldb *sql.DB) *db.FundsDB
- func NewGetExpectedSealDurationFunc(r lotus_repo.LockedRepo) (dtypes.GetExpectedSealDurationFunc, error)
- func NewGetMaxDealStartDelayFunc(r lotus_repo.LockedRepo) (dtypes.GetMaxDealStartDelayFunc, error)
- func NewGraphqlServer(cfg *config.Boost) ...
- func NewIndexBackedBlockstore(cfg *config.Boost) ...
- func NewLegacyStorageProvider(cfg *config.Boost) ...
- func NewLogsDB(logsSqlDB *LogSqlDB) *db.LogsDB
- func NewLotusGFMProviderPieceStore(ps dtypes.ProviderPieceStore) lotus_dtypes.ProviderPieceStore
- func NewOnlineBackupMgr(cfg *config.Boost) ...
- func NewProposalLogsDB(sqldb *sql.DB) *db.ProposalLogsDB
- func NewProtocolProxy(cfg *config.Boost) func(h host.Host) (*protocolproxy.ProtocolProxy, error)
- func NewProviderDataTransfer(lc fx.Lifecycle, net dtypes.ProviderTransferNetwork, ...) (dtypes.ProviderDataTransfer, error)
- func NewProviderPieceStore(lc fx.Lifecycle, ds lotus_dtypes.MetadataDS) (dtypes.ProviderPieceStore, error)
- func NewProviderTransferNetwork(h host.Host) dtypes.ProviderTransferNetwork
- func NewProviderTransport(h host.Host, gs dtypes.StagingGraphsync) dtypes.ProviderTransport
- func NewRetrievalLogDB(db *RetrievalSqlDB) *rtvllog.RetrievalLogDB
- func NewSectorAccessor(cfg *config.Boost) sectoraccessor.SectorAccessorConstructor
- func NewSectorStateDB(sqldb *sql.DB) *db.SectorStateDB
- func NewSetConsiderOfflineRetrievalDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.SetConsiderOfflineRetrievalDealsConfigFunc, error)
- func NewSetConsiderOnlineRetrievalDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.SetConsiderOnlineRetrievalDealsConfigFunc, error)
- func NewSetConsideringOfflineStorageDealsFunc(r lotus_repo.LockedRepo) (dtypes.SetConsiderOfflineStorageDealsConfigFunc, error)
- func NewSetConsideringOnlineStorageDealsFunc(r lotus_repo.LockedRepo) (dtypes.SetConsiderOnlineStorageDealsConfigFunc, error)
- func NewSetConsideringUnverifiedStorageDealsFunc(r lotus_repo.LockedRepo) (dtypes.SetConsiderUnverifiedStorageDealsConfigFunc, error)
- func NewSetConsideringVerifiedStorageDealsFunc(r lotus_repo.LockedRepo) (dtypes.SetConsiderVerifiedStorageDealsConfigFunc, error)
- func NewSetExpectedSealDurationFunc(r lotus_repo.LockedRepo) (dtypes.SetExpectedSealDurationFunc, error)
- func NewSetMaxDealStartDelayFunc(r lotus_repo.LockedRepo) (dtypes.SetMaxDealStartDelayFunc, error)
- func NewSetStorageDealPieceCidBlocklistConfigFunc(r lotus_repo.LockedRepo) (dtypes.SetStorageDealPieceCidBlocklistConfigFunc, error)
- func NewStorageAsk(ctx helpers.MetricsCtx, fapi v1api.FullNode, ds lotus_dtypes.MetadataDS, ...) (*storedask.StoredAsk, error)
- func NewStorageDealPieceCidBlocklistConfigFunc(r lotus_repo.LockedRepo) (dtypes.StorageDealPieceCidBlocklistConfigFunc, error)
- func NewStorageMarketProvider(provAddr address.Address, cfg *config.Boost) ...
- func NewTracing(cfg *config.Boost) func(lc fx.Lifecycle) (*tracing.Tracing, error)
- func NewTransportsListener(cfg *config.Boost) func(h host.Host) (*lp2pimpl.TransportsListener, error)
- func RecordValidator(ps peerstore.Peerstore) record.Validator
- func RegisterClientValidator(crv dtypes.ClientRequestValidator, dtm dtypes.ClientDataTransfer)
- func ResourceManager(connMgrHi uint) func(lc fx.Lifecycle, repo repo.LockedRepo) (network.ResourceManager, error)
- func RetrievalBlockstoreAccessor(r repo.LockedRepo) (retrievalmarket.BlockstoreAccessor, error)
- func RetrievalClient(lc fx.Lifecycle, h host.Host, r repo.LockedRepo, dt dtypes.ClientDataTransfer, ...) (retrievalmarket.RetrievalClient, error)
- func RetrievalDealFilter(userFilter dtypes.RetrievalDealFilter) ...
- func RetrievalGraphsync(parallelTransfersForStorage uint64, parallelTransfersForStoragePerPeer uint64, ...) ...
- func RetrievalNetwork(h host.Host) rmnet.RetrievalMarketNetwork
- func RetrievalPricingFunc(cfg config.DealmakingConfig) ...
- func RetrievalProvider(maddr lotus_dtypes.MinerAddress, adapter retrievalmarket.RetrievalProviderNode, ...) (retrievalmarket.RetrievalProvider, error)
- func SetAskGetter(proxy *ProxyAskGetter, rp retrievalmarket.RetrievalProvider)
- func SetShardSelectorFunc(lc fx.Lifecycle, shardSelector *ShardSelector, ps dtypes.ProviderPieceStore, ...) error
- func StorageBlockstoreAccessor(importmgr dtypes.ClientImportMgr) storagemarket.BlockstoreAccessor
- func StorageClient(lc fx.Lifecycle, h host.Host, dataTransfer dtypes.ClientDataTransfer, ...) (storagemarket.StorageClient, error)
- func StorageNetworkName(ctx helpers.MetricsCtx, a v1api.FullNode) (dtypes.NetworkName, error)
- func StorageProvider(minerAddress lotus_dtypes.MinerAddress, storedAsk *storedask.StoredAsk, ...) (storagemarket.StorageProvider, error)
- type Genesis
- type IdxProv
- type JwtPayload
- type LogSqlDB
- type MinerSealingService
- type MinerStorageService
- type ProxyAskGetter
- type RetrievalSqlDB
- type ShardSelector
Constants ¶
const ( JWTSecretName = "auth-jwt-private" //nolint:gosec KTJwtHmacSecret = "jwt-hmac-secret" //nolint:gosec )
const ( // EnvWatchdogDisabled is an escape hatch to disable the watchdog explicitly // in case an OS/kernel appears to report incorrect information. The // watchdog will be disabled if the value of this env variable is 1. EnvWatchdogDisabled = "LOTUS_DISABLE_WATCHDOG" )
Variables ¶
var (
StorageCounterDSPrefix = "/storage/nextid"
)
var UserAgent = simpleOpt(libp2p.UserAgent("boost-" + build.UserVersion()))
Functions ¶
func APISecret ¶
func APISecret(keystore types.KeyStore, lr lotus_repo.LockedRepo) (*dtypes.APIAlg, error)
func BasicDealFilter ¶
func BasicDealFilter(cfg config.DealmakingConfig, userCmd dtypes.StorageDealFilter) func(onlineOk dtypes.ConsiderOnlineStorageDealsConfigFunc, offlineOk dtypes.ConsiderOfflineStorageDealsConfigFunc, verifiedOk dtypes.ConsiderVerifiedStorageDealsConfigFunc, unverifiedOk dtypes.ConsiderUnverifiedStorageDealsConfigFunc, blocklistFunc dtypes.StorageDealPieceCidBlocklistConfigFunc, expectedSealTimeFunc dtypes.GetExpectedSealDurationFunc, startDelay dtypes.GetMaxDealStartDelayFunc, r lotus_repo.LockedRepo, ) dtypes.StorageDealFilter
func ClientBlockstore ¶
func ClientBlockstore() dtypes.ClientBlockstore
TODO this should be removed.
func ClientImportMgr ¶
func ClientImportMgr(ds lotus_dtypes.MetadataDS, r repo.LockedRepo) (lotus_dtypes.ClientImportMgr, error)
func ConfigBootstrap ¶
func ConfigBootstrap(peers []string) func() (dtypes.BootstrapPeers, error)
func ConnectSealingService ¶
func ConnectSealingService(apiInfo string) func(mctx helpers.MetricsCtx, lc fx.Lifecycle) (MinerSealingService, error)
func ConnectStorageService ¶
func ConnectStorageService(apiInfo string) func(mctx helpers.MetricsCtx, lc fx.Lifecycle) (MinerStorageService, error)
func CreateRetrievalTables ¶ added in v1.5.1
func CreateRetrievalTables(lc fx.Lifecycle, db *RetrievalSqlDB)
func Datastore ¶
func Datastore(disableLog bool) func(lc fx.Lifecycle, mctx helpers.MetricsCtx, r lotus_repo.LockedRepo) (lotus_dtypes.MetadataDS, error)
func DealDeciderFn ¶ added in v1.7.0
func DealDeciderFn(df lotus_dtypes.StorageDealFilter) storageimpl.DealDeciderFunc
func Graphsync ¶
func Graphsync(parallelTransfersForStorage uint64, parallelTransfersForStoragePerPeer uint64, parallelTransfersForRetrieval uint64) func(mctx helpers.MetricsCtx, lc fx.Lifecycle, ibs dtypes.StagingBlockstore, h host.Host) dtypes.StagingGraphsync
func HandleBoostLibp2pDeals ¶ added in v1.6.0
func HandleBoostLibp2pDeals(lc fx.Lifecycle, h host.Host, prov *storagemarket.Provider, a v1api.FullNode, legacySP gfm_storagemarket.StorageProvider, idxProv *indexprovider.Wrapper, plDB *db.ProposalLogsDB, spApi sealingpipeline.API)
func HandleContractDeals ¶ added in v1.6.0
func HandleContractDeals(c *config.ContractDealsConfig) func(mctx helpers.MetricsCtx, lc fx.Lifecycle, prov *storagemarket.Provider, a v1api.FullNode, subCh *gateway.EthSubHandler, maddr lotus_dtypes.MinerAddress)
func HandleLegacyDeals ¶
func HandleLegacyDeals(mctx helpers.MetricsCtx, lc fx.Lifecycle, lsp gfm_storagemarket.StorageProvider) error
func HandleMigrateClientFunds ¶
func HandleMigrateClientFunds(lc fx.Lifecycle, ds lotus_dtypes.MetadataDS, wallet full.WalletAPI, fundMgr *market.FundManager)
func HandleProposalLogCleaner ¶
func HandleProposalLogCleaner(duration time.Duration) func(lc fx.Lifecycle, plDB *db.ProposalLogsDB)
Boost inserts a row into the DB for each deal proposal accepted or rejected. This method periodically cleans up the rows.
func HandleProtocolProxy ¶ added in v1.5.0
func HandleProtocolProxy(lc fx.Lifecycle, pp *protocolproxy.ProtocolProxy)
func HandleRetrieval ¶ added in v1.7.0
func HandleRetrieval(host host.Host, lc fx.Lifecycle, m retrievalmarket.RetrievalProvider)
func HandleRetrievalGraphsyncUpdates ¶ added in v1.5.1
func HandleRetrievalGraphsyncUpdates(duration time.Duration, stalledDuration time.Duration) func(lc fx.Lifecycle, db *rtvllog.RetrievalLogDB, m lotus_retrievalmarket.RetrievalProvider, dt dtypes.ProviderDataTransfer, gsur *server.GraphsyncUnpaidRetrieval)
Write graphsync retrieval updates to the database
func HandleRetrievalTransports ¶ added in v1.4.0
func HandleRetrievalTransports(lc fx.Lifecycle, l *lp2pimpl.TransportsListener)
func IndexProvider ¶
func IndexProvider(cfg config.IndexProviderConfig) func(params IdxProv, marketHost host.Host, dt dtypes.ProviderDataTransfer, maddr lotus_dtypes.MinerAddress, ps *pubsub.PubSub, nn lotus_dtypes.NetworkName) (provider.Interface, error)
func KeyStore ¶
func KeyStore(lr lotus_repo.LockedRepo) (types.KeyStore, error)
func LockedRepo ¶
func LockedRepo(lr lotus_repo.LockedRepo) func(lc fx.Lifecycle) lotus_repo.LockedRepo
func LotusGFMStorageProviderNode ¶ added in v1.7.0
func LotusGFMStorageProviderNode(spn gfm_storagemarket.StorageProviderNode) lotus_gfm_storagemarket.StorageProviderNode
func MemoryConstraints ¶
func MemoryConstraints() system.MemoryConstraints
MemoryConstraints returns the memory constraints configured for this system.
func MemoryWatchdog ¶
func MemoryWatchdog(lr lotus_repo.LockedRepo, lc fx.Lifecycle, constraints system.MemoryConstraints)
MemoryWatchdog starts the memory watchdog, applying the computed resource constraints.
func NewBoostDB ¶
func NewBoostDB(r lotus_repo.LockedRepo) (*sql.DB, error)
func NewBoostGFMDAGStoreWrapper ¶ added in v1.7.0
func NewBoostGFMDAGStoreWrapper(w *mdagstore.Wrapper) stores.DAGStoreWrapper
func NewChainDealManager ¶
func NewChainDealManager(a v1api.FullNode) *storagemarket.ChainDealManager
func NewClientDatastore ¶
func NewClientDatastore(ds lotus_dtypes.MetadataDS) dtypes.ClientDatastore
NewClientDatastore creates a datastore for the client to store its deals
func NewConsiderOfflineRetrievalDealsConfigFunc ¶
func NewConsiderOfflineRetrievalDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.ConsiderOfflineRetrievalDealsConfigFunc, error)
func NewConsiderOfflineStorageDealsConfigFunc ¶
func NewConsiderOfflineStorageDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.ConsiderOfflineStorageDealsConfigFunc, error)
func NewConsiderOnlineRetrievalDealsConfigFunc ¶
func NewConsiderOnlineRetrievalDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.ConsiderOnlineRetrievalDealsConfigFunc, error)
func NewConsiderOnlineStorageDealsConfigFunc ¶
func NewConsiderOnlineStorageDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.ConsiderOnlineStorageDealsConfigFunc, error)
func NewConsiderUnverifiedStorageDealsConfigFunc ¶
func NewConsiderUnverifiedStorageDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.ConsiderUnverifiedStorageDealsConfigFunc, error)
func NewConsiderVerifiedStorageDealsConfigFunc ¶
func NewConsiderVerifiedStorageDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.ConsiderVerifiedStorageDealsConfigFunc, error)
func NewGetExpectedSealDurationFunc ¶
func NewGetExpectedSealDurationFunc(r lotus_repo.LockedRepo) (dtypes.GetExpectedSealDurationFunc, error)
func NewGetMaxDealStartDelayFunc ¶
func NewGetMaxDealStartDelayFunc(r lotus_repo.LockedRepo) (dtypes.GetMaxDealStartDelayFunc, error)
func NewGraphqlServer ¶
func NewGraphqlServer(cfg *config.Boost) func(lc fx.Lifecycle, r repo.LockedRepo, h host.Host, prov *storagemarket.Provider, dealsDB *db.DealsDB, logsDB *db.LogsDB, retDB *rtvllog.RetrievalLogDB, plDB *db.ProposalLogsDB, fundsDB *db.FundsDB, fundMgr *fundmanager.FundManager, storageMgr *storagemanager.StorageManager, publisher *storageadapter.DealPublisher, spApi sealingpipeline.API, legacyProv gfm_storagemarket.StorageProvider, legacyDT dtypes.ProviderDataTransfer, ps dtypes.ProviderPieceStore, sa retrievalmarket.SectorAccessor, dagst dagstore.Interface, fullNode v1api.FullNode, bg gql.BlockGetter) *gql.Server
func NewIndexBackedBlockstore ¶ added in v1.5.0
func NewIndexBackedBlockstore(cfg *config.Boost) func(lc fx.Lifecycle, dagst dagstore.Interface, ss *ShardSelector) (dtypes.IndexBackedBlockstore, error)
func NewLegacyStorageProvider ¶ added in v1.5.0
func NewLegacyStorageProvider(cfg *config.Boost) func(minerAddress lotus_dtypes.MinerAddress, storedAsk *storedask.StoredAsk, h host.Host, ds lotus_dtypes.MetadataDS, r repo.LockedRepo, pieceStore dtypes.ProviderPieceStore, indexer provider.Interface, dataTransfer dtypes.ProviderDataTransfer, spn gfm_storagemarket.StorageProviderNode, df storageimpl.DealDeciderFunc, dsw stores.DAGStoreWrapper, meshCreator idxprov.MeshCreator, ) (gfm_storagemarket.StorageProvider, error)
NewLegacyStorageProvider wraps lotus's storage provider function but additionally sets up the metadata announcement for legacy deals based off of Boost's configured protocols
func NewLotusGFMProviderPieceStore ¶ added in v1.7.0
func NewLotusGFMProviderPieceStore(ps dtypes.ProviderPieceStore) lotus_dtypes.ProviderPieceStore
func NewOnlineBackupMgr ¶ added in v1.6.1
func NewOnlineBackupMgr(cfg *config.Boost) func(lc fx.Lifecycle, r lotus_repo.LockedRepo, ds lotus_dtypes.MetadataDS, dealsDB *sql.DB) *backupmgr.BackupMgr
func NewProposalLogsDB ¶
func NewProposalLogsDB(sqldb *sql.DB) *db.ProposalLogsDB
func NewProtocolProxy ¶ added in v1.5.0
func NewProtocolProxy(cfg *config.Boost) func(h host.Host) (*protocolproxy.ProtocolProxy, error)
func NewProviderDataTransfer ¶
func NewProviderDataTransfer(lc fx.Lifecycle, net dtypes.ProviderTransferNetwork, transport dtypes.ProviderTransport, ds lotus_dtypes.MetadataDS, r repo.LockedRepo) (dtypes.ProviderDataTransfer, error)
NewProviderDataTransfer returns a data transfer manager
func NewProviderPieceStore ¶ added in v1.7.0
func NewProviderPieceStore(lc fx.Lifecycle, ds lotus_dtypes.MetadataDS) (dtypes.ProviderPieceStore, error)
NewProviderPieceStore creates a statestore for storing metadata about pieces shared by the storage and retrieval providers
func NewProviderTransferNetwork ¶ added in v1.6.1
func NewProviderTransferNetwork(h host.Host) dtypes.ProviderTransferNetwork
NewProviderTransferNetwork sets up the libp2p protocol networking for data transfer
func NewProviderTransport ¶ added in v1.7.0
func NewProviderTransport(h host.Host, gs dtypes.StagingGraphsync) dtypes.ProviderTransport
NewProviderTransport sets up a data transfer transport over graphsync
func NewRetrievalLogDB ¶ added in v1.5.1
func NewRetrievalLogDB(db *RetrievalSqlDB) *rtvllog.RetrievalLogDB
func NewSectorAccessor ¶ added in v1.6.1
func NewSectorAccessor(cfg *config.Boost) sectoraccessor.SectorAccessorConstructor
Use a caching sector accessor
func NewSectorStateDB ¶ added in v1.7.0
func NewSectorStateDB(sqldb *sql.DB) *db.SectorStateDB
func NewSetConsiderOfflineRetrievalDealsConfigFunc ¶
func NewSetConsiderOfflineRetrievalDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.SetConsiderOfflineRetrievalDealsConfigFunc, error)
func NewSetConsiderOnlineRetrievalDealsConfigFunc ¶
func NewSetConsiderOnlineRetrievalDealsConfigFunc(r lotus_repo.LockedRepo) (dtypes.SetConsiderOnlineRetrievalDealsConfigFunc, error)
func NewSetConsideringOfflineStorageDealsFunc ¶
func NewSetConsideringOfflineStorageDealsFunc(r lotus_repo.LockedRepo) (dtypes.SetConsiderOfflineStorageDealsConfigFunc, error)
func NewSetConsideringOnlineStorageDealsFunc ¶
func NewSetConsideringOnlineStorageDealsFunc(r lotus_repo.LockedRepo) (dtypes.SetConsiderOnlineStorageDealsConfigFunc, error)
func NewSetConsideringUnverifiedStorageDealsFunc ¶
func NewSetConsideringUnverifiedStorageDealsFunc(r lotus_repo.LockedRepo) (dtypes.SetConsiderUnverifiedStorageDealsConfigFunc, error)
func NewSetConsideringVerifiedStorageDealsFunc ¶
func NewSetConsideringVerifiedStorageDealsFunc(r lotus_repo.LockedRepo) (dtypes.SetConsiderVerifiedStorageDealsConfigFunc, error)
func NewSetExpectedSealDurationFunc ¶
func NewSetExpectedSealDurationFunc(r lotus_repo.LockedRepo) (dtypes.SetExpectedSealDurationFunc, error)
func NewSetMaxDealStartDelayFunc ¶
func NewSetMaxDealStartDelayFunc(r lotus_repo.LockedRepo) (dtypes.SetMaxDealStartDelayFunc, error)
func NewSetStorageDealPieceCidBlocklistConfigFunc ¶
func NewSetStorageDealPieceCidBlocklistConfigFunc(r lotus_repo.LockedRepo) (dtypes.SetStorageDealPieceCidBlocklistConfigFunc, error)
func NewStorageAsk ¶ added in v1.7.0
func NewStorageAsk(ctx helpers.MetricsCtx, fapi v1api.FullNode, ds lotus_dtypes.MetadataDS, minerAddress lotus_dtypes.MinerAddress, spn gfm_storagemarket.StorageProviderNode) (*storedask.StoredAsk, error)
func NewStorageDealPieceCidBlocklistConfigFunc ¶
func NewStorageDealPieceCidBlocklistConfigFunc(r lotus_repo.LockedRepo) (dtypes.StorageDealPieceCidBlocklistConfigFunc, error)
func NewStorageMarketProvider ¶
func NewStorageMarketProvider(provAddr address.Address, cfg *config.Boost) func(lc fx.Lifecycle, h host.Host, a v1api.FullNode, sqldb *sql.DB, dealsDB *db.DealsDB, fundMgr *fundmanager.FundManager, storageMgr *storagemanager.StorageManager, dp *storageadapter.DealPublisher, secb *sectorblocks.SectorBlocks, commpc types.CommpCalculator, sps sealingpipeline.API, df dtypes.StorageDealFilter, logsSqlDB *LogSqlDB, logsDB *db.LogsDB, dagst *mdagstore.Wrapper, ps dtypes.ProviderPieceStore, ip *indexprovider.Wrapper, lp gfm_storagemarket.StorageProvider, cdm *storagemarket.ChainDealManager) (*storagemarket.Provider, error)
func NewTracing ¶ added in v1.4.0
func NewTransportsListener ¶ added in v1.4.0
func RecordValidator ¶
RecordValidator provides namesys compatible routing record validator
func RegisterClientValidator ¶
func RegisterClientValidator(crv dtypes.ClientRequestValidator, dtm dtypes.ClientDataTransfer)
RegisterClientValidator is an initialization hook that registers the client request validator with the data transfer module as the validator for StorageDataTransferVoucher types
func ResourceManager ¶ added in v1.2.0
func ResourceManager(connMgrHi uint) func(lc fx.Lifecycle, repo repo.LockedRepo) (network.ResourceManager, error)
The code in this file is a direct copy from lotus. Unfortunately the lotus modules ResourceManager checks repo.RepoType().Type() == "FullNode", but the Boost node reports "Boost" as its type rather then "FullNode" so we need to change this one line
func RetrievalBlockstoreAccessor ¶
func RetrievalBlockstoreAccessor(r repo.LockedRepo) (retrievalmarket.BlockstoreAccessor, error)
RetrievalBlockstoreAccessor returns the default retrieval blockstore accessor using the subdirectory `retrievals` under the repo.
func RetrievalClient ¶
func RetrievalClient(lc fx.Lifecycle, h host.Host, r repo.LockedRepo, dt dtypes.ClientDataTransfer, payAPI payapi.PaychAPI, resolver discovery.PeerResolver, ds lotus_dtypes.MetadataDS, chainAPI full.ChainAPI, stateAPI full.StateAPI, accessor retrievalmarket.BlockstoreAccessor, j journal.Journal) (retrievalmarket.RetrievalClient, error)
RetrievalClient creates a new retrieval client attached to the client blockstore
func RetrievalDealFilter ¶
func RetrievalDealFilter(userFilter dtypes.RetrievalDealFilter) func(onlineOk dtypes.ConsiderOnlineRetrievalDealsConfigFunc, offlineOk dtypes.ConsiderOfflineRetrievalDealsConfigFunc) dtypes.RetrievalDealFilter
func RetrievalGraphsync ¶ added in v1.7.0
func RetrievalGraphsync(parallelTransfersForStorage uint64, parallelTransfersForStoragePerPeer uint64, parallelTransfersForRetrieval uint64) func(mctx lotus_helpers.MetricsCtx, lc fx.Lifecycle, ibs dtypes.IndexBackedBlockstore, h host.Host, net dtypes.ProviderTransferNetwork, dealDecider dtypes.RetrievalDealFilter, dagStore stores.DAGStoreWrapper, pstore dtypes.ProviderPieceStore, sa retrievalmarket.SectorAccessor, askGetter server.AskGetter) (*server.GraphsyncUnpaidRetrieval, error)
RetrievalGraphsync creates a graphsync instance used to serve retrievals.
func RetrievalNetwork ¶ added in v1.7.0
func RetrievalNetwork(h host.Host) rmnet.RetrievalMarketNetwork
func RetrievalPricingFunc ¶ added in v1.7.0
func RetrievalPricingFunc(cfg config.DealmakingConfig) func(_ dtypes.ConsiderOnlineRetrievalDealsConfigFunc, _ dtypes.ConsiderOfflineRetrievalDealsConfigFunc) dtypes.RetrievalPricingFunc
RetrievalPricingFunc configures the pricing function to use for retrieval deals.
func RetrievalProvider ¶ added in v1.6.0
func RetrievalProvider( maddr lotus_dtypes.MinerAddress, adapter retrievalmarket.RetrievalProviderNode, sa retrievalmarket.SectorAccessor, netwk rmnet.RetrievalMarketNetwork, ds lotus_dtypes.MetadataDS, pieceStore dtypes.ProviderPieceStore, dt dtypes.ProviderDataTransfer, pricingFnc dtypes.RetrievalPricingFunc, userFilter dtypes.RetrievalDealFilter, dagStore stores.DAGStoreWrapper, ) (retrievalmarket.RetrievalProvider, error)
RetrievalProvider creates a new retrieval provider attached to the provider blockstore
func SetAskGetter ¶ added in v1.6.1
func SetAskGetter(proxy *ProxyAskGetter, rp retrievalmarket.RetrievalProvider)
func SetShardSelectorFunc ¶ added in v1.6.1
func SetShardSelectorFunc(lc fx.Lifecycle, shardSelector *ShardSelector, ps dtypes.ProviderPieceStore, sa retrievalmarket.SectorAccessor, rp retrievalmarket.RetrievalProvider) error
func StorageBlockstoreAccessor ¶
func StorageBlockstoreAccessor(importmgr dtypes.ClientImportMgr) storagemarket.BlockstoreAccessor
StorageBlockstoreAccessor returns the default storage blockstore accessor from the import manager.
func StorageClient ¶
func StorageClient(lc fx.Lifecycle, h host.Host, dataTransfer dtypes.ClientDataTransfer, discovery *discoveryimpl.Local, deals dtypes.ClientDatastore, scn storagemarket.StorageClientNode, accessor storagemarket.BlockstoreAccessor, j journal.Journal) (storagemarket.StorageClient, error)
func StorageNetworkName ¶
func StorageNetworkName(ctx helpers.MetricsCtx, a v1api.FullNode) (dtypes.NetworkName, error)
func StorageProvider ¶ added in v1.6.0
func StorageProvider(minerAddress lotus_dtypes.MinerAddress, storedAsk *storedask.StoredAsk, h host.Host, ds lotus_dtypes.MetadataDS, r repo.LockedRepo, pieceStore dtypes.ProviderPieceStore, indexer provider.Interface, dataTransfer dtypes.ProviderDataTransfer, spn storagemarket.StorageProviderNode, df storageimpl.DealDeciderFunc, dsw stores.DAGStoreWrapper, meshCreator idxprov.MeshCreator, ) (storagemarket.StorageProvider, error)
Types ¶
type Genesis ¶
type Genesis func() (*types.BlockHeader, error)
type IdxProv ¶ added in v1.5.1
type IdxProv struct { fx.In fx.Lifecycle Datastore lotus_dtypes.MetadataDS }
type JwtPayload ¶
type JwtPayload struct {
Allow []auth.Permission
}
type LogSqlDB ¶
type LogSqlDB struct {
// contains filtered or unexported fields
}
func NewLogsSqlDB ¶
func NewLogsSqlDB(r repo.LockedRepo) (*LogSqlDB, error)
type MinerSealingService ¶
type MinerSealingService lapi.StorageMiner
type MinerStorageService ¶
type MinerStorageService lapi.StorageMiner
type ProxyAskGetter ¶ added in v1.6.1
ProxyAskGetter is used to avoid circular dependencies: RetrievalProvider depends on RetrievalGraphsync, which depends on RetrievalProvider's GetAsk method. We create an AskGetter that returns zero-priced asks by default. Then we set the AskGetter to the RetrievalProvider after it's been created.
func NewAskGetter ¶ added in v1.6.1
func NewAskGetter() *ProxyAskGetter
func (*ProxyAskGetter) GetAsk ¶ added in v1.6.1
func (ag *ProxyAskGetter) GetAsk() *retrievalmarket.Ask
type RetrievalSqlDB ¶ added in v1.5.1
type RetrievalSqlDB struct {
// contains filtered or unexported fields
}
func NewRetrievalSqlDB ¶ added in v1.5.1
func NewRetrievalSqlDB(r repo.LockedRepo) (*RetrievalSqlDB, error)
type ShardSelector ¶ added in v1.6.1
type ShardSelector struct { Proxy indexbs.ShardSelectorF Target indexbs.ShardSelectorF }
ShardSelector helps to resolve a circular dependency: The IndexBackedBlockstore has a shard selector, which needs to query the RetrievalProviderNode's ask to find out if it's free to retrieve a particular piece. However the RetrievalProviderNode depends on the DAGStore which depends on IndexBackedBlockstore. So we
- create a ShardSelector that has no dependencies with a default shard selection function that just selects no shards
- later call SetShardSelectorFunc to create a real shard selector function with all its dependencies, and set it on the ShardSelector object.
func NewShardSelector ¶ added in v1.6.1
func NewShardSelector() *ShardSelector