snap

package
v1.23.0 Latest Latest
Warning

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

Go to latest
Published: Jul 29, 2024 License: Apache-2.0, MIT Imports: 37 Imported by: 0

Documentation

Index

Constants

View Source
const MinSnapSchedInterval = 10 * time.Second

Variables

This section is empty.

Functions

This section is empty.

Types

type EncodeTask

type EncodeTask struct {
	// contains filtered or unexported fields
}

func NewEncodeTask

func NewEncodeTask(sc *ffi.SealCalls, db *harmonydb.DB, max int) *EncodeTask

func (*EncodeTask) Adder

func (e *EncodeTask) Adder(taskFunc harmonytask.AddTaskFunc)

func (*EncodeTask) CanAccept

func (e *EncodeTask) CanAccept(ids []harmonytask.TaskID, engine *harmonytask.TaskEngine) (*harmonytask.TaskID, error)

func (*EncodeTask) Do

func (e *EncodeTask) Do(taskID harmonytask.TaskID, stillOwned func() bool) (done bool, err error)

func (*EncodeTask) GetSpid

func (e *EncodeTask) GetSpid(db *harmonydb.DB, taskID int64) string

func (*EncodeTask) TypeDetails

func (e *EncodeTask) TypeDetails() harmonytask.TaskTypeDetails

type MoveStorageTask

type MoveStorageTask struct {
	// contains filtered or unexported fields
}

func NewMoveStorageTask

func NewMoveStorageTask(sc *ffi.SealCalls, db *harmonydb.DB, max int) *MoveStorageTask

func (*MoveStorageTask) Adder

func (m *MoveStorageTask) Adder(taskFunc harmonytask.AddTaskFunc)

func (*MoveStorageTask) CanAccept

func (*MoveStorageTask) Do

func (m *MoveStorageTask) Do(taskID harmonytask.TaskID, stillOwned func() bool) (done bool, err error)

func (*MoveStorageTask) GetSpid

func (m *MoveStorageTask) GetSpid(db *harmonydb.DB, taskID int64) string

func (*MoveStorageTask) TypeDetails

func (m *MoveStorageTask) TypeDetails() harmonytask.TaskTypeDetails

type ProveTask

type ProveTask struct {
	// contains filtered or unexported fields
}

func NewProveTask

func NewProveTask(sc *ffi.SealCalls, db *harmonydb.DB, paramck func() (bool, error), max int) *ProveTask

func (*ProveTask) Adder

func (p *ProveTask) Adder(taskFunc harmonytask.AddTaskFunc)

func (*ProveTask) CanAccept

func (p *ProveTask) CanAccept(ids []harmonytask.TaskID, engine *harmonytask.TaskEngine) (*harmonytask.TaskID, error)

func (*ProveTask) Do

func (p *ProveTask) Do(taskID harmonytask.TaskID, stillOwned func() bool) (done bool, err error)

func (*ProveTask) GetSpid

func (p *ProveTask) GetSpid(db *harmonydb.DB, taskID int64) string

func (*ProveTask) TypeDetails

func (p *ProveTask) TypeDetails() harmonytask.TaskTypeDetails

type SubmitTask

type SubmitTask struct {
	// contains filtered or unexported fields
}

func (*SubmitTask) Adder

func (s *SubmitTask) Adder(taskFunc harmonytask.AddTaskFunc)

func (*SubmitTask) CanAccept

func (s *SubmitTask) CanAccept(ids []harmonytask.TaskID, engine *harmonytask.TaskEngine) (*harmonytask.TaskID, error)

func (*SubmitTask) Do

func (s *SubmitTask) Do(taskID harmonytask.TaskID, stillOwned func() bool) (done bool, err error)

func (*SubmitTask) GetSpid

func (s *SubmitTask) GetSpid(db *harmonydb.DB, taskID int64) string

func (*SubmitTask) TypeDetails

func (s *SubmitTask) TypeDetails() harmonytask.TaskTypeDetails

type SubmitTaskNodeAPI

type SubmitTaskNodeAPI interface {
	StateSectorPartition(ctx context.Context, maddr address.Address, sectorNumber abi.SectorNumber, tsk types.TipSetKey) (*miner.SectorLocation, error)
	StateGetAllocation(ctx context.Context, clientAddr address.Address, allocationId verifregtypes9.AllocationId, tsk types.TipSetKey) (*verifregtypes9.Allocation, error)
	ChainHead(ctx context.Context) (*types.TipSet, error)

	WalletBalance(context.Context, address.Address) (types.BigInt, error)
	WalletHas(context.Context, address.Address) (bool, error)
	StateAccountKey(context.Context, address.Address, types.TipSetKey) (address.Address, error)
	StateLookupID(context.Context, address.Address, types.TipSetKey) (address.Address, error)
	StateSectorGetInfo(ctx context.Context, maddr address.Address, sectorNumber abi.SectorNumber, tsk types.TipSetKey) (*miner.SectorOnChainInfo, error)

	StateMinerInfo(context.Context, address.Address, types.TipSetKey) (api.MinerInfo, error)
	StateGetActor(ctx context.Context, actor address.Address, tsk types.TipSetKey) (*types.Actor, error)
	StateVMCirculatingSupplyInternal(ctx context.Context, tsk types.TipSetKey) (api.CirculatingSupply, error)
}

Jump to

Keyboard shortcuts

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