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

Simplify state management in summonerd #3225

Merged
merged 2 commits into from
Oct 25, 2023

Conversation

cronokirby
Copy link
Contributor

Closes #3221

@cronokirby cronokirby temporarily deployed to smoke-test October 25, 2023 02:30 — with GitHub Actions Inactive
@cronokirby cronokirby temporarily deployed to smoke-test October 25, 2023 02:31 — with GitHub Actions Inactive
@cronokirby
Copy link
Contributor Author

https://github.com/penumbra-zone/penumbra/actions/runs/6635035943 the full summoning smoke test passed successfully as well, but a careful review is still warranted imo

Comment on lines +53 to 56
self.storage.strike(&address).await?;
Ok(())
}
Ok(Err(e)) => Err(e),
Copy link
Member

Choose a reason for hiding this comment

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

Why do we want to bubble up an error here if contribute_inner fails? If a participant does something bad (e.g., submitting something that fails validation), won't this still crash the server?

use tonic::{Status, Streaming};

use crate::phase::Phase;

pub struct Participant {
address: Address,
rx: Streaming<pb::ParticipateRequest>,
rx: Mutex<Streaming<pb::ParticipateRequest>>,
Copy link
Member

Choose a reason for hiding this comment

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

I don't think we should be using a Mutex here, why are we sharing access to the participant's messages?

@hdevalence
Copy link
Member

The comments above are largely stylistic; I'm not sure that the new code structure is optimal, but I think it may be good enough for the purposes of our ceremony, so we could merge this and move forward.

@hdevalence hdevalence merged commit cee41ca into main Oct 25, 2023
9 checks passed
@hdevalence hdevalence deleted the summonerd-simplify-state-management branch October 25, 2023 18:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Summonerd shared state refactor
2 participants