Skip to content
Snippets Groups Projects
  • Alexandru Vasile's avatar
    network-gossip: Ensure sync event is processed on unknown peer roles (#6553) · 7c9e34b5
    Alexandru Vasile authored
    
    The `GossipEngine::poll_next` implementation polls both the
    `notification_service` and the `sync_event_stream`.
    
    If both polls produce valid data to be processed
    (`Poll::Ready(Some(..))`), then the sync event is ignored when we
    receive `NotificationEvent::NotificationStreamOpened` and the role
    cannot be deduced.
    
    This PR ensures both events are processed gracefully. While at it, I
    have added a warning to the sync engine related to
    `notification_service` producing `Poll::Ready(None)`.
    
    This effectively ensures that `SyncEvents` propagate to the network
    potentially fixing any state mismatch.
    
    
    For more context: https://github.com/paritytech/polkadot-sdk/issues/6507
    
    cc @paritytech/sdk-node
    
    ---------
    
    Signed-off-by: default avatarAlexandru Vasile <alexandru.vasile@parity.io>
    Unverified
    7c9e34b5
Code owners
Assign users and groups as approvers for specific file changes. Learn more.