Skip to content

[pallet-broker] add extrinsic to add an assignment to the workplan#10797

Open
Stephenlawrence00 wants to merge 18 commits intoparitytech:masterfrom
Stephenlawrence00:pallet_broker_coretime
Open

[pallet-broker] add extrinsic to add an assignment to the workplan#10797
Stephenlawrence00 wants to merge 18 commits intoparitytech:masterfrom
Stephenlawrence00:pallet_broker_coretime

Conversation

@Stephenlawrence00
Copy link
Copy Markdown
Contributor

Part of #6929

This PR expands the coretime management capabilities for sudo/admin operations, enabling direct manipulation of the workplan without requiring complex migrations or runtime upgrades.

@Stephenlawrence00 Stephenlawrence00 requested a review from a team as a code owner January 14, 2026 12:39
@cla-bot-2021
Copy link
Copy Markdown

cla-bot-2021 Bot commented Jan 14, 2026

User @Stephenlawrence00, please sign the CLA here.

@Stephenlawrence00
Copy link
Copy Markdown
Contributor Author

/cmd prdoc --audience runtime_dev --bump minor

@Stephenlawrence00
Copy link
Copy Markdown
Contributor Author

@seadanda @bkchr Also ready for review

Copy link
Copy Markdown
Contributor

@seadanda seadanda left a comment

Choose a reason for hiding this comment

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

