compliance

package
v0.38.0-preview.0 Latest Latest
Warning

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

Go to latest
Published: Sep 18, 2024 License: AGPL-3.0 Imports: 0 Imported by: 11

Documentation

Index

Constants

View Source
const MinSkipNewProposalsThreshold = 1000

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	// SkipNewProposalsThreshold defines the threshold for dropping blocks that are too far in
	// the future. Formally, let `H` be the view of the latest finalized block known to this
	// node. A new block `B` is dropped without further processing, if
	//   B.View > H + SkipNewProposalsThreshold
	SkipNewProposalsThreshold uint64
}

Config is shared config for consensus and collection compliance engines, and the consensus follower engine.

func DefaultConfig

func DefaultConfig() Config

func (*Config) GetSkipNewProposalsThreshold added in v0.31.0

func (c *Config) GetSkipNewProposalsThreshold() uint64

GetSkipNewProposalsThreshold returns stored value in config possibly applying a lower bound.

type Opt

type Opt func(*Config)

func WithSkipNewProposalsThreshold

func WithSkipNewProposalsThreshold(threshold uint64) Opt

WithSkipNewProposalsThreshold returns an option to set the skip new proposals threshold. For inputs less than the minimum threshold, the minimum threshold will be set instead.

Jump to

Keyboard shortcuts

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