Skip to content

Commit

Permalink
services/horizon: Add claimable_balances table to state tables to tru…
Browse files Browse the repository at this point in the history
…ncate (#3100)
  • Loading branch information
bartekn authored Oct 6, 2020
1 parent 107c536 commit 02dafc4
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions services/horizon/internal/db2/history/ingestion.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ func (q *Q) TruncateExpingestStateTables() error {
"accounts",
"accounts_data",
"accounts_signers",
"claimable_balances",
"exp_asset_stats",
"offers",
"trust_lines",
Expand Down
4 changes: 3 additions & 1 deletion services/horizon/internal/expingest/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,9 @@ const (
// - 10: Fixes a bug in meta processing (fees are now processed before
// everything else).
// - 11: Protocol 14: CAP-23 and CAP-33.
CurrentVersion = 11
// - 12: Trigger state rebuild due to `absTime` -> `abs_time` rename
// in ClaimableBalances predicates.
CurrentVersion = 12

// MaxDBConnections is the size of the postgres connection pool dedicated to Horizon ingestion:
// * Ledger ingestion,
Expand Down
2 changes: 1 addition & 1 deletion services/horizon/internal/expingest/verify.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ const assetStatsBatchSize = 500
// check them.
// There is a test that checks it, to fix it: update the actual `verifyState`
// method instead of just updating this value!
const stateVerifierExpectedIngestionVersion = 11
const stateVerifierExpectedIngestionVersion = 12

// verifyState is called as a go routine from pipeline post hook every 64
// ledgers. It checks if the state is correct. If another go routine is already
Expand Down

0 comments on commit 02dafc4

Please sign in to comment.