- 28 Mar, 2021 2 commits
-
-
asynchronous rob authored
* overseer: pass messages directly between subsystems * test that message is held on to * Update node/overseer/src/lib.rs Co-authored-by:
Peter Goodspeed-Niklaus <coriolinus@users.noreply.github.com> * give every subsystem an unbounded sender too * remove metered_channel::name 1. we don't provide good names 2. these names are never used anywhere * unused mut * remove unnecessary &mut * subsystem unbounded_send * remove unused MaybeTimer We have channel size metrics that serve the same purpose better now and the implementation of message timing was pretty ugly. * remove comment * split up senders and receivers * update metrics * fix tests * fix test subsystem context * fix flaky test * fix docs * doc * use select_biased to favor signals * Update node/subsystem/src/lib.rs Co-authored-by:
Andronik Ordian <write@reusable.software> Co-authored-by:
Peter Goodspeed-Niklaus <coriolinus@users.noreply.github.com> Co-authored-by:
Andronik Ordian <write@reusable.software>
-
Robert Klotzner authored
* Indentation fix. * Prepare request-response for PoV fetching. * Drop old PoV distribution. * WIP: Fetch PoV directly from backing. * Backing compiles. * Runtime access and connection management for PoV distribution. * Get rid of seemingly dead code. * Implement PoV fetching. Backing does not yet use it. * Don't send `ConnectToValidators` for empty list. * Even better - no need to check over and over again. * PoV fetching implemented. + Typechecks + Should work Missing: - Guide - Tests - Do fallback fetching in case fetching from seconding validator fails. * Check PoV hash upon reception. * Implement retry of PoV fetching in backing. * Avoid pointless validation spawning. * Add jaeger span to pov requesting. * Add back tracing. * Review remarks. * Whitespace. * Whitespace again. * Cleanup + fix tests. * Log to log target in overseer. * Fix more tests. * Don't fail if group cannot be found. * Simple test for PoV fetcher. * Handle missing group membership better. * Add test for retry functionality. * Fix flaky test. * Spaces again. * Guide updates. * Spaces.
-
- 26 Mar, 2021 2 commits
-
-
Robert Klotzner authored
* Those should really be trace. - Very spammy - And they in fact trace the execution - Should not be enabled lightly - will slow network bridge down. * Make report peers debug again.
-
asynchronous rob authored
* add number to `ActivatedLeavesUpdate` * update subsystem util and overseer * use new ActivatedLeaf everywhere * sort view * sorted and limited view in network bridge * use live block hash only if it's newer * grumples
-
- 25 Mar, 2021 1 commit
-
-
asynchronous rob authored
* add AvailableDataFetchingRequest * rename AvailabilityFetchingRequest to ChunkFetchingRequest * rename AvailabilityFetchingResponse to Chunk_ * add AvailableDataFetching request * add available data fetching request to availability recovery message * remove availability recovery message * fix * update network bridge * port availability recovery to request/response * use validators.len(), not shuffling * fix availability recovery tests * update guide * Update node/network/availability-recovery/src/lib.rs Co-authored-by:
Bernhard Schuster <bernhard@ahoi.io> * Update node/network/availability-recovery/src/lib.rs Co-authored-by:
Arkadiy Paronyan <arkady.paronyan@gmail.com> * remove println Co-authored-by:
Bernhard Schuster <bernhard@ahoi.io> Co-authored-by:
Arkadiy Paronyan <arkady.paronyan@gmail.com>
-
- 24 Mar, 2021 2 commits
-
-
André Silva authored
* collator: authenticate collator protocol messages * fix tests compilation * node: verify collator protocol signatures in tests * collator: fix tests * implementers-guide: update CollatorProtocol messages * collator: add test for verification of collator protocol signatures * node: remove fixmes * node: remove signature from advertisecollation message * node: add magic constant to Declare message signature payload
-
asynchronous rob authored
* malicious reputation cost is fatal * make ReportBad a malicious cost * futures control-flow for cleaning up inactive collator peers * guide: network bridge updates * add `PeerDisconnected` message * guide: update * reverse order * remember to match * implement disconnect peer in network bridge * implement disconnect_inactive_peers * test * remove println * don't hardcore policy * add fuse outside of loop * use default eviction policy
-
- 23 Mar, 2021 1 commit
-
-
Pierre Krieger authored
-
- 19 Mar, 2021 1 commit
-
-
Robert Klotzner authored
* Don't accept incoming connections for collators on the `Collation` peer set. * Better docs.
-
- 18 Mar, 2021 1 commit
-
-
Robert Klotzner authored
* Introduce collation fetching protocol also move to mod.rs * Allow `PeerId`s in requests to network bridge. * Fix availability distribution tests. * Move CompressedPoV to primitives. * Request based collator protocol: validator side - Missing: tests - Collator side - don't connect, if not connected * Fixes. * Basic request based collator side. * Minor fix on collator side. * Don't connect in requests in collation protocol. Also some cleanup. * Fix PoV distribution * Bump substrate * Add back metrics + whitespace fixes. * Add back missing spans. * More cleanup. * Guide update. * Fix tests * Handle results in tests. * Fix weird compilation issue. * Add missing ) * Get rid of dead code. * Get rid of redundant import. * Fix runtime build. * Cleanup. * Fix wasm build. * Format fixes. Thanks @andronik !
-
- 10 Mar, 2021 1 commit
-
-
Andronik Ordian authored
* prefix parachain log targets with parachain:: * even more consistent
-
- 02 Mar, 2021 1 commit
-
-
Andronik Ordian authored
* initial subsystem for issuing connection requests * finish the initial impl * integrate with the overseer * rename to gossip-support * fix renamings leftover * remove run_inner * fix compilation * random subset of sqrt
-
- 26 Feb, 2021 2 commits
-
-
Robert Klotzner authored
* WIP * availability distribution, still very wip. Work on the requesting side of things. * Some docs on what I intend to do. * Checkpoint of session cache implementation as I will likely replace it with something smarter. * More work, mostly on cache and getting things to type check. * Only derive MallocSizeOf and Debug for std. * availability-distribution: Cache feature complete. * Sketch out logic in `FetchTask` for actual fetching. - Compile fixes. - Cleanup. * Format cleanup. * More format fixes. * Almost feature complete `fetch_task`. Missing: - Check for cancel - Actual querying of peer ids. * Finish FetchTask so far. * Directly use AuthorityDiscoveryId in protocol and cache. * Resolve `AuthorityDiscoveryId` on sending requests. * Rework fetch_task - also make it impossible to check the wrong chunk index. - Export needed function in validator_discovery. * From<u32> implementation for `ValidatorIndex`. * Fixes and more integration work. * Make session cache proper lru cache. * Use proper lru cache. * Requester finished. * ProtocolState -> Requester Also make sure to not fetch our own chunk. * Cleanup + fixes. * Remove unused functions - FetchTask::is_finished - SessionCache::fetch_session_info * availability-distribution responding side. * Cleanup + Fixes. * More fixes. * More fixes. adder-collator is running! * Some docs. * Docs. * Fix reporting of bad guys. * Fix tests * Make all tests compile. * Fix test. * Cleanup + get rid of some warnings. * state -> requester * Mostly doc fixes. * Fix test suite. * Get rid of now redundant message types. * WIP * Rob's review remarks. * Fix test suite. * core.relay_parent -> leaf for session request. * Style fix. * Decrease request timeout. * Cleanup obsolete errors. * Metrics + don't fail on non fatal errors. * requester.rs -> requester/mod.rs * Panic on invalid BadValidator report. * Fix indentation. * Use typed default timeout constant. * Make channel size 0, as each sender gets one slot anyways. * Fix incorrect metrics initialization. * Fix build after merge. * More fixes. * Hopefully valid metrics names. * Better metrics names. * Some tests that already work. * Slightly better docs. * Some more tests. * Fix network bridge test.
-
Bernhard Schuster authored
* test: add unit test to catch missing distribution to subsystems faster * add a simple count * introduce proc macro to generate dispatch type * refactor * refactor * chore: add license * fixup unit test * fixup merge * better errors * better fmt * fix error spans * better docs * better error messages * ui test foo * Update node/subsystem/dispatch-gen/src/lib.rs Co-authored-by:
Bastian Köcher <bkchr@users.noreply.github.com> * Update node/network/bridge/src/lib.rs Co-authored-by:
Bastian Köcher <bkchr@users.noreply.github.com> * Update node/subsystem/Cargo.toml Co-authored-by:
Bastian Köcher <bkchr@users.noreply.github.com> * Update node/subsystem/dispatch-gen/src/lib.rs Co-authored-by:
Bastian Köcher <bkchr@users.noreply.github.com> * Update node/subsystem/dispatch-gen/src/lib.rs Co-authored-by:
Bastian Köcher <bkchr@users.noreply.github.com> * Update node/network/bridge/src/lib.rs Co-authored-by:
Andronik Ordian <write@reusable.software> * fix compilation * use find_map * drop the silly 2, use _inner instead * Update node/network/bridge/src/lib.rs Co-authored-by:
Andronik Ordian <write@reusable.software> * Update node/subsystem/dispatch-gen/src/lib.rs Co-authored-by:
Bastian Köcher <bkchr@users.noreply.github.com> * nail deps down * more into() * flatten * missing use statement * fix messages order Co-authored-by:
Bastian Köcher <bkchr@users.noreply.github.com> Co-authored-by:
Andronik Ordian <write@reusable.software>
-
- 23 Feb, 2021 2 commits
-
-
asynchronous rob authored
* add tracing to approval voting * notify if session info is not working * add dispute period to chain specs * propagate genesis session to parachains runtime * use `on_genesis_session` * protect against zero cores in computation * tweak voting rule to be based off of best and add logs * genesis configuration should use VRF slots only * swallow more keystore errors * add some docs * make validation-worker args non-optional and update clap * better tracing for bitfield signing and provisioner * pass amount of bits in bitfields to inclusion instead of recomputing * debug -> warn for some logs * better tracing for availability recovery * a little av-store tracing * bridge: forward availability recovery messages * add missing try_from impl * some more tracing * improve approval distribution tracing * guide: hold onto pending approval messages until NewBlocks * Hold onto pending approval messages until NewBlocks * guide: adjust comment * process all actions for one wakeup at a time * vec * fix network bridge test * replace randomness-collective-flip with Babe * remove PairNotFound
-
Bernhard Schuster authored
* feat/view: assure heads in a view are sorted Allows O(n) comparisons, adds an alternate equiv relation which takes O(n^2) for integrity verification. Ref #2133 * revert: remove custom PartialEq impl, there are no duplicates * fix: do not sort the live_heads, that alters the local view * refactor/view: heads should not be public * chore/spellcheck: add unfinalized * fix/view: add missing len() and is_empty() fns * quirk * vec is not view * Update node/network/approval-distribution/src/tests.rs Co-authored-by:
Andronik Ordian <write@reusable.software> * Update node/network/bridge/src/lib.rs Co-authored-by:
Andronik Ordian <write@reusable.software> * Update node/network/protocol/src/lib.rs Co-authored-by:
Andronik Ordian <write@reusable.software> * fixup comment * fix botched test Co-authored-by:
Andronik Ordian <write@reusable.software>
-
- 19 Feb, 2021 1 commit
-
-
Bernhard Schuster authored
* feat/jaeger: more spans, more stages Stage numbers are still arbitrarily picked. * feat/jaeger: additional spans * chore/spellcheck: improve the dictionary * fix/jaeger JaegerSpan -> jaeger::Span
-
- 17 Feb, 2021 1 commit
-
-
Bernhard Schuster authored
* refactor/reputation: unify the values used * chore/rep: rename Annoy* to Cost*, make duplicate message Cost*Repeated * fix/reputation: lost and found, convert at the boundary to substrate * refactor/rep: move conversion to base reputation one level down, left conversions * fix/rep: order of magnitude adjustments Thanks pierre! * remove spaces * chore/rep: give rationale for order of magnitude * refactor/rep: move UnifiedReputationChange to separate file * fix/rep: order of magnitudes correction
-
- 08 Feb, 2021 1 commit
-
-
Andronik Ordian authored
* validator_discovery: pass PeerSet to the request * validator_discovery: track PeerSet of connected peers * validator_discovery: fix tests * validator_discovery: fix long line * some fixes * some validator_discovery logs * log validator discovery request * Also connect to validators on `DistributePoV`. * validator_discovery: store the whole state per peer_set * bump spec versions in kusama, polkadot and westend * Correcting doc. * validator_discovery: bump channel capacity * pov-distribution: some cleanup * this should fix the test, but it does not * I just got some brain damage while fixing this Why are you even reading this??? * wrap long line * address some review nits Co-authored-by:
Robert Klotzner <robert.klotzner@gmx.at>
-
- 06 Feb, 2021 1 commit
-
-
asynchronous rob authored
* send our view to new peers immediately * guide: update * Fix tests by expecting the view updates * Add test that we send our view on connection Co-authored-by:
Sergei Shulepov <sergei@parity.io>
-
- 04 Feb, 2021 1 commit
-
-
Robert Klotzner authored
* End multiplexer stream once one of its inputs end. Also add test, that we don't panic once a stream is exhausted. * Don't fuse already fused stream.
-
- 03 Feb, 2021 1 commit
-
-
Robert Klotzner authored
* Move NetworkBridgeEvent to subsystem::messages. It is not protocol related at all, it is in fact only part of the subsystem communication as it gets wrapped into messages of each subsystem. * Request/response infrastructure is taking shape. WIP: Does not compile. * Multiplexer variant not supported by Rusts type system. * request_response::request type checks. * Cleanup. * Minor fixes for request_response. * Implement request sending + move multiplexer. Request multiplexer is moved to bridge, as there the implementation is more straight forward as we can specialize on `AllMessages` for the multiplexing target. Sending of requests is mostly complete, apart from a few `From` instances. Receiving is also almost done, initializtion needs to be fixed and the multiplexer needs to be invoked. * Remove obsolete multiplexer. * Initialize bridge with multiplexer. * Finish generic request sending/receiving. Subsystems are now able to receive and send requests and responses via the overseer. * Doc update. * Fixes. * Link issue for not yet implemented code. * Fixes suggested by @ordian - thanks! - start encoding at 0 - don't crash on zero protocols - don't panic on not yet implemented request handling * Update node/network/protocol/src/request_response/v1.rs Use index 0 instead of 1. Co-authored-by:
Andronik Ordian <write@reusable.software> * Update node/network/protocol/src/request_response.rs Co-authored-by:
Andronik Ordian <write@reusable.software> * Fix existing tests. * Better avoidance of division by zoro errors. * Doc fixes. * send_request -> start_request. * Fix missing renamings. * Update substrate. * Pass TryConnect instead of true. * Actually import `IfDisconnected`. * Fix wrong import. * Update node/network/bridge/src/lib.rs typo Co-authored-by:
Pierre Krieger <pierre.krieger1708@gmail.com> * Update node/network/bridge/src/multiplexer.rs Remove redundant import. Co-authored-by:
Pierre Krieger <pierre.krieger1708@gmail.com> * Stop doing tracing from within `From` instance. Thanks for the catch @tomaka ! * Get rid of redundant import. * Formatting cleanup. * Fix tests. * Add link to issue. * Clarify comments some more. * Fix tests. * Formatting fix. * tabs * Fix link Co-authored-by:
Bernhard Schuster <bernhard@ahoi.io> * Use map_err. Co-authored-by:
Bernhard Schuster <bernhard@ahoi.io> * Improvements inspired by suggestions by @drahnr. - Channel size is now determined by function. - Explicitely scope NetworkService::start_request. Co-authored-by:
Andronik Ordian <write@reusable.software> Co-authored-by:
Pierre Krieger <pierre.krieger1708@gmail.com> Co-authored-by:
Bernhard Schuster <bernhard@ahoi.io>
-
- 29 Jan, 2021 1 commit
-
-
thiolliere authored
* upgrade codec and bitvec * "Update Substrate" Co-authored-by: parity-processbot <>
-
- 25 Jan, 2021 1 commit
-
-
Andronik Ordian authored
* initial impl approval distribution * initial tests and fixes * batching seems difficult: different peers have different needs * bridge: fix test after merge * some guide updates * only send assignments to peers who know about the block * fix a test, add approvals test * simplify * do not send assignment to peers for finalized blocks * guide: protocol input and output * one more test * more comments, logs, initial metrics * fix a typo * one more thing: early return when reimporting a thing locally
-
- 14 Jan, 2021 1 commit
-
-
Robert Klotzner authored
* More doc fixes. * Minor refactorings in the process of #2177 By having everything peer set related depend directly on the enum the code becomes more clear and it is also straight forward to add more peersets/protocols as the compiler will complain if you forget to implement parts of it. * Add peer set infos on startup properly For feature real_overseer. + Fixes from review. Thanks @coriolinus and @ordian ! * More structure in network-bridge Some changes, which would have helped me in groking the code faster. Entry points/public types more to the top. Factored out implementation in their own files, to clear up the top-level view. * Get rid of local ProtocolName type definition. Does not add much at this level. * Fix tests + import cleanup. * Make spaces tabs. * Clarify what correct parameters to send_message are * Be more less vague in docs of send_message. * Apply suggestions from code review Extend copyright on new files to 2021 as well. Co-authored-by:
Andronik Ordian <write@reusable.software> Co-authored-by:
Andronik Ordian <write@reusable.software>
-
- 13 Jan, 2021 1 commit
-
-
Bernhard Schuster authored
-
- 08 Jan, 2021 1 commit
-
-
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:
Peter Goodspeed-Niklaus <coriolinus@users.noreply.github.com> * Don't work if they're are no added heads * Fix test * Ahhh * More fixes Co-authored-by:
Peter Goodspeed-Niklaus <coriolinus@users.noreply.github.com>
-
- 07 Jan, 2021 2 commits
-
-
asynchronous rob authored
Batch messages to network bridge and introduce a timeout to `SubsystemContext::send_message` (#2197) * guide: batch network messages * bridge: batch * av-dist: batch outgoing messages * time-out message sends in subsystem context * Update node/subsystem/src/messages.rs Co-authored-by:
Bastian Köcher <bkchr@users.noreply.github.com> * Revert "time-out message sends in subsystem context" This reverts commit d49be625 . * Update node/network/availability-distribution/src/lib.rs Co-authored-by:
Bastian Köcher <bkchr@users.noreply.github.com>
-
Pierre Krieger authored
* Companion PR for refactoring priority groups * Fix non reserved node * Try fix tests * Missing import * Fix warning * Change protocols order * Fix test * Renames * Update syn dependency to make it compile again after merging master * "Update Substrate" Co-authored-by: parity-processbot <>
-
- 05 Jan, 2021 1 commit
-
-
Bastian Köcher authored
* Add one Jaeger span per relay parent This adds one Jaeger span per relay parent, instead of always creating new spans per relay parent. This should improve the UI view, because subsystems are now grouped below one common span. * Fix doc tests * Replace `PerLeaveSpan` to `PerLeafSpan` * More renaming * Moare * Update node/subsystem/src/lib.rs Co-authored-by:
Andronik Ordian <write@reusable.software> * Skip the spans * Increase `spec_version` Co-authored-by:
Andronik Ordian <write@reusable.software>
-
- 17 Dec, 2020 1 commit
-
-
Andronik Ordian authored
* refactor View to include finalized_number * guide: update the NetworkBridge on BlockFinalized * av-store: fix the tests * actually fix tests * grumbles * ignore macro doctest * use Hash::repeat_bytes more consistently * broadcast empty leaves updates as well * fix issuing view updates on empty leaves updates
-
- 02 Dec, 2020 1 commit
-
-
Bastian Köcher authored
-
- 30 Nov, 2020 1 commit
-
-
asynchronous rob authored
* introduce a waiting period before selecting candidates and bitfields * add network_bridge=debug tracing for rep * change to 2.5s timeout in proposer * pass timeout to proposer * move timeout back to provisioner * grumbles * Update node/core/provisioner/src/lib.rs * Fix nitpicks * Fix bug Co-authored-by:
Bastian Köcher <bkchr@users.noreply.github.com> Co-authored-by:
Bastian Köcher <git@kchr.de>
-
- 23 Nov, 2020 1 commit
-
-
Andronik Ordian authored
* send_message should not return an error * Apply suggestions from code review Co-authored-by:
Peter Goodspeed-Niklaus <coriolinus@users.noreply.github.com> * s/send_logging_error/send_and_log_error Co-authored-by:
Peter Goodspeed-Niklaus <coriolinus@users.noreply.github.com>
-
- 20 Nov, 2020 2 commits
-
-
Andronik Ordian authored
* use snake_case for log targets * remove unused continue * validator_discovery: when disconnecting, use all addresses * validator_discovery: simplify request revokation * fix a typo
-
Peter Goodspeed-Niklaus authored
* drop in tracing to replace log * add structured logging to trace messages * add structured logging to debug messages * add structured logging to info messages * add structured logging to warn messages * add structured logging to error messages * normalize spacing and Display vs Debug * add instrumentation to the various 'fn run' * use explicit tracing module throughout * fix availability distribution test * don't double-print errors * remove further redundancy from logs * fix test errors * fix more test errors * remove unused kv_log_macro * fix unused variable * add tracing spans to collation generation * add tracing spans to av-store * add tracing spans to backing * add tracing spans to bitfield-signing * add tracing spans to candidate-selection * add tracing spans to candidate-validation * add tracing spans to chain-api * add tracing spans to provisioner * add tracing spans to runtime-api * add tracing spans to availability-distribution * add tracing spans to bitfield-distribution * add tracing spans to network-bridge * add tracing spans to collator-protocol * add tracing spans to pov-distribution * add tracing spans to statement-distribution * add tracing spans to overseer * cleanup
-
- 18 Nov, 2020 1 commit
-
-
Pierre Krieger authored
* Companion PR for substrate#7549 * "Update Substrate" Co-authored-by: parity-processbot <>
-
- 29 Oct, 2020 1 commit
-
-
Bastian Köcher authored
* Make sure validator discovery works with a delayed peer to validator mapping Currently the implementation checks on connect of a peer if this peer is a validator by asking the authority discovery. It can now happen that the authority discovery is not yet aware that a given peer is an authority. This can for example happen on start up of the node. This pr changes the behavior, to make it possible to later associate a peer to a validator id. Instead of just storing the connected validators, we now store all connected peers with a vector of associated validator ids. When we get a request to connect to a given given set of validators, we start by checking the connected peers. If we didn't find a validator id in the connected peers, we ask the authority discovery for the peerid of a given authority id. When the returned peerid is part of our connected peers set, we cache and return the authority id. * Update node/network/bridge/Cargo.toml Co-authored-by:
Pierre Krieger <pierre.krieger1708@gmail.com> * Update node/network/bridge/src/validator_discovery.rs Co-authored-by:
Pierre Krieger <pierre.krieger1708@gmail.com> * Update `Cargo.lock` Co-authored-by:
Pierre Krieger <pierre.krieger1708@gmail.com>
-
- 28 Oct, 2020 1 commit
-
-
Fedor Sakharov authored
* Change SpawnedSubsystem type to log subsystem errors * Remove clone
-
- 27 Oct, 2020 1 commit
-
-
Bernhard Schuster authored
-