-
Notifications
You must be signed in to change notification settings - Fork 102
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
feat(zebra-scan): Immediately scan newly verified blocks #7905
Comments
Hey team! Please add your planning poker estimate with Zenhub @arya2 @oxarbitrage @teor2345 @upbqdn |
This comment might be useful here: |
I have some suggestions for the scope of this ticket: Block Range Scanning & Scanning StrategyScanning arbitrary supplied block ranges should be split into another ticket, because it depends on the scanning strategy and scanner design. I think it would be helpful to write up a draft scanning strategy with the team and with ECC before we design and implement it. For now let's just scan new blocks in this ticket, then drop the results? That moves this part of the pseudocode to another ticket:
Block RetrievalThis pseudocode can be modified to split out the scanning strategy, and multiple receivers via a broadcast channel (#7906). Running this code in its own process is also out of scope for this project.
This code is part of one alternative design for ticket #7906, so we don't need to implement it here:
@arya2 did you want to open a ticket to cover the changes we discussed to
|
Do we need to create another issue for scanning the existing blockchain, i.e finalised blocks only? I feel like that should come before this |
Yes, there should be another ticket, I just made #7953. It's complicated to do both things in the same task, so they should be separate tickets, PRs, and tasks. Scanning new blocks is about the same complexity as scanning existing blocks:
But one of them should block the other, so we don't duplicate the scanning function work. |
@upbqdn for the MVP I suggest we do the simplest thing that works. Here's a simpler approach, feel free to cut it down:
|
Just a clarification here: outside the state there is no distinction between finalised blocks (the single chain of blocks on disk) and non-finalised blocks (blocks in memory in chain forks). So for the MVP I suggest we don't care either. The difference outside the state is between blocks that have already verified, and blocks that haven't been verified or downloaded yet. They need very different code, because one waits, and the other doesn't. |
This has been estimated as a "Large" or 8 points... We should consider splitting this issue up into smaller parts |
This does not need to be in the MVP, un-scheduling |
We won't be doing any more work on the scanner |
Motivation
This ticket is a performance improvement to the scanner task in zebra-scan. The scanner task's primary responsibility is to receive a block and scan it for keys stored in the database.
In #7953 we wait 10 seconds for the next block. If we await a change notification, we can scan that block as soon as it arrives.
Possible Design
To complete this task, we could:
Optional / Out-of-Scope
Pseudo-code brainstorm:
The text was updated successfully, but these errors were encountered: