Documentation
¶
Index ¶
Constants ¶
View Source
const ( // DefaultCacheSize is calculated as memory consumption in a worst case scenario with default configuration // Average memory consumption might be 3-5 times lower than the maximum DefaultCacheSize = 3200 ConstantCacheSize = 1024 )
View Source
const ( DefaultP2PPort = 5050 // Default p2p port for listening DefaultHTTPPort = 18545 // Default TCP port for the HTTP RPC server DefaultWSPort = 18546 // Default TCP port for the websocket RPC server )
Variables ¶
View Source
var ( // DataDirFlag defines directory to store Sirius state and user's wallets DataDirFlag = utils.DirectoryFlag{ Name: "datadir", Usage: "Data directory for the databases and keystore", Value: utils.DirectoryString(DefaultDataDir()), } CacheFlag = cli.IntFlag{ Name: "cache", Usage: "Megabytes of memory allocated to internal caching", Value: DefaultCacheSize, } // GenesisFlag specifies network genesis configuration GenesisFlag = cli.StringFlag{ Name: "genesis", Usage: "'path to genesis file' - sets the network genesis configuration.", } RPCGlobalGasCapFlag = cli.Uint64Flag{ Name: "rpc.gascap", Usage: "Sets a cap on gas that can be used in tpc_call/estimateGas (0=infinite)", Value: gossip.DefaultConfig(cachescale.Identity).RPCGasCap, } RPCGlobalTxFeeCapFlag = cli.Float64Flag{ Name: "rpc.txfeecap", Usage: "Sets a cap on transaction fee (in TPC) that can be sent via the RPC APIs (0 = no cap)", Value: gossip.DefaultConfig(cachescale.Identity).RPCTxFeeCap, } AllowedPhotonGenesisHashes = map[uint64]hash.Hash{ photon.MainNetworkID: hash.HexToHash("0x4a53c5445584b3bfc20dbfb2ec18ae20037c716f3ba2d9e1da768a9deca17cb4"), photon.TestNetworkID: hash.HexToHash("0xc4a5fc96e575a16a9a0c7349d44dc4d0f602a54e0a8543360c2fee4c3937b49e"), } )
View Source
var AppHelpFlagGroups = calcAppHelpFlagGroups()
AppHelpFlagGroups is the application flags, grouped by functionality.
View Source
var (
Bootnodes = []string{
"enode://6ae039d34e69dd61fdafcc40198e1cab264afd4e17d22f80b19f7d4d3b67ea36de11ee9b5702b7122d113ec135494c063d68b5b2156b4730fbcf4aaa6581b7d5@178.62.69.60:5050",
"enode://c8cd5a794e64b4d1c08fb38b35630e981805c959921cec4ff3edd621e105babbe57d4ad2687884a3a00c02bba99d54ab7cebfb519dfc1fe6b0095ecae7971192@167.99.199.7:5050",
"enode://8ca6e8b391eefe43c31b23368d85ac886030ffebc4cfa4167bc0bb2e818a4136f9ade8a328bd3ffdf3a2dec978cfb6222484c478d9125d9cbddfbb548b2576fa@142.93.33.192:5050",
"enode://a4b35611552fbb0506c35d4c09b975a2f9a5d50a0dc23f7dde879afe5f86756a6e4cc223837654317b258eec5f8712f2b7da1b6dcce4c2ae9c1ea6c3e7df11fd@159.65.52.165:5050",
"enode://fc0eac29900b92213d4d6882566ba96668fd54bcce81153c45183d92c372e6152d9eebe0928c9f5968327885fb8b16e2c2d7cbe25c9bdc5c9eea96b292298f31@46.101.28.195:5050",
"enode://0b22327fc7b0d63a25b5f16389f12f84b81d2de4d3da859d6072621a155d79edfa67943270d1f381a26dc66548257dc10bd5abfcc1f6edca982b6ace9c831e5a@142.93.42.96:5050",
}
)
View Source
var (
EventsCheckFlag = cli.BoolTFlag{
Name: "check",
Usage: "true if events should be fully checked before importing",
}
)
View Source
var FakeNetFlag = cli.StringFlag{
Name: "fakenet",
Usage: "'n/N' - sets coinbase as fake n-th key from genesis of N validators.",
}
FakeNetFlag enables special testnet, where validators are automatically created
View Source
var NodeDefaultConfig = node.Config{ DataDir: DefaultDataDir(), HTTPPort: DefaultHTTPPort, HTTPModules: []string{}, HTTPVirtualHosts: []string{"localhost"}, HTTPTimeouts: rpc.DefaultHTTPTimeouts, WSPort: DefaultWSPort, WSModules: []string{}, GraphQLVirtualHosts: []string{"localhost"}, P2P: p2p.Config{ NoDiscovery: false, DiscoveryV5: true, ListenAddr: fmt.Sprintf(":%d", DefaultP2PPort), MaxPeers: 50, NAT: nat.Any(), }, }
NodeDefaultConfig contains reasonable default settings.
Functions ¶
func DefaultDataDir ¶
func DefaultDataDir() string
DefaultDataDir is the default data directory to use for the databases and other persistence requirements.
func FindAccountKeypath ¶
Types ¶
This section is empty.
Source Files
¶
Click to show internal directories.
Click to hide internal directories.