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

ChainSyncClient: respond to ControlMessageSTM #2531

Merged
merged 3 commits into from
Aug 21, 2020

Conversation

mrBliss
Copy link
Contributor

@mrBliss mrBliss commented Aug 21, 2020

Fixes #2528.

This allows us to later easily add arguments to an `App`, e.g.,
`NodeToClientVersion` or `ControlMessageSTM m`.
The control message isn't used yet.
@mrBliss mrBliss force-pushed the mrBliss/respond-to-control-message-stm branch from 6f63d9b to 85340b1 Compare August 21, 2020 10:34
@mrBliss mrBliss requested a review from coot August 21, 2020 10:34
@mrBliss mrBliss marked this pull request as ready for review August 21, 2020 10:34
@mrBliss mrBliss added the consensus issues related to ouroboros-consensus label Aug 21, 2020
@mrBliss
Copy link
Contributor Author

mrBliss commented Aug 21, 2020

@coot The ChainSync client is the only client developed by consensus. All other clients are in the network layer. We have some servers (in this folder https://github.com/input-output-hk/ouroboros-network/tree/master/ouroboros-consensus/src/Ouroboros/Consensus/MiniProtocol), but these protocols (ChainSync and BlockFetch) don't allow the server to gracefully terminate the connection.

@mrBliss mrBliss linked an issue Aug 21, 2020 that may be closed by this pull request
5 tasks
@mrBliss
Copy link
Contributor Author

mrBliss commented Aug 21, 2020

@coot CI fails because of a test failure (https://hydra.iohk.io/build/3901172/nixlog/1):

    bidirectional:                                             FAIL (1.09s)
      *** Failed! Exception: 'ExceptionInHandler 127.0.0.1:63956 MuxError (MuxIOException Network.Socket.recvBuf: resource vanished (Connection reset by peer)) "(recv errored)"' (after 54 tests):
      ClientAndServerData {responderAccumulatorFn = <fun>, hotResponderAccumulator = 2, warmResponderAccumulator = 52, establishedResponderAccumulator = 18, hotInitiatorRequests = [[-23,-69,14,84,-69,66,-96,89,-21,-76]], warmInitiatorRequests = [], establishedInitiatorRequests = [[81,-75,60],[50,-13,36,90,42,-13,44,89],[-90,37,13,-8,-69]]}
      ClientAndServerData {responderAccumulatorFn = <fun>, hotResponderAccumulator = 45, warmResponderAccumulator = 9, establishedResponderAccumulator = -23, hotInitiatorRequests = [[83,35,-53,-88,90,-7,21,26]], warmInitiatorRequests = [[-69],[]], establishedInitiatorRequests = [[10,-35,-39,48,60,44,98],[98,54,35,6,-56,43,-87],[-2,73,-30,66,-99,58]]}
      Use --quickcheck-replay=771777 to reproduce.

Copy link
Contributor

@coot coot left a comment

Choose a reason for hiding this comment

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

LGTM

@coot coot merged commit bbfc0b7 into coot/connection-manager Aug 21, 2020
@iohk-bors iohk-bors bot deleted the mrBliss/respond-to-control-message-stm branch August 21, 2020 11:22
iohk-bors bot added a commit that referenced this pull request Aug 28, 2020
2548: Port #2525 and #2531 to master r=mrBliss a=mrBliss

#2525 and #2531 were merged in the https://github.com/input-output-hk/ouroboros-network/tree/coot/connection-manager. However, that branch won't be merged for another few weeks. In the meantime, the merge conflicts with the changes made in those two PRs will accumulate. For example, I know that #2546 will cause a merge conflict.

Now that @coot has kindly merged #2541 (which those PRs depended on) in master, we can port #2525 and #2532 to master so we can avoid the upcoming merge conflicts. After this PR is merged, the `coot/connection-manager` branch should be rebased onto master.

Co-authored-by: Thomas Winant <thomas@well-typed.com>
Co-authored-by: Nicolas Frisby <nick.frisby@iohk.io>
@mrBliss mrBliss modified the milestone: S20 2020-08-27 Aug 28, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
consensus issues related to ouroboros-consensus
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Clients should respond to ControlMessage
2 participants