Nearly there, thanks. Needs fmt and benches to be run (we can run benches when we're done)

Comment thread substrate/frame/broker/src/dispatchable_impls.rs Outdated
Comment thread substrate/frame/broker/src/lib.rs Outdated
Comment thread substrate/frame/broker/src/lib.rs Outdated
Comment thread substrate/frame/broker/src/dispatchable_impls.rs Outdated
Comment thread substrate/frame/broker/src/dispatchable_impls.rs
@seadanda
Copy link
Copy Markdown
Contributor

/cmd fmt

Stephenlawrence00 and others added 5 commits February 13, 2026 11:10
Co-authored-by: Dónal Murray <donalm@seadanda.dev>
Co-authored-by: Dónal Murray <donalm@seadanda.dev>
Co-authored-by: Dónal Murray <donalm@seadanda.dev>
Co-authored-by: Dónal Murray <donalm@seadanda.dev>
@Stephenlawrence00
Copy link
Copy Markdown
Contributor Author

@seadanda Done. please run benches

@Stephenlawrence00
Copy link
Copy Markdown
Contributor Author

/cmd bench --pallet pallet_broker

@github-actions
Copy link
Copy Markdown
Contributor

Command "bench --pallet pallet_broker" has started 🚀 See logs here

@github-actions
Copy link
Copy Markdown
Contributor

Command "bench --pallet pallet_broker" has finished ✅ See logs here

Details

Subweight results:
File Extrinsic Old New Change [%]
substrate/frame/assets/src/weights.rs destroy_accounts 16.10ms 265.61ms +1549.73
substrate/frame/assets/src/weights.rs transfer_keep_alive 52.87us 542.96us +927.04
substrate/frame/assets/src/weights.rs force_create 16.19us 163.00us +906.81
substrate/frame/assets/src/weights.rs force_set_metadata 17.25us 163.99us +850.63
substrate/frame/assets/src/weights.rs force_transfer 57.68us 547.58us +849.31
substrate/frame/assets/src/weights.rs transfer 58.05us 547.77us +843.60
substrate/frame/assets/src/weights.rs refund 43.47us 409.98us +843.04
substrate/frame/assets/src/weights.rs touch 45.71us 411.64us +800.54
substrate/frame/assets/src/weights.rs mint 33.02us 276.62us +737.79
substrate/frame/assets/src/weights.rs transfer_approved 83.20us 694.48us +734.69
substrate/frame/assets/src/weights.rs transfer_ownership 20.87us 166.89us +699.74
substrate/frame/assets/src/weights.rs transfer_all 69.82us 556.80us +697.44
substrate/frame/assets/src/weights.rs create 39.02us 306.52us +685.52
substrate/frame/assets/src/weights.rs force_asset_status 18.29us 139.80us +664.40
substrate/frame/assets/src/weights.rs destroy_approvals 18.45ms 140.95ms +664.03
substrate/frame/assets/src/weights.rs set_reserves 20.85us 157.97us +657.73
substrate/frame/assets/src/weights.rs finish_destroy 22.19us 166.16us +648.73
substrate/frame/assets/src/weights.rs set_team 18.79us 139.86us +644.39
substrate/frame/assets/src/weights.rs freeze_asset 18.95us 140.41us +641.00
substrate/frame/assets/src/weights.rs thaw_asset 19.12us 140.28us +633.63
substrate/frame/assets/src/weights.rs start_destroy 19.34us 140.43us +625.97
substrate/frame/assets/src/weights.rs set_min_balance 19.53us 140.50us +619.39
substrate/frame/assets/src/weights.rs block 24.39us 170.10us +597.52
substrate/frame/assets/src/weights.rs thaw 24.39us 169.87us +596.46
substrate/frame/assets/src/weights.rs freeze 24.60us 169.80us +590.27
substrate/frame/assets/src/weights.rs refund_other 41.21us 283.21us +587.25
substrate/frame/assets/src/weights.rs burn 42.19us 284.66us +574.78
substrate/frame/assets/src/weights.rs touch_other 43.34us 284.52us +556.46
substrate/frame/assets/src/weights.rs approve_transfer 44.13us 284.98us +545.69
substrate/frame/assets/src/weights.rs force_cancel_approval 45.19us 286.58us +534.16
substrate/frame/assets/src/weights.rs cancel_approval 45.69us 286.88us +527.86
substrate/frame/assets/src/weights.rs force_clear_metadata 37.55us 180.30us +380.15
substrate/frame/assets/src/weights.rs clear_metadata 38.77us 180.68us +366.02
substrate/frame/assets/src/weights.rs set_metadata 39.95us 181.91us +355.32
substrate/frame/assets/src/weights.rs balance 11.46us 34.41us +200.13
substrate/frame/assets/src/weights.rs total_issuance 11.46us 34.09us +197.49
substrate/frame/assets/src/weights.rs allowance 14.86us 36.88us +148.18
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs on_new_timeslice 30.25us 73.43us +142.79
cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_conviction_voting.rs remove_vote 432.34us 704.98us +63.06
substrate/frame/broker/src/weights.rs request_core_count 3.99us 6.38us +59.91
cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_conviction_voting.rs vote_existing 767.90us 1.01ms +31.72
cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_conviction_voting.rs delegate 71.45ms 89.13ms +24.75
substrate/frame/broker/src/weights.rs on_new_timeslice 251.00ns 313.00ns +24.70
cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_conviction_voting.rs undelegate 71.21ms 88.55ms +24.35
substrate/frame/broker/src/weights.rs request_revenue_info_at 184.00ns 219.00ns +19.02
cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_conviction_voting.rs remove_other_vote 260.52us 245.94us -5.60
cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_conviction_voting.rs unlock 619.20us 510.44us -17.56
substrate/frame/broker/src/weights.rs purchase_credit 171.45us 54.47us -68.23
substrate/frame/broker/src/weights.rs drop_history 261.46us 81.11us -68.98
substrate/frame/broker/src/weights.rs drop_contribution 226.35us 62.01us -72.60
substrate/frame/broker/src/weights.rs drop_region 186.28us 48.61us -73.91
substrate/frame/broker/src/weights.rs drop_renewal 191.67us 49.71us -74.07
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs drop_history 328.00us 84.93us -74.11
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs drop_region 218.23us 54.26us -75.14
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs drop_renewal 205.11us 50.77us -75.25
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs purchase_credit 371.54us 88.62us -76.15
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs drop_contribution 311.26us 67.73us -78.24
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs reserve 150.27us 29.97us -80.05
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs unreserve 149.70us 29.03us -80.61
substrate/frame/broker/src/weights.rs partition 242.93us 47.08us -80.62
substrate/frame/broker/src/weights.rs reserve 140.42us 27.13us -80.68
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs partition 248.38us 47.38us -80.92
substrate/frame/broker/src/weights.rs unreserve 139.62us 26.25us -81.20
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs assign 336.47us 62.04us -81.56
substrate/frame/broker/src/weights.rs disable_auto_renew 140.21us 25.69us -81.68
substrate/frame/broker/src/weights.rs assign 332.04us 60.01us -81.93
substrate/frame/broker/src/weights.rs purchase 287.54us 51.53us -82.08
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs renew 653.89us 113.54us -82.64
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs request_core_count 196.49us 33.18us -83.11
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs transfer 146.75us 24.49us -83.31
substrate/frame/broker/src/weights.rs remove_assignment 140.78us 23.41us -83.37
substrate/frame/broker/src/weights.rs transfer 141.40us 23.40us -83.45
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs purchase 456.78us 75.06us -83.57
cumulus/parachains/runtimes/assets/asset-hub-westend/src/weights/pallet_conviction_voting.rs vote_new 4.94ms 812.15us -83.57
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs remove_assignment 146.87us 24.12us -83.58
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs disable_auto_renew 143.78us 21.77us -84.86
substrate/frame/broker/src/weights.rs remove_potential_renewal 147.58us 21.70us -85.30
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs remove_potential_renewal 144.22us 21.02us -85.42
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs enable_auto_renew 911.33us 130.80us -85.65
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs interlace 349.67us 50.02us -85.69
substrate/frame/broker/src/weights.rs interlace 344.21us 48.32us -85.96
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs force_reserve 417.83us 55.85us -86.63
substrate/frame/broker/src/weights.rs set_lease 132.71us 17.56us -86.77
substrate/frame/broker/src/weights.rs renew 572.33us 73.83us -87.10
substrate/frame/broker/src/weights.rs claim_revenue 725.23us 93.16us -87.15
substrate/frame/broker/src/weights.rs remove_lease 132.34us 16.91us -87.23
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs process_revenue 550.62us 69.96us -87.29
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs request_revenue_info_at 191.39us 23.85us -87.54
substrate/frame/broker/src/weights.rs enable_auto_renew 834.47us 102.08us -87.77
substrate/frame/broker/src/weights.rs process_revenue 414.96us 50.71us -87.78
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs claim_revenue 728.04us 88.76us -87.81
substrate/frame/broker/src/weights.rs force_reserve 403.07us 46.27us -88.52
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs process_core_schedule 457.11us 45.88us -89.96
substrate/frame/broker/src/weights.rs swap_leases 129.63us 12.40us -90.43
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs remove_lease 135.72us 12.32us -90.92
substrate/frame/broker/src/weights.rs process_core_schedule 262.12us 23.33us -91.10
substrate/frame/broker/src/weights.rs do_tick_base 210.65us 18.24us -91.34
substrate/frame/broker/src/weights.rs process_pool 130.31us 11.02us -91.55
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs set_lease 188.45us 15.40us -91.83
substrate/frame/broker/src/weights.rs process_core_count 131.08us 10.47us -92.01
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs process_core_count 133.45us 10.05us -92.47
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs pool 668.18us 48.65us -92.72
substrate/frame/broker/src/weights.rs pool 664.63us 47.30us -92.88
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs process_pool 133.15us 9.33us -93.00
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs do_tick_base 239.51us 15.65us -93.47
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs swap_leases 132.63us 8.42us -93.65
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs start_sales 3.00ms 141.20us -95.29
substrate/frame/broker/src/weights.rs start_sales 1.83ms 77.02us -95.79
substrate/frame/broker/src/weights.rs configure 102.15us 3.53us -96.54
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs configure 102.79us 3.51us -96.58
substrate/frame/broker/src/weights.rs notify_revenue 102.07us 3.42us -96.65
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs notify_revenue 102.68us 3.40us -96.69
substrate/frame/broker/src/weights.rs notify_core_count 101.91us 3.18us -96.88
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs notify_core_count 102.57us 3.19us -96.89
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs rotate_sale 108.90ms 2.78ms -97.44
substrate/frame/broker/src/weights.rs rotate_sale 105.70ms 2.09ms -98.03
substrate/frame/broker/src/weights.rs add_assignment 27.78us Added
cumulus/parachains/runtimes/coretime/coretime-westend/src/weights/pallet_broker.rs add_assignment 24.31us Added
Command output:

✅ Successful benchmarks of runtimes/pallets:
-- dev: ['pallet_broker']
-- coretime-westend: ['pallet_broker']

@seadanda
Copy link
Copy Markdown
Contributor

/cmd bench --pallet pallet_broker

Benchmarking gave incorrect results. Needed to update from master to include #10947

@seadanda seadanda added the T2-pallets This PR/Issue is related to a particular pallet. label Feb 13, 2026
@Stephenlawrence00
Copy link
Copy Markdown
Contributor Author

/cmd bench --pallet pallet_broker

Benchmarking gave incorrect results. Needed to update from master to include #10947

Hmm, I see.
help run the benchmarks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

T2-pallets This PR/Issue is related to a particular pallet.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants