slashfilter

package
v1.6.0 Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2022 License: Apache-2.0, MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewMysqlSlashFilter added in v1.1.0

func NewMysqlSlashFilter(cfg *config.MySQLConfig) func() (SlashFilterAPI, error)

Types

type MinedBlock added in v1.1.0

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

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

func (*MinedBlock) TableName added in v1.1.0

func (m *MinedBlock) TableName() string

type MysqlSlashFilter added in v1.1.0

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

func (*MysqlSlashFilter) MinedBlock added in v1.1.0

func (f *MysqlSlashFilter) MinedBlock(ctx context.Context, bh *types.BlockHeader, parentEpoch abi.ChainEpoch) error

type SlashFilter

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

func New

func New(dstore ds.Batching) *SlashFilter

func (*SlashFilter) MinedBlock

func (f *SlashFilter) MinedBlock(ctx context.Context, bh *types.BlockHeader, parentEpoch abi.ChainEpoch) error

type SlashFilterAPI added in v1.1.0

type SlashFilterAPI interface {
	MinedBlock(context.Context, *types.BlockHeader, abi.ChainEpoch) error
}

func NewLocal added in v1.1.0

func NewLocal(ds dtypes.MetadataDS) SlashFilterAPI

Jump to

Keyboard shortcuts

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