Skip to content

Commit c8b68db

Browse files
Merge pull request #217 from vulcanize/feature/known-gaps
Feature/known gaps
2 parents 3045068 + d24a49e commit c8b68db

File tree

34 files changed

+686
-480
lines changed

34 files changed

+686
-480
lines changed

.github/workflows/on-master.yaml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
name: Docker Build and publish to Github
22

33
on:
4+
workflow_dispatch:
45
push:
56
branches:
67
- statediff

.gitignore

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,3 +49,11 @@ profile.cov
4949
**/yarn-error.log
5050
foundry/deployments/local-private-network/geth-linux-amd64
5151
foundry/projects/local-private-network/geth-linux-amd64
52+
53+
# Helpful repos
54+
related-repositories/foundry-test/**
55+
related-repositories/hive/**
56+
related-repositories/ipld-eth-db/**
57+
statediff/indexer/database/sql/statediffing_test_file.sql
58+
statediff/statediffing_test_file.sql
59+
statediff/known_gaps.sql

.gitmodules

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,4 @@
55
[submodule "evm-benchmarks"]
66
path = tests/evm-benchmarks
77
url = https://github.com/ipsilon/evm-benchmarks
8-
shallow = true
9-
[submodule "foundry/projects/local-private-network/Stateful/lib/ds-test"]
10-
path = foundry/projects/local-private-network/Stateful/lib/ds-test
11-
url = https://github.com/dapphub/ds-test
8+
shallow = true

cmd/geth/config.go

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -252,13 +252,14 @@ func makeFullNode(ctx *cli.Context) (*node.Node, ethapi.Backend) {
252252
}
253253
}
254254
p := statediff.Config{
255-
IndexerConfig: indexerConfig,
256-
ID: nodeID,
257-
ClientName: clientName,
258-
Context: context.Background(),
259-
EnableWriteLoop: ctx.GlobalBool(utils.StateDiffWritingFlag.Name),
260-
NumWorkers: ctx.GlobalUint(utils.StateDiffWorkersFlag.Name),
261-
WaitForSync: ctx.GlobalBool(utils.StateDiffWaitForSync.Name),
255+
IndexerConfig: indexerConfig,
256+
KnownGapsFilePath: ctx.GlobalString(utils.StateDiffKnownGapsFilePath.Name),
257+
ID: nodeID,
258+
ClientName: clientName,
259+
Context: context.Background(),
260+
EnableWriteLoop: ctx.GlobalBool(utils.StateDiffWritingFlag.Name),
261+
NumWorkers: ctx.GlobalUint(utils.StateDiffWorkersFlag.Name),
262+
WaitForSync: ctx.GlobalBool(utils.StateDiffWaitForSync.Name),
262263
}
263264
utils.RegisterStateDiffService(stack, eth, &cfg.Eth, p, backend)
264265
}

cmd/geth/main.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,7 @@ var (
176176
utils.StateDiffWritingFlag,
177177
utils.StateDiffWorkersFlag,
178178
utils.StateDiffFilePath,
179+
utils.StateDiffKnownGapsFilePath,
179180
utils.StateDiffWaitForSync,
180181
configFileFlag,
181182
}

cmd/geth/usage.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -246,6 +246,7 @@ var AppHelpFlagGroups = []flags.FlagGroup{
246246
utils.StateDiffWritingFlag,
247247
utils.StateDiffWorkersFlag,
248248
utils.StateDiffFilePath,
249+
utils.StateDiffKnownGapsFilePath,
249250
utils.StateDiffWaitForSync,
250251
},
251252
},

cmd/utils/flags.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -867,6 +867,11 @@ var (
867867
Name: "statediff.file.path",
868868
Usage: "Full path (including filename) to write statediff data out to when operating in file mode",
869869
}
870+
StateDiffKnownGapsFilePath = cli.StringFlag{
871+
Name: "statediff.knowngapsfile.path",
872+
Usage: "Full path (including filename) to write knownGaps statements when the DB is unavailable.",
873+
Value: "./known_gaps.sql",
874+
}
870875
StateDiffDBClientNameFlag = cli.StringFlag{
871876
Name: "statediff.db.clientname",
872877
Usage: "Client name to use when writing state diffs to database",

docker-compose.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
version: '3.2'
1+
version: "3.2"
22

33
services:
44
ipld-eth-db:
55
restart: always
6-
image: vulcanize/ipld-eth-db:v0.3.1
6+
image: vulcanize/ipld-eth-db:v3.2.0
77
environment:
88
POSTGRES_USER: "vdbm"
99
POSTGRES_DB: "vulcanize_testing_v3"

foundry/README.md

Lines changed: 0 additions & 59 deletions
This file was deleted.

foundry/projects/local-private-network/Dockerfile

Lines changed: 0 additions & 37 deletions
This file was deleted.

0 commit comments

Comments
 (0)