Skip to content

Commit d68f960

Browse files
yihuangmmsqe
andauthored
Problem: node startup is slow (#779)
* Problem: archive node startup is slow Solution: - update cosmos-sdk to support lazy loading - support new config option `iavl-lazy-loading: true`. * enable lazy loading in integration test * Update CHANGELOG.md Signed-off-by: yihuang <huang@crypto.com> * fix test config * Update integration_tests/configs/cosmovisor.jsonnet Co-authored-by: mmsqe <tqd0800210105@gmail.com> Signed-off-by: yihuang <huang@crypto.com> * update to release branch * bump to v0.46.9-rc.0 --------- Signed-off-by: yihuang <huang@crypto.com> Co-authored-by: mmsqe <tqd0800210105@gmail.com>
1 parent 11ef44e commit d68f960

File tree

7 files changed

+15
-11
lines changed

7 files changed

+15
-11
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
### Improvements
2222

2323
- [#813](https://github.com/crypto-org-chain/cronos/pull/813) Tune up rocksdb options.
24+
- [#779](https://github.com/crypto-org-chain/cronos/pull/779) Add config iavl-lazy-loading to enable lazy loading of iavl store.
2425

2526
*Jan 04, 2023*
2627

go.mod

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ require (
66
cosmossdk.io/errors v1.0.0-beta.7
77
cosmossdk.io/math v1.0.0-beta.4
88
github.com/armon/go-metrics v0.4.1
9-
github.com/cosmos/cosmos-sdk v0.46.7
9+
github.com/cosmos/cosmos-sdk v0.46.9-rc.0
1010
github.com/cosmos/ibc-go/v5 v5.2.0
1111
github.com/ethereum/go-ethereum v1.10.26
1212
github.com/evmos/ethermint v0.6.1-0.20221101220534-a8ea4eceb6d9
@@ -61,7 +61,7 @@ require (
6161
github.com/cosmos/btcutil v1.0.5 // indirect
6262
github.com/cosmos/cosmos-proto v1.0.0-beta.1 // indirect
6363
github.com/cosmos/go-bip39 v1.0.0 // indirect
64-
github.com/cosmos/iavl v0.19.5-rc.1 // indirect
64+
github.com/cosmos/iavl v0.19.5 // indirect
6565
github.com/cosmos/ledger-cosmos-go v0.12.2 // indirect
6666
github.com/creachadair/taskgroup v0.3.2 // indirect
6767
github.com/danieljoos/wincred v1.1.2 // indirect
@@ -190,7 +190,7 @@ require (
190190
replace (
191191
// Ref: https://forum.cosmos.network/t/ibc-security-advisory-dragonberry/7702
192192
github.com/confio/ics23/go => github.com/confio/ics23/go v0.9.0
193-
github.com/cosmos/cosmos-sdk => github.com/cosmos/cosmos-sdk v0.46.9-0.20230130122755-5e7dcbcce1e9
193+
github.com/cosmos/cosmos-sdk => github.com/cosmos/cosmos-sdk v0.46.9-rc.0
194194
github.com/ethereum/go-ethereum => github.com/crypto-org-chain/go-ethereum v1.10.19-deepcopy-jumptable
195195
github.com/evmos/ethermint => github.com/crypto-org-chain/ethermint v0.20.2-cronos
196196

go.sum

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -220,13 +220,13 @@ github.com/cosmos/btcutil v1.0.5 h1:t+ZFcX77LpKtDBhjucvnOH8C2l2ioGsBNEQ3jef8xFk=
220220
github.com/cosmos/btcutil v1.0.5/go.mod h1:IyB7iuqZMJlthe2tkIFL33xPyzbFYP0XVdS8P5lUPis=
221221
github.com/cosmos/cosmos-proto v1.0.0-beta.1 h1:iDL5qh++NoXxG8hSy93FdYJut4XfgbShIocllGaXx/0=
222222
github.com/cosmos/cosmos-proto v1.0.0-beta.1/go.mod h1:8k2GNZghi5sDRFw/scPL8gMSowT1vDA+5ouxL8GjaUE=
223-
github.com/cosmos/cosmos-sdk v0.46.9-0.20230130122755-5e7dcbcce1e9 h1:hXrnTzoNjZzZpbymFimFwVuxwA83VkBmcmwsgjJ7p+w=
224-
github.com/cosmos/cosmos-sdk v0.46.9-0.20230130122755-5e7dcbcce1e9/go.mod h1:yjK6RtOTUm/bRJdRGka73Hh0Arl+4vwhsK6miJjvoX8=
223+
github.com/cosmos/cosmos-sdk v0.46.9-rc.0 h1:n5IaBWtkhteuurOzOzREm0dUXCNhZ3nHfhUjgGE2HOw=
224+
github.com/cosmos/cosmos-sdk v0.46.9-rc.0/go.mod h1:tAJbKEH0I+5JSMv0itvSO/pxYliYXNm7S5DEZmKbXpU=
225225
github.com/cosmos/go-bip39 v0.0.0-20180819234021-555e2067c45d/go.mod h1:tSxLoYXyBmiFeKpvmq4dzayMdCjCnu8uqmCysIGBT2Y=
226226
github.com/cosmos/go-bip39 v1.0.0 h1:pcomnQdrdH22njcAatO0yWojsUnCO3y2tNoV1cb6hHY=
227227
github.com/cosmos/go-bip39 v1.0.0/go.mod h1:RNJv0H/pOIVgxw6KS7QeX2a0Uo0aKUlfhZ4xuwvCdJw=
228-
github.com/cosmos/iavl v0.19.5-rc.1 h1:4PjF2PdScyPbN1WbXpiQU21YtyonnrMU31xN74g8Rkg=
229-
github.com/cosmos/iavl v0.19.5-rc.1/go.mod h1:X9PKD3J0iFxdmgNLa7b2LYWdsGd90ToV5cAONApkEPw=
228+
github.com/cosmos/iavl v0.19.5 h1:rGA3hOrgNxgRM5wYcSCxgQBap7fW82WZgY78V9po/iY=
229+
github.com/cosmos/iavl v0.19.5/go.mod h1:X9PKD3J0iFxdmgNLa7b2LYWdsGd90ToV5cAONApkEPw=
230230
github.com/cosmos/ibc-go/v5 v5.2.0 h1:LxwttRQqdUJpQ3/Gc3XPg5lkRo3pcbzx65dxFIY6ONE=
231231
github.com/cosmos/ibc-go/v5 v5.2.0/go.mod h1:MhDUMDVSboK5JW2pEWHNcw0wJHaHqKV/vwwP7awGhzI=
232232
github.com/cosmos/ledger-cosmos-go v0.12.2 h1:/XYaBlE2BJxtvpkHiBm97gFGSGmYGKunKyF3nNqAXZA=

gomod2nix.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -102,15 +102,15 @@ schema = 3
102102
version = "v1.0.0-beta.1"
103103
hash = "sha256-oATkuj+fM5eBn+ywO+w/tL0AFSIEkx0J3Yz+VhVe0QA="
104104
[mod."github.com/cosmos/cosmos-sdk"]
105-
version = "v0.46.9-0.20230130122755-5e7dcbcce1e9"
106-
hash = "sha256-Mh9MYorO+CoqBfEFPbNdPfz9Lebkdwg2KuSFJZOIFCE="
105+
version = "v0.46.9-rc.0"
106+
hash = "sha256-V/ghG07THSmbU6C1p/bAHnLnGuHdJafAChqfl4RMlHY="
107107
replaced = "github.com/cosmos/cosmos-sdk"
108108
[mod."github.com/cosmos/go-bip39"]
109109
version = "v1.0.0"
110110
hash = "sha256-Qm2aC2vaS8tjtMUbHmlBSagOSqbduEEDwc51qvQaBmA="
111111
[mod."github.com/cosmos/iavl"]
112-
version = "v0.19.5-rc.1"
113-
hash = "sha256-ArjdhXTJPT4RsOfZ/voQ+XWvMQou3IGTQ14QyHpNm4c="
112+
version = "v0.19.5"
113+
hash = "sha256-8PerCyxQrBCtr2zkhgriqauhCSoIe580dsYpZ44o+cE="
114114
[mod."github.com/cosmos/ibc-go/v5"]
115115
version = "v5.2.0"
116116
hash = "sha256-Gfqhdz9ZKEgb7LCkHiXCwYZYUYluQ+vMew/GkssfVj8="

integration_tests/configs/cosmovisor.jsonnet

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ config {
66
'minimum-gas-prices': '100000000000basetcro',
77
store:: super.store,
88
streamers:: super.streamers,
9+
'iavl-lazy-loading':: super['iavl-lazy-loading'],
910
},
1011
genesis+: {
1112
app_state+: {

integration_tests/configs/cosmovisor_gravity.jsonnet

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ config {
77
'minimum-gas-prices': '100000000000basetcro',
88
store:: super.store,
99
streamers:: super.streamers,
10+
'iavl-lazy-loading':: super['iavl-lazy-loading'],
1011
},
1112
genesis+: {
1213
app_state+: {

integration_tests/configs/default.jsonnet

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
'app-db-backend': 'rocksdb',
1313
'minimum-gas-prices': '0basetcro',
1414
'index-events': ['ethereum_tx.ethereumTxHash'],
15+
'iavl-lazy-loading': true,
1516
'json-rpc': {
1617
address: '0.0.0.0:{EVMRPC_PORT}',
1718
'ws-address': '0.0.0.0:{EVMRPC_PORT_WS}',

0 commit comments

Comments
 (0)