-
Notifications
You must be signed in to change notification settings - Fork 28
Conversation
09c8bad
to
a4ce1dd
Compare
Rebased against the updated |
20138bb
to
67c4957
Compare
67c4957
to
e32edfb
Compare
Codecov Report
@@ Coverage Diff @@
## master #416 +/- ##
==========================================
- Coverage 57.96% 57.54% -0.42%
==========================================
Files 63 65 +2
Lines 3007 3173 +166
==========================================
+ Hits 1743 1826 +83
- Misses 1264 1347 +83
Continue to review full report at Codecov.
|
7901c85
to
3d8db52
Compare
5af9e8f
to
9e44c78
Compare
9f8b95e
to
25424b9
Compare
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.
I still need some time to think about the "no rollback" implications for update_seed_dict
. But the rest looks really good to me 👍 I just left a few comments mostly about the doc, along with a bunch of questions.
/// | ||
/// Returns [`DeleteSumParticipant::Ok`] if field was deleted or | ||
/// [`DeleteSumParticipant::DoesNotExist`] if field does not exist. | ||
pub async fn remove_sum_dict_entry( |
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.
Do we actually need to remove participants?
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.
We remove the sum participant in the sum2 phase
https://github.com/xaynetwork/xaynet/pull/519/files#diff-5b85450e9124bca33ff393eee368f61fR187
My idea was to add this command to the incr_mask_count
method. However, we will then have the same issue that we have with the update_seed_dict
method. (the mask count would increase even if the sum particpant is not in the sum dict)
} | ||
|
||
/// Retrieves the [`SeedDict`] or an empty [`SeedDict`] when the [`SumDict`] does not exist. | ||
pub async fn get_seed_dict(mut self) -> RedisResult<SeedDict> { |
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.
Do we ever need to retrieve the full seed dict? I thought we only needed parts of it for each sum participant.
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.
Unfortunately yes, we broadcast the seed dict at the end of the update phase
https://github.com/xaynetwork/xaynet/pull/519/files#diff-b15272399ff491c84d93d4ca104eaab1R77
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.
Oh ok. With these changes though we shouldn't need to do so anymore. xaynet_server::services::fetchers::SeedDictService
should actually talk to redis directly. We should just send an event saying that a new dict is available. Same goes for the sum dictionary. But better address that in a follow-up PR.
Thanks for the review 🙂
I agree, maybe we should set up a meeting to discuss it |
0209c29
to
113fdf9
Compare
113fdf9
to
5f41ea9
Compare
Summary:
FromRedisValue
andToRedisArgs
for various crypto types, for theCoordinatorState
and for theMaskObject
redis::Client
(some methods might not be needed and will be removed after the integration into the state machine is done)