types

package
v1.15.0 Latest Latest
Warning

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

Go to latest
Published: Apr 1, 2024 License: Apache-2.0, MIT Imports: 8 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIEndpoint

type APIEndpoint multiaddr.Multiaddr

type BlocksQueryParams added in v1.13.0

type BlocksQueryParams struct {
	Miners []address.Address
	Limit  int
	Offset int
}

type CountWinners

type CountWinners struct {
	Miner         address.Address `json:"miner"`
	TotalWinCount int64           `json:"totalWinCount"`
	Msg           string          `json:"msg"`
	WinEpochList  []SimpleWinInfo `json:"winEpochList"`
}

type ErrorCode added in v1.14.0

type ErrorCode int
const (
	ConnectGatewayError ErrorCode = iota
	CallNodeRPCError
	WalletSignError
)

func (ErrorCode) Error added in v1.14.0

func (e ErrorCode) Error() string

func (ErrorCode) String added in v1.14.0

func (e ErrorCode) String() string

type LogCids

type LogCids []cid.Cid

func (LogCids) MarshalLogArray

func (cids LogCids) MarshalLogArray(ae zapcore.ArrayEncoder) error

type MetadataDS

type MetadataDS datastore.Batching

MetadataDS stores metadata dy default it's namespaced under /metadata in main repo datastore

type MinedBlock added in v1.13.0

type MinedBlock struct {
	ParentEpoch int64  `gorm:"column:parent_epoch;type:bigint(20);default:0;NOT NULL"`
	ParentKey   string `gorm:"column:parent_key;type:varchar(2048);default:'';NOT NULL"`

	Epoch int64  `gorm:"column:epoch;type:bigint(20);NOT NULL;primary_key"`
	Miner string `gorm:"column:miner;type:varchar(256);NOT NULL;primary_key"`
	Cid   string `gorm:"column:cid;type:varchar(256);default:''"`

	WinningAt time.Time   `gorm:"column:winning_at;type:datetime"`
	MineState StateMining `gorm:"column:mine_state;type:tinyint(4);default:0;comment:0-mining,1-success,2-timeout,3-chain forked,4-error;NOT NULL"`
	Consuming int64       `gorm:"column:consuming;type:bigint(10);default:0;NOT NULL"` // reserved
}

func (*MinedBlock) TableName added in v1.13.0

func (m *MinedBlock) TableName() string

type MinerInfo

type MinerInfo struct {
	Addr       address.Address
	Id         string
	Name       string
	OpenMining bool
}

type MinerState

type MinerState struct {
	Addr     address.Address
	IsMining bool
	Err      []string
}

type NetworkName

type NetworkName string

type QueryRecordParams added in v1.13.0

type QueryRecordParams struct {
	Miner address.Address
	Epoch abi.ChainEpoch
	Limit uint
}

type ShutdownChan

type ShutdownChan chan struct{}

ShutdownChan is a channel to which you send a value if you intend to shut down the daemon (or miner), including the node and RPC server.

type SimpleWinInfo

type SimpleWinInfo struct {
	Epoch    abi.ChainEpoch `json:"epoch"`
	WinCount int64          `json:"winCount"`
	Msg      string         `json:"msg"`
}

type StateMining added in v1.13.0

type StateMining int
const (
	Mining StateMining = iota
	Success
	Timeout
	ChainForked
	Error
)

func (StateMining) String added in v1.13.0

func (sm StateMining) String() string

Jump to

Keyboard shortcuts

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