consensus

package
v0.0.0-...-f077743 Latest Latest
Warning

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

Go to latest
Published: Aug 4, 2021 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

View Source
const (
	MaxwellPerMass uint64 = 100000000
	// 1 mass, 1 day old, a tx of 250 bytes
	MinHighPriority          = 1e8 * 1920.0 / 250
	MaxNewBlockChSize        = 1024
	DefaultBlockPrioritySize = 50000

	// staking tx
	MaxStakingRewardNum = 30
)

Variables

View Source
var (
	MASSIP0001Height         uint64 = 694000
	MASSIP0001MaxValidPeriod        = defaultMinFrozenPeriod * 24 // 1474560

	MASSIP0002WarmUpHeight         uint64 = 1398801                // disable old binding
	MASSIP0002Height               uint64 = 1404801                // disallow minting without binding
	MASSIP0002BindingLockedPeriod  uint64 = 0x00000000ffffffff - 1 // wire.SequenceLockTimeMask - 1
	MASSIP0002SetPoolPkCoinbaseFee        = 100000000              // 1 MASS
	MASSIP0002PayloadNonceGap             = 5
)
View Source
var (
	// CoinbaseMaturity is the number of blocks required before newly
	// mined coins can be spent
	CoinbaseMaturity = defaultCoinbaseMaturity

	// TransactionMaturity is the number of blocks required before newly
	// binding tx get reward
	TransactionMaturity = defaultTransactionMaturity

	// MaxMass the maximum MASS amount
	MaxMass = defaultMaxMass

	SubsidyHalvingInterval = defaultSubsidyHalvingInterval
	// BaseSubsidy is the original subsidy Maxwell for mined blocks.  This
	// value is halved every SubsidyHalvingInterval blocks.
	BaseSubsidy = defaultBaseSubsidy
	// MinHalvedSubsidy is the minimum subsidy Maxwell for mined blocks.
	MinHalvedSubsidy = defaultMinHalvedSubsidy

	// MinRelayTxFee minimum relay fee in Maxwell
	MinRelayTxFee = defaultMinRelayTxFee

	//Min Frozen Period in a StakingScriptHash output
	MinFrozenPeriod = defaultMinFrozenPeriod
	//MinStakingValue minimum StakingScriptHash output in Maxwell
	MinStakingValue = defaultMinStakingValue

	StakingTxRewardStart = defaultStakingTxRewardStart
)

Functions

This section is empty.

Types

type ServiceFlag

type ServiceFlag uint64

ServiceFlag use uint64 to indicate what kind of server this node can provide. one uint64 can represent 64 type of service flag

const (
	// SFFullNode is a flag used to indicate a peer is a full node.
	SFFullNode ServiceFlag = 1 << iota
	// SFFastSync indicate peer support header first mode
	SFFastSync
	// SFSPV indicate peer support spv mode
	SFSPV
	// DefaultServices is the server that this node support
	DefaultServices = SFFullNode | SFFastSync
)

func (ServiceFlag) IsEnable

func (f ServiceFlag) IsEnable(checkFlag ServiceFlag) bool

IsEnable check does the flag support the input flag function

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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