Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Rework the event system of sc-network #14197

Open
wants to merge 50 commits into
base: master
Choose a base branch
from
Open

Commits on May 23, 2023

  1. Take notification configs

    altonen committed May 23, 2023
    Configuration menu
    Copy the full SHA
    cb99f5c View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    471616a View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    c456edd View commit details
    Browse the repository at this point in the history
  4. Introduce NotificationService

    altonen committed May 23, 2023
    Configuration menu
    Copy the full SHA
    5593a53 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    22cd46c View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    b42b901 View commit details
    Browse the repository at this point in the history
  7. Poll commands from protocols in Notifications

    Substream open/close functionality is not supported so they're left as
    `todo!()s`.
    
    Remove `SendNotification` command as sending notifications is now
    supported by using the installed notification sink received in
    `NotificationStreamOpened` event.
    altonen committed May 23, 2023
    Configuration menu
    Copy the full SHA
    9685625 View commit details
    Browse the repository at this point in the history
  8. Configuration menu
    Copy the full SHA
    b93cf90 View commit details
    Browse the repository at this point in the history
  9. Send NotificationEvents from Notifications

    The role should not be part of `NotificationStreamOpened` as
    `Notifications` has no knowledge of that and the protocols that are
    interested in that information should query it from `Peerset` (when the
    support for that is added)
    altonen committed May 23, 2023
    Configuration menu
    Copy the full SHA
    8cc85c6 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    f4f9090 View commit details
    Browse the repository at this point in the history
  11. Configuration menu
    Copy the full SHA
    796f826 View commit details
    Browse the repository at this point in the history
  12. Configuration menu
    Copy the full SHA
    00a093a View commit details
    Browse the repository at this point in the history
  13. Configuration menu
    Copy the full SHA
    a3746dc View commit details
    Browse the repository at this point in the history
  14. Configuration menu
    Copy the full SHA
    15d093b View commit details
    Browse the repository at this point in the history
  15. Configuration menu
    Copy the full SHA
    513ca87 View commit details
    Browse the repository at this point in the history
  16. Configuration menu
    Copy the full SHA
    2e9da9c View commit details
    Browse the repository at this point in the history
  17. Configuration menu
    Copy the full SHA
    1fd9a08 View commit details
    Browse the repository at this point in the history

Commits on May 25, 2023

  1. Configuration menu
    Copy the full SHA
    94e1e79 View commit details
    Browse the repository at this point in the history
  2. Apply suggestions from code review

    Co-authored-by: Dmitry Markin <[email protected]>
    altonen and dmitry-markin authored May 25, 2023
    Configuration menu
    Copy the full SHA
    b19ccb8 View commit details
    Browse the repository at this point in the history

Commits on May 26, 2023

  1. Configuration menu
    Copy the full SHA
    37db9f6 View commit details
    Browse the repository at this point in the history
  2. Apply review comments

    altonen committed May 26, 2023
    Configuration menu
    Copy the full SHA
    4e2ad89 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    3441cfa View commit details
    Browse the repository at this point in the history
  4. Apply suggestions from code review

    Co-authored-by: Dmitry Markin <[email protected]>
    altonen and dmitry-markin authored May 26, 2023
    Configuration menu
    Copy the full SHA
    182fdc7 View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    440402c View commit details
    Browse the repository at this point in the history
  6. Configuration menu
    Copy the full SHA
    96d2250 View commit details
    Browse the repository at this point in the history

Commits on Jun 5, 2023

  1. Configuration menu
    Copy the full SHA
    fd41d7d View commit details
    Browse the repository at this point in the history
  2. Rename Peerset functions

    altonen committed Jun 5, 2023
    Configuration menu
    Copy the full SHA
    ea56743 View commit details
    Browse the repository at this point in the history

Commits on Jun 6, 2023

  1. Add metrics

    altonen committed Jun 6, 2023
    Configuration menu
    Copy the full SHA
    1097738 View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    140b830 View commit details
    Browse the repository at this point in the history

