Message-oriented middleware localization substitution adaptation method and system for power dispatching
By adopting lightweight communication protocols, Consul service registration and discovery, Kubernetes automated deployment and AI load prediction methods in the power scheduling system, the problem of compatibility and stability in the domestic replacement of message middleware in the power scheduling system is solved, and the system flexibility, expansion capabilities and operational stability are achieved.
Patent Information
- Application Number
- CN202411967325.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-30
- Publication Date
- 2025-04-25
- Estimated Expiration
- 2044-12-30
AI Technical Summary
The power scheduling system has extremely high requirements for real-time, stability and security. It is difficult for existing message middleware to take into account compatibility, performance, reliability, monitoring management, security and migration costs during the domestic replacement process.
It adopts lightweight communication protocol and message middleware to realize service registration and discovery through Consul, uses Kubernetes for automated deployment and expansion, combines AI technology to predict system load and performance bottlenecks, optimizes the domestic alternative adaptation solution for message middleware, and conducts compatibility and stability testing.
It realizes the flexibility, expansion capabilities and operational stability of the power scheduling system, ensures that the system maintains compatibility and stability in the process of domestic substitution of message middleware, and improves technical autonomy and the overall performance of the system.
Smart Images

Figure CN119886881A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of power system optimization, and in particular to a localized replacement adaptation method and system for a message middleware for power dispatching. Background Art
[0002] In modern power dispatching systems, with the continuous development of smart grid technology and the increasing complexity of power networks, traditional communication and data processing methods have gradually failed to meet actual needs. These systems require high reliability, real-time and scalability to cope with diverse and dynamically changing load demands. The core of the power dispatching system lies in efficient message transmission and coordination to ensure that different nodes and devices can quickly respond to changes in the power grid status to achieve stable power supply services.
[0003] With the country's emphasis on independent and controllable technology and the increasing requirements for network security, the adoption of domestic technology and software has become an inevitable trend. Domestic message middleware not only needs to provide performance and functions comparable to international mainstream technologies, but also must have better compatibility and security to ensure the stable operation of the system. In addition, the demand for intelligent and automated scheduling has promoted the evolution of system architecture from traditional centralized to distributed and microservice-oriented, while integrating artificial intelligence technology for predictive analysis to further optimize resource scheduling and improve operational efficiency.
[0004] The electric power dispatching system has extremely high requirements for real-time, stability and security. Therefore, in the process of domestic substitution of message middleware, it is necessary to focus on solving problems such as compatibility, performance, reliability, monitoring management, security and migration and transformation costs to ensure stable operation of the system and meet the needs of domestic independent control. Summary of the invention
[0005] In order to solve the above problems, the purpose of the present invention is to provide a method and system for localization substitution and adaptation of message middleware for power dispatching, which can ensure that localization substitution not only brings technical autonomy, but also improves the flexibility, expansion capability and operational stability of the entire power dispatching system.
[0006] To achieve the above object, the present invention adopts the following technical solutions:
[0007] A method for localizing and replacing message middleware for power dispatching, comprising the following steps:
[0008] Split the cloud system into independent services, each responsible for a specific function, including messaging, load balancing, and failover;
[0009] Use lightweight communication protocols to communicate between services and implement the service registration and discovery mechanism Consul to ensure that services can be dynamically discovered and called;
[0010] Scale each service instance independently based on load conditions, and use the API gateway to coordinate and manage the scaling results of each service instance through load balancing and routing functions;
[0011] Create a Docker image for each service, including all the dependencies required to run, and use Docker Compose for local development and testing; use Kubernetes to automate deployment, expansion, and management of each service instance;
[0012] Lightweight protocols and message middleware are used to provide basic support for communication between system services. Local schedulers are deployed on edge nodes. Local schedulers are directly associated with the dispatching logic of other nodes through message middleware to achieve multi-level communication between cloud, edge and nodes. AI technology is used to predict system load and performance bottlenecks, and to optimize the localization replacement adaptation solution of message middleware.
[0013] Based on the evaluation indicators, the compatibility and stability of the domestic alternative adaptation solutions for the message middleware are tested, and the domestic middleware that has passed the evaluation is replaced in the production environment.
[0014] Furthermore, Kubernetes is used for automated deployment, expansion, and management, as follows:
[0015] Deploy services in a Kubernetes cluster and use Pod, Deployment, and Service resources to manage applications; configure automatic scaling to dynamically adjust the number of Pods based on load; use ConfigMap and Secret to manage configuration and sensitive information.
[0016] Furthermore, a lightweight communication protocol is used to communicate between services, and the service registration and discovery mechanism Consul is implemented to ensure that services can be dynamically discovered and called. Specifically:
[0017] Deploy the Consul cluster: Install the Consul Agent in each runtime environment and run it in client mode or server mode to ensure communication and data synchronization with the entire Consul cluster;
[0018] When each service starts, it registers with Consul through Consul's HTTP API, notifies Consul of the service's name, address, and port information, and provides health check configuration. Consul periodically checks the health status of the service based on the health check configuration.
[0019] Each service queries other services that need to be called through Consul, and obtains the address and status information of the services that need to be called to achieve dynamic calling and load balancing; Consul provides the latest list of healthy instances for the query service;
[0020] Consul performs HTTP or TCP health checks on registered services to determine the health status of the services. When the health check fails, Consul automatically removes the abnormal service from the available list.
[0021] Using ConsulKV to store configuration allows services to obtain configuration information at startup or dynamically update configuration at runtime.
[0022] Furthermore, each service instance is independently expanded according to the load situation, supporting horizontal expansion. The API gateway is used to coordinate and manage the expansion results of each service instance through load balancing and routing functions. Specifically:
[0023] Configure service routing rules in the API gateway to forward requests to corresponding service instances, supporting dynamic increase and decrease of services;
[0024] API Gateway supports path rewriting to adjust request paths or add version control.
[0025] Integrate authentication and authorization services in the API gateway to perform access token verification;
[0026] Provide load balancing functions for backend service instances in the API gateway configuration, including polling and minimum number of connections strategy.
[0027] Furthermore, a local scheduler is deployed on each node, local tasks are communicated based on the message middleware, AI technology is used to predict system load and performance bottlenecks, and the localization replacement adaptation solution of the message middleware is optimized. Specifically:
[0028] A local scheduler is deployed on each physical or virtual node. The local scheduler is responsible for managing the task scheduling on the node.
[0029] A local message queue is configured in each local scheduler. Tasks in the local message queue communicate through the producer-consumer model, supporting message publishing, consumption, and queue management. Domestic message middleware is used to implement communication for local tasks.
[0030] Message middleware provides reliability of message consumption through message confirmation mechanism and delivery guarantee strategy, and configures subscription, publishing and queue monitoring to ensure the timeliness and effectiveness of task communication;
[0031] The local scheduler collects relevant indicator data from the system operation, including CPU utilization, memory usage, and load balancing traffic, and performs data cleaning and feature extraction. It also uses the time series prediction model ARIMA to predict future system loads and possible performance bottlenecks. It adjusts the system resource allocation strategy in real time based on the prediction results, and uses reinforcement learning to optimize scheduling decisions and resource allocation to form a dynamic optimization mechanism.
[0032] Furthermore, the system resource allocation strategy is adjusted in real time according to the prediction results, and reinforcement learning is used to optimize scheduling decisions and resource allocation to form a dynamic optimization mechanism, as follows:
[0033] Use the Prometheus monitoring system to collect real-time data, including key performance indicators of service instances such as CPU utilization, memory consumption, and network traffic;
[0034] Predict future system loads and possible performance bottlenecks using the time series forecasting model ARIMA. Based on the forecast results, adjust resource allocation in real time, including automatically expanding or reducing the number of Pod instances in Kubernetes.
[0035] The steps to building a reinforcement learning model include:
[0036] Define the state space: including the current system resource allocation, load conditions, and task queue length;
[0037] Action space: including adding or reducing service instances, adjusting task priorities, and changing scheduling strategies;
[0038] Train reinforcement learning models using simulated environments or historical data;
[0039] Use the Q-Learning policy gradient method to optimize long-term decisions, deploy reinforcement learning models for real-time decision-making, update models and adjust policies based on actual feedback information, continuously input new performance and load data into the model, and refine the accuracy of model decisions.
[0040] Further stability testing is carried out as follows: obtaining the interaction mode between the current system and the existing middleware, including message format, protocol, and interface call; identifying all affected system modules, third-party libraries, and other middleware so that the test covers all dependencies; establishing a test environment consistent with the production environment, and configuring domestically produced middleware to simulate real workloads; so that the test environment contains the same network topology, node configuration, and security policy as production.
[0041] Further, compatibility testing is as follows: verify the compatibility of middleware APIs one by one, including message sending, receiving, and queue management interfaces; simulate the message traffic in normal and extreme situations in the production environment to ensure that the new middleware can operate normally under given conditions; after replacing the middleware, the relevant business functions remain unchanged, and use automated testing tools to perform key function regression testing;
[0042] Apply continuous load to the middleware, monitor its behavior under long-term high load, apply extreme load, test the stability and collapse points of the system under extreme conditions, and collect performance data analysis such as response time, throughput, and error rate; simulate network failures and node failures, evaluate the system's tolerance to sudden failures and automatic recovery mechanism, and check whether the middleware can maintain data integrity and system consistency after failure recovery.
[0043] A localized replacement adaptation system for message middleware used in power dispatching, including a cloud system and edge nodes;
[0044] Split the cloud system into independent services, each responsible for a specific function, including messaging, load balancing, and failover;
[0045] Use lightweight communication protocols to communicate between services and implement the service registration and discovery mechanism Consul to ensure that services can be dynamically discovered and called;
[0046] Scale each service instance independently based on load conditions, and use the API gateway to coordinate and manage the scaling results of each service instance through load balancing and routing functions;
[0047] Create a Docker image for each service, including all the dependencies required to run, and use Docker Compose for local development and testing; use Kubernetes to automate deployment, expansion, and management of each service instance;
[0048] Lightweight protocols and message middleware are used to provide basic support for communication between system services. Local schedulers are deployed on edge nodes. Local schedulers are directly associated with the dispatching logic of other nodes through message middleware to achieve multi-level communication between cloud, edge and nodes. AI technology is used to predict system load and performance bottlenecks, and to optimize the localization replacement adaptation solution of message middleware.
[0049] Based on the evaluation indicators, the compatibility and stability of the domestic alternative adaptation solutions for the message middleware are tested, and the domestic middleware that has passed the evaluation is replaced in the production environment.
[0050] A computer storage medium stores a plurality of instructions, wherein the instructions are suitable for being loaded by a processor and executing the above method steps.
[0051] The present invention has the following beneficial effects:
[0052] The present invention combines independent service design with containerized deployment and dynamic management of Kubernetes, so that the system can flexibly meet the complex and changeable demand scenarios in power dispatching, support horizontal expansion and high-availability deployment, and maintain service stability during load peaks and failures. It optimizes communication and task scheduling through local schedulers and AI technology to achieve more efficient resource utilization and load regulation, effectively ensure the compatibility and stability of the power dispatching system when replacing the domestic message middleware, keep the system in the best operating state, and improve the flexibility, scalability and operational stability of the entire power dispatching system. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] Figure 1 The figure is a flow chart of the method of the present invention. DETAILED DESCRIPTION
[0054] The present invention is further described in detail below with reference to the accompanying drawings and specific embodiments:
[0055] refer to Figure 1 In this embodiment, a method for localization substitution and adaptation of message middleware for power dispatching is provided, comprising the following steps:
[0056] Split the cloud system into independent services, each responsible for a specific function, including messaging, load balancing, and failover;
[0057] Use lightweight communication protocols to communicate between services and implement the service registration and discovery mechanism Consul to ensure that services can be dynamically discovered and called;
[0058] Scale each service instance independently based on load conditions, and use the API gateway to coordinate and manage the scaling results of each service instance through load balancing and routing functions;
[0059] Create a Docker image for each service, including all the dependencies required to run, and use Docker Compose for local development and testing; use Kubernetes to automate deployment, expansion, and management of each service instance;
[0060] Lightweight protocols and message middleware are used to provide basic support for communication between system services. Local schedulers are deployed on edge nodes. Local schedulers are directly associated with the dispatching logic of other nodes through message middleware to achieve multi-level communication between cloud, edge and nodes. AI technology is used to predict system load and performance bottlenecks, and to optimize the localization replacement adaptation solution of message middleware.
[0061] Based on the evaluation indicators, the compatibility and stability of the domestic alternative adaptation solutions for the message middleware are tested, and the domestic middleware that has passed the evaluation is replaced in the production environment.
[0062] In this embodiment, Kubernetes is used for automated deployment, expansion and management, as follows: services are deployed in the Kubernetes cluster, and applications are managed using Pod, Deployment, and Service resources; automatic expansion is configured to dynamically adjust the number of Pods based on the load; and ConfigMap and Secret are used to manage configuration and sensitive information.
[0063] In this embodiment, a lightweight communication protocol is used to communicate between services, and the service registration and discovery mechanism Consul is implemented to ensure that services can be dynamically discovered and called, specifically:
[0064] Deploy the Consul cluster: Install the Consul Agent in each runtime environment and run it in client mode or server mode to ensure communication and data synchronization with the entire Consul cluster;
[0065] When each service starts, it registers with Consul through Consul's HTTP API, notifies Consul of the service's name, address, and port information, and provides health check configuration. Consul periodically checks the health status of the service based on the health check configuration.
[0066] Each service queries other services that need to be called through Consul, and obtains the address and status information of the services that need to be called to achieve dynamic calling and load balancing; Consul provides the latest list of healthy instances for the query service;
[0067] Consul performs HTTP or TCP health checks on registered services to determine the health status of the services. When the health check fails, Consul automatically removes the abnormal service from the available list.
[0068] Using ConsulKV to store configuration allows services to obtain configuration information at startup or dynamically update configuration at runtime.
[0069] In this embodiment, each service instance is independently expanded according to the load situation, horizontal expansion is supported, and the API gateway is used to coordinate and manage the expansion results of each service instance through load balancing and routing functions, specifically:
[0070] Configure service routing rules in the API gateway to forward requests to corresponding service instances, supporting dynamic increase and decrease of services;
[0071] API Gateway supports path rewriting to adjust request paths or add version control.
[0072] Integrate authentication and authorization services in the API gateway to perform access token verification;
[0073] Provide load balancing functions for backend service instances in the API gateway configuration, including polling and minimum number of connections strategy.
[0074] In this embodiment, a local scheduler is deployed on each node, and communication of local tasks is realized based on the message middleware. AI technology is used to predict system load and performance bottlenecks, and the localization substitution adaptation solution of the message middleware is optimized. Specifically,
[0075] A local scheduler is deployed on each physical or virtual node. The local scheduler is responsible for managing the task scheduling on the node.
[0076] A local message queue is configured in each local scheduler. Tasks in the local message queue communicate through the producer-consumer model, supporting message publishing, consumption, and queue management. Domestic message middleware is used to implement communication for local tasks.
[0077] Message middleware provides reliability of message consumption through message confirmation mechanism and delivery guarantee strategy, and configures subscription, publishing and queue monitoring to ensure the timeliness and effectiveness of task communication;
[0078] The local scheduler collects relevant indicator data from the system operation, including CPU utilization, memory usage, and load balancing traffic, and performs data cleaning and feature extraction. It also uses the time series prediction model ARIMA to predict future system loads and possible performance bottlenecks. It adjusts the system resource allocation strategy in real time based on the prediction results, and uses reinforcement learning to optimize scheduling decisions and resource allocation to form a dynamic optimization mechanism.
[0079] In this embodiment, the system resource allocation strategy is adjusted in real time according to the prediction results, and reinforcement learning is used to optimize scheduling decisions and resource allocation to form a dynamic optimization mechanism, as follows:
[0080] Use the Prometheus monitoring system to collect real-time data, including key performance indicators of service instances such as CPU utilization, memory consumption, and network traffic;
[0081] Predict future system loads and possible performance bottlenecks using the time series forecasting model ARIMA. Based on the forecast results, adjust resource allocation in real time, including automatically expanding or reducing the number of Pod instances in Kubernetes.
[0082] The steps to building a reinforcement learning model include:
[0083] Define the state space: including the current system resource allocation, load conditions, and task queue length;
[0084] Action space: including adding or reducing service instances, adjusting task priorities, and changing scheduling strategies;
[0085] Train reinforcement learning models using simulated environments or historical data;
[0086] Use the Q-Learning policy gradient method to optimize long-term decisions, deploy reinforcement learning models for real-time decision-making, update models and adjust policies based on actual feedback information, continuously input new performance and load data into the model, and refine the accuracy of model decisions.
[0087] In this embodiment, the stability test is specifically as follows: obtain the interaction mode between the current system and the existing middleware, including message format, protocol, and interface call; identify all affected system modules, third-party libraries, and other middleware so that the test covers all dependencies; establish a test environment consistent with the production environment, and configure domestically produced middleware to simulate real workloads; so that the test environment contains the same network topology, node configuration, and security policy as production.
[0088] In this embodiment, the compatibility test is specifically as follows: verify the compatibility of the middleware APIs one by one, including message sending, receiving, and queue management interfaces; simulate the message traffic in normal and extreme situations in the production environment to ensure that the new middleware can operate normally under given conditions; after replacing the middleware, the relevant business functions remain unchanged, and an automated testing tool is used to perform key function regression testing;
[0089] Apply continuous load to the middleware, monitor its behavior under long-term high load, apply extreme load, test the stability and collapse points of the system under extreme conditions, and collect performance data analysis such as response time, throughput, and error rate; simulate network failures and node failures, evaluate the system's tolerance to sudden failures and automatic recovery mechanism, and check whether the middleware can maintain data integrity and system consistency after failure recovery.
[0090] In this embodiment, a localized replacement adaptation system for message middleware for power dispatching is also provided, including a cloud system and an edge node;
[0091] Split the cloud system into independent services, each responsible for a specific function, including messaging, load balancing, and failover;
[0092] Use lightweight communication protocols to communicate between services and implement the service registration and discovery mechanism Consul to ensure that services can be dynamically discovered and called;
[0093] Scale each service instance independently based on load conditions, and use the API gateway to coordinate and manage the scaling results of each service instance through load balancing and routing functions;
[0094] Create a Docker image for each service, including all the dependencies required to run, and use Docker Compose for local development and testing; use Kubernetes to automate deployment, expansion, and management of each service instance;
[0095] Lightweight protocols and message middleware are used to provide basic support for communication between system services. Local schedulers are deployed on edge nodes. Local schedulers are directly associated with the dispatching logic of other nodes through message middleware to achieve multi-level communication between cloud, edge and nodes. AI technology is used to predict system load and performance bottlenecks, and to optimize the localization replacement adaptation solution of message middleware.
[0096] Based on the evaluation indicators, the compatibility and stability of the domestic alternative adaptation solutions for the message middleware are tested, and the domestic middleware that has passed the evaluation is replaced in the production environment.
[0097] In this embodiment, a computer storage medium is further provided, wherein the computer storage medium stores a plurality of instructions, wherein the instructions are suitable for being loaded by a processor and executing the above method steps.
[0098] Those skilled in the art will appreciate that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0099] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0100] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0101] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.
[0102] The above is only a preferred embodiment of the present invention, and does not limit the present invention in other forms. Any technician familiar with the profession may use the above disclosed technical content to change or modify it into an equivalent embodiment with equivalent changes. However, any simple modification, equivalent change and modification made to the above embodiment according to the technical essence of the present invention without departing from the technical solution of the present invention still belongs to the protection scope of the technical solution of the present invention.
Claims
1. A method for localizing and replacing message middleware for power dispatching, characterized in that: The following steps are involved: Split the cloud system into independent services, each responsible for a specific function, including messaging, load balancing, and failover; Scale each service instance independently based on load conditions, and use the API gateway to coordinate and manage the scaling results of each service instance through load balancing and routing functions; Create a Docker image for each service, including all the dependencies needed to run it, and use Docker Compose for local development and testing; Use Kubernetes to automate deployment, expansion, and management of each service instance. Lightweight protocols and message middleware are used to provide basic support for communication between system services. Local schedulers are deployed on edge nodes. Local schedulers are directly associated with the dispatching logic of other nodes through message middleware to achieve multi-level communication between cloud, edge and nodes. AI technology is used to predict system load and performance bottlenecks, and to optimize localized message middleware replacement and adaptation solutions; Based on the evaluation indicators, the compatibility and stability of the domestic alternative adaptation solutions for the message middleware are tested, and the domestic middleware that has passed the evaluation is replaced in the production environment.
2. According to claim 1, a method for localization substitution and adaptation of message middleware for power dispatching, characterized in that: The automated deployment, expansion and management using Kubernetes is described as follows: deploy services in a Kubernetes cluster, use Pod, Deployment, and Service resources to manage applications; configure automatic expansion to dynamically adjust the number of Pods based on load; use ConfigMap and Secret to manage configuration and sensitive information.
3. According to claim 1, a method for localization substitution and adaptation of message middleware for power dispatching, characterized in that: The lightweight protocol provides basic support for communication between system services, specifically: Deploy the Consul cluster: Install the Consul Agent in each runtime environment and run it in client mode or server mode to ensure communication and data synchronization with the entire Consul cluster; When each service starts, it registers with Consul through Consul's HTTP API, notifies Consul of the service's name, address, and port information, and provides health check configuration. Consul periodically checks the health status of the service based on the health check configuration. Each service queries other services that need to be called through Consul, and obtains the address and status information of the services that need to be called to achieve dynamic calling and load balancing; Consul provides the latest list of healthy instances for the query service; Consul performs HTTP or TCP health checks on registered services to determine the health status of the services. When the health check fails, Consul automatically removes the abnormal service from the available list. Using ConsulKV to store configuration allows services to obtain configuration information at startup or dynamically update configuration at runtime.
4. According to claim 1, a method for localization substitution and adaptation of message middleware for power dispatching, characterized in that: The method independently expands each service instance according to the load situation, supports horizontal expansion, and uses the API gateway to coordinate and manage the expansion results of each service instance through load balancing and routing functions. Specifically: Configure service routing rules in the API gateway to forward requests to corresponding service instances, supporting dynamic increase and decrease of services; API Gateway supports path rewriting to adjust request paths or add version control. Integrate authentication and authorization services in the API gateway to perform access token verification; Provide load balancing functions for backend service instances in the API gateway configuration, including polling and minimum number of connections strategy.
5. According to claim 1, a method for localization substitution and adaptation of message middleware for power dispatching, characterized in that: The local scheduler is deployed on the edge node. The local scheduler directly establishes an association with the deployment logic of other nodes through the message middleware to achieve multi-level communication between cloud, edge and node. The AI technology is used to predict system load and performance bottlenecks, and optimize the localization substitution adaptation solution of the message middleware, specifically: A local scheduler is deployed on each physical or virtual node. The local scheduler is responsible for managing the task scheduling on the node. A local message queue is configured in each local scheduler. Tasks in the local message queue communicate through the producer-consumer model, supporting message publishing, consumption, and queue management. Domestic message middleware is used to implement communication for local tasks. Message middleware provides reliability of message consumption through message confirmation mechanism and delivery guarantee strategy, and configures subscription, publishing and queue monitoring to ensure the timeliness and effectiveness of task communication; The local scheduler collects relevant indicator data from the system operation, including CPU utilization, memory usage, and load balancing traffic, and performs data cleaning and feature extraction. It also uses the time series prediction model ARIMA to predict future system loads and possible performance bottlenecks. It adjusts the system resource allocation strategy in real time based on the prediction results, and uses reinforcement learning to optimize scheduling decisions and resource allocation to form a dynamic optimization mechanism.
6. According to claim 5, a method for localization substitution and adaptation of message middleware for power dispatching, characterized in that: The system resource allocation strategy is adjusted in real time according to the prediction results, and reinforcement learning is used to optimize scheduling decisions and resource allocation to form a dynamic optimization mechanism, which is as follows: Use the Prometheus monitoring system to collect real-time data, including key performance indicators of service instances such as CPU utilization, memory consumption, and network traffic; Predict future system loads and possible performance bottlenecks using the time series forecasting model ARIMA. Based on the forecast results, adjust resource allocation in real time, including automatically expanding or reducing the number of Pod instances in Kubernetes. The steps to building a reinforcement learning model include: Define the state space: including the current system resource allocation, load conditions, and task queue length; Action space: including adding or reducing service instances, adjusting task priorities, and changing scheduling strategies; Train reinforcement learning models using simulated environments or historical data; Use the Q-Learning policy gradient method to optimize long-term decisions, deploy reinforcement learning models for real-time decision-making, update models and adjust policies based on actual feedback information, continuously input new performance and load data into the model, and refine the accuracy of model decisions.
7. According to claim 1, a method for localization substitution and adaptation of message middleware for power dispatching, characterized in that: The stability test is specifically as follows: obtain the interaction mode between the current system and the existing middleware, including message format, protocol, and interface call; identify all affected system modules, third-party libraries, and other middleware so that the test covers all dependencies; establish a test environment consistent with the production environment, and configure domestically produced middleware to simulate real workloads; so that the test environment contains the same network topology, node configuration, and security policy as production.
8. According to claim 1, a method for localization substitution and adaptation of message middleware for power dispatching, characterized in that: The compatibility test is specifically as follows: verify the compatibility of the middleware APIs one by one, including message sending, receiving, and queue management interfaces; simulate the message traffic in normal and extreme situations in the production environment to ensure that the new middleware can operate normally under given conditions; after replacing the middleware, the relevant business functions remain unchanged, and an automated testing tool is used to perform key function regression testing; Apply continuous load to the middleware, monitor its behavior under long-term high load, apply extreme load, test the stability and collapse points of the system under extreme conditions, and collect performance data analysis such as response time, throughput, and error rate; simulate network failures and node failures, evaluate the system's tolerance to sudden failures and automatic recovery mechanism, and check whether the middleware can maintain data integrity and system consistency after failure recovery.
9. A localized replacement adaptation system for message middleware used in power dispatching, characterized in that: Includes cloud systems and edge nodes; Split the cloud system into independent services, each responsible for a specific function, including messaging, load balancing, and failover; Scale each service instance independently based on load conditions, and use the API gateway to coordinate and manage the scaling results of each service instance through load balancing and routing functions; Create a Docker image for each service, including all the dependencies needed to run it, and use Docker Compose for local development and testing; Use Kubernetes to automate deployment, expansion, and management of each service instance. Lightweight protocols and message middleware are used to provide basic support for communication between system services. Local schedulers are deployed on edge nodes. Local schedulers are directly associated with the dispatching logic of other nodes through message middleware to achieve multi-level communication between cloud, edge and nodes. AI technology is used to predict system load and performance bottlenecks, and to optimize localized message middleware replacement and adaptation solutions; Based on the evaluation indicators, the compatibility and stability of the domestic alternative adaptation solutions for the message middleware are tested, and the domestic middleware that has passed the evaluation is replaced in the production environment.
10. A computer storage medium, characterized in that: The computer storage medium stores a plurality of instructions, and the instructions are suitable for being loaded by a processor and executing the method steps according to any one of claims 1 to 8.
Citation Information
Patent Citations
Internet of Things platform construction method based on micro-service architecture
CN110149396A
Server resource adjustment method and device, electronic equipment and medium
CN117081943A
Intelligent scheduling method and system based on deep reinforcement learning and distributed cooperation
CN118250223A
Cited By
Safety management system compatible adaptation method supporting domestic middleware environment
CN120631434A