Skip to content

Commit

Permalink
chore(confix): update v2 config (#21956)
Browse files Browse the repository at this point in the history
Co-authored-by: Akhil Kumar P <[email protected]>
  • Loading branch information
julienrbrt and akhilkumarpilli authored Sep 27, 2024
1 parent 0d9b416 commit 9d631d3
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 13 deletions.
8 changes: 1 addition & 7 deletions tools/confix/data/v0.52-app.toml
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ index-events = []
# IavlCacheSize set the size of the iavl tree cache (in number of nodes).
iavl-cache-size = 781250

# IAVLDisableFastNode enables or disables the fast node feature of IAVL.
# IAVLDisableFastNode enables or disables the fast node feature of IAVL.
# Default is false.
iavl-disable-fastnode = false

Expand Down Expand Up @@ -223,9 +223,3 @@ stop-node-on-err = true
# Note, this configuration only applies to SDK built-in app-side mempool
# implementations.
max-txs = -1

[custom]

# That field will be parsed by server.InterceptConfigsPreRunHandler and held by viper.
# Do not forget to add quotes around the value if it is a string.
custom-field = "anything"
43 changes: 37 additions & 6 deletions tools/confix/data/v2-app.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,11 @@ trace = false
# standalone starts the application without the CometBFT node. The node should be started separately.
standalone = false

# mempool defines the configuration for the SDK built-in app-side mempool implementations.
[comet.mempool]
# max-txs defines the maximum number of transactions that can be in the mempool. A value of 0 indicates an unbounded mempool, a negative value disables the app-side mempool.
max-txs = -1

[grpc]
# Enable defines if the gRPC server should be enabled.
enable = true
Expand All @@ -37,27 +42,53 @@ minimum-gas-prices = '0stake'
app-db-backend = 'goleveldb'

[store.options]
# State storage database type. Currently we support: 0 for SQLite, 1 for Pebble
ss-type = 0
# State commitment database type. Currently we support:0 for iavl, 1 for iavl v2
sc-type = 0
# SState storage database type. Currently we support: "sqlite", "pebble" and "rocksdb"
ss-type = 'sqlite'
# State commitment database type. Currently we support: "iavl" and "iavl-v2"
sc-type = 'iavl'

# Pruning options for state storage
[store.options.ss-pruning-option]
# Number of recent heights to keep on disk.
keep-recent = 2
# Height interval at which pruned heights are removed from disk.
interval = 1
interval = 100

# Pruning options for state commitment
[store.options.sc-pruning-option]
# Number of recent heights to keep on disk.
keep-recent = 2
# Height interval at which pruned heights are removed from disk.
interval = 1
interval = 100

[store.options.iavl-config]
# CacheSize set the size of the iavl tree cache.
cache-size = 100000
# If true, the tree will work like no fast storage and always not upgrade fast storage.
skip-fast-storage-upgrade = true

[telemetry]
# Enable enables the application telemetry functionality. When enabled, an in-memory sink is also enabled by default. Operators may also enabled other sinks such as Prometheus.
enable = true
# Address defines the metrics server address to bind to.
address = 'localhost:1338'
# Prefixed with keys to separate services.
service-name = ''
# Enable prefixing gauge values with hostname.
enable-hostname = false
# Enable adding hostname to labels.
enable-hostname-label = false
# Enable adding service to labels.
enable-service-label = false
# PrometheusRetentionTime, when positive, enables a Prometheus metrics sink. It defines the retention duration in seconds.
prometheus-retention-time = 0
# GlobalLabels defines a global set of name/value label tuples applied to all metrics emitted using the wrapper functions defined in telemetry package.
# Example:
# [["chain_id", "cosmoshub-1"]]
global-labels = []
# MetricsSink defines the type of metrics backend to use. Default is in memory
metrics-sink = ''
# StatsdAddr defines the address of a statsd server to send metrics to. Only utilized if MetricsSink is set to "statsd" or "dogstatsd".
stats-addr = ''
# DatadogHostname defines the hostname to use when emitting metrics to Datadog. Only utilized if MetricsSink is set to "dogstatsd".
data-dog-hostname = ''
2 changes: 2 additions & 0 deletions tools/confix/migrations.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,8 @@ var v2KeyChanges = v2KeyChangesMap{
},
"iavl-cache-size": []string{"store.options.iavl-config.cache-size"},
"iavl-disable-fastnode": []string{"store.options.iavl-config.skip-fast-storage-upgrade"},
"telemetry.enabled": []string{"telemetry.enable"},
"mempool.max-txs": []string{"comet.mempool.max-txs"},
// Add other key mappings as needed
}

Expand Down

0 comments on commit 9d631d3

Please sign in to comment.