indexing

package
v0.11.0 Latest Latest
Warning

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

Go to latest
Published: Aug 25, 2021 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Finalize

func Finalize(db *store.Store, data *Data) error

Finalize generates summary records

func Import

func Import(db *store.Store, data *Data) error

Import creates new database records for the chain data

func RewardCalculation added in v0.11.0

func RewardCalculation(db *store.Store, block model.Block) error

RewardCalculation calculates rewards

Types

type Data

type Data struct {
	Block           *model.Block
	Validator       *model.Validator
	CreatorAccount  *model.Account
	ValidatorEpochs []model.ValidatorEpoch
	Accounts        []model.Account
	Snarkers        []model.Snarker
	Transactions    []model.Transaction
	SnarkJobs       []model.SnarkJob
}

Data contains all the records processed for a height

func Prepare

func Prepare(archiveBlock *archive.Block, graphBlock *graph.Block, validatorEpochs []model.ValidatorEpoch) (*Data, error)

Prepare generates a new models from the graph block data

Jump to

Keyboard shortcuts

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