1. Jan 15, 2021
    • Fedor Sakharov's avatar
      Availability recovery subsystem (#2122) · 90a68626
      Fedor Sakharov authored
      * Adds message types
      
      * Add code skeleton
      
      * Adds subsystem code.
      
      * Adds a first test
      
      * Adds interaction result to availability_lru
      
      * Use LruCache instead of a HashMap
      
      * Whitespaces to tabs
      
      * Do not ignore errors
      
      * Change error type
      
      * Add a timeout to chunk requests
      
      * Add custom errors and log them
      
      * Adds replace_availability_recovery method
      
      * recovery_threshold computed by erasure crate
      
      * change core to std
      
      * adds docs to error type
      
      * Adds a test for invalid reconstruction
      
      * refactors interaction run into multiple methods
      
      * Cleanup AwaitedChunks
      
      * Even more fixes
      
      * Test that recovery with wrong root is an error
      
      * Break to launch another requests
      
      * Styling fixes
      
      * Add SessionIndex to API
      
      * Proper relay parents for MakeRequest
      
      * Remove validator_discovery and use message
      
      * Remove a stream on exhaustion
      
      * On cleanup free the request streams
      
      * Fix merge and refactor
      90a68626
  2. Jan 14, 2021
  3. Jan 13, 2021
    • asynchronous rob's avatar
      scheduler: handle re-scheduling around finalization correctly (#2257) · 3465c18b
      asynchronous rob authored
      
      
      * scheduler: handle re-scheduling around finalization correctly
      
      * also make sure parathreads get cleaned
      
      * run scheduling in finalization
      
      * Remove stray println!
      
      * Update the schedule call site in inclusion inherent
      
      * Clarify subtlety around SessionStartBlock
      
      * Remove double semi-colon
      
      * reschedule prior to `availability_cores` and in on-initialize
      
      * improve docs
      
      * fix line
      
      * more doc reformat
      
      * remove unneeded call
      
      * avoid unnecessary scheduling on initialize
      
      * split `clear` and `schedule
      
      * Update runtime/parachains/src/scheduler.rs
      
      Co-authored-by: default avatarSergei Shulepov <[email protected]>
      
      Co-authored-by: default avatarSergei Shulepov <[email protected]>
      3465c18b
    • Bernhard Schuster's avatar
      display errors with their sources (#2264) · 1d28f59e
      Bernhard Schuster authored
      * update futures to 0.3.9
      
      * companion changes for generic error types
      
      * improve errors, keep error sources
      
      * command compile fix
      
      * use the correct Error type, add annotation
      
      * avoid async { fut.await.map_err(E::Variant) } with TryFuture
      
      * fix cargo lock, bump futures to 0.3.10
      
      futures 0.3.9 got yanked
      
      * chore cargo update -p sp-io
      
      * minor quirk
      
      * make rustc 1.48 happy by bouning the error more tightly
      
      * be more explicit
      
      * cargo lock futures
      1d28f59e
    • Sergey Pepyakin's avatar
      ff341a7b
    • ordian's avatar
      Companion for substrate#7892 (#2262) · e1773be6
      ordian authored
      * session_info: use correct authorities set
      
      * bump rococo spec_version to 19
      
      * "Update Substrate"
      
      Co-authored-by: parity-processbot <>
      e1773be6
    • Bernhard Schuster's avatar
      metered mpsc channels (#2235) · d7adf8f2
      Bernhard Schuster authored
      d7adf8f2
    • Sergey Pepyakin's avatar
      HRMP channel deposits (#2225) · c644c39f
      Sergey Pepyakin authored
      * Drive by fixes
      
      The visibility modifiers are remnants of the previous structure where
      HRMP wasn't a standalone module, by rather a submodule of the router
      module.
      
      * Add Currency assoc type to Config
      
      This would allow us to reserve balance for deposits. This commit also
      integrates the HRMP module in rococo, test-runtime and mocks to use the
      balances pallet.
      
      * Fix a bug that doesn't increment the age
      
      In case the request is not confirmed, the age would be incremented but
      not persisted.
      
      * Fix cleaning the indexes
      
      Before that change, the cleaning of the channel indexes was wrong, because it
      naively removed entire rows that was pertaining to the para we delete.
      This approach is flawed because it doesn't account for the rows that are
      pertaining to other paras that contain the outgoing one.
      
      This clearly violates the invariant imposed on the indexes, that all
      the index rows must contain alive paras, but apart from that it also
      lead to the situation where ingress index would contain the a different
      set of channels that an egress have.
      
      * Reserve currency for opening the channels
      
      Note the ugly `unique_saturated_into` calls. The reason for them is the
      currency trait accepts and defines the `Balance` associated type and the
      deposit values are coming from the `HostConfiguration` where they are
      defined using the `Balance`.
      
      I figured that parameterising `HostConfiguration` would be annoying. On
      the other hand, I don't expect these `unique_saturated_into` calls to
      give us problems since it seems to be a reasonable assumption that this
      module will be instantiated within a runtime where the Currency provided
      will have a Balance that matches the one used in the configuration.
      
      * Tests: Adapt `run_to_block` so that it submits a proper config
      
      * Tests: exercise the deposit logic
      c644c39f
    • Sergey Pepyakin's avatar
      Avoid inlining `update_config_member` (#2246) · eae961ee
      Sergey Pepyakin authored
      Closes #2241
      eae961ee
  4. Jan 12, 2021
  5. Jan 11, 2021
  6. Jan 08, 2021
    • asynchronous rob's avatar
      subsystems have an unbounded channel to the overseer (#2236) · 03e39cf5
      asynchronous rob authored
      
      
      * subsystems have an unbounded channel to the overseer
      
      * Update node/overseer/src/lib.rs
      
      Co-authored-by: default avatarBernhard Schuster <[email protected]>
      
      * bump Cargo.lock
      
      Co-authored-by: default avatarBernhard Schuster <[email protected]>
      03e39cf5
    • Bastian Köcher's avatar
      Do not send empty view updates to peers (#2233) · 475915ff
      Bastian Köcher authored
      
      
      * Do not send empty view updates to peers
      
      It happened that we send empty view updates to our peers, because we
      only updated our finalized block. This could lead to situations where we
      overwhelmed sub systems with too many messages. On Rococo this lead to
      constant restarts of our nodes, because some node apparently was
      finalizing a lot of blocks.
      
      To prevent this, the pr is doing the following:
      
      1. If a peer sends us an empty view, we report this peer and decrease it
      reputation.
      
      2. We ensure that we only send a view update when the `heads` changed
      and not only the `finalized_number`.
      
      3. We do not send empty `ActiveLeavesUpdates` from the overseer, as this
      makes no sense to send these empty updates. If some subsystem is relying
      on the finalized block, it needs to listen for the overseer signal.
      
      * Update node/network/bridge/src/lib.rs
      
      Co-authored-by: default avatarPeter Goodspeed-Niklaus <[email protected]>
      
      * Don't work if they're are no added heads
      
      * Fix test
      
      * Ahhh
      
      * More fixes
      
      Co-authored-by: default avatarPeter Goodspeed-Niklaus <[email protected]>
      475915ff
    • Fedor Sakharov's avatar
      Exit from av-store loop on fatal error. (#2232) · 8f293e18
      Fedor Sakharov authored
      * Fuse receive stream in Context
      
      * Revert "Fuse receive stream in Context"
      
      This reverts commit ddd26fa98f0ca1afbc22064e93010e4193a058b2.
      
      * Exit on node shutdown from av-store loop
      
      * Filter only context error
      8f293e18
  7. Jan 07, 2021
  8. Jan 06, 2021