-
Notifications
You must be signed in to change notification settings - Fork 55
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
bitcoin finality request+query efficiency #346
Conversation
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.
Since this is a band aid i don't think this makes it worse :-)
64912ff
to
eef7536
Compare
database/bfgd/postgres/postgres.go
Outdated
SELECT` + | ||
// DISTINCT ON returns the first result for each unique l2 block number | ||
` | ||
DISTINCT ON (l2_block_number) |
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.
this is still a bit inefficient
I have to give this a bit more thought; don't merge quite yet |
fa48c63
to
fba541c
Compare
* make "recent finalities" call "finalities by keystone" with recent keystones * remove expensive joins, prefer additional (fast) queries
32f5e53
to
32ebf8e
Compare
still doing some testing before merge 🧑💻 |
after some discussion with @max-sanchez , going with a different approach here. the functionality will be quite different and require new reviews. |
Summary
Changes
see summary