Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Extrinsic for reserving a parachain ID #3008

Merged
merged 7 commits into from
May 11, 2021
Merged

Conversation

gavofyork
Copy link
Member

No description provided.

@gavofyork gavofyork added A0-please_review Pull request needs code review. B0-silent Changes should not be mentioned in any release notes C1-low PR touches the given topic and has a low impact on builders. D2-notlive 💤 PR contains changes in a runtime directory that is not deployed to a chain that requires an audit. labels May 11, 2021
@gavofyork gavofyork mentioned this pull request May 11, 2021
47 tasks
@apopiak
Copy link
Contributor

apopiak commented May 11, 2021

meaning register is no longer deprecated?

@parity-benchapp
Copy link

parity-benchapp bot commented May 11, 2021

Finished benchmark for branch: gav-paras-reserve-id

Benchmark: Benchmark Runtime Westend Pallet

cargo run --release --features=runtime-benchmarks -- benchmark --chain=westend-dev --steps=50 --repeat=20 --pallet=polkadot_common::paras_registrar --extrinsic="*" --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/westend/src/weights/polkadot_common_paras_registrar.rs

Results

Compiling westend-runtime v0.9.1 (/home/benchbot/bench-bot/git/polkadot/runtime/westend)
Compiling polkadot-runtime v0.9.1 (/home/benchbot/bench-bot/git/polkadot/runtime/polkadot)
Compiling rococo-runtime v0.9.1 (/home/benchbot/bench-bot/git/polkadot/runtime/rococo)
Compiling kusama-runtime v0.9.1 (/home/benchbot/bench-bot/git/polkadot/runtime/kusama)
Compiling polkadot-runtime-common v0.9.1 (/home/benchbot/bench-bot/git/polkadot/runtime/common)
Compiling polkadot-service v0.9.1 (/home/benchbot/bench-bot/git/polkadot/node/service)
Compiling polkadot-cli v0.9.1 (/home/benchbot/bench-bot/git/polkadot/cli)
Compiling polkadot v0.9.1 (/home/benchbot/bench-bot/git/polkadot)
Finished release [optimized] target(s) in 7m 06s
Running target/release/polkadot benchmark --chain=westend-dev --steps=50 --repeat=20 '--pallet=polkadot_common::paras_registrar' '--extrinsic=*' --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/westend/src/weights/polkadot_common_paras_registrar.rs
2021-05-11 17:07:14 Took active validators from set with wrong size
2021-05-11 17:07:14 Took active validators from set with wrong size
Error: Benchmark not found for this pallet.

@paritytech paritytech deleted a comment from parity-benchapp bot May 11, 2021
@shawntabrizi
Copy link
Member

/benchmark runtime westend runtime_common::paras_registrar

@parity-benchapp
Copy link

parity-benchapp bot commented May 11, 2021

Finished benchmark for branch: gav-paras-reserve-id

Benchmark: Benchmark Runtime Westend Pallet

cargo run --release --features=runtime-benchmarks -- benchmark --chain=westend-dev --steps=50 --repeat=20 --pallet=runtime_common::paras_registrar --extrinsic="*" --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/westend/src/weights/runtime_common_paras_registrar.rs

Results

Pallet: "runtime_common::paras_registrar", Extrinsic: "reserve", Lowest values: [], Highest values: [], Steps: [50], Repeat: 20
Median Slopes Analysis

-- Extrinsic Time --

Model:
Time ~= 50.55
µs

Reads = 3
Writes = 2
Min Squares Analysis

-- Extrinsic Time --

Model:
Time ~= 50.55
µs

Reads = 3
Writes = 2
Pallet: "runtime_common::paras_registrar", Extrinsic: "register", Lowest values: [], Highest values: [], Steps: [50], Repeat: 20
Median Slopes Analysis

-- Extrinsic Time --

Model:
Time ~= 8254
µs

Reads = 4
Writes = 4
Min Squares Analysis

-- Extrinsic Time --

Model:
Time ~= 8254
µs

Reads = 4
Writes = 4
Pallet: "runtime_common::paras_registrar", Extrinsic: "force_register", Lowest values: [], Highest values: [], Steps: [50], Repeat: 20
Median Slopes Analysis

-- Extrinsic Time --

Model:
Time ~= 8253
µs

Reads = 4
Writes = 4
Min Squares Analysis

-- Extrinsic Time --

Model:
Time ~= 8253
µs

Reads = 4
Writes = 4
Pallet: "runtime_common::paras_registrar", Extrinsic: "deregister", Lowest values: [], Highest values: [], Steps: [50], Repeat: 20
Median Slopes Analysis

-- Extrinsic Time --

Model:
Time ~= 88.24
µs

Reads = 4
Writes = 4
Min Squares Analysis

-- Extrinsic Time --

Model:
Time ~= 88.24
µs

