Skip to content

Commit

Permalink
ci(e2e): align snapshot period
Browse files Browse the repository at this point in the history
  • Loading branch information
corverroos committed Sep 19, 2024
1 parent f10c572 commit b9a1c7f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions e2e/app/geth/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ import (

// snapshotCacheMB increases the default snapshot cache size of 102MB.
// This is required to support SnapSync since it must overlap with cosmos which
// takes snapshots every 1000 blocks.
const snapshotCacheMB = 2 * 1024
// takes snapshots every 100 blocks.
const snapshotCacheMB = 1024

// WriteAllConfig writes all the geth config files for all omniEVMs.
func WriteAllConfig(testnet types.Testnet, genesis core.Genesis) error {
Expand Down
2 changes: 1 addition & 1 deletion halo/cmd/init.go
Original file line number Diff line number Diff line change
Expand Up @@ -390,7 +390,7 @@ func getTrustHeightAndHash(ctx context.Context, cl *rpchttp.HTTP) (int64, string
}

// Truncate height to last defaultSnapshotPeriod
const defaultSnapshotPeriod int64 = 1000
const defaultSnapshotPeriod int64 = 100
snapshotHeight := defaultSnapshotPeriod * (latest.Block.Height / defaultSnapshotPeriod)

if snapshotHeight == 0 {
Expand Down
2 changes: 1 addition & 1 deletion halo/config/config.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ const (
executionGenesisFile = "execution_genesis.json"

DefaultHomeDir = "./halo" // Defaults to "halo" in current directory
defaultSnapshotInterval = 100 // Roughly once an hour (given 3s blocks)
defaultSnapshotInterval = 100 // Can't be too large, must overlap with geth snapshotcache.
defaultSnapshotKeepRecent = 2
defaultMinRetainBlocks = 1 // Prune all blocks by default, Cosmsos will still respect other needs like snapshots

Expand Down

0 comments on commit b9a1c7f

Please sign in to comment.