-
Notifications
You must be signed in to change notification settings - Fork 500
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
services/horizon: Use COPY to speed up ClaimableBalanceChangeProcessor #5104
services/horizon: Use COPY to speed up ClaimableBalanceChangeProcessor #5104
Conversation
Since we'll be updating all change processors to use This solution works, but I am not sure about the design. Here are some other ideas I had:
|
adfd61f
to
cb51c0e
Compare
services/horizon/internal/ingest/processors/claimable_balances_change_processor.go
Outdated
Show resolved
Hide resolved
services/horizon/internal/ingest/processors/claimable_balances_change_processor.go
Outdated
Show resolved
Hide resolved
services/horizon/internal/db2/history/claimable_balance_batch_insert_builder.go
Outdated
Show resolved
Hide resolved
services/horizon/internal/db2/history/claimable_balance_claimant_batch_insert_builder.go
Outdated
Show resolved
Hide resolved
services/horizon/internal/ingest/processors/claimable_balances_change_processor.go
Outdated
Show resolved
Hide resolved
services/horizon/internal/db2/history/claimable_balance_batch_insert_builder.go
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice work, left comments for consideration on two ongoing threads related to builder interface design choices for Exec()
and Reset()
.
services/horizon/internal/db2/history/claimable_balance_batch_insert_builder.go
Outdated
Show resolved
Hide resolved
services/horizon/internal/db2/history/claimable_balance_claimant_batch_insert_builder.go
Outdated
Show resolved
Hide resolved
services/horizon/internal/ingest/processors/claimable_balances_change_processor.go
Outdated
Show resolved
Hide resolved
fe775dd
to
824caf1
Compare
services/horizon/internal/ingest/processors/claimable_balances_change_processor_test.go
Outdated
Show resolved
Hide resolved
services/horizon/internal/ingest/processors/claimable_balances_change_processor_test.go
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
there are a few lint warnings about unused fields / variables. But once those are fixed, we should be good to merge!
40a230b
to
2defa45
Compare
…s and claimable_balance_claimants tables
2defa45
to
527172d
Compare
PR Checklist
PR Structure
otherwise).
services/friendbot
, orall
ordoc
if the changes are broad or impact manypackages.
Thoroughness
.md
files, etc... affected by this change). Take a look in the
docs
folder for a given service,like this one.
Release planning
needed with deprecations, added features, breaking changes, and DB schema changes.
semver, or if it's mainly a patch change. The PR is targeted at the next
release branch if it's not a patch change.
What
Use FastBatchInsertBuilder for writing to claimable_balances and claimable_balance_claimants tables. FastBatchInsertBuilder uses ‘COPY' to insert into the db which is faster than using 'INSERT'.
Why
#5086
Known limitations
N/A