2020-03-25 15:30:21 +00:00
|
|
|
package config
|
|
|
|
|
|
|
|
import (
|
2020-06-14 07:34:50 +00:00
|
|
|
"github.com/nspcc-dev/neo-go/pkg/config/netmode"
|
2020-03-25 15:30:21 +00:00
|
|
|
"github.com/nspcc-dev/neo-go/pkg/util"
|
|
|
|
)
|
|
|
|
|
|
|
|
// ProtocolConfiguration represents the protocol config.
|
|
|
|
type (
|
|
|
|
ProtocolConfiguration struct {
|
|
|
|
// FeePerExtraByte sets the expected per-byte fee for
|
|
|
|
// transactions exceeding the MaxFreeTransactionSize.
|
|
|
|
FeePerExtraByte float64 `yaml:"FeePerExtraByte"`
|
|
|
|
// FreeGasLimit is an amount of GAS which can be spent for free.
|
2020-06-14 07:34:50 +00:00
|
|
|
FreeGasLimit util.Fixed8 `yaml:"FreeGasLimit"`
|
|
|
|
LowPriorityThreshold float64 `yaml:"LowPriorityThreshold"`
|
|
|
|
Magic netmode.Magic `yaml:"Magic"`
|
|
|
|
MaxTransactionsPerBlock int `yaml:"MaxTransactionsPerBlock"`
|
2020-03-25 15:30:21 +00:00
|
|
|
// Maximum size of low priority transaction in bytes.
|
|
|
|
MaxFreeTransactionSize int `yaml:"MaxFreeTransactionSize"`
|
|
|
|
// Maximum number of low priority transactions accepted into block.
|
|
|
|
MaxFreeTransactionsPerBlock int `yaml:"MaxFreeTransactionsPerBlock"`
|
|
|
|
MemPoolSize int `yaml:"MemPoolSize"`
|
|
|
|
// SaveStorageBatch enables storage batch saving before every persist.
|
2020-06-05 09:40:07 +00:00
|
|
|
SaveStorageBatch bool `yaml:"SaveStorageBatch"`
|
|
|
|
SecondsPerBlock int `yaml:"SecondsPerBlock"`
|
|
|
|
SeedList []string `yaml:"SeedList"`
|
|
|
|
StandbyValidators []string `yaml:"StandbyValidators"`
|
2020-03-25 15:30:21 +00:00
|
|
|
// Whether to verify received blocks.
|
|
|
|
VerifyBlocks bool `yaml:"VerifyBlocks"`
|
|
|
|
// Whether to verify transactions in received blocks.
|
|
|
|
VerifyTransactions bool `yaml:"VerifyTransactions"`
|
|
|
|
}
|
|
|
|
)
|