-
Notifications
You must be signed in to change notification settings - Fork 289
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
Adds simple indexing to qgb module #246
Adds simple indexing to qgb module #246
Conversation
Indexing by commitment is useful, but it might be even more useful to index by nonce instead, mainly because we wouldn't have to generate the commitment before querying. Specifically, I could see this being useful for both celestiaorg/blobstream-contracts#54 and #332 |
we can keep this the way it is now though, just something to think about |
What is a nonce for a data commitment message? |
We don't have a nonce yet for the data commitment, but we will need one once this is expected by the contracts, and will make slashing easier. Currently the mvp relayer just generates the nonce, but that's not ideal. edit: added an issue #248 . Definitely something we refactor later |
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 will speed up the mvp relayer queries significantly! thanks for this @sweexordious
two 👍 👍
* use index prefix for commitments query * adds test for indexed query * linter
Uses index prefix to query for commitments.
Adds to: #241
Currently, the keys are as follows:
celestia-app/x/qgb/types/keys.go
Line 111 in 8209e23