Commits on Jun 14, 2023

  1. Introduce MessageSink

    The previous implementation of exposing `NotificationsSink` to the
    protocol was too leaky. Introduce new `MessageSink` abstraction which
    provides a clean send interface and internally handles notification sink
    replaces so the protocol doesn't have replace the sink when it's replaced.
    altonen committed Jun 14, 2023
    Configuration menu
    Copy the full SHA
    711761d View commit details
    Browse the repository at this point in the history

Commits on Jul 17, 2023

  1. Configuration menu
    Copy the full SHA
    294fd49 View commit details
    Browse the repository at this point in the history

Commits on Jul 24, 2023

  1. Configuration menu
    Copy the full SHA
    b9368f8 View commit details
    Browse the repository at this point in the history
  2. Minor fixes

    altonen committed Jul 24, 2023
    Configuration menu
    Copy the full SHA
    258fd5a View commit details
    Browse the repository at this point in the history

Commits on Jul 25, 2023

  1. Store peer role in PeerStore

    altonen committed Jul 25, 2023
    Configuration menu
    Copy the full SHA
    1132424 View commit details
    Browse the repository at this point in the history
  2. Don't return Result for send_sync_notification()

    The original API ignores the case where the peer doesn't exist
    altonen committed Jul 25, 2023
    Configuration menu
    Copy the full SHA
    4b02a3d View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    c3ff587 View commit details
    Browse the repository at this point in the history

Commits on Aug 3, 2023

  1. Fix metrics

    altonen committed Aug 3, 2023
    Configuration menu
    Copy the full SHA
    b8e2fcc View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    1b84a72 View commit details
    Browse the repository at this point in the history

Commits on Aug 4, 2023

  1. Rework peer role detection

    Previously the peer role was decoded in `Protocol` but now that the
    protocol is directly communicating with `Notifications`, the handshake
    decoding is no longer done on behalf of the protocol.
    
    Introduce a new function `NetworkPeers::peer_role()` which allows the
    protocol to fetch the peer role. The function takes the received
    handshake (which should contain the role) and in case the handshake
    doesn't contain the protocol, it's fetched from `PeerStore`.
    
    If the peer role cannot be determined, `None` is returned, indicating
    to the protocol that it should discard the peer.
    altonen committed Aug 4, 2023
    Configuration menu
    Copy the full SHA
    aad966a View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    295a6a7 View commit details
    Browse the repository at this point in the history

Commits on Aug 7, 2023

  1. Fix BEEFY test

    altonen committed Aug 7, 2023
    Configuration menu
    Copy the full SHA
    fe8eeed View commit details
    Browse the repository at this point in the history
  2. Remove dead code

    altonen committed Aug 7, 2023
    Configuration menu
    Copy the full SHA
    ccb3beb View commit details
    Browse the repository at this point in the history

Commits on Aug 8, 2023

  1. Configuration menu
    Copy the full SHA
    d38b53b View commit details
    Browse the repository at this point in the history

Commits on Aug 9, 2023

  1. Minor code cleanups

    altonen committed Aug 9, 2023
    Configuration menu
    Copy the full SHA
    a84000f View commit details
    Browse the repository at this point in the history
  2. Fix warnings

    altonen committed Aug 9, 2023
    Configuration menu
    Copy the full SHA
    92da646 View commit details
    Browse the repository at this point in the history

Commits on Aug 10, 2023

  1. Fix documentation

    altonen committed Aug 10, 2023
    Configuration menu
    Copy the full SHA
    18d948e View commit details
    Browse the repository at this point in the history
  2. Apply review comments

    altonen committed Aug 10, 2023
    Configuration menu
    Copy the full SHA
    b7c3b68 View commit details
    Browse the repository at this point in the history
  3. Fix documentation

    altonen committed Aug 10, 2023
    Configuration menu
    Copy the full SHA
    10bdc28 View commit details
    Browse the repository at this point in the history

Commits on Aug 11, 2023

  1. Apply suggestions from code review

    Co-authored-by: Dmitry Markin <[email protected]>
    altonen and dmitry-markin authored Aug 11, 2023
    Configuration menu
    Copy the full SHA
    e5e6af0 View commit details
    Browse the repository at this point in the history
  2. Apply review comments

    altonen committed Aug 11, 2023
    Configuration menu
    Copy the full SHA
    25c12b2 View commit details
    Browse the repository at this point in the history