Coretime Order Control and Assurance

Coretime order control and assurance functions are for on-demand coretime only.

Coretime Orders and Price Control

Price Limit: The Price Limit is a parameter that sets the maximum allowable price for coretime orders. This limit ensures that users are protected from excessive costs, particularly during periods of high demand or network congestion.

Price Threshold: The Price Threshold controls profitability from gas collection.

Price Threshold=Gas Fee CollectedCoretime Price\text{Price Threshold} = \frac{\text{Gas Fee Collected}}{\text{Coretime Price}}

For example, a threshold of 0.7 means that the total gas fee collection equals 70% of the real-time on-demand coretime price, implying that a 30% loss is acceptable; a threshold of 1.6 means that the total gas fee collection equals 160% of the real-time on-demand coretime price, implying that a 60% profit is required.

Coretime Workflow:In the on-demand model, the system first checks if the current core time price is within the user-configured price limit (setting price limit = 0 disables this check). If the price exceeds the limit and Assurance is disabled, the system continuously checks until the core time price is within the limit. It then compares the gas fee with the core time cost: if (gas fee collected / core time price) > price threshold, it purchases core time; otherwise, it waits until both conditions are met. If Assurance is enabled and any condition is not met, the assurance pallet checks the difference between the current block number of the relay chain and last bid block number. If the difference is bigger than “bid threshold”, then Assurance pallet calls create_order function to place order.

Assurance Mechanism in Magnet

Magnet’s Assurance mechanism is designed to ensure the reliability and execution of coretime orders, providing a safeguard against disruptions in block production.

In cases where coretime order placement is halted by the order control mechanisms (Price Limit & Price Threshold) for an extended period, the Assurance mechanism steps in. If the halt persists beyond the defined bid threshold—measured in relay chain blocks—this function forces the placement of the coretime order, ensuring that block production continues uninterrupted.

For example, if the bid threshold is set to 8 relay chain blocks, the Assurance mechanism allows the system to pause on-demand order placement for up to 8 blocks if the Price Limit and Price Threshold conditions are not met. Beyond this threshold, the Assurance mechanism intervenes to guarantee that orders are placed and the network remains stable.

Last updated