Skip to content

Commit

Permalink
Problem: new iavl indexes migration is slow and not optional (#714) (#…
Browse files Browse the repository at this point in the history
…720)

* Problem: new iavl indexes migration is slow and not optional

Closes: #712
Solution:
- Integrate the option introduced in cosmos-sdk

* Update CHANGELOG.md

Signed-off-by: yihuang <[email protected]>

Signed-off-by: yihuang <[email protected]>

Signed-off-by: yihuang <[email protected]>
  • Loading branch information
yihuang committed Sep 27, 2022
1 parent 7981ed1 commit d6457e8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

### Improvements

- [cronos#720](https://github.com/crypto-org-chain/cronos/pull/720) Add option `iavl-disable-fastnode` to disable iavl fastnode indexing migration (backport #714).
- [cronos#721](https://github.com/crypto-org-chain/cronos/pull/721) Integrate the file state streamer (backport #702).

*Sep 20, 2022*
Expand Down
6 changes: 2 additions & 4 deletions cmd/cronosd/cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -213,9 +213,6 @@ type appCreator struct {
encCfg params.EncodingConfig
}

// missing flag from cosmos-sdk
const flagIAVLCacheSize = "iavl-cache-size"

// newApp is an AppCreator
func (a appCreator) newApp(logger log.Logger, db dbm.DB, traceStore io.Writer, appOpts servertypes.AppOptions) servertypes.Application {
var cache sdk.MultiStorePersistentCache
Expand Down Expand Up @@ -271,7 +268,8 @@ func (a appCreator) newApp(logger log.Logger, db dbm.DB, traceStore io.Writer, a
baseapp.SetTrace(cast.ToBool(appOpts.Get(server.FlagTrace))),
baseapp.SetIndexEvents(cast.ToStringSlice(appOpts.Get(server.FlagIndexEvents))),
baseapp.SetSnapshot(snapshotStore, snapshotOptions),
baseapp.SetIAVLCacheSize(cast.ToInt(appOpts.Get(flagIAVLCacheSize))),
baseapp.SetIAVLCacheSize(cast.ToInt(appOpts.Get(server.FlagIAVLCacheSize))),
baseapp.SetIAVLDisableFastNode(cast.ToBool(appOpts.Get(server.FlagIAVLFastNode))),
)
}

Expand Down

0 comments on commit d6457e8

Please sign in to comment.