-
Notifications
You must be signed in to change notification settings - Fork 69
/
default-configuration.toml
354 lines (241 loc) · 11.2 KB
/
default-configuration.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
# Do not support:
# * Nested tables
# * Arrays
[log]
# Log level, e.g. DEBUG, INFO, WARN, ERROR.
level = "INFO"
# Optionally print logs to a file in JSON format.
# json-path =
# io.casperlabs.node.configuration.Configuration.Server
[server]
# Hostname or IP of this node.
# host =
# Network port to use for intra-node gRPC communication.
port = 40400
# HTTP port for utility services: /metrics, /version and /status.
http-port = 40403
# Kademlia port used for node discovery based on Kademlia algorithm.
kademlia-port = 40404
# Host IP address changes dynamically.
dynamic-host-address = false
# Use this flag to disable UpNp.
no-upnp = false
# Default timeout for roundtrip connections.
default-timeout = "15second"
# Timeout for shutting down gRPC services.
shutdown-timeout = "1minute"
# Bootstrap casperlabs node addresses for initial seeds. Empty defaut provided for standalone mode.
# bootstrap = "casperlabs://<keccak-hash-of-tls-public-key>:<chain id>@<host>?protocol=<intra-node-port>&discovery=<kademila-port>"
bootstrap = ""
# Path to data directory.
data-dir = "$HOME/.casperlabs"
# Maximum number of peers allowed to connect to the node.
max-num-of-connections = 500
# Maximum size of message that can be sent via transport layer.
max-message-size = 4194304
# Size of the buffer to store emitted block events
event-stream-buffer-size = 1000
# Target parallelism for execution engine requests.
engine-parallelism = 1
# Size of chunks to split larger payloads into when streamed via transport layer.
chunk-size = 1048576
# Number of new nodes to which try to gossip a new block.
relay-factor = 2
# Percentage (in between 0 and 100) of nodes required to have already seen a new block before stopping to try to gossip it to new nodes.
relay-saturation = 90
# Number of nodes to relay genesis approvals to.
approval-relay-factor = 10
# Time to wait between asking the bootstrap node for an updated list of genesis approvals.
approval-poll-interval = "30second"
# Time to cache live peers for and to ban unresponsive ones.
alive-peers-cache-expiration-period = "1minute"
# Maximum DAG depth to allow when syncing after a new block notification.
sync-max-possible-depth = 1000
# Minimum DAG size before we start checking the branching factor for abnormal growth.
sync-min-block-count-to-check-width = 100
# Maximum bonding rate per rank to allow during syncs before terminating the operation as malicious.
sync-max-bonding-rate = 1.0
# Maximum DAG depth to ask in iterative requests during syncing.
sync-max-depth-ancestors-request = 5
# Maximum number of parallel synchronizations to run at any time.
sync-max-parallel = 7
# Disable DAG shape validations during synchronization.
sync-disable-validations = true
# Maximum number of nodes to try to sync with initially in a round.
init-sync-max-nodes = 5
# Minimum number of successful initial syncs in a round to call it done.
init-sync-min-successful = 1
# Remember the selection of nodes to synchronize with initially, or pick a new set in each round.
init-sync-memoize-nodes = false
# Skip nodes which failed previous synchronization attempts or allow them to be tried again.
init-sync-skip-failed-nodes = false
# Depth of DAG slices (by rank) retrieved slice-by-slice until node fully synchronized.
init-sync-step = 100
# Time to wait between initial synchronization attempts.
init-sync-round-period = "1second"
# Maximum number of blocks to allow to be synced initially.
init-sync-max-block-count = 1000000
# Time to wait between periodic synchronization attempts.
periodic-sync-round-period = "60second"
# Maximum number of parallel block downloads initiated by the download manager.
download-max-parallel-blocks = 8
# Maximum number of parallel deploy downloads initiated by the download manager.
download-max-parallel-deploys = 2
# Maximum number of times to retry to download a block from the same node.
download-max-retries = 0
# Time to wait before trying to download a failed block again from the same node.
download-retry-initial-backoff-period = "5second"
# Exponential factor to apply on subsequent wait times before trying to download again.
download-retry-backoff-factor = 2.0
# Try downloading blocks without deploys in them first, fetching the missing deploys as a separate step.
download-partial-blocks = true
# How long to remember having recently downloaded an item.
download-cache-expiry = "1hour"
# Maximum number of parallel block downloads allowed to peers.
relay-max-parallel-blocks = 5
# Maximum time to allow a peer downloading a block to consume each chunk.
relay-block-chunk-consumer-timeout = "10second"
# Maximum number of blocks to try to validate at any time.
validate-max-parallel-blocks = 8
# Use this flag to clear the blockStorage and dagStorage
clean-block-storage = false
# Maximum number of block download requests per peer in period (see below),
# if 0 then rate limiting will be disabled.
block-upload-rate-max-requests = 0
# Time window to apply rate limiting (see above),
# if 0 then rate limiting will be disabled.
block-upload-rate-period = "0s"
# Maximum number of in-flight throttled block download requests per peer,
# if 0 then unlimited, if reached max size then peer will receive RESOURCE_EXHAUSTED response.
block-upload-rate-max-throttled = 0
# Size of the main thread pool.
main-threads = 50
# Size of the thread pool used to handle incoming requests.
ingress-threads = 60
# Size of the thread pool waiting for the database writer connection.
db-write-threads = 70
# Size of the thread pool waiting for a database reader connection.
db-read-threads = 75
# Number of database connections in the reader pool.
db-read-connections = 10
# Parallelism per CPU core.
parallelism-cpu-multiplier = 1.0
# Minimum parallelism.
min-parallelism = 8
# With deploy gossiping enabled, nodes will share deploys among each other as soon as they received them,
# and try to optimize block downloads by fetching missing deploys separately.
deploy-gossip-enabled = false
# io.casperlabs.node.configuration.Configuration.BlockStorage
[blockstorage]
# Maximum size of each of in-memory block/dag/justifications caches in bytes.
cache-max-size-bytes = 262144000
# How far to go to the past (by ranks) for caching neighborhood of looked up block
cache-neighborhood-before = 5
# How far to go to the future (by ranks) for caching neighborhood of looked up block
cache-neighborhood-after = 6
# How many records to pull from the DB in a chunk of a stream.
deploy-stream-chunk-size = 10
# How many records or rank ranges to pull from the DB in a chunk of a stream.
dag-stream-chunk-size = 10
# io.casperlabs.node.configuration.Configuration.GrpcServer
[grpc]
# Externally addressable hostname or IP of node on which gRPC service is running.
host = "localhost"
# Socket path used for internal gRPC API.
socket = "$HOME/.casperlabs/.casper-node.sock"
# Port used for external gRPC API, e.g. deployments.
port-external = 40401
# Port used for internal gRPC API, e.g. proposing blocks, diagnostics.
port-internal = 40402
# Whether to enable TLS encryption on the public facing gRPC interfaces (e.g. deployments).
use-tls = false
# io.casperlabs.comm.transport.Tls
[tls]
# Path to node's X.509 certificate file, that is being used for identification during intra-node gossiping.
# The Common Name in the certificate should be the same as the Keccak256 hash of the public key in it.
certificate = "$HOME/.casperlabs/node.certificate.pem"
# Path to node's unencrypted secp256r1 PKCS#8 private key file, that is being used for intra-node TLS communication.
key = "$HOME/.casperlabs/node.key.pem"
# X.509 certificate used for the public facing API, preferrably one signed by a root CA
# so that clients which can't implement custom SSL verificaton can use standard methods.
# The Common Name should match the host name where the node is exposed.
api-certificate = "$HOME/.casperlabs/api.certificate.pem"
# Private key to use with the public API certificate.
api-key = "$HOME/.casperlabs/api.key.pem"
# io.casperlabs.casper.CasperConf
[casper]
# base-64 or PEM encoding of the public key to use for signing a proposed blocks.
# Can be inferred from the private key for some signature algorithms.
# validator-public-key =
# Path to the base-64 or PEM encoded public key to use for signing a proposed blocks.
# Can be inferred from the private key for some signature algorithms.
# validator-public-key-path =
# base-64 or PEM encoding of the private key to use for signing a proposed blocks.
# It is not recommended to use in production since private key could be revealed through the process table.
# Use the `validator-private-key-path` instead.
# validator-private-key =
# Path to the base-64 or PEM encoded private key to use for signing a proposed blocks.
# validator-private-key-path =
# Name of the algorithm to use for signing proposed blocks.
# Currently supported values: ed25519.
validator-sig-algorithm = "ed25519"
# Path to plain text file listing the public keys of validators known to the user (one per line).
# Signatures from these validators are required in order to accept a block which starts the local
# node's view of the DAG.
# known-validators-file =
# Number of signatures from trusted validators required to creating an approved genesis block.
required-sigs = 0
# Path to the directory which contains the Chain Spec. If not specified, the default chainspec packaged with the node will be used.
# chain-spec-path = "$HOME/.casperlabs/chainspec"
# Start a stand-alone node (no bootstrapping).
standalone = false
# Enable auto-proposal of blocks.
auto-propose-enabled = false
# Time between proposal checks.
auto-propose-check-interval = "1second"
# Maximum time to allow before proposing a ballot or block.
auto-propose-ballot-interval = "36500days"
# Time to accumulate deploys before proposing.
auto-propose-acc-interval = "5seconds"
# Number of deploys to accumulate before proposing.
auto-propose-acc-count = 10
# Minimum TTL value of a deploy
min-ttl = "1hour"
# Override the value in the chainspec with a lower value; 0 means use whatever is in the chainspec.
max-block-cost = 0
# Highway parameters that we can freely choose or tweak; the rest is in the Genesis chain spec.
[highway]
# Use highway, or stick to NCB.
enabled = true
# Fraction of time through the round after which we can create an omega message.
omega-message-time-start = 0.5
# Fraction of time through the round before which we must have created the omega message.
omega-message-time-end = 0.75
# Enable the creating blocks instead of ballots as omega-messages.
omega-blocks-enabled = false
# Initial round exponent to start the node with, before auto-adjustment takes over; corresponds to the tick unit of the chain.
init-round-exponent = 14
# io.casperlabs.node.configuration.Configuration.Kamon
[metrics]
# Enable the Prometheus metrics reporter.
prometheus = false
# Enable the Zipkin span reporter.
zipkin = false
# Enable Sigar host system metrics.
sigar = false
# Enable Influx system metrics.
influx = false
# io.casperlabs.node.configuration.Configuration.Influx
[influx]
# Hostname or IP of the Influx instance.
# hostname = "0.0.0.0"
# Port of the Influx instance.
# port = 14
# Name of the database in Influx.
# database = "test"
# Protocol used in Influx.
# protocol = "https"
# Username for Influx database authentication.
# user = "user"
# Password for Influx database authentication.
# password = "password"