-
Notifications
You must be signed in to change notification settings - Fork 375
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
fix: operator downtime #1073
Merged
uri-99
merged 25 commits into
staging
from
962-fixoperator-aggregator-aggregator-or-operator-downtime-can-break-eventual-consistency
Oct 3, 2024
Merged
fix: operator downtime #1073
uri-99
merged 25 commits into
staging
from
962-fixoperator-aggregator-aggregator-or-operator-downtime-can-break-eventual-consistency
Oct 3, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oppen
reviewed
Sep 24, 2024
Oppen
reviewed
Sep 24, 2024
Oppen
reviewed
Sep 24, 2024
MarcosNicolau
commented
Sep 25, 2024
Oppen
reviewed
Sep 26, 2024
Oppen
reviewed
Sep 26, 2024
Oppen
reviewed
Sep 26, 2024
Oppen
approved these changes
Sep 26, 2024
uri-99
suggested changes
Oct 1, 2024
…BatchesWhileOffline
…operator-downtime-can-break-eventual-consistency
in order to read the latest assigned err, we need to create a closure
uri-99
suggested changes
Oct 2, 2024
Oppen
reviewed
Oct 2, 2024
Oppen
reviewed
Oct 2, 2024
Oppen
reviewed
Oct 2, 2024
Oppen
reviewed
Oct 2, 2024
Oppen
reviewed
Oct 2, 2024
uri-99
suggested changes
Oct 2, 2024
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.
final detail and i think its ready to approve
also add the new .json file to .gitignore to avoid having files with random variables being pushed to the repo |
…operator-downtime-can-break-eventual-consistency
uri-99
approved these changes
Oct 2, 2024
Oppen
reviewed
Oct 2, 2024
OK, seems to work here. |
…operator-downtime-can-break-eventual-consistency
PatStiles
pushed a commit
that referenced
this pull request
Oct 7, 2024
Co-authored-by: Urix <43704209+uri-99@users.noreply.github.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Changes
This pr adds a way to recover the operator's tasks from downtime. The way it works now is:
avs_reader
for all the tasks that have not been responded to starting from that block minus100
(this is to account for the case that a higher block number task finished first than a previous one, since batches can be processed in parallel). This is to be improved with an algorithm by @Oppen.A new check is also added to not send already responded blocks in the
avs_subscriber
'get_latest_task` interval. This problem happened at startup specially, it would always run the latest task doesn't matter how old it was.Test
To make sure everything works, we can run the following test: setup
make anvil_start_with_block
,make aggregator_start
,make batcher_start_local
1
:make operator_register_and_start
2
:make operator_register_and_start CONFIG_FILE=config-files/config-operator-1.yml
3
:make operator_register_and_start CONFIG_FILE=config-files/config-operator-2.yml
4
:make operator_register_and_start CONFIG_FILE=config-files/config-operator-3.yml
make batcher_send_plonk_bls12_381_burst
2
,3
and4
make batcher_send_risc0_burst
(it is better if you send many batches)2
and3
again:make operator_start CONFIG_FILE=config-files/config-operator-1.yml
make operator_start CONFIG_FILE=config-files/config-operator-2.yml
4
:make operator_start CONFIG_FILE=config-files/config-operator-3.yml
Deploy
Warning
This PR adds the following parameter to the operator configuration
last_processed_batch_filepath: '<>'
Advances on #962
Closes #978