Changeset View
Changeset View
Standalone View
Standalone View
src/init.cpp
Show First 20 Lines • Show All 1,329 Lines • ▼ Show 20 Lines | argsman.AddArg( | ||||
ArgsManager::ALLOW_ANY, OptionsCategory::AVALANCHE); | ArgsManager::ALLOW_ANY, OptionsCategory::AVALANCHE); | ||||
argsman.AddArg( | argsman.AddArg( | ||||
"-avaminquorumconnectedstakeratio", | "-avaminquorumconnectedstakeratio", | ||||
strprintf("Minimum proportion of known stake we" | strprintf("Minimum proportion of known stake we" | ||||
" need nodes for to have a usable quorum (default: %s)", | " need nodes for to have a usable quorum (default: %s)", | ||||
AVALANCHE_DEFAULT_MIN_QUORUM_CONNECTED_STAKE_RATIO), | AVALANCHE_DEFAULT_MIN_QUORUM_CONNECTED_STAKE_RATIO), | ||||
ArgsManager::ALLOW_STRING, OptionsCategory::AVALANCHE); | ArgsManager::ALLOW_STRING, OptionsCategory::AVALANCHE); | ||||
argsman.AddArg( | argsman.AddArg( | ||||
"-avaminavaproofsnodecount", | |||||
strprintf("Minimum number of node that needs to send us an avaproofs" | |||||
" message before we consider we have a usable quorum" | |||||
" (default: %s)", | |||||
AVALANCHE_DEFAULT_MIN_AVAPROOFS_NODE_COUNT), | |||||
ArgsManager::ALLOW_INT, OptionsCategory::AVALANCHE); | |||||
argsman.AddArg( | |||||
"-avastalevotethreshold", | "-avastalevotethreshold", | ||||
strprintf("Number of avalanche votes before a voted item goes stale " | strprintf("Number of avalanche votes before a voted item goes stale " | ||||
"when voting confidence is low (default: %u)", | "when voting confidence is low (default: %u)", | ||||
AVALANCHE_VOTE_STALE_THRESHOLD), | AVALANCHE_VOTE_STALE_THRESHOLD), | ||||
ArgsManager::ALLOW_INT, OptionsCategory::AVALANCHE); | ArgsManager::ALLOW_INT, OptionsCategory::AVALANCHE); | ||||
argsman.AddArg( | argsman.AddArg( | ||||
"-avastalevotefactor", | "-avastalevotefactor", | ||||
strprintf( | strprintf( | ||||
▲ Show 20 Lines • Show All 311 Lines • ▼ Show 20 Lines | if (args.IsArgSet("-avalanche")) { | ||||
fAvalanche | fAvalanche | ||||
? FormatMoney(int64_t(1'000'000'000'000) * SATOSHI) // 10B XEC | ? FormatMoney(int64_t(1'000'000'000'000) * SATOSHI) // 10B XEC | ||||
: FormatMoney(AVALANCHE_DEFAULT_MIN_QUORUM_STAKE)); | : FormatMoney(AVALANCHE_DEFAULT_MIN_QUORUM_STAKE)); | ||||
args.SoftSetArg( | args.SoftSetArg( | ||||
"-avaminquorumconnectedstakeratio", | "-avaminquorumconnectedstakeratio", | ||||
fAvalanche | fAvalanche | ||||
? "0.8" | ? "0.8" | ||||
: ToString(AVALANCHE_DEFAULT_MIN_QUORUM_CONNECTED_STAKE_RATIO)); | : ToString(AVALANCHE_DEFAULT_MIN_QUORUM_CONNECTED_STAKE_RATIO)); | ||||
args.SoftSetArg( | |||||
"-avaminavaproofsnodecount", | |||||
fAvalanche ? "8" | |||||
: ToString(AVALANCHE_DEFAULT_MIN_AVAPROOFS_NODE_COUNT)); | |||||
} | } | ||||
} | } | ||||
/** | /** | ||||
* Initialize global loggers. | * Initialize global loggers. | ||||
* | * | ||||
* Note that this is called very early in the process lifetime, so you should be | * Note that this is called very early in the process lifetime, so you should be | ||||
* careful about what global state you rely on here. | * careful about what global state you rely on here. | ||||
▲ Show 20 Lines • Show All 1,451 Lines • Show Last 20 Lines |