Skip to content

Exit policy #3785

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

Merged
merged 9 commits into from
Jul 12, 2022
Merged

Exit policy #3785

merged 9 commits into from
Jul 12, 2022

Conversation

coot
Copy link
Contributor

@coot coot commented Jun 1, 2022

Resolves #3779

@coot coot added networking outbound-governor Issues / PRs related to outbound-governor labels Jun 1, 2022
@coot coot force-pushed the coot/exit-policy branch from 8226b78 to 67e7294 Compare June 2, 2022 07:25
@coot coot marked this pull request as ready for review June 2, 2022 07:25
@coot coot requested review from nfrisby and dnadales as code owners June 2, 2022 07:25
@coot coot requested review from dcoutts, nfrisby and dnadales and removed request for dnadales and nfrisby June 2, 2022 07:25
@coot coot force-pushed the coot/exit-policy branch from 67e7294 to 41b4730 Compare June 2, 2022 09:35
Copy link
Contributor

@nfrisby nfrisby left a comment

Choose a reason for hiding this comment

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

I Approve the Consensus side of things, without actually clicking Approve since that's a relatively small part of this PR.

I have a few comments, but all minor.

@coot coot force-pushed the coot/exit-policy branch 3 times, most recently from c2b8be7 to 56742ea Compare June 3, 2022 19:47
@coot coot mentioned this pull request Jun 7, 2022
Copy link
Contributor

@bolt12 bolt12 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! Some small comments

@coot coot force-pushed the coot/exit-policy branch from 56742ea to 0916edb Compare July 4, 2022 16:10
coot added 9 commits July 5, 2022 13:42
By hiding `peerconn` we can simplify diffusion types.  This is required
if we want to add result type of protocols (on the initiator side).
ExitPolicy governs the delay for reconnecting either if any of the
mini-protocol exists cleanly or throws an exception.
When any of the mini-protocol exits (either with an error or otherwise),
we reactivation delay which is used by the outbound governor.  It is
expected that multiple mini-protocol exits roughly at the same time,
e.g.  in hot to warm transition `chain-sync`, `block-fetch` and
`tx-submission` will terminate around the same time.  For this reason
the `setActivateTimes` is taking the maximum of the existing connect time
and the new one, as well as the `ReconnectDelay` is an additive monoid.
The outbound governor needs to know the reconnection delay when
a connection errors (asynchronous demotion to cold peer).  We use the
`ExitPolicy` `epErrorDelay`, which is set to 10 seconds.   This patch
fixes a bunch of TODOs.
@coot coot force-pushed the coot/exit-policy branch from 0916edb to bf57a58 Compare July 5, 2022 12:07
@coot coot mentioned this pull request Jul 11, 2022
13 tasks
@coot
Copy link
Contributor Author

coot commented Jul 11, 2022

bors merge

iohk-bors bot added a commit that referenced this pull request Jul 11, 2022
3785: Exit policy r=coot a=coot

Resolves #3779 


Co-authored-by: Marcin Szamotulski <[email protected]>
@iohk-bors
Copy link
Contributor

iohk-bors bot commented Jul 11, 2022

Build failed:

@coot
Copy link
Contributor Author

coot commented Jul 12, 2022

bors merge

@iohk-bors
Copy link
Contributor

iohk-bors bot commented Jul 12, 2022

@iohk-bors iohk-bors bot merged commit e600042 into master Jul 12, 2022
@iohk-bors iohk-bors bot deleted the coot/exit-policy branch July 12, 2022 21:26
iohk-bors bot added a commit that referenced this pull request Jul 13, 2022
3893: Document flakiness of WallClock tests r=amesgen a=amesgen

# Description

Reported by `@coot` (found in #3785 (comment)), thanks!



Co-authored-by: Alexander Esgen <[email protected]>
iohk-bors bot added a commit that referenced this pull request Nov 9, 2022
4120: Cherry picked network changes for cardano-node-1.35.5 release r=coot a=coot

This cherry-picked patches from the following PRs:

* #3794
* #3844
* #3785
* #3904
* #3915
* #3852
* #3970
* #3979
* #4015
* #4067
* #4004
* #4086
* #4113
* #4106
* #4127
* #4103

Also cherry-picked almost all the commits which modify GitHub actions:
* 18c5244 Run GitHub Actions on pull requests   
* 3adf5a9 Use newer version of io-sim           
* ee9b7a6 Fix GH Actions Windows CI: switch from pkgconf to pkg-config 
* e6cf074 github-actions: use `ubuntu-latest`   
* 9a8b959 Updated versions of github actions    
* fc8f8f0 Fix GH Actions Windows CI caching     
* 7f07c40 Windows Github Actions now use MSYS2  
* b21a7ce Fix chocolatey CI error
* #4134               

TODO:

* [x] bump versions of packages
* [x] input-output-hk/cardano-haskell-packages#84

Co-authored-by: Mark Tullsen <[email protected]>
Co-authored-by: Marcin Szamotulski <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
outbound-governor Issues / PRs related to outbound-governor
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Exit policy for reconnection delay
4 participants