forked from cerc-io/ipld-eth-server
Extract storage diff fetching behind an interface
- Replaces directly reading from a CSV - Simplifies testing - Should hopefully make it easier to plug in other sources for storage diffs (e.g. differently formatted CSVs, JSON RPC, etc)
This commit is contained in:
@@ -37,7 +37,7 @@ type EventWatcher struct {
|
||||
Transformers []transformer.EventTransformer
|
||||
BlockChain core.BlockChain
|
||||
DB *postgres.DB
|
||||
Fetcher fetcher.LogFetcher
|
||||
Fetcher fetcher.ILogFetcher
|
||||
Chunker chunker.Chunker
|
||||
Addresses []common.Address
|
||||
Topics []common.Hash
|
||||
@@ -47,7 +47,7 @@ type EventWatcher struct {
|
||||
|
||||
func NewEventWatcher(db *postgres.DB, bc core.BlockChain) EventWatcher {
|
||||
logChunker := chunker.NewLogChunker()
|
||||
logFetcher := fetcher.NewFetcher(bc)
|
||||
logFetcher := fetcher.NewLogFetcher(bc)
|
||||
transactionSyncer := transactions.NewTransactionsSyncer(db, bc)
|
||||
return EventWatcher{
|
||||
BlockChain: bc,
|
||||
|
||||
Reference in New Issue
Block a user