Expand description
§Pallet Broker
Brokerage tool for managing Polkadot Core scheduling.
Properly described in RFC-0001 Agile Coretime.
§Implementation Specifics
§Core Mask Bits
This is 1/80th of a Polkadot Core per timeslice. Assuming timeslices are 80 blocks, then this indicates usage of a single core one time over a timeslice.
§The Sale
1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7
--------------------------------------------------------
< interlude >
< sale >
... of which ...
< descending-price >< fixed-price >
| <-------\
price fixed, unsold assigned to instapool, system cores reserved -/
Re-exports§
pub use weights::WeightInfo;
pub use pallet::*;
Modules§
- migration
- pallet
- The
pallet
module in each FRAME pallet hosts the most important items needed to construct this pallet. - runtime_
api - Runtime API definition for the FRAME Broker pallet.
- weights
- Autogenerated weights for
pallet_broker
Structs§
- Adapted
Prices - Result of
AdaptPrice::adapt_price
. - Auto
Renewal Record - A record containing information regarding auto-renewal for a specific core.
- Center
Target Price - Simple implementation of
AdaptPrice
with two linear phases. - Config
Record - Configuration of this pallet.
- Contribution
Record - The record body of a Region which was contributed to the Instantaneous Coretime Pool. This helps with making pro rata payments to contributors.
- Core
Mask - Insta
Pool History Record - A per-timeslice bookkeeping record for tracking Instantaneous Coretime Pool activity and making proper payments to contributors.
- Lease
Record Item - Information on a single legacy lease.
- OnDemand
Revenue Record - Record for On demand core sales.
- Pool
IoRecord - A record of flux in the InstaPool.
- Potential
Renewal Id - The identity of a possibly renewable Core workload.
- Potential
Renewal Record - A record of a potential renewal.
- Region
Id - Self-describing identity for a Region of Bulk Coretime.
- Region
Record - The rest of the information describing a Region.
- Sale
Info Record - The status of a Bulk Coretime Sale.
- Sale
Performance - Performance of a past sale.
- Schedule
Item - An distinct item which can be scheduled on a Polkadot Core.
- Status
Record - General status of the system.
Enums§
- Completion
Status - How much of a core has been assigned or, if completely assigned, the workload itself.
- Core
Assignment - An element to which a core can be assigned.
- Finality
- Whether a core assignment is revokable or not.
Constants§
- CORE_
MASK_ BITS - The number of bits in the
CoreMask
.
Traits§
- Adapt
Price - Type for determining how to set price.
- Coretime
Interface - Type able to accept Coretime scheduling instructions and provide certain usage information. Generally implemented by the Relay-chain or some means of communicating with it.
Type Aliases§
- Balance
Of - Config
Record Of - Contribution
Record Of - Core
Index - Index of a Polkadot Core.
- Core
Mask BitCount - Counter for the total number of set bits over every core’s
CoreMask
.u32
so we don’t ever get an overflow. This is 1/80th of a Polkadot Core per timeslice. Assuming timeslices are 80 blocks, then this indicates usage of a single core one time over a timeslice. - Insta
Pool History Record Of - Leases
Record - Record for Polkadot Core legacy leases.
- Leases
Record Of - OnDemand
Revenue Record Of - Parts
Of57600 - Fraction expressed as a nominator with an assumed denominator of 57,600.
- Potential
Renewal Record Of - RCBlock
Number Of - Relay chain block number of
T
that implementsCoretimeInterface
. - RCBlock
Number Provider Of - Relay chain block number provider of
T
that implementsCoretimeInterface
. - Region
Record Of - Relay
Account IdOf - Relay
Balance Of - Relay
Block Number Of - Reservations
Record - Record for Polkadot Core reservations (generally tasked with the maintenance of System Chains).
- Reservations
Record Of - Sale
Info Record Of - Schedule
- Signed
Core Mask BitCount - The same as
CoreMaskBitCount
but signed. - TaskId
- A Task Id. In general this is called a ParachainId.
- Timeslice
- Relay-chain block number with a fixed divisor of Config::TimeslicePeriod.