A method and system for device and database adaptive prescheduled handover
Patent Information
- Application Number
- CN202611149735.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-31
- Publication Date
- 2026-10-13
AI Technical Summary
其一,现有预测式调度方案均采用点估计方式输出单一预测值,决策环节基于该点估计直接触发动作,未考虑预测本身可能存在的误差和不确定性,导致在模型置信度较低的场景下容易做出错误决策,或过早执行预调度造成资源浪费,或过晚响应导致故障蔓延
第一,预调度触发时机的动态优化效果。
Smart Images

Figure CN122903395A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of data resource allocation technology, specifically to a method and system for adaptive pre-scheduling switching between devices and databases. Background Technology
[0002] With the deepening of digital transformation, complex application systems comprising front-end device clusters and back-end databases have become the infrastructure for key areas such as financial transactions, industrial control, and e-commerce. In such systems, device task scheduling and database resource management belong to different operation and maintenance planes, and the efficiency of their collaboration directly determines the overall service quality and stability of the system. In recent years, regarding elastic scheduling and failover of databases, the industry has gradually evolved from manual operation and maintenance relying solely on human experience to automatic switching based on fixed thresholds of monitoring indicators, and then to intelligent scheduling incorporating time series prediction or reinforcement learning models. For example, existing solutions monitor database performance indicators in real time and use predictive models to estimate future load trends, with the decision engine outputting elastic scheduling instructions; other solutions proactively trigger master node switching based on multi-dimensional performance scores and dynamic migration thresholds, aiming to complete resource adjustments before failures occur.
[0003] However, existing technologies still have several problems that urgently need to be addressed. First, existing predictive scheduling schemes all use point estimation to output a single predicted value. The decision-making process directly triggers actions based on this point estimate, without considering the potential errors and uncertainties in the prediction itself. This can lead to incorrect decisions in scenarios with low model confidence, premature pre-scheduling resulting in resource waste, or delayed response leading to fault propagation. Second, pre-scheduling triggering mechanisms are mostly based on fixed threshold conditions, lacking the ability to dynamically optimize the triggering timing based on the real-time system status, and unable to make the most cost-effective choice between "immediate action" and "continued waiting." Third, when it is necessary to perform primary / standby switching or task migration, the strategy selection criteria of existing schemes are relatively singular, either relying on manually set fixed rules or on comprehensive scoring functions that require manual weighting. This lacks awareness of prediction confidence and cannot achieve differentiated scheduling based on business levels. Fourth, in schemes that introduce reinforcement learning, the multi-objective weights of the reward function still require repeated manual trial and error setting, resulting in strong subjectivity and poor generalization ability.
[0004] To address the aforementioned shortcomings, this invention proposes a method and system for adaptive pre-scheduling switching between devices and databases. By introducing prediction uncertainty as a core decision variable into the complete decision-making link of pre-scheduling timing determination and strategy matching, autonomous scheduling with zero manual weight setting is achieved throughout the entire link. This overcomes the defects in existing technologies, such as decision-making being detached from prediction confidence, static and rigid triggering mechanisms, and lack of business awareness in strategy selection. Summary of the Invention
[0005] To address the aforementioned problems in the existing technology, this invention provides a technical solution for adaptive pre-scheduling switching between devices and databases.
[0006] According to a first aspect of the present invention, a method for adaptive pre-scheduling switching between devices and databases is proposed, comprising the following steps: S1: Collect real-time operating metrics of the database and front-end devices to determine the current system status; S2: Input the current system state into the trained quantile distributed reinforcement learning network and output the probability distribution of future risk values; calculate the risk coefficient and cognitive uncertainty based on the probability distribution, whereby cognitive uncertainty is used to characterize the degree of dispersion of the probability distribution; S3: Substitute the probability distribution into the optimal stopping decision framework, calculate the expected cost of immediately executing the pre-scheduled action and the expected cost of continuing to wait for observation, and use the difference between the expected cost of continuing to wait for observation and the expected cost of immediately executing the pre-scheduled action as the decision basis; when the difference meets the preset triggering conditions, generate a pre-scheduled action suggestion; S4: Obtain the current business level label, and select the optimal switching strategy from the preset strategy pool based on the risk coefficient, cognitive uncertainty and the current business level label through a multi-attribute decision-making method. S5: Combine the pre-scheduled action suggestion with the optimal switching strategy into an executable instruction and issue it for execution.
[0007] According to some embodiments, in the method of the first aspect of the present invention, the quantile distributed reinforcement learning network in step S2 is an implicit quantile network. The implicit quantile network takes the current system state vector and the randomly sampled quantile as input and outputs the risk value corresponding to the quantile. By sampling and fitting multiple quantiles, the probability distribution of future risk values is obtained.
[0008] According to some embodiments, in the method of the first aspect of the present invention, cognitive uncertainty is characterized by the difference between the risk value corresponding to the preset high quantile and the risk value corresponding to the preset low quantile of the probability distribution; the risk coefficient is characterized by the mean of the probability distribution.
[0009] According to some embodiments, in the method of the first aspect of the present invention, the expected cost of immediately performing the pre-scheduling action in step S3 includes the resource consumption cost and business impact cost of performing the pre-scheduling action; the expected cost of continuing to wait for observation includes the failure loss cost that may occur during system operation if the pre-scheduling is not performed; the expected cost is calculated based on the conditional value of risk of the probability distribution.
[0010] According to some embodiments, in the method of the first aspect of the present invention, the conditional risk value is the expected value of the worst preset quantile of the probability distribution; when the difference is greater than zero, a pre-scheduling action is triggered, indicating that the expected cost of continuing to wait for observation is higher than the expected cost of immediately executing pre-scheduling, and immediately executing pre-scheduling is better.
[0011] According to some embodiments, in the method of the first aspect of the present invention, the preset strategy pool in step S4 includes: a first strategy, performing a switch from read traffic to the standby database; a second strategy, performing a preloading or expansion operation determined based on risk prediction results; and a third strategy, performing a complete switchover between primary and standby databases, a full cache rebuild, and a device task migration.
[0012] According to some embodiments, in the method of the first aspect of the present invention, the multi-attribute decision-making method in step S4 is the entropy weight method, which includes: collecting the performance values of each candidate strategy on multiple evaluation attributes in historical decisions and constructing a decision matrix; normalizing the decision matrix and calculating the information entropy of each attribute; calculating the weight of each attribute based on the information entropy; calculating the basic score of each candidate strategy according to the weight; using cognitive uncertainty as a correction factor to correct the basic score and obtain the final score of each candidate strategy; and selecting the strategy with the highest final score as the optimal switching strategy.
[0013] According to some embodiments, in the method of the first aspect of the present invention, multiple evaluation attributes include security gain, resource overhead, and business impact; security gain is the expected decrease in risk coefficient after implementing the strategy, resource overhead is the amount of additional system resources occupied by implementing the strategy, and business impact is determined based on business level labels.
[0014] According to some embodiments, in the method of the first aspect of the present invention, cognitive uncertainty is used as a correction factor to correct the basic score. Specifically, this includes: pre-setting a safety reserve factor for each candidate strategy, wherein the relative magnitude of the safety reserve factor among the strategies is positively correlated with the switching intensity of the strategy, wherein the safety reserve factor corresponding to the candidate strategy with the smallest switching intensity is negative, and the safety reserve factor corresponding to the candidate strategy with the largest switching intensity is the largest positive value among all candidate strategies; the product of cognitive uncertainty, safety reserve factor, and adjustment coefficient is used as a correction term and added to the basic score to obtain the final score of each candidate strategy; the adjustment coefficient is determined according to the principle of matching the magnitude of the correction term with the basic score.
[0015] According to a second aspect of the present invention, a system for adaptive pre-scheduling switching between devices and databases is provided, comprising: The data acquisition module is used to collect real-time operating indicators of the database and front-end devices as the current system status; The risk prediction module is used to input the current system state into a trained quantile distributed reinforcement learning network, output the probability distribution of future risk values, and calculate the risk coefficient and cognitive uncertainty based on the probability distribution. The pre-scheduling decision module is used to substitute the probability distribution into the optimal stopping decision framework to calculate the expected cost of immediately executing the pre-scheduling action and the expected cost of continuing to wait for observation, respectively. The difference between the expected cost of continuing to wait for observation and the expected cost of immediately executing the pre-scheduling action is used as the decision basis. When the difference meets the preset triggering conditions, a pre-scheduling action suggestion is generated. The strategy matching module is used to obtain the level label of the current business and select the optimal switching strategy from the preset strategy pool based on the risk coefficient, cognitive uncertainty and the level label of the current business through a multi-attribute decision-making method. The execution module is used to merge pre-scheduled action suggestions and optimal switching strategies into executable instructions and issue them for execution.
[0016] Compared with the prior art, the present invention provides the following beneficial effects: First, the dynamic optimization effect of pre-scheduled triggering timing.
[0017] By modeling the pre-scheduling timing determination as an optimal stopping problem and using the probability distribution of the distributed quantile reinforcement learning network output as the data-driven input to the cost function, the system can make dynamic decisions based on expected cost comparisons between "immediately executing pre-scheduling" and "continuing to wait for observation." This mechanism replaces the static triggering method with a fixed threshold in existing technologies, helping to avoid resource waste caused by premature pre-scheduling and fault propagation caused by late pre-scheduling, and enabling the timing of pre-scheduling actions to adaptively adjust according to the real-time state of the system.
[0018] Second, the decision robustness of prediction confidence perception is improved.
[0019] By using a distributed quantile reinforcement learning network to output the complete probability distribution of future risk values, and extracting cognitive uncertainty as an independent decision-making dimension from this distribution, the system can perceive the reliability of its own predictions. When cognitive uncertainty is high, the system automatically increases the scoring weight of strategies with larger safety reserve factors, causing the switching strategy selection to favor a more conservative end-to-end takeover scheme; when cognitive uncertainty is low, the system can prioritize lightweight strategies while ensuring safety. This mechanism solves the problem of the disconnect between the decision-making process and prediction confidence in existing technologies, and helps improve the system's decision robustness in scenarios at the cognitive boundaries of the model.
[0020] Third, the matching of differentiated strategies and business awareness.
[0021] By pre-setting a policy pool with three granularities—lightweight hot standby, elastic buffering, and full-link takeover—and combining business level tags as input dimensions for multi-attribute decision-making, the system can match differentiated switching solutions based on the core nature of the current business. For database instances carrying high-value businesses such as core transactions, the system automatically increases the weight of security gains and business impact attributes in policy selection; for non-core businesses, the system can prioritize policies with lower resource overhead while ensuring basic availability. This mechanism aligns switching strategies with business value, helping to avoid unnecessary service disruptions to non-core businesses due to excessive governance.
[0022] Fourth, the burden of autonomous decision-making and operation and maintenance across the entire chain is reduced.
[0023] By automatically calculating the weights of each evaluation attribute from historical decision-making data using the entropy weight method, and by automating reward generation for reinforcement learning training through a reward construction mechanism using counterfactual baselines and dynamic Lagrange multipliers, the system eliminates the need for manual setting of thresholds or weight parameters throughout the entire chain from data collection, risk prediction, pre-scheduling decision-making to policy matching. This mechanism reduces the system's reliance on the experience of operations and maintenance experts, helps reduce the workload of manual parameter tuning, and improves the solution's generalization and migration capabilities across different business scenarios.
[0024] Fifth, the system's observability and ability to continuously evolve are enhanced.
[0025] By writing back the complete decision-making process—including input state, prediction distribution, cognitive uncertainty, cost difference, policy score, and execution result—to the log system, operations personnel can trace the decision-making basis for any pre-scheduled action. Simultaneously, the positive and negative feedback from the execution results is continuously used to accumulate subsequent training data, helping to drive continuous iterative optimization of the model.
[0026] Sixth, the balance between resource utilization efficiency and system stability.
[0027] By embedding the resource consumption budget constraint into the reward signal in the form of a dynamic Lagrange multiplier, the resource overhead of pre-scheduled actions during reinforcement learning training is automatically constrained within a preset budget range. This mechanism effectively restricts resource consumption while the system pursues security gains, helping to maintain a balance between resource utilization efficiency and system stability, and preventing excessive pre-scheduling from consuming resources needed for normal business operations. Attached Figure Description
[0028] Figure 1 This is a flowchart illustrating an embodiment 1000 of the device and database adaptive pre-scheduling switching method of the present invention; Figure 2 for Figure 1 A flowchart illustrating step S4 of Example 1000; Figure 3 for Figure 2 A flowchart illustrating the basic score correction step S4A in step S4; Figure 4 This is a schematic diagram of an embodiment 2000 of the device and database adaptive pre-scheduling switching system of the present invention. Detailed Implementation
[0029] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0030] Figure 1 This is a flowchart illustrating an embodiment 1000 of the device and database adaptive pre-scheduling switching method of the present invention. Figure 1 As shown, Example 1000 includes steps S1-S5.
[0031] In step S1, real-time operating metrics of the database and front-end devices are collected as the current system status.
[0032] The system state vector comprises two dimensions: device-side metrics and database-side metrics. Device-side metrics include, but are not limited to: CPU utilization, memory utilization, network I / O throughput, number of currently running tasks, and online status of front-end devices. Database-side metrics include, but are not limited to: queries per second (QPS) and transactions per second (TPS) of the database cluster, the number of currently active and idle connections in the database connection pool, data synchronization latency between the primary and secondary nodes, the ratio of used storage capacity to total storage capacity, and the number of transactions currently in a lock-waiting state.
[0033] The aforementioned metrics are collected at a fixed frequency by monitoring agents deployed on each node. The collected results are then aggregated to form the current system state vector. This serves as the input for step S2. To control the computational complexity of the model, the dimension of the system state vector is limited to 20. The specific types of indicators collected can be configured based on the availability of monitoring data in the actual deployment environment. Optionally, the collection frequency is once every 10 seconds.
[0034] Step S1 simultaneously collects two types of heterogeneous indicators from the front-end device side and the database side to construct a unified system state vector. Compared with the existing technology where device monitoring and database monitoring belong to different management planes, this solution, through the fusion perception of cross-domain indicators, enables the subsequent risk prediction model to capture the temporal correlation between changes in device load and database performance degradation, providing a data foundation for cross-level coordinated decision-making.
[0035] In step S2, the current system state is input into the trained quantile distributed reinforcement learning network, which outputs the probability distribution of future risk values and calculates the risk coefficient and cognitive uncertainty based on the probability distribution. Cognitive uncertainty is used to characterize the degree of dispersion of the probability distribution.
[0036] Quantile distributed reinforcement learning networks are implicit quantile networks. These networks take the current system state vector and randomly sampled quantiles as input and output the risk value corresponding to that quantile. By sampling and fitting multiple quantiles, a probability distribution of future risk values is obtained. Cognitive uncertainty is characterized by the difference between the risk value corresponding to a preset high quantile and a preset low quantile in the probability distribution; the risk coefficient is characterized by the mean of the probability distribution.
[0037] (I) Structure of Distributed Quantile Reinforcement Learning Network In some specific embodiments, the distributed quantile reinforcement learning network is an implicit quantile network (IQN). The IQN network adopts a multilayer perceptron (MLP) architecture, and its input layer receives two parts of data: the first part is the current system state vector output in step S1. The second part is the quantile τ obtained by randomly sampling from the interval [0,1]. After forward propagation through several fully connected layers and activation functions, the network outputs the risk value corresponding to this quantile τ. .
[0038] In practice, by sampling the quantile τ multiple times, the risk value corresponding to each quantile is combined into a set. This set constitutes a discrete approximation of the probability distribution of future risk values. The training of the IQN network is performed offline; the specific training method will be detailed in subsequent embodiments. During the online inference phase, only the forward propagation calculation of the network is performed; gradient backpropagation or network parameter updates are not involved to ensure that the latency of a single inference meets the requirements of real-time decision-making.
[0039] In some specific embodiments, the number of quantile samples is preset to 32. This value is based on the following: too few samples, such as 8 or 16, will result in insufficient approximate accuracy of the probability distribution, affecting the accuracy of subsequent calculations of risk coefficients and cognitive uncertainty; too many samples, such as more than 64, will increase the dimensionality of the network output layer and the computational cost of forward propagation, potentially affecting the real-time performance of online inference. In the engineering implementation of IQN, 32 is a commonly used default value for the number of samples. In scenarios with ample computational resources and higher requirements for prediction accuracy, it can be appropriately increased to 64, but it is generally not recommended to exceed this upper limit. In earlier quantile reinforcement learning methods such as QR-DQN, the number of samples can reach 200 to obtain a more refined quantile distribution, but its network size and computational overhead also increase accordingly. The 32 sampling points used in this scheme for IQN represent a balance between accuracy and efficiency.
[0040] Compared to existing technologies where point estimation outputs only convey a single numerical information, this scheme outputs a complete probability distribution through an IQN network. This allows subsequent decision-making processes to not only understand the magnitude of the risk but also the accuracy of the prediction and the complete distribution of risk values. This richness of information provides the data prerequisites for the CVaR-based tail risk-sensitive decision-making in step S3 and the uncertainty-driven strategy correction in step S4.
[0041] (ii) Calculation of risk coefficient and cognitive uncertainty Based on the probability distribution of the IQN network output, calculate the following two metrics.
[0042] One is the risk coefficient. The risk coefficient represents the average risk level under the current system state. It is characterized by the mean of the probability distribution and is calculated using the following formula:
[0043] Where n is the number of samples for the quantile. Let be the value at risk corresponding to the i-th quantile. The higher the value, the greater the expected risk of the current system state.
[0044] Secondly, cognitive uncertainty. Cognitive uncertainty is characterized by the confidence level of the model in predicting the current state. It is represented by the dispersion of the probability distribution. In some specific embodiments, cognitive uncertainty is measured as the difference between the value at risk corresponding to a preset high quantile and the value at risk corresponding to a preset low quantile in the probability distribution.
[0045] in For the preset high quantile, This is the preset low quantile. The larger the value, the more dispersed the probability distribution of the model output, meaning the more uncertain the model's prediction of the current state. The smaller the value, the more concentrated the probability distribution of the model output, meaning the more confident the model is in predicting the current state.
[0046] This scheme quantifies cognitive uncertainty by using the difference between high and low quantiles, transforming the confidence level of model predictions into a computable numerical metric. This metric does not rely on additional Bayesian inference or ensemble learning methods; it is extracted directly from the quantile output of the IQN network, resulting in extremely low computational cost and mathematical compatibility with subsequent optimal stopping decisions and policy adjustments.
[0047] Risk coefficient and cognitive uncertainty After the calculation is completed, it will be used as the input parameters for steps S3 and S4, which will be used to determine the pre-scheduling timing and select the optimal switching strategy, respectively.
[0048] In some specific embodiments, the high quantile is preset to 0.9, and the low quantile is preset to 0.1. Measuring cognitive uncertainty requires selecting two quantiles that reflect the dispersion of the tails of the probability distribution. Choosing 0.1 and 0.9 corresponds to the left and right tails of the probability distribution, respectively. The difference between the high and low quantiles covers 80% of the middle range of the probability distribution, effectively reflecting the overall dispersion. If quantiles too close to the middle, such as 0.4 and 0.6, are chosen, the interval is too narrow, and the perception of changes in the tails of the distribution is insufficient; if tails too extreme, such as 0.01 and 0.99, they are easily affected by noise points, and the stability of the measurement decreases. The combination of 0.1 and 0.9 is widely used in the field of uncertainty quantification, achieving a balance between sensitivity and stability.
[0049] In step S3, the probability distribution is substituted into the optimal stopping decision framework to calculate the expected cost of immediately executing the pre-scheduled action and the expected cost of continuing to wait for observation. The difference between the expected cost of continuing to wait for observation and the expected cost of immediately executing the pre-scheduled action is used as the decision basis. When the difference meets the preset triggering condition, a pre-scheduled action suggestion is generated.
[0050] In some specific embodiments, the expected cost of immediately executing a pre-scheduled action includes the resource consumption cost and business impact cost of executing the pre-scheduled action; the expected cost of continuing to wait for observation includes the failure loss cost that may occur during system operation if pre-scheduling is not executed; the expected cost is calculated based on the conditional value of risk of the probability distribution. Optionally, the conditional value of risk is taken as the expected value of the worst preset quantile of the probability distribution; when the difference is greater than zero, the pre-scheduled action is triggered, indicating that the expected cost of continuing to wait for observation is higher than the expected cost of immediately executing pre-scheduling, and immediately executing pre-scheduling is better.
[0051] In step S3, the probability distribution of future risk values output in step S2 is substituted into the optimal stopping decision framework. By comparing the "expected cost of immediately executing the pre-scheduled action" with the "expected cost of continuing to wait for observation", it is determined whether the current moment is the optimal time to execute the pre-scheduled action.
[0052] (I) Modeling the Optimal Stopping Problem The pre-scheduling timing determination is modeled as an optimal stopping problem. The system observes the current system state at each decision time step t. Based on the probability distribution output in step S2, the expected costs of the two decision options are calculated.
[0053] Option 1 is to execute the pre-scheduled action immediately. The expected cost for this option is... Defined as the sum of all costs incurred immediately after the execution of the pre-scheduled action, including but not limited to: the additional CPU and memory resource costs consumed in the execution of resource pre-allocation, and the instantaneous interference costs that may be caused to normal business processing during the execution of read / write permission switching or master / slave switching.
[0054] Option two is to continue waiting for observation. The expected cost of this option is... Defined as the potential failure costs of the system over a future period, assuming no pre-scheduled actions are performed in the current decision cycle and the system remains in an observation state. These costs include, but are not limited to: service timeout losses due to increased database response latency, service rejection losses due to connection pool exhaustion, and service interruption losses due to node failures.
[0055] This approach combines optimal stopping theory with the probability distribution output by the IQN network. This allows the cost function within the optimal stopping framework to no longer rely on pre-defined probability distribution assumptions, but instead directly draws input from a data-driven quantile distribution. Compared to the limitations of traditional optimal stopping theory, which requires pre-assuming that the risk state follows a certain parameter distribution, this approach's cost function can adapt to any form of risk distribution and has stronger generalization capabilities.
[0056] (ii) Calculation of expected cost based on conditional value of risk The aforementioned expected cost is calculated based on the Conditional Value at Risk (CVaR) of the probability distribution output in step S2. CVaR refers to the expected loss exceeding the Value at Risk (VaR) at a preset confidence level, i.e., the expected value of the worst-case preset quantile segment of the probability distribution. The calculation of CVaR only requires using the quantiles in the quantile set output by the IQN network that belong to the worst-case quantile segment. The arithmetic mean of the Value at Risk corresponding to the quantiles falling into this quantile segment yields an approximate value of CVaR. This calculation process does not involve complex integration or iteration; it is only a simple arithmetic average and can be completed within microseconds.
[0057] Conditional Value at Risk (CVaR) effectively captures the tails of probability distributions, representing the worst-case risk information. This allows decisions to be made without relying on assumptions about the distribution's shape, instead extracting the tail mean directly from the quantile set output by the IQN network. Compared to using only expected value or mean for decision-making, CVaR is more sensitive to extreme risks, enabling the system to adopt more conservative pre-scheduling strategies in high-risk scenarios.
[0058] This approach uses Conditional Value at Risk (CVaR) instead of expected value to calculate costs, making decisions more sensitive to the tails of the probability distribution, i.e., the risks of the worst-case scenario. Compared to methods that only use the mean for decision-making, CVaR can trigger pre-scheduling actions in scenarios where the probability of potentially catastrophic consequences is low but the losses are huge, thus improving the system's defense capabilities against extreme events.
[0059] (III) Dynamic Decision-Making Rules Define marginal expected revenue The difference between the expected cost of continuing to wait for observation and the expected cost of immediately executing the pre-scheduled action:
[0060] The decision rule is: when When this occurs, it indicates that the expected cost of continuing to wait for observation has exceeded the expected cost of immediately executing pre-scheduling, and continuing to wait no longer has a cost advantage, thus triggering the pre-scheduling action. If the expected cost of immediately executing pre-scheduling is not lower than the expected cost of continuing to wait, then executing pre-scheduling at the current moment does not have a cost advantage, therefore the pre-scheduling action is not triggered, and the system continues to wait and enter the next decision cycle.
[0061] This decision rule is equivalent to the marginal benefit stopping rule in optimal stopping theory. As long as the marginal expected benefit of continuing to wait, i.e. the expected cost saved, is positive, the system will continue to wait; once the marginal expected benefit turns negative, i.e., continuing to wait will increase the expected cost, the system will immediately stop waiting and execute the action.
[0062] (iv) Generation of pre-scheduled action suggestions when When pre-scheduling is triggered, step S3 generates pre-scheduling action suggestions. The pre-scheduling action suggestions include two dimensions: action type and action intensity.
[0063] Action types include one or more combinations of the following: pre-expansion of the database connection pool, pre-loading of core data cache, pre-switching of read / write permissions (i.e., pre-switching read traffic from the primary database to the standby database), and pre-cleaning or expansion of storage space. The choice of action type is determined based on the most prominent risk factor in the current system state. For example, when the connection pool utilization rate rises rapidly, connection pool expansion is preferred; when the master-slave synchronization delay continues to increase, pre-switching of read / write permissions is preferred.
[0064] Action intensity is expressed as a relative value. For example, scaling up to 1.5 times the current connection pool size, or preloading the K most frequently accessed data tables from the last 30 minutes. The specific magnitude is determined by the risk factor. The value is determined by the number of . The higher the value, the greater the expected risk, and the action intensity value approaches the upper limit of the preset range. After the pre-scheduled action suggestion is generated, it is used as one of the inputs for step S4 and merged into a complete executable instruction after the strategy matching is completed.
[0065] The pre-scheduled action suggestions generated by this solution include two independent dimensions: action type and action intensity. The action intensity continuously changes with the risk coefficient. Compared to the all-or-nothing binary mode of pre-scheduled actions in existing technologies (either execute or don't execute), this solution achieves fine-grained control of action magnitude, avoiding resource waste caused by excessive pre-scheduling when the risk is low.
[0066] In step S4, the level label of the current business is obtained. Based on the risk coefficient, cognitive uncertainty and the level label of the current business, the optimal switching strategy is selected from the preset strategy pool through a multi-attribute decision-making method.
[0067] In some specific embodiments, the preset strategy pool in step S4 includes: a first strategy, performing a switchover of read traffic to the standby database; a second strategy, performing a preloading or expansion operation determined based on risk prediction results; and a third strategy, performing a complete primary / standby switchover, full cache rebuilding, and device task migration. Specifically: The first strategy is a lightweight hot standby strategy. This strategy only performs read traffic switching operations to the standby database, without involving cache preloading or primary database switching. This strategy has the lowest resource overhead and minimal business impact, and is suitable for scenarios with minor system anomalies and high prediction confidence, i.e., situations where the risk is controllable and the uncertainty is small.
[0068] The second strategy is the elastic buffering strategy. This strategy performs preloading or expansion operations based on the pre-scheduled action suggestions output in step S3, such as preloading hot data into the cache or increasing the database connection pool capacity, but does not perform a master database switch. The resource overhead and business impact of this strategy are both at a moderate level, making it suitable for situations with a moderate to high risk factor or moderate cognitive uncertainty.
[0069] The third strategy is the full-link takeover strategy. This strategy performs a complete primary / standby switchover, full cache rebuild, and device task migration. This strategy has the highest resource overhead and the greatest business impact, but it also provides the most comprehensive security guarantees and is suitable for situations with high risk factors or high cognitive uncertainty.
[0070] In some specific embodiments, the multi-attribute decision-making method is the entropy weight method, which includes: collecting the performance values of each candidate strategy on multiple evaluation attributes in historical decisions and constructing a decision matrix; normalizing the decision matrix and calculating the information entropy of each attribute; calculating the weight of each attribute based on the information entropy; calculating the basic score of each candidate strategy according to the weight; using cognitive uncertainty as a correction factor to correct the basic score and obtain the final score of each candidate strategy; and selecting the strategy with the highest final score as the optimal switching strategy.
[0071] In step S5, the pre-scheduled action suggestion and the optimal switching strategy are merged into an executable instruction and issued for execution.
[0072] In practice, the merging is performed according to the following logic: If the optimal switchover strategy is Strategy 1, the execution instruction is to switch read traffic to the standby database. The preloading or expansion operations in the pre-scheduling action suggestion in step S3 are not executed under this strategy to avoid unnecessary resource consumption. If the optimal switchover strategy is Strategy 2, the execution instruction includes executing the preloading or expansion operations in the pre-scheduling action suggestion in step S3, but the primary database remains unchanged. If the optimal switchover strategy is Strategy 3, the execution instruction includes a complete primary-standby switchover, a full cache rebuild, and device task migration. The preloading operation in the pre-scheduling action suggestion in step S3 can be absorbed as a pre-step for the full cache rebuild, making the cache rebuilding process smoother.
[0073] After the execution instructions are generated, they are distributed to the corresponding infrastructure through various execution channels. Specifically, this includes: distributing read / write separation or master-slave switchover instructions through the database management interface; distributing cache preloading or full rebuild instructions through the cache client; and distributing device task migration instructions through the device management platform. Upon completion, the execution results are written back to the log system, serving as the data source for subsequent updates to the entropy weight method decision matrix, thus achieving continuous closed-loop optimization of the system.
[0074] According to such Figure 1The most crucial technical effect of this invention, as illustrated in the embodiments shown, lies in the fact that by using prediction confidence, i.e. cognitive uncertainty, as the core decision variable throughout the determination of pre-scheduling timing and the selection of switching strategies, the system's decision-making behavior can adaptively match the reliability of the prediction itself. This solves the fundamental problem in the prior art where the prediction and decision-making processes are disconnected and the decision-maker cannot perceive the reliability of the prediction, and realizes an adaptive scheduling mechanism where the more uncertain the prediction, the more conservative the decision.
[0075] Figure 2 for Figure 1 A flowchart illustrating step S4 of Example 1000. (See attached diagram.) Figure 2 As shown, step S4 includes steps S41-S46.
[0076] In some specific embodiments, the multi-attribute decision-making method in step S4 of the present invention is the entropy weight method, because: The core requirement of strategy matching in this solution is to objectively and dynamically determine the relative importance of the three evaluation attributes—security gain, resource overhead, and business impact—in decision-making. This importance should adaptively adjust with changes in the system's operating state, rather than relying on manually preset fixed weights. The entropy weight method, as an objective weighting method, is based on the idea that the greater the difference in the performance values of a certain attribute among different candidate strategies, the richer the decision information contained in that attribute, and therefore, the higher its weight should be assigned in the comprehensive evaluation. This aligns perfectly with the actual needs of strategy matching in this solution, because the contribution of each evaluation attribute to distinguishing the merits of strategies does indeed differ significantly under different system states.
[0077] Meanwhile, the entropy weight method only involves normalization, entropy calculation, and simple algebraic operations, without iterative optimization or gradient solving. Its online computational overhead is extremely low, allowing for periodic weight updates without affecting the real-time nature of decision-making. In contrast, subjective weighting methods, such as the analytic hierarchy process (AHP), rely on expert experience and have fixed weights, making them difficult to adapt to dynamic changes in system operating characteristics. More complex objective weighting methods, such as the CRITIC method or principal component analysis, significantly increase computational complexity without providing additional decision-making benefits in this scenario. Therefore, the entropy weight method, with its objectivity, adaptability, and computational efficiency, matches the requirements of step S4 and is the technical choice for multi-attribute decision-making in this scheme.
[0078] In step S41, the performance values of each candidate strategy in historical decisions on multiple evaluation attributes are collected to construct a decision matrix. Optionally, the multiple evaluation attributes include security gain, resource overhead, and business impact; security gain is the expected decrease in risk coefficient after implementing the strategy, resource overhead is the amount of additional system resources used to implement the strategy, and business impact is determined based on the business level label.
[0079] In some specific embodiments, the evaluation attributes include three dimensions: security gain, resource overhead, and business impact.
[0080] The safety gain is the expected decrease in the risk coefficient after implementing the strategy. A higher safety gain value indicates a more significant effect of implementing the strategy on reducing system risk. In practice, the safety gain value is obtained by statistically averaging the changes in the risk coefficient before and after implementing the strategy in historical decision records.
[0081] Resource overhead refers to the additional system resources consumed in executing the strategy, measured as the combined increase in CPU utilization and memory usage. A higher resource overhead value for a strategy indicates a more significant resource drain on normal business processes. In practice, the resource overhead value is directly obtained from the system metrics collected in step S1, and the increase in resource usage within a preset time window before and after strategy execution is recorded as the resource overhead for that execution.
[0082] Business impact refers to the degree of disruption caused to business operations by policy execution, determined by business level labels. In practice, business level labels are preset by operations personnel for each database instance in the system configuration, dividing them into core business and non-core business levels. For core business levels, any momentary fluctuations during policy execution are assigned a higher business impact value; for non-core business levels, fluctuations of the same degree are assigned a lower business impact value. The specific numerical value of the business impact can be determined through a preset mapping relationship. For example, core business levels are mapped to high impact values (e.g., 9), and non-core business levels are mapped to low impact values (e.g., 3). The specific value setting is based on the ability to reflect the distinction between the two business levels in decision-making calculations.
[0083] In practice, the decision matrix is constructed based on historical decision records within a recent time window. The setting of this time window should balance statistical representativeness and timeliness: a window that is too small will result in insufficient statistical samples and decreased reliability of weight calculations; a window that is too large will prevent historical data from reflecting changes in the current system's operating characteristics. In some specific embodiments, the time window is preset to the most recent 200 decision records. This sample size statistically provides a stable entropy estimate, while the time span covered is sufficient to reflect the changing trends of the system's operating characteristics.
[0084] In this scheme, the entropy weight method calculates weights based on historical decision data within a sliding time window, rather than a fixed historical set. As the time window slides, old data is gradually eliminated, and new decision records are continuously added, enabling attribute weights to be continuously updated in accordance with changes in system operating characteristics, thus achieving adaptive evolution of decision criteria.
[0085] In step S42, the decision matrix is normalized, and the information entropy of each attribute is calculated. Normalization converts the original values of each attribute into standardized values between 0 and 1, eliminating differences in dimensions and orders of magnitude between different attributes. Specifically, for benefit-type attributes such as security gain and business impact, larger values are better, so maximum value normalization is used; for cost-type attributes such as resource expenditure, smaller values are better, so minimum value normalization is used.
[0086] The formula for calculating information entropy is:
[0087] Where N is the total number of samples in the decision matrix. Information entropy is the proportion of the normalized value of the i-th sample on the j-th attribute to the sum of the normalized values of all samples for that attribute. The value of entropy ranges from 0 to 1. The closer the entropy value is to 1, the smaller the difference in the value of the attribute among different samples, and the lower its contribution to the distinction of the decision.
[0088] In step S43, the weights of each attribute are calculated based on information entropy. The weight of each attribute is determined by the degree of difference in information entropy. Attribute Weights The calculation formula is:
[0089] Where M is the total number of evaluation attributes, and in this scheme, M=3. The physical meaning of this formula is: the lower the information entropy of an attribute, that is, the greater the difference in the value of the attribute among different strategies, the higher its weight and the greater its influence on the final decision; conversely, the higher the information entropy of an attribute, the lower its weight.
[0090] In step S44, the base score for each candidate strategy is calculated based on its weight:
[0091] in This represents the k-th candidate strategy. This represents the normalized performance value of the strategy on the j-th evaluation attribute. The base score reflects the overall performance of each strategy within the entropy weight method framework; a higher score indicates a greater overall advantage of the strategy in terms of historical data statistics.
[0092] In step S45, cognitive uncertainty is used as a correction factor to adjust the base score, resulting in the final score for each candidate strategy. Adjusting the base score using cognitive uncertainty as a correction factor specifically includes: pre-setting a safety reserve factor for each candidate strategy; the relative magnitude of the safety reserve factor among strategies is positively correlated with the switching intensity of the strategy; and adding the product of cognitive uncertainty, the safety reserve factor, and the adjustment coefficient as a correction term to the base score to obtain the final score for each candidate strategy.
[0093] In step S46, the strategy with the highest final score is selected as the optimal switching strategy.
[0094] Compared with the prior art, this solution has the following improvements in the strategy matching stage corresponding to step S4: First, in existing technologies, the weights of each dimension in the comprehensive decision function need to be set manually. These weights often rely on the experience and judgment of operations and maintenance experts and are difficult to adaptively adjust with changes in the system's operating environment. This solution automatically calculates the weights of each attribute from historical decision data using the entropy weight method, without manual intervention. Furthermore, the weights are continuously updated as the time window slides, dynamically reflecting changes in the system's operating characteristics.
[0095] Second, existing technologies rely on relatively singular decision-making variables for strategy selection, often based on single-dimensional judgments such as risk level or performance score. This solution incorporates three dimensions—risk coefficient, cognitive uncertainty, and business level label—into the decision-making framework simultaneously, ensuring that strategy selection considers "how great the risk is," "how accurate the prediction is," and "how important the business is," resulting in more complete decision-making information.
[0096] Third, in existing technologies, the prediction module and the decision-making module are independent of each other. The prediction result is unidirectionally transmitted to the decision-making module in the form of point estimates, and the confidence information of the prediction is lost during the transmission process. This solution uses cognitive uncertainty as a correction factor for strategy scoring, enabling the prediction confidence to influence strategy selection in reverse, and realizing bidirectional information flow between the prediction module and the decision-making module.
[0097] Fourth, existing technologies mostly rely on static priority presets in terms of business perception. This solution directly embeds business level labels into the evaluation attribute system of multi-attribute decision-making, making business level one of the target dimensions for decision optimization, rather than a simple pre-filter condition.
[0098] Based on the specific implementation of step S4 above, the present invention can achieve the following technical effects: First, it automates the weighting of policy matching. By automatically calculating the weights of three attributes—security gain, resource overhead, and business impact—using the entropy weighting method, it eliminates the need for manual weight setting in existing technologies, reducing the complexity of system deployment and maintenance, while enabling the weights to adaptively adjust as the system's operating environment changes.
[0099] Second, it achieves policy bias driven by prediction confidence. By using cognitive uncertainty as a correction factor, policy selection automatically shifts towards policies with greater switching intensity when the model prediction is uncertain, and maintains the historically statistically optimal policy selection when the prediction is certain, thereby obtaining higher security in uncertain scenarios.
[0100] Third, implement differentiated scheduling based on business level. By incorporating business level labels as one of the evaluation attributes into the decision matrix, core businesses receive a higher weight for security gains in strategy selection, while non-core businesses receive a higher weight for resource overhead, thereby achieving differentiated services aligned with business value.
[0101] Figure 3 for Figure 2 The flowchart for the basic score correction step S45 in step S4 is shown below. Figure 3 As shown, step S45 further includes steps S451-S452.
[0102] Step S451: Preset a safety reserve factor for each candidate strategy. The relative magnitude of the safety reserve factor among strategies is positively correlated with the switching intensity of the strategy. The safety reserve factor is a pre-set constant, and its relative magnitude among strategies is positively correlated with the switching intensity of the strategy; that is, the greater the switching intensity of the strategy, the higher its safety reserve factor.
[0103] In some specific embodiments, the safety reserve factors for the first, second, and third strategies are preset to -0.2, +0.1, and +0.4, respectively. The basis for these values is that the third strategy provides the highest level of security and should be prioritized when prediction uncertainty is high, thus receiving the largest positive value; the first strategy has the smallest switching intensity and should be chosen cautiously when prediction uncertainty is high, thus receiving a negative value; the second strategy's switching intensity is between the two, receiving a moderate positive value. The relative magnitude of the three values, rather than the specific numerical values, is the decisive factor. As long as the safety reserve factors for the first to third strategies increase sequentially, the technical effect of "the higher the uncertainty, the more the strategy selection shifts towards the strategy with the larger switching intensity" can be achieved. In specific implementations, operations and maintenance personnel can adjust the above values appropriately according to the actual scenario.
[0104] In this scheme, the safety reserve factors for the three strategies exhibit a gradient distribution of "negative value - positive value - larger positive value," rather than a simple binary distinction of 0-1. This gradient design ensures that the effect of cognitive uncertainty on strategy scoring is continuous rather than abrupt. As uncertainty increases, the bias in strategy selection gradually transitions from the first strategy to the second strategy and then to the third strategy, avoiding drastic oscillations in strategy selection near the uncertainty threshold.
[0105] Step S452: The product of cognitive uncertainty, safety reserve factor, and adjustment coefficient is used as a correction term and added to the base score to obtain the final score for each candidate strategy.
[0106] in The cognitive uncertainty calculated in step S2, Let η be the safety reserve factor for the k-th strategy, and η be the adjustment coefficient.
[0107] The adjustment coefficient is used to control the weight of the correction item in the final score. If the adjustment coefficient is too low, the correction effect of cognitive uncertainty is not obvious, and adaptive adjustment of strategy bias cannot be achieved; if the adjustment coefficient is too high, the correction item may dominate the final score, causing strategy selection to rely excessively on cognitive uncertainty and ignore the historical statistical information reflected by the base score. In some specific embodiments, the adjustment coefficient is preset to 0.5. The basis for setting this value is as follows: when cognitive uncertainty... When varying within its typical range, the magnitude of the correction term is roughly equivalent to that of the base score, ensuring that the correction term has an effective influence on the base score but does not completely dominate the score result. In practical implementation, operations and maintenance personnel can adjust the correction term based on actual observations. The distribution range allows for appropriate adjustments to the adjustment coefficient, which is generally between 0.3 and 0.8.
[0108] In this scheme, the product of cognitive uncertainty, safety reserve factor, and adjustment coefficient constitutes a correction term, which has the same dimension as the base score and can be directly added. This dimension-matching design ensures that the introduction of the correction term does not change the physical meaning of the final score. The final score remains a dimensionless comprehensive evaluation value, and the strategy with the highest score is the optimal strategy, thus avoiding the problem of ambiguity in the meaning of decision criteria due to the introduction of the correction term.
[0109] Figure 4 This is a schematic diagram of an embodiment 2000 of the device and database adaptive pre-scheduling switching system of the present invention. Figure 4 As shown, embodiment 2000 includes a data acquisition module 201, a risk prediction module 202, a pre-scheduling decision module 203, a strategy matching module 204, and an execution module 205.
[0110] The data acquisition module 201 is used to collect real-time operating indicators of the database and front-end devices as the current system status.
[0111] The risk prediction module 202 is used to input the current system state into a trained quantile distributed reinforcement learning network, output the probability distribution of future risk values, and calculate the risk coefficient and cognitive uncertainty based on the probability distribution.
[0112] The pre-scheduling decision module 203 is used to substitute the probability distribution into the optimal stopping decision framework, calculate the expected cost of immediately executing the pre-scheduling action and the expected cost of continuing to wait for observation, and use the difference between the expected cost of continuing to wait for observation and the expected cost of immediately executing the pre-scheduling action as the decision basis; when the difference meets the preset triggering conditions, a pre-scheduling action suggestion is generated.
[0113] The strategy matching module 204 is used to obtain the level label of the current business and select the optimal switching strategy from the preset strategy pool based on the risk coefficient, cognitive uncertainty and the level label of the current business through a multi-attribute decision-making method.
[0114] The execution module 205 is used to merge the pre-scheduled action suggestions and the optimal switching strategy into an executable instruction and issue it for execution.
[0115] It should be noted that, in this document, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0116] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.
Claims
1. A method for adaptive pre-scheduling switching between devices and databases, characterized in that, Includes the following steps: S1: Collect real-time operating metrics of the database and front-end devices to determine the current system status; S2: Input the current system state into a trained quantile distributed reinforcement learning network and output the probability distribution of future risk values; calculate the risk coefficient and cognitive uncertainty based on the probability distribution, whereby the cognitive uncertainty is used to characterize the degree of dispersion of the probability distribution; S3: Substitute the probability distribution into the optimal stopping decision framework, calculate the expected cost of immediately executing the pre-scheduled action and the expected cost of continuing to wait for observation, and use the difference between the expected cost of continuing to wait for observation and the expected cost of immediately executing the pre-scheduled action as the decision basis; when the difference meets the preset triggering condition, generate a pre-scheduled action suggestion; S4: Obtain the level label of the current business, and select the optimal switching strategy from the preset strategy pool based on the risk coefficient, the cognitive uncertainty and the level label of the current business through a multi-attribute decision-making method; S5: Combine the pre-scheduled action suggestion with the optimal switching strategy into an executable instruction and issue it for execution.
2. The method according to claim 1, characterized in that, The quantile distributed reinforcement learning network mentioned in step S2 is an implicit quantile network. The implicit quantile network takes the current system state vector and the randomly sampled quantile as input and outputs the risk value corresponding to the quantile. By sampling and fitting multiple quantiles, the probability distribution of the future risk value is obtained.
3. The method according to claim 2, characterized in that, The cognitive uncertainty is characterized by the difference between the risk value corresponding to the preset high quantile and the risk value corresponding to the preset low quantile of the probability distribution; the risk coefficient is characterized by the mean of the probability distribution.
4. The method according to claim 1, characterized in that, The expected cost of immediately executing the pre-scheduled action in step S3 includes the resource consumption cost and business impact cost of executing the pre-scheduled action; the expected cost of continuing to wait for observation includes the failure loss cost that may occur during system operation if pre-scheduled action is not executed; the expected cost is calculated based on the conditional value of risk of the probability distribution.
5. The method according to claim 4, characterized in that, The conditional risk value is the expected value of the worst preset quantile of the probability distribution; when the difference is greater than zero, a pre-scheduling action is triggered, indicating that the expected cost of continuing to wait for observation is higher than the expected cost of immediately executing pre-scheduling, and immediately executing pre-scheduling is better.
6. The method according to claim 1, characterized in that, The preset strategy pool mentioned in step S4 includes: a first strategy, which performs a switchover of read traffic to the standby database; a second strategy, which performs a preloading or expansion operation based on the risk prediction results; and a third strategy, which performs a complete switchover between primary and standby databases, a full cache rebuild, and a device task migration.
7. The method according to claim 1, characterized in that, The multi-attribute decision-making method in step S4 is the entropy weight method, which includes: collecting the performance values of each candidate strategy on multiple evaluation attributes in historical decisions and constructing a decision matrix; normalizing the decision matrix and calculating the information entropy of each attribute; calculating the weight of each attribute based on the information entropy; calculating the basic score of each candidate strategy according to the weight; using the cognitive uncertainty as a correction factor to correct the basic score to obtain the final score of each candidate strategy; and selecting the strategy with the highest final score as the optimal switching strategy.
8. The method according to claim 7, characterized in that, The multiple evaluation attributes include security gain, resource overhead, and business impact; the security gain is the expected decrease in the risk coefficient after implementing the strategy, the resource overhead is the amount of additional system resources used to implement the strategy, and the business impact is determined based on the business level label.
9. The method according to claim 7, characterized in that, The step of using cognitive uncertainty as a correction factor to adjust the base score specifically includes: pre-setting a safety reserve factor for each candidate strategy, wherein the relative magnitude of the safety reserve factor among the strategies is positively correlated with the switching intensity of the strategy, wherein the safety reserve factor corresponding to the candidate strategy with the smallest switching intensity is negative, and the safety reserve factor corresponding to the candidate strategy with the largest switching intensity is the largest positive value among all candidate strategies; the product of the cognitive uncertainty, the safety reserve factor, and the adjustment coefficient is used as a correction term and added to the base score to obtain the final score of each candidate strategy; the adjustment coefficient is determined according to the principle of matching the magnitude of the correction term with the base score.
10. A system for adaptive pre-scheduling switching between devices and databases, characterized in that, include: The data acquisition module is used to collect real-time operating indicators of the database and front-end devices as the current system status; The risk prediction module is used to input the current system state into a trained quantile distributed reinforcement learning network, output the probability distribution of future risk values, and calculate the risk coefficient and cognitive uncertainty based on the probability distribution. The pre-scheduling decision module is used to substitute the probability distribution into the optimal stopping decision framework, calculate the expected cost of immediately executing the pre-scheduling action and the expected cost of continuing to wait for observation, and use the difference between the expected cost of continuing to wait for observation and the expected cost of immediately executing the pre-scheduling action as the decision basis; when the difference meets the preset triggering condition, a pre-scheduling action suggestion is generated. The strategy matching module is used to obtain the level label of the current business and select the optimal switching strategy from the preset strategy pool based on the risk coefficient, the cognitive uncertainty and the level label of the current business through a multi-attribute decision-making method. The execution module is used to merge the pre-scheduled action suggestion and the optimal switching strategy into an executable instruction and issue it for execution.