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

Announce supported schema ids in network before replication #515

Merged
merged 38 commits into from
Aug 25, 2023

Conversation

adzialocha
Copy link
Member

@adzialocha adzialocha commented Aug 20, 2023

This PR introduces our concept of "Announcements" (read more here: https://p2panda.org/specification/replication/#1-announcement).

There's a specification change involved: We need to give Announce messages their own message type. I've took 0 for them and changed the ones for SyncRequest, SyncDone and Entry as well. Related PR: p2panda/handbook#290

Closes #405

📋 Checklist

  • Add tests that cover your changes
  • Add this PR to the Unreleased section in CHANGELOG.md
  • Link this PR to any issues it closes
  • New files contain a SPDX license header

@codecov
Copy link

codecov bot commented Aug 20, 2023

Codecov Report

Patch coverage: 88.08% and project coverage change: -0.19% ⚠️

Comparison is base (bf77be8) 92.35% compared to head (5dda823) 92.16%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #515      +/-   ##
==========================================
- Coverage   92.35%   92.16%   -0.19%     
==========================================
  Files          99      101       +2     
  Lines       15801    16079     +278     
==========================================
+ Hits        14593    14820     +227     
- Misses       1208     1259      +51     
Files Changed Coverage Δ
aquadoggo/src/bus.rs 100.00% <ø> (ø)
aquadoggo/src/network/peers/handler.rs 73.07% <ø> (ø)
aquadoggo/src/network/peers/protocol.rs 100.00% <ø> (ø)
aquadoggo/src/network/service.rs 29.20% <0.00%> (+0.29%) ⬆️
aquadoggo/src/replication/errors.rs 50.00% <ø> (ø)
aquadoggo/src/replication/manager.rs 87.69% <ø> (ø)
aquadoggo/src/replication/ingest.rs 89.47% <14.28%> (-3.68%) ⬇️
aquadoggo/src/replication/service.rs 76.25% <77.77%> (-8.60%) ⬇️
aquadoggo/src/replication/message.rs 85.52% <93.33%> (+0.27%) ⬆️
aquadoggo/src/schema/schema_provider.rs 93.57% <94.73%> (-0.37%) ⬇️
... and 4 more

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@adzialocha adzialocha changed the title Target set announcements in network Announce supported schema ids in network before replication Aug 21, 2023
@adzialocha adzialocha marked this pull request as ready for review August 22, 2023 10:20
@adzialocha
Copy link
Member Author

adzialocha commented Aug 22, 2023

I don't feel like adding more tests to this, we have e2e tests checking against successful replication which still succeeded and I've extended our replication service "lifetime" test to deal with announcement messages. Think that should be sufficient?

Copy link
Member

@sandreae sandreae left a comment

Choose a reason for hiding this comment

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

I had a couple of comments, only about naming. Except for that, all looking really good!

aquadoggo/src/network/peers/behaviour.rs Show resolved Hide resolved
aquadoggo/src/replication/announcement.rs Outdated Show resolved Hide resolved
aquadoggo/src/replication/ingest.rs Show resolved Hide resolved
aquadoggo/src/schema/schema_provider.rs Show resolved Hide resolved
@sandreae sandreae changed the base branch from network-service-refactor to main August 23, 2023 17:06
@adzialocha adzialocha merged commit 0c208d4 into main Aug 25, 2023
8 checks passed
@adzialocha adzialocha deleted the announcements branch August 25, 2023 10:15
adzialocha added a commit that referenced this pull request Aug 25, 2023
* main:
  Announce supported schema ids in network before replication (#515)
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.

Announcement messages
2 participants