HRMP - set `DefaultChannelSizeAndCapacityWithSystem` with dynamic values...
HRMP - set `DefaultChannelSizeAndCapacityWithSystem` with dynamic values according to the `ActiveConfig` (#4332) ## Summary This PR enhances the capability to set `DefaultChannelSizeAndCapacityWithSystem` for HRMP. Currently, all testnets (Rococo, Westend) have a hard-coded value set as 'half of the maximum' determined by the live `ActiveConfig`. While this approach appears satisfactory, potential issues could arise if the live `ActiveConfig` are adjusted below these hard-coded values, necessitating a new runtime release with updated values. Additionally, hard-coded values have consequences, such as Rococo's benchmarks not functioning: https://gitlab.parity.io/parity/mirrors/polkadot-sdk/-/jobs/6082656. ## Solution The proposed solution here is to utilize `ActiveConfigHrmpChannelSizeAndCapacityRatio`, which reads the current `ActiveConfig` and calculates `DefaultChannelSizeAndCapacityWithSystem`, for example, "half of the maximum" based on live data. This way, whenever `ActiveConfig` is modified, `ActiveConfigHrmpChannelSizeAndCapacityRatio` automatically returns adjusted values with the appropriate ratio. Thus, manual adjustments and new runtime releases become unnecessary. Relates to a comment/discussion: https://github.com/paritytech/polkadot-sdk/pull/3721/files#r1541001420 Relates to a comment/discussion: https://github.com/paritytech/polkadot-sdk/pull/3721/files#r1549291588 --------- Co-authored-by: command-bot <>
Please register or sign in to comment