-
Notifications
You must be signed in to change notification settings - Fork 4
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 account related txs and events #277
Conversation
c74b201
to
d387207
Compare
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.
Thanks Andy! I mostly only have stylistic suggestions, which should be easy to address. The only exception is the very last comment, on the structure of the accounts_related_events
table.
Regarding the open questions from the PR description:
I've been wanting to do the
Yeah I think we're OK. We could add a comment? In #281, I argue we don't even need the full list, because checking for a valid enum input is maybe more work than it's worth. My opinion would be different if Go had better supprot for enums, or of oapi-codegen supproted them better. But really I don't care very much either way; I'm fine with a different solution to the one I'm proposing.
My intuition is to go the other way; in fact, I think I recently renamed |
Agree with @mitjat on
I'm also okay with a comment.
I can go either way. Probably also defer to |
678bed3
to
02cbf69
Compare
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.
Looking good! Thank you!
…/transactions [db] add rel events/transactions for consensus [analyzer] index account-related events/txs [api] impl /consensus/events endpoint; rel param for /consensus/transactions [openapi] adjust event type nits remove obsolete Event enum in favor of autogenerated one [analyzer] store rel addresses in text[] col [api] update rel events/txs address comments oapi linter address comments
863090f
to
7e2af40
Compare
I compiled+tested this prior to rebasing onto the openapi generated type changes. It will need to be rebased again once the codegen follow-up changes are merged.
It might be useful to go commit by commit, but only for the first 4 commits.
Open questions:
ConsensusEvents
but consensus transactionsTransaction
, which seems inconsistent. I'm in favor of renaming toEvents
, but we could also renameTransaction
->ConsensusTransaction
Event
type the api types, but now that event types are autogenerated the mapping is separate from the ground truth. This could(?) drift, but it seems like this would be a rare occurence.block
fields ->height
. We discussed it at the last product design meeting of December and the follow up was to do some user research, but the general sentiment seemed to be thatheight
>>block
. I'll do this in a separate PR, but for now the new type introduced usesEvent.Height
.