-
Notifications
You must be signed in to change notification settings - Fork 270
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
add bank hash to frozen slot update #3881
base: master
Are you sure you want to change the base?
add bank hash to frozen slot update #3881
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.
This lgtm. The bank is expected to be frozen at this point, so we know we'll get a valid hash from the hash()
method.
Cool, we (Overclock) need this as well for the mithril project. Since the current RPC interface does not expose bankhashes, we've been using our own getBankHash method that we hacked into a test validator, so we'd love to see these changes land sooner rather than later. Thanks for this PR @diman-io. |
Just a kind reminder |
I'm only just glancing at this PR, but is this change safe to make ? Assuming this lands in |
Hi @diman-io - I'm also curious what the use-case is for this; can you elaborate ? Ie, what do you need the bank hashes for ? |
Yes you're right, a client subscribed to the wrong RPC API version would break. I figured clients should use an API version compatible with the server they're subscribed to, but we definitely shouldn't break the API on a minor bump. I guess that leaves two options:
Wdyt? |
for a validator sidecar to filter transactions (I use my own, but the same can be done on jito relayer / anza vortexor / etc ) |
Actually, I did some research after the initial question. However, I still haven’t come to any straightforward solution. I would prefer the new method option with parameters. It provides scalability, and transaction statistics can be included there as well (not as an excluded option, which can be handled with the option option):
|
How does the bank hash come into play for filtering transactions ?
|
I'd just like to add that we also need bank hashes for mithril, which is a project funded by a Solana Foundation grant, so we (Overclock) support the usefulness of these changes and/or any other RPC method that lets you retrieve bankhashes. |
I have some ideas but can you confirm what your desired use-case / workflow is for wanting bank hashes ? |
fixed while hanging my head in shame... Of course, I meant the last blockhash. Now I’m extracting them from the sysvar |
No worries! And I guess you can't use |
Problem
There is no easy way to get bank hashes as fast as possible
Summary of Changes
Added bank hash for frozen slot update