Pierre Krieger
6a7e86e677
Use new block requests protocol ( #5760 )
...
* Use new block requests protocol
* Tweak comment
2020-04-24 13:48:22 +02:00
Pierre Krieger
a7f578d63a
Add a protocol that answers finality proofs ( #5718 )
...
* Add a protocol that answers finality proofs
* Fix documentation
* Use Toggle
2020-04-22 10:58:26 +02:00
Pierre Krieger
3ad9f65f11
Send a status message on block announce handshake ( #5726 )
...
* Send a status message on block announce handshake
* Make sure to send the handshake to all handlers
2020-04-22 10:20:52 +02:00
Pierre Krieger
f2578bdc3b
Pass an encoded Roles as the notifications protocols handshakes ( #5665 )
2020-04-21 10:47:37 +02:00
cheme
4ffcf98d8d
Child trie api changes BREAKING ( #4857 )
...
Co-Authored-By: thiolliere <gui.thiolliere@gmail.com >
2020-04-20 15:21:22 +02:00
Pierre Krieger
efde6056f6
Temporarily increase notifications buffer size ( #5644 )
...
* Temporarily increase notifications buffer size
* Add a 511.0 bucket
2020-04-15 23:27:33 +02:00
Arkadiy Paronyan
76a5555031
More robust sync ( #5604 )
...
* More robust ancestry search
* Punish peers for being on the wrong fork
* Update client/network/src/protocol/sync.rs
Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com >
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
2020-04-13 19:09:43 +02:00
Roman Borschel
40c56deea3
Do not prematurely emit CustomProtocolClosed on connection close. ( #5595 )
2020-04-09 12:41:34 +02:00
Pierre Krieger
cebd073649
Report local force-closing connections to Prometheus ( #5575 )
...
* Report local force-closing connections to Prometheus
* Also report ping timeouts separately
* Address concerns of #5571
2020-04-09 11:24:01 +02:00
Pierre Krieger
0cc2e4df89
Fix #5516 ( #5560 )
...
* Add a failing test
* Make test not freeze
* Fix the bug
* Fix spaces
* Fix tests
* Apply suggestions from code review
Co-Authored-By: Toralf Wittner <tw@dtex.org >
* Make sure test doesn't succeed if nothing happened
* Fix build
* Do the events change
Co-authored-by: Toralf Wittner <tw@dtex.org >
2020-04-08 13:32:22 +02:00
Roman Borschel
f8c8355ac7
libp2p-next ( #5278 )
...
* Adapt to rust-libp2p#1440.
* Further adapt to libp2p/master.
* Update to libp2p-0.17
* Finishing touches.
* Remove stray TODO.
* Incorporate review feedback.
* Remove unused import.
2020-04-08 09:23:21 +02:00
Pierre Krieger
8c03a4fcef
Split the Roles in three types ( #5520 )
...
* Split the Roles bitfield in three
* Forgot to include some changes
* Fix cli test
* More test fixes
* Oh God, merging master broke other tests
* Didn't run the doctests
* Address review
* I'm trying to fix the build blindly because it's taking a good hour to compile on my machine
* Address some review
* Also update the peerset's API to make sense
* Fix peerset tests
* Fix browser node
* client: distinguish between local and network authority
Co-authored-by: André Silva <andre.beat@gmail.com >
2020-04-03 19:08:14 +02:00
Pierre Krieger
c9f3d16f44
Improve warning about notifications queue and remove spurious triggers ( #5512 )
...
* Better logging for notifications and buffer size increase
* Address review
* Improve warning about notifications queue and remove spurious triggers
2020-04-03 14:14:55 +02:00
Pierre Krieger
e8dfb37aaf
Add a sub_libp2p_notifications_queues_size Prometheus metric ( #5503 )
...
* Add a sub_libp2p_notifications_queues_size Prometheus metric
* Fix network tests
* Address review
2020-04-03 08:43:55 +02:00
Gavin Wood
3b43429729
More emojies and spaces ( #5498 )
...
* More emojies and spaces
* Sync emojis
* More emoji
2020-04-02 20:17:39 +02:00
Pierre Krieger
a8aedfa16f
Switch to new light client protocol ( #5472 )
...
* Switch to the new protocol
* Oops, forgot to remove light_dispatch.rs
* Fix tests
* Address review
2020-04-01 19:44:42 +02:00
Gavin Wood
b86c7e87a9
A few missing emojies ( #5490 )
...
* A few missing emojies
* P2p message emojis
* Add a bit of colour
* format
* Introduce a couple of spaces
* Some spaces
2020-04-01 19:41:48 +02:00
Pierre Krieger
84ff6ef157
Remove DiscoveryNetBehaviour trait ( #5430 )
2020-04-01 16:25:53 +01:00
Pierre Krieger
f04486e5bc
Increase limit on light client response size ( #5461 )
...
* Increase limit on light client response size
* Address review
2020-03-31 20:16:56 +02:00
Nikolay Volf
b4d83a4b54
And one more fix to flaky tests ( #5467 )
...
* imporoved intervallier version
* remove extra event
* use version 0.3.1
* fix warning
2020-03-31 12:15:31 +02:00
Pierre Krieger
dbba4f8929
Fix tried to send handshake twice ( #5413 )
...
* Fix tried to send handshake twice
* Fix wrong boolean
* Change to debug
2020-03-30 13:33:46 +02:00
Pierre Krieger
462eaa3f41
Make transactions and block announces use notifications substre… ( #5360 )
...
* Make transactions and block announces use notifications
* Add documentation
2020-03-30 10:00:34 +02:00
Gavin Wood
acab5f0570
Add emojis ( #5420 )
2020-03-27 10:41:31 +01:00
Arkadiy Paronyan
d474864d67
Allow syncing to peers with finalized common block ( #5408 )
...
* Allow syncing to peers with finalized common block
* Added test
2020-03-26 09:13:09 +01:00
Stanislav Tkach
4414d00082
Get rid of rustc_hex in favor of hex ( #5370 )
...
* Get rid of rustc_hex in favor of hex
* Use HexDisplay
2020-03-24 11:48:23 +01:00
Pierre Krieger
1da48b3b3f
Rewrite reconnect_after_disconnect test ( #5351 )
2020-03-23 11:50:11 +01:00
Pierre Krieger
57af4facbd
Remove the #[doc(hidden)] reexports of sc_network ( #5264 )
...
* Remove the #[doc(hidden)] reexports of sc_network
* Fix tests not building
2020-03-20 16:42:00 +01:00
Arkadiy Paronyan
a66615446d
Fixed a couple of syncing issues ( #5277 )
...
* Don't queue duplicate blocks
* Keep queue_blocks on restart
2020-03-19 14:02:07 +01:00
Toralf Wittner
89b93d9d4b
sc-network: Return on Poll::Pending. ( #5295 )
...
If polling encounters a `Poll::Pending` we need to return it instead of
continuing the loop which may turn it into a blocking operation, causing
problems with executors.
2020-03-18 11:21:10 +00:00
Seun Lanlege
3193b0d4aa
removes use of sc_client::Client from node-transaction-factory ( #5158 )
...
* removes use of sc_client::Client from node-transaction-factory
* move sc-block-builder to [dev-dependencies] in substrate-test-runtime
2020-03-12 19:19:38 +01:00
Seun Lanlege
9898fc7e81
removes use of sc_client::Client from sc_network ( #5147 )
...
* removes use of sc_client::Client from sc_network
* rename BlockProvider to BlockBackend
* fix broken test
2020-03-12 14:02:04 +01:00
Bastian Köcher
1cfcf5cbfe
Don't include :code by default in storage proofs ( #5179 )
...
* Don't include `:code` by default in storage proofs (#5060 )
* Adds test to verify that the runtime currently is always contained in
the proof
* Start passing the runtime wasm code from the outside
* Fix compilation
* More build fixes
* Make the test work as expected now :)
* Last fixes
* Fixes benchmarks
* Review feedback
* Apply suggestions from code review
Co-Authored-By: Sergei Pepyakin <sergei@parity.io >
* Review feedback
* Fix compilation
Co-authored-by: Sergei Pepyakin <s.pepyakin@gmail.com >
* Fix compilation and change the way `RuntimeCode` works
* Fix tests
* Switch to `Cow`
Co-authored-by: Benjamin Kampmann <ben@gnunicorn.org >
Co-authored-by: Sergei Pepyakin <s.pepyakin@gmail.com >
2020-03-10 11:13:20 +01:00
Pierre Krieger
9c6d53f436
Fix NotificationStreamClosed reported when it shouldn't ( #5160 )
...
* Fix NotificationStreamClosed reported when it shouldn't
* Fix test
* Add test
* Update client/network/src/protocol.rs
Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com >
* Oops, fix test
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
2020-03-06 21:24:51 +01:00
Gavin Wood
d957220435
Add lots of networking metrics for Prometheus ( #5126 )
...
* Add some metrics
* Address concerns
2020-03-05 21:38:41 +01:00
Gavin Wood
868d8b8252
Add more prometheus metrics to network::Protocol. ( #5145 )
2020-03-05 17:01:24 +01:00
Benjamin Kampmann
99ae5342eb
removes use of sc_client::Client from sc-rpc ( #5063 )
...
* removes use of sc_client::Client from sc-rpc
* remove Client impl from sc-finality-benches
* remove client impl from sc-finality-grandpa
* read_proof accepts iterator
* remove generic Executor param from ExecutorProvider
* fix long ass line
* code style changes
* merge with master
Co-authored-by: Arkadiy Paronyan <arkady.paronyan@gmail.com >
2020-03-05 16:41:10 +01:00
Arkadiy Paronyan
9a1b3b53f2
Revert "Don't include :code by default in storage proofs ( #5060 )" ( #5136 )
...
This reverts commit 6ee39261c8 .
2020-03-05 10:55:05 +01:00
Benjamin Kampmann
6ee39261c8
Don't include :code by default in storage proofs ( #5060 )
...
* Adds test to verify that the runtime currently is always contained in
the proof
* Start passing the runtime wasm code from the outside
* Fix compilation
* More build fixes
* Make the test work as expected now :)
* Last fixes
* Fixes benchmarks
* Review feedback
* Apply suggestions from code review
Co-Authored-By: Sergei Pepyakin <sergei@parity.io >
* Review feedback
* Fix compilation
Co-authored-by: Sergei Pepyakin <s.pepyakin@gmail.com >
2020-03-04 20:26:16 +01:00
Shawn Tabrizi
3d6329a22d
A Pallet for Benchmarking Common Runtime Operations ( #4902 )
...
* Benchmark pallet
* Add a bunch more benchmarks
* do nothing test
* new benchmarks
* Clean up extra tests
* Encode and Decode Vec<T::AccountId>
* Starting to migrate benchmarks to macro
* Use macro
* Remove call and storage
* Update Cargo.toml
* Add storage recalc benchmark
* Add support for custom functions in benchmark! macro
* Reset DB for storage recalc
* Feedback from review
* Add more comments
* Remove benchmark pallet from node
* Fix cargo files
* Fix comments
* Change `crate` to `super`
* missed one
* Use results of benchmark encode/decode
* Pass generic to extra functions
* reset macro to master
* Update lib.rs
* Update to use standard syntax
2020-03-04 17:21:42 +01:00
Bastian Köcher
d3244b728a
Make sure we remove a peer on disconnect in gossip ( #5104 )
...
* Make sure we remove peers on disconnect in gossip state machine
* Clear up the code
* Add a comment
2020-03-02 18:20:04 +01:00
Pierre Krieger
9ab9134ea5
Remove request ID from the new protocol ( #5049 )
2020-03-02 13:43:29 +01:00
Arkadiy Paronyan
492a820c6c
Sync: validate block responses for required data ( #5052 )
...
* Less verbose state-db logging
* Validate block responses for block bodies
* Update client/network/src/protocol.rs
Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com >
* Added validation test
* Disconnect on missing header as well
* Typo
Co-Authored-By: André Silva <andre.beat@gmail.com >
Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com >
Co-authored-by: André Silva <andre.beat@gmail.com >
2020-02-25 22:17:42 +01:00
Robert Habermeier
0090fe979b
Remove NetworkSpecialization ( #4665 )
...
* remove networkspecialization
* Fix most of the fallout
* get all tests compiling
Co-authored-by: Pierre Krieger <pierre.krieger1708@gmail.com >
2020-02-21 14:02:12 +01:00
Pierre Krieger
7a04055814
Open one substream for each notifications protocol ( #4909 )
...
* Open one substream for each notifications protocol
* Fix WASM build
* Apply suggestions from code review
Co-Authored-By: Toralf Wittner <tw@dtex.org >
* Address concerns
* Use unsigned-varint to read the varint
* Use unsigned-varint
* Forgot Cargo.lock
Co-authored-by: Toralf Wittner <tw@dtex.org >
2020-02-21 11:06:24 +01:00
Pierre Krieger
1489397f7b
Cleanup the exports of sc-network ( #4983 )
...
* Cleanup the exports of sc-network
* Fix RPC tests
* Revert moving the NetworkStateInfo trait
* Fix GrandPa tests
2020-02-19 16:52:39 +01:00
Stanislav Tkach
ba2362dadd
[In Progress] Remove deprecated api ( #4973 )
...
* Remove deprecated api
* Revert changes to wasm-build-runner
2020-02-18 23:25:56 +01:00
Ashley
133a4f967f
Re-enable networking on wasm ( #4880 )
...
* Use noise and timeouts on wasm
* Don't use wasm-opt when compiling to wasm
* Forgot lockfile
* Add node about disabling wasm-opt
* Enable timeouts in telemetry on wasm
2020-02-18 16:18:32 +01:00
André Silva
9cc650d91c
sync: process empty response for justification requests ( #4957 )
...
* sync: process empty response for justification request
* sync: add test for justification request empty response
* network: remove deprecated comment
2020-02-18 15:11:44 +01:00
Pierre Krieger
d67994c561
Fix potential panics related to time ( #4951 )
...
* Fix potential peerset panic at initialization
* Also fix legacy_proto/behaviour.rs
2020-02-18 00:29:37 +01:00
Shawn Tabrizi
c7a14db792
Fix various spelling errors ( #4940 )
...
* meaningfull -> meaningful
* initialise -> initialize
* tokans -> tokens
* incentivise -> incentivize
* lenght -> length
* incentivisation -> incentivization
* doesnt't -> doesn't
* overwriten -> overwritten
* lifecycle -> life cycle
* lifecycle -> life cycle
* usefull -> useful
* noone -> no one
* spaming -> spamming
* defered -> deferred
* hieght -> height
* sumation -> summation
* ingore -> ignore
* registed -> registered
* Auxialary -> Auxiliary
* loggin -> logging
* independance -> independence
* trailling -> trailing
* responsability -> responsibility
* trunkated -> truncated
* Weither -> Whether
* informations -> information
* Runtume -> Runtime
* choosen -> chosen
* delcataion -> declaration
* Unchekced -> Unchecked
* defintion -> definition
* scrach -> scratch
* imput -> input
* transfered -> transferred
* endownment -> endowment
* Determinator -> Determiner
* relevent -> relevant
* emited -> emitted
* acocunt -> account
* proprotional -> proportional
* instantiaion -> instantiation
* commited -> committed
* tombstonedead -> tombstone
* uwnrap -> unwrap
* acount -> account
* specialised -> specialized
* existant -> existent
* requried -> required
* Anull -> Annul
* AUTHORITES -> AUTHORITIES
* underyling -> underlying
* recognisable -> recognizable
* Capitalise -> Capitalize
* reportfor -> report for
* hearbeat -> heartbeat
* onlineness -> being online
* creater -> creator
* Bytearray -> Byte array
* Despoit -> Deposit
* substratced -> subtracted
* Curent -> Current
* imbalanes -> imbalances
* countfown -> countdown
* inexisting -> inexistent
* additionaly -> additionally
* substracted -> subtracted
* auxilary -> auxiliary
* parital -> partial
* in't -> isn't
* compatability -> compatibility
* infomation -> information
* etected -> detected
* extrinsiscs -> extrinsics
* reprensentation -> representation
* coonfiguration -> configuration
* primtives -> primitives
* miscelanious -> miscellaneous
* VERISON -> VERSION
* endcoded -> encoded
* Genrates -> Generates
* miliseconds -> milliseconds
* occured -> occurred
* trully -> truely
* truely -> truly
* conjuction -> conjunction
* encouters -> encounters
* customised -> customized
* deterministicly -> deterministically
* finalisation -> finalization
* pluggable -> plugable
* wakeup -> wake-up
* interemdiate -> intermediate
* intepreting -> interpreting
* finalzied -> finalized
* throgh -> through
* extinsic -> extrinsic
* convient -> convenient
* allocater -> allocator
* propagateable -> propagatable
* succesfuly -> successfully
* finalising -> finalizing
* publically -> publicly
* phrasee -> phrase
* substration -> substractions
* substractions -> subtractions
* neccessarily -> necessarily
* Inlucde -> Include
* unefficient -> inefficient
* thay -> they
* funtion -> function
* datastructures -> data structures
* infromation -> information
* propagatable -> propagable
* ecountered -> encountered
* recognise -> recognize
* intergration -> integration
* lastet -> latest
* datatypes -> data types
* datatype -> data type
* Strongarming -> Strong Arming
* avaible -> available
* Commiting -> Committing
* Retreiving -> Retrieving
* shoud -> should
* canonicaliziation -> canonicalization
* comitted -> committed
* clonable -> cloneable
* Uknown -> Unknown
* reponse -> response
* arbitary -> arbitrary
* Capapbilities -> Capabilities
* responsbile -> responsible
* initialisation -> initialization
* cames -> came
* intemediate -> intermediate
* reqeust -> request
* intance -> instance
* explcitly -> explicitly
* neighor -> neighbor
* reolving -> resolving
* untill -> until
* Validte -> Validate
* deserailize -> deserialize
* literaly -> literally
* preceeding -> preceding
* abpve -> above
* chcecked -> checked
* numbet -> number
* Unknow -> Unknown
* halfs -> halves
* gossup -> gossip
* givent -> given
* immediatelly -> immediately
* slicable -> sliceable
* conensus -> consensus
* Mimicks -> Mimics
* acccept -> accept
* serialise -> serialize
* exstrinsics -> extrinsics
* panicks -> panics
* maintaince -> maintenance
* repeatidely -> repeatedly
* anecstor -> ancestor
* becasue -> because
* processer -> processor
* Prunning -> Pruning
* insterested -> interested
* unuseful -> not useful
* yeided -> yielded
* descendfing -> descending
* corresponts -> corresponds
* survivew -> survive
* keps -> keeps
* ligh -> light
* prerequisities -> prerequisites
* positiion -> position
* depedency -> dependency
* extrinisic -> extrinsic
* atomicaly -> atomically
* staticly -> statically
* resul -> result
* timestamb -> timestamp
* Utilites -> Utilities
* ammount -> amount
* pocess -> process
* exteral -> external
* Update client/finality-grandpa/src/tests.rs
* Update primitives/io/src/lib.rs
Co-Authored-By: joe petrowski <25483142+joepetrowski@users.noreply.github.com >
* Update primitives/blockchain/src/lib.rs
Co-Authored-By: joe petrowski <25483142+joepetrowski@users.noreply.github.com >
* Update frame/support/src/weights.rs
Co-Authored-By: joe petrowski <25483142+joepetrowski@users.noreply.github.com >
* Update bin/node/cli/tests/common.rs
Co-Authored-By: joe petrowski <25483142+joepetrowski@users.noreply.github.com >
* Update client/api/src/execution_extensions.rs
Co-Authored-By: joe petrowski <25483142+joepetrowski@users.noreply.github.com >
* Update client/cli/src/params.rs
Co-Authored-By: joe petrowski <25483142+joepetrowski@users.noreply.github.com >
* Update client/executor/common/src/sandbox.rs
Co-Authored-By: joe petrowski <25483142+joepetrowski@users.noreply.github.com >
* Update client/api/src/execution_extensions.rs
Co-Authored-By: joe petrowski <25483142+joepetrowski@users.noreply.github.com >
* Update client/finality-grandpa/src/communication/mod.rs
Co-Authored-By: joe petrowski <25483142+joepetrowski@users.noreply.github.com >
* Update client/state-db/src/pruning.rs
Co-Authored-By: joe petrowski <25483142+joepetrowski@users.noreply.github.com >
* Update frame/contracts/src/tests.rs
Co-Authored-By: joe petrowski <25483142+joepetrowski@users.noreply.github.com >
* Update client/api/src/execution_extensions.rs
* bump impl
* timestamb -> timestamp
Co-authored-by: joe petrowski <25483142+joepetrowski@users.noreply.github.com >
2020-02-17 15:07:24 +01:00