diff --git a/config/localTemplate.go b/config/localTemplate.go index 08eef67201..247d09ef8b 100644 --- a/config/localTemplate.go +++ b/config/localTemplate.go @@ -44,39 +44,43 @@ type Local struct { // for an existing parameter. This field tag must be updated any time we add a new version. Version uint32 `version[0]:"0" version[1]:"1" version[2]:"2" version[3]:"3" version[4]:"4" version[5]:"5" version[6]:"6" version[7]:"7" version[8]:"8" version[9]:"9" version[10]:"10" version[11]:"11" version[12]:"12" version[13]:"13" version[14]:"14" version[15]:"15" version[16]:"16" version[17]:"17" version[18]:"18" version[19]:"19" version[20]:"20" version[21]:"21" version[22]:"22" version[23]:"23" version[24]:"24" version[25]:"25" version[26]:"26" version[27]:"27" version[28]:"28" version[29]:"29" version[30]:"30" version[31]:"31"` - // environmental (may be overridden) - // When enabled, stores blocks indefinitely, otherwise, only the most recent blocks - // are being kept around. ( the precise number of recent blocks depends on the consensus parameters ) + // Archival nodes retain a full copy of the block history. Non-Archival nodes will delete old blocks and only retain what's need to properly validate blockchain messages (the precise number of recent blocks depends on the consensus parameters. Currently the last 1321 blocks are required). This means that non-Archival nodes require significantly less storage than Archival nodes. Relays (nodes with a valid NetAddress) are always Archival, regardless of this setting. This may change in the future. If setting this to true for the first time, the existing ledger may need to be deleted to get the historical values stored as the setting only effects current blocks forward. To do this, shutdown the node and delete all .sqlite files within the data/testnet-version directory, except the crash.sqlite file. Restart the node and wait for the node to sync. Archival bool `version[0]:"false"` - // gossipNode.go - // how many peers to propagate to? - GossipFanout int `version[0]:"4"` - NetAddress string `version[0]:""` + // GossipFanout sets the maximum number of peers the node will connect to with outgoing connections. If the list of peers is less than this setting, fewer connections will be made. The node will not connect to the same peer multiple times (with outgoing connections). + GossipFanout int `version[0]:"4"` - // 1 * time.Minute = 60000000000 ns + // NetAddress is the address and/or port on which the relay node listens for incoming connections, or blank to ignore incoming connections. Specify an IP and port or just a port. For example, 127.0.0.1:0 will listen on a random port on the localhost. + NetAddress string `version[0]:""` + + // ReconnectTime is deprecated and unused. ReconnectTime time.Duration `version[0]:"60" version[1]:"60000000000"` - // The public address to connect to that is advertised to other nodes. + // PublicAddress is the public address to connect to that is advertised to other nodes. // For MainNet relays, make sure this entry includes the full SRV host name // plus the publicly-accessible port number. // A valid entry will avoid "self-gossip" and is used for identity exchange - // to deduplicate redundant connections + // to de-duplicate redundant connections PublicAddress string `version[0]:""` + // MaxConnectionsPerIP is the maximum number of connections allowed per IP address. MaxConnectionsPerIP int `version[3]:"30" version[27]:"15"` - // 0 == disable + // PeerPingPeriodSeconds is deprecated and unused. PeerPingPeriodSeconds int `version[0]:"0"` - // for https serving + // TLSCertFile is the certificate file used for the websocket network if povided. TLSCertFile string `version[0]:""` - TLSKeyFile string `version[0]:""` - // Logging + // TLSKeyFile is the key file used for the websocket network if povided. + TLSKeyFile string `version[0]:""` + + // BaseLoggerDebugLevel specifies the logging level for algod (node.log). The levels range from 0 (critical error / silent) to 5 (debug / verbose). The default value is 4 (‘Info’ - fairly verbose). BaseLoggerDebugLevel uint32 `version[0]:"1" version[1]:"4"` - // if this is 0, do not produce agreement.cadaver + + // CadaverSizeTarget specifies the maximum size of the agreement.cfv file in bytes. Once full the file will be renamed to agreement.archive.log and a new agreement.cdv will be created. CadaverSizeTarget uint64 `version[0]:"1073741824" version[24]:"0"` + // if this is not set, MakeService will attempt to use ColdDataDir instead CadaverDirectory string `version[27]:""` @@ -130,12 +134,12 @@ type Local struct { IncomingConnectionsLimit int `version[0]:"-1" version[1]:"10000" version[17]:"800" version[27]:"2400"` // BroadcastConnectionsLimit specifies the number of connections that - // will receive broadcast (gossip) messages from this node. If the + // will receive broadcast (gossip) messages from this node. If the // node has more connections than this number, it will send broadcasts // to the top connections by priority (outgoing connections first, then - // by money held by peers based on their participation key). 0 means + // by money held by peers based on their participation key). 0 means // no outgoing messages (not even transaction broadcasting to outgoing - // peers). -1 means unbounded (default). + // peers). -1 means unbounded (default). BroadcastConnectionsLimit int `version[4]:"-1"` // AnnounceParticipationKey specifies that this node should announce its @@ -149,7 +153,7 @@ type Local struct { // outgoing broadcast messages from this node. PriorityPeers map[string]bool `version[4]:""` - // To make sure the algod process does not run out of FDs, algod ensures + // ReservedFDs is used to make sure the algod process does not run out of file descriptors (FDs). Algod ensures // that RLIMIT_NOFILE >= IncomingConnectionsLimit + RestConnectionsHardLimit + // ReservedFDs. ReservedFDs are meant to leave room for short-lived FDs like // DNS queries, SQLite files, etc. This parameter shouldn't be changed. @@ -157,21 +161,27 @@ type Local struct { // then either RestConnectionsHardLimit or IncomingConnectionsLimit decreased. ReservedFDs uint64 `version[2]:"256"` - // local server - // API endpoint address + // EndpointAddress configures the address the node listens to for REST API calls. Specify an IP and port or just port. For example, 127.0.0.1:0 will listen on a random port on the localhost (preferring 8080). EndpointAddress string `version[0]:"127.0.0.1:0"` - // timeouts passed to the rest http.Server implementation - RestReadTimeoutSeconds int `version[4]:"15"` + // RestReadTimeoutSeconds is passed to the API servers rest http.Server implementation. + RestReadTimeoutSeconds int `version[4]:"15"` + + // RestWriteTimeoutSeconds is passed to the API servers rest http.Server implementation. RestWriteTimeoutSeconds int `version[4]:"120"` - // SRV-based phonebook + // DNSBootstrapID specifies the names of a set of DNS SRV records that identify the set of nodes available to connect to. + // When resolving the bootstrap ID will be replaced by the genesis block's network name. This string uses a URL + // parsing library and supports optional backup and dedup parameters. 'backup' is used to provide a second DNS entry to use + // in case the primary is unavailable. dedup is intended to be used to deduplicate SRV records returned from the primary + // and backup DNS address. If the macro is used in the dedup mask, it must be at the beginning of the expression. + // This is not typically something a user would configure. For more information see config/dnsbootstrap.go. DNSBootstrapID string `version[0]:".algorand.network" version[28]:".algorand.network?backup=.algorand.net&dedup=.algorand-.(network|net)"` - // Log file size limit in bytes. When set to 0 logs will be written to stdout. + // LogSizeLimit is the log file size limit in bytes. When set to 0 logs will be written to stdout. LogSizeLimit uint64 `version[0]:"1073741824"` - // text/template for creating log archive filename. + // LogArchiveName text/template for creating log archive filename. // Available template vars: // Time at start of log: {{.Year}} {{.Month}} {{.Day}} {{.Hour}} {{.Minute}} {{.Second}} // Time at end of log: {{.EndYear}} {{.EndMonth}} {{.EndDay}} {{.EndHour}} {{.EndMinute}} {{.EndSecond}} @@ -185,33 +195,34 @@ type Local struct { // Valid units are 's' seconds, 'm' minutes, 'h' hours LogArchiveMaxAge string `version[4]:""` - // number of consecutive attempts to catchup after which we replace the peers we're connected to + // CatchupFailurePeerRefreshRate is the maximum number of consecutive attempts to catchup after which we replace the peers we're connected to. CatchupFailurePeerRefreshRate int `version[0]:"10"` - // where should the node exporter listen for metrics + // NodeExporterListenAddress is used to set the specific address for publishing metrics; the Prometheus server connects to this incoming port to retrieve metrics. NodeExporterListenAddress string `version[0]:":9100"` - // enable metric reporting flag + // EnableMetricReporting determines if the metrics service for a node is to be enabled. This setting controls metrics being collected from this specific instance of algod. If any instance has metrics enabled, machine-wide metrics are also collected. EnableMetricReporting bool `version[0]:"false"` - // enable top accounts reporting flag + // EnableTopAccountsReporting enable top accounts reporting flag. Deprecated, do not use. EnableTopAccountsReporting bool `version[0]:"false"` - // enable agreement reporting flag. Currently only prints additional period events. + // EnableAgreementReporting controls the agreement reporting flag. Currently only prints additional period events. EnableAgreementReporting bool `version[3]:"false"` - // enable agreement timing metrics flag + // EnableAgreementTimeMetrics controls the agreement timing metrics flag. EnableAgreementTimeMetrics bool `version[3]:"false"` - // The path to the node exporter. + // NodeExporterPath is the path to the node_exporter binary. NodeExporterPath string `version[0]:"./node_exporter"` - // The fallback DNS resolver address that would be used if the system resolver would fail to retrieve SRV records + // FallbackDNSResolverAddress defines the fallback DNS resolver address that would be used if the system resolver would fail to retrieve SRV records. FallbackDNSResolverAddress string `version[0]:""` - // exponential increase factor of transaction pool's fee threshold, should always be 2 in production + // TxPoolExponentialIncreaseFactor exponential increase factor of transaction pool's fee threshold, should always be 2 in production. TxPoolExponentialIncreaseFactor uint64 `version[0]:"2"` + // SuggestedFeeBlockHistory is deprecated and unused. SuggestedFeeBlockHistory int `version[0]:"3"` // TxBacklogServiceRateWindowSeconds is the window size used to determine the service rate of the txBacklog @@ -228,77 +239,76 @@ type Local struct { // if EnableTxBacklogRateLimiting enabled, the over-all size will be larger by MAX_PEERS*TxBacklogReservedCapacityPerPeer TxBacklogSize int `version[27]:"26000"` - // TxPoolSize is the number of transactions that fit in the transaction pool + // TxPoolSize is the number of transactions in the transaction pool buffer. TxPoolSize int `version[0]:"50000" version[5]:"15000" version[23]:"75000"` // number of seconds allowed for syncing transactions TxSyncTimeoutSeconds int64 `version[0]:"30"` - // number of seconds between transaction synchronizations + // TxSyncIntervalSeconds number of seconds between transaction synchronizations. TxSyncIntervalSeconds int64 `version[0]:"60"` - // the number of incoming message hashes buckets. + // IncomingMessageFilterBucketCount is the number of incoming message hash buckets. IncomingMessageFilterBucketCount int `version[0]:"5"` - // the size of each incoming message hash bucket. + // IncomingMessageFilterBucketSize is the size of each incoming message hash bucket. IncomingMessageFilterBucketSize int `version[0]:"512"` - // the number of outgoing message hashes buckets. + // OutgoingMessageFilterBucketCount is the number of outgoing message hash buckets. OutgoingMessageFilterBucketCount int `version[0]:"3"` - // the size of each outgoing message hash bucket. + // OutgoingMessageFilterBucketSize is the size of each outgoing message hash bucket. OutgoingMessageFilterBucketSize int `version[0]:"128"` - // enable the filtering of outgoing messages + // EnableOutgoingNetworkMessageFiltering enable the filtering of outgoing messages EnableOutgoingNetworkMessageFiltering bool `version[0]:"true"` - // enable the filtering of incoming messages + // EnableIncomingMessageFilter enable the filtering of incoming messages. EnableIncomingMessageFilter bool `version[0]:"false"` - // control enabling / disabling deadlock detection. + // DeadlockDetection controls enabling or disabling deadlock detection. // negative (-1) to disable, positive (1) to enable, 0 for default. DeadlockDetection int `version[1]:"0"` - // The threshold used for deadlock detection, in seconds. + // DeadlockDetectionThreshold is the threshold used for deadlock detection, in seconds. DeadlockDetectionThreshold int `version[20]:"30"` - // Prefer to run algod Hosted (under algoh) - // Observed by `goal` for now. + // RunHosted configures whether to run algod in Hosted mode (under algoh). Observed by `goal` for now. RunHosted bool `version[3]:"false"` - // The maximal number of blocks that catchup will fetch in parallel. + // CatchupParallelBlocks is the maximum number of blocks that catchup will fetch in parallel. // If less than Protocol.SeedLookback, then Protocol.SeedLookback will be used as to limit the catchup. // Setting this variable to 0 would disable the catchup CatchupParallelBlocks uint64 `version[3]:"50" version[5]:"16"` - // Generate AssembleBlockMetrics telemetry event + // EnableAssembleStats specifies whether or not to emit the AssembleBlockMetrics telemetry event. EnableAssembleStats bool `version[0]:""` - // Generate ProcessBlockMetrics telemetry event + // EnableProcessBlockStats specifies whether or not to emit the ProcessBlockMetrics telemetry event. EnableProcessBlockStats bool `version[0]:""` - // SuggestedFeeSlidingWindowSize is number of past blocks that will be considered in computing the suggested fee + // SuggestedFeeSlidingWindowSize is deprecated and unused. SuggestedFeeSlidingWindowSize uint32 `version[3]:"50"` - // the max size the sync server would return + // TxSyncServeResponseSize the max size the sync server would return. TxSyncServeResponseSize int `version[3]:"1000000"` - // UseXForwardedForAddress indicates whether or not the node should use the X-Forwarded-For HTTP Header when + // UseXForwardedForAddressField indicates whether or not the node should use the X-Forwarded-For HTTP Header when // determining the source of a connection. If used, it should be set to the string "X-Forwarded-For", unless the // proxy vendor provides another header field. In the case of CloudFlare proxy, the "CF-Connecting-IP" header // field can be used. UseXForwardedForAddressField string `version[0]:""` - // ForceRelayMessages indicates whether the network library relay messages even in the case that no NetAddress was specified. + // ForceRelayMessages indicates whether the network library should relay messages even in the case that no NetAddress was specified. ForceRelayMessages bool `version[0]:"false"` - // ConnectionsRateLimitingWindowSeconds is being used in conjunction with ConnectionsRateLimitingCount; + // ConnectionsRateLimitingWindowSeconds is being used along with ConnectionsRateLimitingCount; // see ConnectionsRateLimitingCount description for further information. Providing a zero value // in this variable disables the connection rate limiting. ConnectionsRateLimitingWindowSeconds uint `version[4]:"1"` // ConnectionsRateLimitingCount is being used along with ConnectionsRateLimitingWindowSeconds to determine if - // a connection request should be accepted or not. The gossip network examine all the incoming requests in the past + // a connection request should be accepted or not. The gossip network examines all the incoming requests in the past // ConnectionsRateLimitingWindowSeconds seconds that share the same origin. If the total count exceed the ConnectionsRateLimitingCount // value, the connection is refused. ConnectionsRateLimitingCount uint `version[4]:"60"` @@ -306,12 +316,12 @@ type Local struct { // EnableRequestLogger enabled the logging of the incoming requests to the telemetry server. EnableRequestLogger bool `version[4]:"false"` - // PeerConnectionsUpdateInterval defines the interval at which the peer connections information is being sent to the - // telemetry ( when enabled ). Defined in seconds. + // PeerConnectionsUpdateInterval defines the interval at which the peer connections information is sent to + // telemetry (when enabled). Defined in seconds. PeerConnectionsUpdateInterval int `version[5]:"3600"` // HeartbeatUpdateInterval defines the interval at which the heartbeat information is being sent to the - // telemetry ( when enabled ). Defined in seconds. Minimum value is 60. + // telemetry (when enabled). Defined in seconds. Minimum value is 60. HeartbeatUpdateInterval int `version[27]:"600"` // EnableProfiler enables the go pprof endpoints, should be false if @@ -321,7 +331,7 @@ type Local struct { // EnableRuntimeMetrics exposes Go runtime metrics in /metrics and via node_exporter. EnableRuntimeMetrics bool `version[22]:"false"` - // TelemetryToLog records messages to node.log that are normally sent to remote event monitoring + // TelemetryToLog configures whether to record messages to node.log that are normally only sent to remote event monitoring. TelemetryToLog bool `version[5]:"true"` // DNSSecurityFlags instructs algod validating DNS responses. @@ -337,7 +347,7 @@ type Local struct { EnablePingHandler bool `version[6]:"true"` // DisableOutgoingConnectionThrottling disables the connection throttling of the network library, which - // allow the network library to continuesly disconnect relays based on their relative ( and absolute ) performance. + // allow the network library to continuously disconnect relays based on their relative (and absolute) performance. DisableOutgoingConnectionThrottling bool `version[5]:"false"` // NetworkProtocolVersion overrides network protocol version ( if present ) @@ -347,16 +357,16 @@ type Local struct { // See CatchpointTracking for more details. CatchpointInterval uint64 `version[7]:"10000"` - // CatchpointFileHistoryLength defines how many catchpoint files we want to store back. - // 0 means don't store any, -1 mean unlimited and positive number suggest the number of most recent catchpoint files. + // CatchpointFileHistoryLength defines how many catchpoint files to store. + // 0 means don't store any, -1 mean unlimited and positive number suggest the maximum number of most recent catchpoint files to store. CatchpointFileHistoryLength int `version[7]:"365"` // EnableLedgerService enables the ledger serving service. The functionality of this depends on NetAddress, which must also be provided. // This functionality is required for the catchpoint catchup. EnableLedgerService bool `version[7]:"false"` - // EnableBlockService enables the block serving service. The functionality of this depends on NetAddress, which must also be provided. - // This functionality is required for the catchup. + // EnableBlockService controls whether to enables the block serving service. The functionality of this depends on NetAddress, which must also be provided. + // This functionality is required for catchup. EnableBlockService bool `version[7]:"false"` // EnableGossipBlockService enables the block serving service over the gossip network. The functionality of this depends on NetAddress, which must also be provided. @@ -372,10 +382,10 @@ type Local struct { // CatchupLedgerDownloadRetryAttempts controls the number of attempt the ledger fetching would be attempted before giving up catching up to the provided catchpoint. CatchupLedgerDownloadRetryAttempts int `version[9]:"50"` - // CatchupLedgerDownloadRetryAttempts controls the number of attempt the block fetching would be attempted before giving up catching up to the provided catchpoint. + // CatchupBlockDownloadRetryAttempts controls the number of attempts the block fetcher would make before giving up on a provided catchpoint. CatchupBlockDownloadRetryAttempts int `version[9]:"1000"` - // EnableDeveloperAPI enables teal/compile, teal/dryrun API endpoints. + // EnableDeveloperAPI enables teal/compile and teal/dryrun API endpoints. // This functionality is disabled by default. EnableDeveloperAPI bool `version[9]:"false"` @@ -399,8 +409,8 @@ type Local struct { // for further information see the description of SynchronousMode in dbutil.go LedgerSynchronousMode int `version[12]:"2"` - // AccountsRebuildSynchronousMode defines the synchronous mode used by the ledger database while the account database is being rebuilt. This is not a typical operational usecase, - // and is expected to happen only on either startup ( after enabling the catchpoint interval, or on certain database upgrades ) or during fast catchup. The values specified here + // AccountsRebuildSynchronousMode defines the synchronous mode used by the ledger database while the account database is being rebuilt. This is not a typical operational use-case, + // and is expected to happen only on either startup (after enabling the catchpoint interval, or on certain database upgrades) or during fast catchup. The values specified here // and their meanings are identical to the ones in LedgerSynchronousMode. AccountsRebuildSynchronousMode int `version[12]:"1"` @@ -414,7 +424,7 @@ type Local struct { // the default of 20480 would be used. MinCatchpointFileDownloadBytesPerSecond uint64 `version[13]:"20480"` - // TraceServer is a host:port to report graph propagation trace info to. + // NetworkMessageTraceServer is a host:port address to report graph propagation trace info to. NetworkMessageTraceServer string `version[13]:""` // VerifiedTranscationsCacheSize defines the number of transactions that the verified transactions cache would hold before cycling the cache storage in a round-robin fashion. @@ -422,7 +432,7 @@ type Local struct { // EnableCatchupFromArchiveServers controls which peers the catchup service would use in order to catchup. // When enabled, the catchup service would use the archive servers before falling back to the relays. - // On networks that doesn't have archive servers, this becomes a no-op, as the catchup service would have no + // On networks that don't have archive servers, this becomes a no-op, as the catchup service would have no // archive server to pick from, and therefore automatically selects one of the relay nodes. EnableCatchupFromArchiveServers bool `version[15]:"false"` @@ -456,25 +466,25 @@ type Local struct { // previously used executabled, and would not provide any additional security guarantees. CatchupBlockValidateMode int `version[16]:"0"` - // Generate AccountUpdates telemetry event + // EnableAccountUpdatesStats specifies whether or not to emit the AccountUpdates telemetry event. EnableAccountUpdatesStats bool `version[16]:"false"` - // Time interval in nanoseconds for generating accountUpdates telemetry event + // AccountUpdatesStatsInterval is the time interval in nanoseconds between accountUpdates telemetry events. AccountUpdatesStatsInterval time.Duration `version[16]:"5000000000"` // ParticipationKeysRefreshInterval is the duration between two consecutive checks to see if new participation - // keys have been placed on the genesis directory. + // keys have been placed on the genesis directory. Deprecated and unused. ParticipationKeysRefreshInterval time.Duration `version[16]:"60000000000"` // DisableNetworking disables all the incoming and outgoing communication a node would perform. This is useful - // when we have a single-node private network, where there is no other nodes that need to be communicated with. - // features like catchpoint catchup would be rendered completly non-operational, and many of the node inner - // working would be completly dis-functional. + // when we have a single-node private network, where there are no other nodes that need to be communicated with. + // Features like catchpoint catchup would be rendered completely non-operational, and many of the node inner + // working would be completely dis-functional. DisableNetworking bool `version[16]:"false"` // ForceFetchTransactions allows to explicitly configure a node to retrieve all the transactions // into it's transaction pool, even if those would not be required as the node doesn't - // participate in the consensus or used to relay transactions. + // participate in consensus and is not used to relay transactions. ForceFetchTransactions bool `version[17]:"false"` // EnableVerbosedTransactionSyncLogging enables the transaction sync to write extensive @@ -495,11 +505,12 @@ type Local struct { // ProposalAssemblyTime is the max amount of time to spend on generating a proposal block. ProposalAssemblyTime time.Duration `version[19]:"250000000" version[23]:"500000000"` + // RestConnectionsSoftLimit is the maximum number of active requests the API server // When the number of http connections to the REST layer exceeds the soft limit, // we start returning http code 429 Too Many Requests. RestConnectionsSoftLimit uint64 `version[20]:"1024"` - // The http server does not accept new connections as long we have this many - // (hard limit) connections already. + + // RestConnectionsHardLimit is the maximum number of active connections the API server will accept before closing requests with no response. RestConnectionsHardLimit uint64 `version[20]:"2048"` // MaxAPIResourcesPerAccount sets the maximum total number of resources (created assets, created apps,