Commit Graph

36 Commits

Author SHA1 Message Date
s0me0ne-unkn0wn cd2d5d2579 Tracking/limiting memory allocator (#1192) 2023-11-03 17:48:41 +02:00
Marcin S e39253c022 PVF: Add worker check during tests and benches (#1771) 2023-10-24 16:22:15 +02:00
Bastian Köcher e005aef59b Make the node version independent of the crate version (#1495) 2023-09-12 14:12:10 +02:00
Oliver Tale-Yazdi 2f242e0792 Cleanup repo (a tiny bit) (#1382)
* Delete stale adoc files

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Convert adoc to md

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Add adoc to gitignore

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Delete more random unmaintained files

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Markdown lint

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

---------

Signed-off-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
2023-09-04 15:45:33 +03:00
Marcin S 85b06f18b9 98.6% OF DEVELOPERS CANNOT REVIEW THIS PR! [read more...] (#7337)
* [WIP] PVF: Split out worker binaries

* Address compilation problems and re-design a bit

* Reorganize once more, fix tests

* Reformat with new nightly to make `cargo fmt` test happy

* Address `clippy` warnings

* Add temporary trace to debug zombienet tests

* Fix zombienet node upgrade test

* Fix malus and its CI

* Fix building worker binaries with malus

* More fixes for malus

* Remove unneeded cli subcommands

* Support placing auxiliary binaries to `/usr/libexec`

* Fix spelling

* Spelling

Co-authored-by: Marcin S. <marcin@realemail.net>

* Implement review comments (mostly nits)

* Fix worker node version flag

* Rework getting the worker paths

* Address a couple of review comments

* Minor restructuring

* Fix CI error

* Add tests for worker binaries detection

* Improve tests; try to fix CI

* Move workers module into separate file

* Try to fix failing test and workers not printing latest version

- Tests were not finding the worker binaries
- Workers were not being rebuilt when the version changed
- Made some errors easier to read

* Make a bunch of fixes

* Rebuild nodes on version change

* Fix more issues

* Fix tests

* Pass node version from node into dependencies to avoid recompiles

- [X] get version in CLI
- [X] pass it in to service
- [X] pass version along to PVF
- [X] remove rerun from service
- [X] add rerun to CLI

- [X] don’t rerun pvf/worker’s (these should be built by nodes which have rerun enabled)

* Some more improvements for smoother tests

- [X] Fix tests
- [X] Make puppet workers pass None for version and remove rerun
- [X] Make test collators self-contained

* Add back rerun to PVF workers

* Move worker binaries into files in cli crate

As a final optimization I've separated out each worker binary from its own crate
into the CLI crate. Before, the worker bin shared a crate with the worker lib,
so when the binaries got recompiled so did the libs and everything transitively
depending on the libs. This commit fixes this regression that was causing
recompiles after every commit.

* Fix bug (was passing worker version for node version)

* Move workers out of cli into root src/bin/ dir

- [X] Pass in node version from top-level (polkadot)
- [X] Add build.rs with rerun-git-head to root dir

* Add some sanity checks for workers to dockerfiles

* Update malus

  + [X] Make it self-contained
  + [X] Undo multiple binary changes

* Try to fix clippy errors

* Address `cargo run` issue

- [X] Add default-run for polkadot
- [X] Add note about installation to error

* Update readme (installation instructions)

* Allow disabling external workers for local/testing setups

  + [X] cli flag to enable single-binary mode
  + [X] Add message to error

* Revert unnecessary Cargo.lock changes

* Remove unnecessary build scripts from collators

* Add back missing malus commands (should fix failing ZN job)

* Some minor fixes

* Update Cargo.lock

* Fix some build errors

* Undo self-contained binaries; cli flag to disable version check

  + [X] Remove --dont-run-external-workers
  + [X] Add --disable-worker-version-check
  + [X] Remove PVF subcommands
  + [X] Redo malus changes

* Try to fix failing job and add some docs for local tests

---------

Co-authored-by: Dmitry Sinyavin <dmitry.sinyavin@parity.io>
Co-authored-by: s0me0ne-unkn0wn <48632512+s0me0ne-unkn0wn@users.noreply.github.com>
Co-authored-by: parity-processbot <>
2023-07-31 13:35:42 +00:00
s0me0ne-unkn0wn 64660ee8d2 Remove years from copyright notes (#7034)
* Happy New Year!

* Remove year entierly

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>

* Remove years from copyright notice in the entire repo

---------

Co-authored-by: Oliver Tale-Yazdi <oliver.tale-yazdi@parity.io>
2023-04-08 20:38:35 +00:00
Anthony Alaribe b8eaf25040 Introduce jemalloc-allocator feature flag (#6675)
* Introduce jemalloc-stats feature flag

* remove unneeded space

* Update node/overseer/src/lib.rs

Co-authored-by: Marcin S. <marcin@bytedude.com>

* Update Cargo.toml

Co-authored-by: Marcin S. <marcin@bytedude.com>

* revert making tikv-jemallocator depend on jemalloc-stats

* conditionally import memory_stats instead of using dead_code

* fix test via expllicit import

* Add jemalloc-stats feature to crates, propagate it from root

* Apply `jemalloc-stats` feature to prepare mem stats; small refactor

* effect changes recommended on PR

* Update node/overseer/src/metrics.rs

Co-authored-by: Marcin S. <marcin@bytedude.com>

* fix compile error on in pipeline for linux. missing import

* Update node/overseer/src/lib.rs

Co-authored-by: Bastian Köcher <git@kchr.de>

* revert to defining collect_memory_stats inline

---------

Co-authored-by: Marcin S. <marcin@bytedude.com>
Co-authored-by: Marcin S <marcin@realemail.net>
Co-authored-by: Bastian Köcher <git@kchr.de>
2023-02-09 09:09:10 +00:00
Marcin S 3f951cce16 Companion for paritytech/substrate#12795 (#6374)
* Begin removing `parity-util-mem`; remove `collect_memory_stats`

* Update some dependencies that were using `parity-util-mem`

* Remove `trie-memory-tracker` feature

* Update Cargo.lock

* Update `kvdb-shared-tests`

* Add back jemalloc

* Add missing license header

* update lockfile for {"substrate"}

Co-authored-by: parity-processbot <>
Co-authored-by: Andronik <write@reusable.software>
2022-12-06 16:41:00 +00:00
Bastian Köcher f6cbe8e8d8 polkadot-service: Make native runtime configurable (#3189)
* polkadot-service: Make native runtime configurable

This pull requests adds support for configuring the native runtimes used
by polkadot-service. While this whole pr doesn't change that much for
polkadot, besides not having the light-node enabled for the default
polkadot binary. However, downstream projects (parachains) will have a
much better compile time. In cumulus for example the `cargo test --all
--release` is about 4m faster to compile.

* Fixes

* Fix

* Enable rococo-native

* Fix light client

* 🤦

* Fixes
2021-06-08 22:05:20 +02:00
Bernhard Schuster 8a305ac963 remove error wrapper type (#1871)
* get rid of glue wrapper error type

* cargo update -p sp-io

* cargo update -p sp-io

* "Update Substrate"

Co-authored-by: Andronik Ordian <write@reusable.software>
Co-authored-by: parity-processbot <>
2020-10-28 16:42:23 +00:00
Bernhard Schuster 5fbb8a381c use color_eyre for its backtrace feature and error reporting (#1855)
* use color_eyre for its backtrace feature and error reporting

* lost Cargo.lock update

* wrapper

* add error glue to be able to utilize eyre

* Update src/main.rs

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* Update src/main.rs

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>

* avoid duplicate error print

* Update src/main.rs

Co-authored-by: Andronik Ordian <write@reusable.software>

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
Co-authored-by: Andronik Ordian <write@reusable.software>
2020-10-27 21:31:57 +00:00
Cecile Tonglet 9477be3440 Update cli to new sc-cli API (#935)
* Initial commit

Forked at: 9283855dba
Parent branch: origin/master

* Switch substrate to branch cecton-the-revenge-of-the-cli

* Adapting code

* Update Cargo.lock

* Adapting code

* Adapt more code

* Implement force_kusama parameter

* Revert dependency update

* Adapt code to use ref to SubstrateCli object

* Updated to latest version

* Updated with latest changes

* Bump spec vesion

* Fixed tests

* WIP

Forked at: 9283855dba
Parent branch: origin/master

* More fixes

* Cargo.lock

* Updated code

* Fixed and adapt

* Fixed dependency issue with wasm

* Adapted code

* Revert branch change

* Cargo.lock

* Cargo.lock

* Adapt code

* Clean-up

* More clean-up

* Cargo.lock
2020-04-07 12:08:53 +02:00
Bastian Köcher 8a38b7af3c Update to latest Substrate master (#863)
* Begin to update to latest Substrate master

* Fix compilation

* Remove `Balances` from `OnKilledAccount`

* Update cli/src/command.rs

Co-Authored-By: Cecile Tonglet <cecile@parity.io>

* Change gossip name

* Change again

Co-authored-by: Cecile Tonglet <cecile.tonglet@cecton.com>
2020-02-28 12:32:16 +01:00
Gavin Wood 131ad136cb Update Substrate (#812)
* Update to latest Substrate master

* upgrade decl_storage declaration

* Companion PR to Substrate#4752

* Substrate update: Identity should bound additional fields (#4770)

Substrate commit: 2c9ce7296b19934b1ffd50150be2fdb2ddf81a4e

* WIP

* WIP

* Updated substrate and fixes

* Fix compilation and switch to latest wasm-builder-runner

* Fixed missing doc

* Update collator/src/lib.rs

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
Co-authored-by: thiolliere <gui.thiolliere@gmail.com>
Co-authored-by: Pierre Krieger <pierre.krieger1708@gmail.com>
Co-authored-by: Cecile Tonglet <cecile.tonglet@cecton.com>
2020-01-31 11:47:02 +00:00
Shawn Tabrizi c975d4ee84 Update copyright year (#718) 2020-01-05 17:57:13 +01:00
Arkadiy Paronyan a00d74d825 Support both polkadot and kusama runtimes (#704)
* Allow both polkadot and kusama runtimes

* Allow both polkadot and kusama runtimes

* Make `collator` build

* Removed kusama runtime

* Introduced common runtime

* Updated for latest substrate

* Updated CI targets

* Updated CI version check

* Removed unused dependency

* Pulled latests substrate

* Pulled latest substrate

* Fixed version

* Apply suggestions from code review

Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com>

* NEW_HEADS_IDENTIFIER moved to primitives

* Updated CI check script

* Fixed script

* Set epoch duration for polkadot

* ci: check_runtime for both runtimes

Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
Co-authored-by: gabriel klawitter <gabreal@users.noreply.github.com>
2020-01-03 18:31:39 +00:00
Ashley 25aa988f9b Update futures and tokio for browser light client (#673)
* Make availability-store compile for WASM

* Use --manifest-path instead

* Make validation work on wasm!

* Switch to Spawn trait

* Migrate validation to std futures

* Migrate network to std futures

* Final changes to validation

* Tidy up network

* Tidy up validation

* Switch branch

* Migrate service

* Get polkadot to compile via wasm!

* Add browser-demo

* Add initial browser file

* Add browser-demo

* Tidy

* Temp switch back to substrate/master

* tidy

* Fix wasm build

* Re-add release flag

* Switch to polkadot-master

* Revert cli tokio version to avoid libp2p panic

* Update tokio version

* Fix availability store tests

* Fix validation tests

* Remove futures01 from availability-store

* Fix network tests

* Small changes

* Fix collator

* Fix typo

* Revert removal of tokio_executor that causes tokio version mismatch panic

* Fix adder test parachain

* Revert "Revert removal of tokio_executor that causes tokio version mismatch panic"

This reverts commit cfeb50c01d8df5e209483406a711e64761b44ae9.

* Update availability-store/src/worker.rs

Co-Authored-By: Pierre Krieger <pierre.krieger1708@gmail.com>

* Update network/src/lib.rs

Co-Authored-By: Pierre Krieger <pierre.krieger1708@gmail.com>

* Update network/src/lib.rs

Co-Authored-By: Pierre Krieger <pierre.krieger1708@gmail.com>

* Box pin changes

* Asyncify network functions

* Clean up browser validation worker error

* Fix av store test

* Nits

* Fix validation test

* Switch favicon

* Fix validation test again

* Revert "Asyncify network functions"

This reverts commit f20ae6548dc482cb1e75bc80641cfe55c6131a53.

* Add async blocks back in
2019-12-10 11:58:22 +01:00
joe petrowski c9b1e3d959 Update for Substrate master (#600)
* update substrate for change to palette

* change paint to palette

* update lock

* Fix missing import

* change to polkadot-master

* Use same commit hash of parity-common

* Resolve linking errors

* Rename to frame

* bump spec

* Subsume #602 and #596

* Fix DispatchInfo

* Merge `futures03` and `joe-update-to-palette` (#606)

* Change repo and branch

* Made changes

* Bumped async-std version

* Fix line width

* Bump spec_version

* Fix `run_to_block` for Crowdfund module (#603)

Probably a copy paste error.

* Bump dependencies

* Update trie-db to be inline with substrate

* Fix documentation warning

* Fix test compilation
2019-11-23 00:16:04 +01:00
Pierre Krieger bd8ebbfee5 Update to latest Substrate (#407)
* Update to latest Substrate

* Fix main.rs
2019-08-27 15:50:24 +02:00
Arkadiy Paronyan f1fdb0cb83 Parachain validation moved to external process (#325)
* Improved execution & tests

* Style

* Made CLI arg const

* Moved Upwards message

* CLI subcommand for validation worker

* Build halting parachain

* Build halting parachain

* Made stuff private

* Reorganized parachain tests

* Comment

* Whitespace

* Apply suggestions from code review

Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com>

* Fixed call data size check and introduced an enum

* Apply suggestions from code review

Co-Authored-By: Bastian Köcher <bkchr@users.noreply.github.com>
2019-07-23 11:09:30 +02:00
Stanislav Tkach 2c85f90e0a Migrate to the 2018 edition (#273) 2019-05-29 18:33:49 +02:00
Pierre Krieger c699bdc10a Update to Substrate master (#271) 2019-05-25 20:23:14 +02:00
Robert Habermeier 454ddf8921 Collators get incoming parachain messages (#149)
* refactor out a consensus data fetcher from table router

* move statement checking logic into router

* refuse to start authority if collator

* support building the table router asynchronously

* instantiate_consensus does not overwrite old

* update key in new consensus if there was none before

* collator collects ingress from network

* test produced egress roots

* fix adder-collator compilation

* address first grumbles

* integrate new gossip with collator network launch

* address review
2019-03-22 00:48:36 +01:00
joe petrowski 426daaf0f5 Add README Issue Link (#160)
* add issue link

* add issue link

* add issue link

* Update README.adoc

* add parens

* add issue link

* add issue link

* add issue link

* add issue link

* add issue link

* add issue link

* add issue link
2019-02-26 16:04:05 +00:00
Benjamin Kampmann 9fb22ce28d Cleaning up dependencies (#125)
* cargo update
* Update to latest ctrlc crate
* Update vergen
* Update to latest pretty_assertions
* Update log
* Update parking_lot
* Update hex-rustc
2019-02-08 18:25:15 +01:00
Bastian Köcher 36034e79a2 Update to latest substrate (#120) 2019-02-04 18:58:03 -03:00
Gav Wood ccb79c05ed Update to latest Substrate (#90)
* Update to latest Substrate

* Fix tests

* Update src/main.rs

Co-Authored-By: gavofyork <github@gavwood.com>
2019-01-18 16:30:41 +01:00
Gav Wood c31f8168df Make work with Substrate master (#36)
* Fix up wasm runtime build

* Fixes for runtime

* Fix.

* More fixes

* Runtime builds on native.

* Native and wasm both build without warnings.

* Fix runtime tests.

* Merge #20

* Final fix for native runtime.

* Compile polkadot wo consensus

* Reverted changes to polkadot-consensus

* reintroduce minimal subset of consensus

* reintroduce checked_block to runtime for std

* polkadot_consensus compiles without most of the code

* remove checked_block again and do more checks in parachains for runtime

* uncomment proposer

* remove offline tracker

* extract out parachain-attestation logic from proposal directly

* reintroduce transaction_pool

* write some custom aura verification logic for the block verifier

* use transaction pool in more generic way

* service compiles again

* polkadot-network and tests pass

* remove unused session_key function from router

* everything but CLI compiles due to service hell

* Fixes compilation of `polkadot_cli`

* everything compiles

* update adder wasm
2018-11-25 11:25:36 +01:00
Arkadiy Paronyan 9214f42a3b Exit signal gets its own trait (#433)
* Exit signal gets its own trait

* Typo

* Removed clone bounds
2018-07-28 08:31:16 +02:00
Arkadiy Paronyan ed00e11188 Substrate CLI (#423)
* Moved chain ops to substrate-service

* moved RPC to susbstrate-service WIP

* Moved RPC to substrate-service

* Version

* Removed redundadnt messages

* substrate CLI

* Removed obsolete files

* Sorted out startup messages

* Pass executable name to CLI
2018-07-25 22:10:09 +02:00
Chevdor 526de11fe8 WIP: Asciidoc (#407)
* Rename readme

* Add some Asciidoc demo

* Remove extra lines
2018-07-24 11:12:53 +02:00
Arkadiy Paronyan 16ff3579ef Split polkadot-service (#310)
* Substrate service

* Splitting polkadot service

* Specialised components

* Specialised components

* Docs and style

* Docs and style

* Final touches

* Added db key assertion
2018-07-14 18:07:11 +02:00
Robert Habermeier 24f7b548dc Collator node workflow (#280)
* arbitrary application logic in CLI

* collation work

* split up exit and work futures in application

* collation node workflow

* typo

* indentation fix

* doc grumbles

* rename Application to Worker

* refactor Worker::exit to exit_only
2018-07-06 17:13:31 +03:00
Arkadiy Paronyan e81229ae04 Basic informant (#118)
* Informant

* Pass Handle instead of Core
2018-04-11 16:47:22 +02:00
Arkadiy Paronyan f532982623 Consensus message buffering and more (#114)
* CLI options and keystore integration

* Replace multiqueue with future::mpsc

* BFT gossip

* Revert to app_dirs

* generate_from_seed commented

* Refactor event loop

* Start consensus by timer

* Message buffering

* Minor fixes

* Work around duty-roster issue.

* some more minor fixes

* fix compilation

* more consistent formatting

* make bft input stream never conclude

* Minor fixes

* add timestamp module to executive

* more cleanups and logging

* Fixed message propagation
2018-04-06 19:18:26 +02:00
Gav aa67fe3781 Fix warning and directory restructure. 2018-02-08 14:29:30 +01:00