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

[CDK-187]: Aggregator timeout issue #133

Merged
merged 4 commits into from
Apr 26, 2024

Conversation

goran-ethernal
Copy link
Collaborator

While trying to build and aggregate proofs, the aggregator has a for loop, where it waits for the syncronizer to sync up. That loop doesn't have a break point if the context provided by the prover communication channel is canceled, leaving it in the infinite loop state, since it constantly returns the context canceled error, and just tries to wait again and again.

This PR provides a fix which breakes the infinite loop if the context was canceled.

The main cause of this issue is the context which aggregator uses, which is the one provided by the prover communication channel. If the connection to the prover is lost (the context is canceled), we can end up in the situation where the old channel is still alive and in infinite loop trying to wait for the syncronizer by using the same context.

The fix breaks the loop, returns an error, which will eventually stop the old (closed channel), and the connection can be re-established again.

@goran-ethernal goran-ethernal added the bug Something isn't working label Apr 25, 2024
@goran-ethernal goran-ethernal self-assigned this Apr 25, 2024
@goran-ethernal goran-ethernal requested a review from a team as a code owner April 25, 2024 12:41
aggregator/aggregator.go Outdated Show resolved Hide resolved
aggregator/aggregator.go Outdated Show resolved Hide resolved
aggregator/aggregator.go Outdated Show resolved Hide resolved
@goran-ethernal goran-ethernal merged commit e74a227 into develop Apr 26, 2024
18 checks passed
@goran-ethernal goran-ethernal deleted the CDK-187-aggregator-timeout-issue branch April 26, 2024 14:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants