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

Add deduplication layer to deduplicate shuffle messages #308

Merged
merged 4 commits into from
Apr 21, 2023
Merged

Add deduplication layer to deduplicate shuffle messages #308

merged 4 commits into from
Apr 21, 2023

Conversation

tillrohrmann
Copy link
Contributor

This PR introduces the DeduplicatingStateMachine to deduplicate messages coming from shuffle components. This is important because the shuffle components might resend persisted messages on a restart even though they have already been received (e.g. if the truncation has not happened yet before the restart).

This fixes #147.

@tillrohrmann
Copy link
Contributor Author

Once this PR is merged, we should be able to re-enable the persistence e2e tests again.

Copy link
Contributor

@slinkydeveloper slinkydeveloper left a comment

Choose a reason for hiding this comment

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

Looks good overall, I have some comments related to style and type modelling, mostly related to me trying to understand the PR :)

src/worker/src/partition/effects/mod.rs Outdated Show resolved Hide resolved
src/worker/src/partition/dedup.rs Outdated Show resolved Hide resolved
src/worker/src/partition/ack.rs Show resolved Hide resolved
src/worker/src/partition/dedup.rs Outdated Show resolved Hide resolved
src/common/src/types.rs Show resolved Hide resolved
src/worker/src/partition/shuffle.rs Show resolved Hide resolved
src/worker/src/partition/ack.rs Outdated Show resolved Hide resolved
This commits extends the DedupLayer to deduplicate messages coming
from other shuffle components. This is important because the shuffle
components might resend persisted messages on a restart even though
they have already been received (e.g. if the truncation has not happened
yet before the restart).

This fixes #147.

Rename DedupLayer into DeduplicatingStateMachine and move under state_machine module
@tillrohrmann tillrohrmann merged commit fb0c16d into restatedev:main Apr 21, 2023
@tillrohrmann tillrohrmann deleted the issue#147 branch April 21, 2023 19:37
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.

Let partition processor handle duplicate messages
2 participants