From 594b77e033ae2a4f5da9fdb7f9438e11511147b6 Mon Sep 17 00:00:00 2001 From: Diego Ximenes Date: Thu, 13 Jun 2024 13:24:20 -0300 Subject: [PATCH 1/2] Exposes CacheConfig.triedbConfig --- core/blockchain.go | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/core/blockchain.go b/core/blockchain.go index 98b5cbc55..1e4deb42e 100644 --- a/core/blockchain.go +++ b/core/blockchain.go @@ -158,6 +158,11 @@ type CacheConfig struct { SnapshotWait bool // Wait for snapshot construction on startup. TODO(karalabe): This is a dirty hack for testing, nuke it } +// arbitrum: exposing CacheConfig.triedbConfig to be used by Nitro when initializing arbos in database +func (c *CacheConfig) TriedbConfig() *trie.Config { + return c.triedbConfig() +} + // triedbConfig derives the configures for trie database. func (c *CacheConfig) triedbConfig() *trie.Config { config := &trie.Config{Preimages: c.Preimages} From dbf2a65e760e29712fe9d70051b34d1c558a7293 Mon Sep 17 00:00:00 2001 From: Diego Ximenes Date: Thu, 18 Jul 2024 16:02:59 -0300 Subject: [PATCH 2/2] Updates CacheConfig.TriedbConfig return type since CacheConfig.triedbConfig return type changed. --- core/blockchain.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/blockchain.go b/core/blockchain.go index e1b13a01e..8cf4d00d1 100644 --- a/core/blockchain.go +++ b/core/blockchain.go @@ -159,7 +159,7 @@ type CacheConfig struct { } // arbitrum: exposing CacheConfig.triedbConfig to be used by Nitro when initializing arbos in database -func (c *CacheConfig) TriedbConfig() *trie.Config { +func (c *CacheConfig) TriedbConfig() *triedb.Config { return c.triedbConfig() }