Skip to content
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

change(rpc): Adds a TrustedChainSync struct for keeping up with Zebra's non-finalized best chain from a separate process #8589

Closed
wants to merge 12 commits into from

Conversation

arya2
Copy link
Contributor

@arya2 arya2 commented Jun 5, 2024

Motivation

This is an early draft for making the ReadStateService more usable from a separate process. This PR will likely go through large changes before it merges, there are still many TODOs left and it's missing tests.

Closes #8580.
Closes #8576.
Closes #8520.

PR Author Checklist

Check before marking the PR as ready for review:

  • Will the PR name make sense to users?
  • Does the PR have a priority label?
  • Have you added or updated tests?
  • Is the documentation up to date?
For significant changes:
  • Is there a summary in the CHANGELOG?
  • Can these changes be split into multiple PRs?

If a checkbox isn't relevant to the PR, mark it as done.

Solution

Adds a TrustedChainSync struct for getting non-finalized blocks from a Zebra RPC server and sending new blocks to the ChainTipSender to be usable by ChainTipChange in zebra-scan and elsewhere.

Testing

This PR still needs tests.

Review

Anyone can review, @oxarbitrage may be interested.

Reviewer Checklist

Check before approving the PR:

  • Does the PR scope match the ticket?
  • Are there enough tests to make sure it works? Do the tests cover the PR motivation?
  • Are all the PR blockers dealt with?
    PR blockers can be dealt with in new tickets or PRs.

And check the PR Author checklist is complete.

@arya2 arya2 added A-rpc Area: Remote Procedure Call interfaces A-state Area: State / database changes P-Medium ⚡ labels Jun 5, 2024
@arya2 arya2 self-assigned this Jun 5, 2024
@arya2 arya2 requested a review from oxarbitrage June 5, 2024 15:14
@arya2 arya2 changed the title Standalone read state svc change(rpc): Adds a TrustedChainSync struct for keeping up with Zebra's non-finalized best chain from a separate process Jun 5, 2024
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@oxarbitrage this file is probably the most ready for review and would benefit most from suggestions, other files would probably be easier to review after some clean up.

@arya2 arya2 closed this Jun 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-rpc Area: Remote Procedure Call interfaces A-state Area: State / database changes P-Medium ⚡
Projects
None yet
1 participant