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

[frame/im-online] remove network state from heartbeats #14251

Merged
Changes from 1 commit
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
0073c30
[frame/im-online] remove `external_addresses` from heartbeats
melekes May 26, 2023
c8218b9
remove unused import
melekes May 29, 2023
a282042
run benchmark
melekes May 29, 2023
b60c5c4
remove external_addresses from offchain NetworkState
melekes May 29, 2023
5c7956e
add missing fn to TestNetwork
melekes May 29, 2023
97b9fd2
Revert "run benchmark"
melekes May 29, 2023
cd589f6
update weights
melekes May 29, 2023
e88d7e2
address @bkchr comments
melekes May 30, 2023
1eb8086
Merge branch 'master' into anton/7181-remove-external-addresses-from-…
melekes May 30, 2023
41bca16
remove duplicate fn
melekes May 30, 2023
619a28e
cleanup benchmarking.rs
melekes May 30, 2023
aaefc66
fix executor tests
melekes May 30, 2023
57246bf
remove peer_id from hearbeat as well
melekes May 31, 2023
8e4061d
remove MaxPeerDataEncodingSize
melekes May 31, 2023
dcc7b38
change storage value type to `()`
melekes Jun 5, 2023
81d9560
scaffold storage migration
melekes Jun 6, 2023
c822c2d
no need to check the type actually
melekes Jun 6, 2023
ace0f6e
remove unnecessary types from v0 mod
melekes Jun 6, 2023
906fa96
add a test for migration
melekes Jun 6, 2023
4092dfb
expose Config types
melekes Jun 6, 2023
9538acd
fix test
melekes Jun 7, 2023
8818c18
replace dummy type with ConstU32
melekes Jun 7, 2023
eedf528
add some comments to migration test
melekes Jun 7, 2023
11c4fd7
fix comment
melekes Jun 7, 2023
aedfdb9
respond to @bkchr comments
melekes Jun 15, 2023
f8970f6
use BoundedOpaqueNetworkState::default
melekes Jun 15, 2023
fbbbd3f
Merge branch 'master' into anton/7181-remove-external-addresses-from-…
melekes Jun 15, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
replace dummy type with ConstU32
melekes committed Jun 7, 2023

Unverified

This user has not yet uploaded their public signing key.
commit 8818c1835f80fc960741357a19aa9f8139d599ef
13 changes: 6 additions & 7 deletions frame/im-online/src/migration.rs
Original file line number Diff line number Diff line change
@@ -18,7 +18,10 @@
//! Storage migrations for the im-online pallet.

use super::*;
use frame_support::{storage_alias, traits::OnRuntimeUpgrade};
use frame_support::{
storage_alias,
traits::{ConstU32, OnRuntimeUpgrade},
};

#[cfg(feature = "try-runtime")]
use frame_support::ensure;
@@ -64,12 +67,8 @@ mod v0 {
AuthIndex,
WrapperOpaque<
BoundedOpaqueNetworkState<
<T as Config>::MaxPeerInHeartbeats, /* XXX: used `MaxPeerInHeartbeats` because
* `MaxPeerDataEncodingSize` was removed in
* v1 */
<T as Config>::MaxPeerInHeartbeats, /* XXX: used `MaxPeerInHeartbeats` because
* `MaxPeerDataEncodingSize` was removed in
* v1 */
ConstU32<1_000>,
ConstU32<1_000>,
<T as Config>::MaxPeerInHeartbeats,
>,
>,