Reads = 4
Writes = 4
Pallet: "runtime_common::paras_registrar", Extrinsic: "swap", Lowest values: [], Highest values: [], Steps: [50], Repeat: 20
Median Slopes Analysis

-- Extrinsic Time --

Model:
Time ~= 67.14
µs

Reads = 8
Writes = 6
Min Squares Analysis

-- Extrinsic Time --

Model:
Time ~= 67.14
µs

Reads = 8
Writes = 6

…n=westend-dev --steps=50 --repeat=20 --pallet=runtime_common::paras_registrar --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/westend/src/weights/runtime_common_paras_registrar.rs
@joao-paulo-parity
Copy link
Contributor

/cla run-cla-check

@cla-bot-2021
Copy link

cla-bot-2021 bot commented May 11, 2021

Queueing command execution: run-cla-check

@cla-bot-2021
Copy link

cla-bot-2021 bot commented May 11, 2021

@joao-paulo-parity Command execution has finished.

Co-authored-by: Robert Habermeier <rphmeier@gmail.com>
@shawntabrizi
Copy link
Member

/benchmark runtime kusama runtime_common::paras_registrar

@parity-benchapp
Copy link

parity-benchapp bot commented May 11, 2021

Finished benchmark for branch: gav-paras-reserve-id

Benchmark: Benchmark Runtime Kusama Pallet

cargo run --release --features=runtime-benchmarks -- benchmark --chain=kusama-dev --steps=50 --repeat=20 --pallet=runtime_common::paras_registrar --extrinsic="*" --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/kusama/src/weights/runtime_common_paras_registrar.rs

Results

Pallet: "runtime_common::paras_registrar", Extrinsic: "reserve", Lowest values: [], Highest values: [], Steps: [50], Repeat: 20
Median Slopes Analysis

-- Extrinsic Time --

Model:
Time ~= 52
µs

Reads = 3
Writes = 2
Min Squares Analysis

-- Extrinsic Time --

Model:
Time ~= 52
µs

Reads = 3
Writes = 2
Pallet: "runtime_common::paras_registrar", Extrinsic: "register", Lowest values: [], Highest values: [], Steps: [50], Repeat: 20
Median Slopes Analysis

-- Extrinsic Time --

Model:
Time ~= 8249
µs

Reads = 4
Writes = 4
Min Squares Analysis

-- Extrinsic Time --

Model:
Time ~= 8249
µs

Reads = 4
Writes = 4
Pallet: "runtime_common::paras_registrar", Extrinsic: "force_register", Lowest values: [], Highest values: [], Steps: [50], Repeat: 20
Median Slopes Analysis

-- Extrinsic Time --

Model:
Time ~= 8228
µs

Reads = 4
Writes = 4
Min Squares Analysis

-- Extrinsic Time --

Model:
Time ~= 8228
µs

Reads = 4
Writes = 4
Pallet: "runtime_common::paras_registrar", Extrinsic: "deregister", Lowest values: [], Highest values: [], Steps: [50], Repeat: 20
Median Slopes Analysis

-- Extrinsic Time --

Model:
Time ~= 88.94
µs

Reads = 4
Writes = 4
Min Squares Analysis

-- Extrinsic Time --

Model:
Time ~= 88.94
µs

Reads = 4
Writes = 4
Pallet: "runtime_common::paras_registrar", Extrinsic: "swap", Lowest values: [], Highest values: [], Steps: [50], Repeat: 20
Median Slopes Analysis

-- Extrinsic Time --

Model:
Time ~= 69.86
µs

Reads = 8
Writes = 6
Min Squares Analysis

-- Extrinsic Time --

Model:
Time ~= 69.86
µs

Reads = 8
Writes = 6

…n=kusama-dev --steps=50 --repeat=20 --pallet=runtime_common::paras_registrar --extrinsic=* --execution=wasm --wasm-execution=compiled --heap-pages=4096 --header=./file_header.txt --output=./runtime/kusama/src/weights/runtime_common_paras_registrar.rs
} else {
ensure!(!ensure_reserved, Error::<T>::NotReserved);
Default::default()
};
ensure!(paras::Module::<T>::lifecycle(id).is_none(), Error::<T>::AlreadyRegistered);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We might be able to loosen this restriction and allow re-registration too.

Will look into it as a follow up

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@gavofyork gavofyork merged commit 3a63304 into master May 11, 2021
@gavofyork gavofyork deleted the gav-paras-reserve-id branch May 11, 2021 20:28
@jakoblell jakoblell added the D1-audited 👍 PR contains changes to critical logic that has been properly reviewed and externally audited. label May 19, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A0-please_review Pull request needs code review. B0-silent Changes should not be mentioned in any release notes C1-low PR touches the given topic and has a low impact on builders. D1-audited 👍 PR contains changes to critical logic that has been properly reviewed and externally audited. D2-notlive 💤 PR contains changes in a runtime directory that is not deployed to a chain that requires an audit.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants