Documentation
¶
Index ¶
- type Candidate
- func (c *Candidate) CalculateExitProfit(ctx context.Context) (types.ExitProfitRsp, error)
- func (c *Candidate) CheckNetworkConnectable(ctx context.Context, network, targetURL string) (bool, error)
- func (c *Candidate) CheckNetworkConnectivity(ctx context.Context, network, targetURL string) error
- func (c *Candidate) DeactivateNode(ctx context.Context) error
- func (c *Candidate) GetBlocksWithAssetCID(ctx context.Context, assetCID string, randomSeed int64, randomCount int) ([]string, error)
- func (c *Candidate) GetExternalAddress(ctx context.Context) (string, error)
- func (c *Candidate) GetMinioConfig(ctx context.Context) (*types.MinioConfig, error)
- func (c *Candidate) WaitQuiet(ctx context.Context) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Candidate ¶
type Candidate struct {
fx.In
*common.CommonAPI
*asset.Asset
*device.Device
*vd.Validation
*datasync.DataSync
Scheduler api.Scheduler
Config *config.CandidateCfg
}
Candidate represents the c node.
func (*Candidate) CalculateExitProfit ¶ added in v0.1.21
func (*Candidate) CheckNetworkConnectable ¶ added in v0.1.18
func (*Candidate) CheckNetworkConnectivity ¶
checkNetworkConnectivity check tcp or udp network connectivity network is "tcp" or "udp"
func (*Candidate) DeactivateNode ¶ added in v0.1.21
func (*Candidate) GetBlocksWithAssetCID ¶
func (c *Candidate) GetBlocksWithAssetCID(ctx context.Context, assetCID string, randomSeed int64, randomCount int) ([]string, error)
GetBlocksWithAssetCID returns a map of blocks with given asset CID, random seed, and random count.
func (*Candidate) GetExternalAddress ¶
GetExternalAddress retrieves the external address of the caller.
func (*Candidate) GetMinioConfig ¶ added in v0.1.11
Click to show internal directories.
Click to hide internal directories.