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 tracked_sessions field to consensus service #3155

Merged
merged 6 commits into from
Mar 3, 2023

Conversation

NotGyro
Copy link
Contributor

@NotGyro NotGyro commented Feb 22, 2023

Adds a tracked_sessions field to consensus service and a _tracked_sessions field to the client API service in consensus, as well as a ClientSessionTracking struct, to fill with tracked session information, which is a stub at present.

Motivation

Some way of keeping track of how many failed tx proposals have been sent recently needs to be available, so that bad connections can be dropped, to prevent attacks and harmful behavior from buggy clients. See: #2977

Future Work

The rest of #2977, as in:

  • Populate the client session tracking structure with metadata about incoming sessions
  • Keep track of how many recent failed tx proposals have been made by each client
  • Drop clients which have made too many failed tx proposals in too short of a span of time.

@github-actions
Copy link

❌ Heads up, I tried building full-service using this branch and it failed.
Build logs can be found by inspecting the github action run Check that repositories submoduling us will still build after this PR / full-service or by clicking here.

@jcape jcape requested review from a team, jcape and varsha888 and removed request for remoun, cbeck88, jcape and a team February 22, 2023 09:48
@github-actions
Copy link

✅ Good job, full-service was built successfully.
Build logs can be found by inspecting the github action run Check that repositories submoduling us will still build after this PR / full-service or by clicking here.

@jcape jcape self-requested a review February 22, 2023 17:54
@jcape
Copy link
Contributor

jcape commented Feb 22, 2023

There are still clippy lints that need to be fixed.

@NotGyro
Copy link
Contributor Author

NotGyro commented Feb 23, 2023

@NotGyro NotGyro added the consensus Related only to the consensus protocol or service label Feb 24, 2023
@NotGyro NotGyro requested a review from varsha888 March 2, 2023 18:50
@github-actions
Copy link

github-actions bot commented Mar 2, 2023

❌ Heads up, I tried building full-service using this branch and it failed.
Build logs can be found by inspecting the github action run Check that repositories submoduling us will still build after this PR / full-service or by clicking here.

@NotGyro NotGyro force-pushed the milliec/consensus-session-field branch from 39fe366 to 001ba38 Compare March 2, 2023 19:24
@github-actions
Copy link

github-actions bot commented Mar 2, 2023

❌ Heads up, I tried building full-service using this branch and it failed.
Build logs can be found by inspecting the github action run Check that repositories submoduling us will still build after this PR / full-service or by clicking here.

@NotGyro NotGyro force-pushed the milliec/consensus-session-field branch from 001ba38 to 4e23c5f Compare March 2, 2023 23:42
@NotGyro NotGyro merged commit 49fcd42 into master Mar 3, 2023
@NotGyro NotGyro deleted the milliec/consensus-session-field branch March 3, 2023 22:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
consensus Related only to the consensus protocol or service
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

None yet

3 participants