Message processing method and related equipment for edge devices
By performing feature extraction and resource prediction on messages reported by edge devices, and matching cluster resources, the message accumulation and performance problems caused by insufficient MQTT server resources are solved, and timely processing and performance improvement are achieved.
Patent Information
- Application Number
- CN202410592680.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-05-13
- Publication Date
- 2024-09-03
- Estimated Expiration
- 2044-05-13
AI Technical Summary
When the MQTT server processes messages reported by edge devices, due to insufficient resources, messages accumulate and service performance is poor. The existing technology adds resources in batches but cannot meet the demand in time.
By receiving messages reported by edge devices, the message feature vectors are extracted and input into the message matching resource prediction model to predict device needs and match cluster resources based on predicted resource information to ensure timely processing of messages, avoid message accumulation and improve server performance.
It achieves timely and sufficient provision of cluster resources when receiving messages reported by edge devices, avoids message accumulation, and improves server service performance.
Smart Images

Figure CN118170566B
Abstract
Description
Background Art
[0002] When deploying MQTT (Message Queuing Telemetry Transport) servers at the edge, visible infrastructure as a service (IaaS) resources are basically used for deployment. However, due to the relatively tight edge IaaS resources, performance bottlenecks of MQTT servers are usually caused. It is acceptable to solve some small-scale request services, but large-scale edge devices require more physical resources to support the services of MQTT servers. At present, in response to the demand for resources from MQTT servers, serverless computing (Serverless) technology is initially introduced to solve the MQTT capacity expansion capability. When the consumption capacity of the MQTT server is poor, the data center is requested to expand the capacity using the Serverless architecture, and resources are gradually added in batches until the consumption traffic demand of the MQTT server is met at that time. However, with the surge in the number of edge devices or more computing power requirements, the batch addition of resources causes the MQTT server to call resources in insufficient and untimely manner, which makes it impossible for the MQTT server to process messages reported by edge devices in a timely manner, resulting in message accumulation and poor service performance of the MQTT server.
[0003] It should be noted that the information disclosed in the above background technology section is only used to enhance the understanding of the background of the present disclosure, and therefore may include information that does not constitute the prior art known to ordinary technicians in the field. Summary of the invention
[0004] The present disclosure provides a message processing method and related equipment for edge devices, which at least to a certain extent overcomes the problem in the related art that the MQTT server cannot process the messages reported by the edge devices in a timely manner, resulting in message accumulation and poor service performance of the MQTT server.
[0005] Other features and advantages of the present disclosure will become apparent from the following detailed description, or may be learned in part by the practice of the present disclosure.
[0006] According to the first aspect of the present disclosure, a message processing method for edge devices is provided, including: receiving messages reported by edge devices within a first processing period; performing feature extraction on the messages to obtain message feature vectors; inputting the extracted message feature vectors into a constructed message matching resource prediction model to obtain resource information required by the edge devices; matching cluster resources based on the resource information required by the edge devices, so as to process the messages reported by the edge devices within the first processing period through the cluster resources.
[0007] In some embodiments of the present disclosure, before inputting the extracted message feature vector into a constructed message matching resource prediction model to obtain resource information required by the edge device, the method further includes: constructing the message matching resource prediction model.
[0008] In some embodiments of the present disclosure, constructing the message matching resource prediction model includes: obtaining historical messages reported by multiple edge devices and historical resource information required by multiple edge devices; performing feature extraction on the historical messages to obtain multiple message feature vectors; the message feature vectors correspond one-to-one to the historical messages; and constructing the message matching resource prediction model using the multiple message feature vectors as input data and the historical resource information required by the multiple edge devices as output data.
[0009] In some embodiments of the present disclosure, the message matching resource prediction model is constructed using the multiple message feature vectors as input data and the historical resource information of the multiple edge device requirements as output data, including: training a long short-term memory model using the multiple message feature vectors and the historical resource information of the multiple edge device requirements to obtain the message matching resource prediction model.
[0010] In some embodiments of the present disclosure, when the message is a consumer subscription message, the dimension of the message feature vector includes at least one of the following: message upload time, device identification, message upload data volume, service quality level, number of subscriptions, and message queue telemetry transmission protocol MQTT resource requirement number.
[0011] In some embodiments of the present disclosure, the resource information required by the edge device includes at least one of the following: the quantity of resources required by the edge device and the type of resources required by the edge device.
[0012] In some embodiments of the present disclosure, the cluster resources are resources based on a serverless computing architecture.
[0013] In some embodiments of the present disclosure, cluster resources are matched based on the resource information required by the edge device, including: determining the cluster resource type based on the resource type required by the edge device; and selecting a corresponding number of cluster resources for service preheating based on the number of resources required by the edge device in a resource pool of the determined cluster resource type.
[0014] In some embodiments of the present disclosure, a message processing method for edge devices is provided, which also includes: obtaining resource information required by the edge device during the first processing period; and retraining the constructed message matching resource prediction model using the extracted message feature vector and the resource information required by the edge device during the first processing period.
[0015] In some embodiments of the present disclosure, the provided message processing method for edge devices also includes: monitoring whether a new edge device appears; when the appearance of a new edge device is monitored, obtaining historical private data of the new edge device from a third-party platform; performing feature extraction on the historical private data to obtain an estimated message feature vector; inputting the estimated message feature vector into a constructed message matching resource prediction model to obtain resource information required by the new edge device; matching cluster resources based on the resource information required by the new edge device, and preheating the matched cluster resources to process the messages reported by the new edge device.
[0016] In some embodiments of the present disclosure, before the extracted message feature vector is input into a constructed message matching resource prediction model to obtain the resource information required by the edge device, a message processing method for edge devices is provided, which also includes: determining a reference message feature vector corresponding to the edge device within a first processing period; comparing the extracted message feature vector with the reference message feature vector corresponding to the edge device to obtain the similarity between the two; wherein, inputting the extracted message feature vector into the constructed message matching resource prediction model to obtain the resource information required by the edge device includes: when the similarity is lower than a preset threshold, inputting the extracted message feature vector into the constructed message matching resource prediction model to obtain the resource information required by the edge device.
[0017] In some embodiments of the present disclosure, a message processing method for edge devices is provided, further comprising: when the similarity is higher than or equal to a preset threshold, determining resource information required by the edge device according to a reference message feature vector corresponding to the edge device.
[0018] In some embodiments of the present disclosure, after the extracted message feature vector is input into a constructed message matching resource prediction model to obtain the resource information required by the edge device, the provided message processing method for edge devices also includes: using the message feature vector extracted in the first processing time period as a reference message feature vector corresponding to the edge device in the second processing time period; wherein the second processing time period is an adjacent time period after the first processing time period.
[0019] According to the second aspect of the present disclosure, a message processing device for edge devices is also provided, including: a message receiving module, used to receive messages reported by edge devices within a first processing period; a feature extraction module, used to extract features from the messages to obtain message feature vectors; a resource information prediction module, used to input the extracted message feature vectors into a constructed message matching resource prediction model to obtain resource information required by the edge devices; a resource matching module, used to match cluster resources based on the resource information required by the edge devices, so as to process the messages reported by the edge devices within the first processing period through the cluster resources.
[0020] According to the third aspect of the present disclosure, a message processing system for edge devices is also provided, including: an edge device, a cluster scheduling system and a subscriber-end device; the subscriber-end device is used to subscribe to the message reported by the edge device to the cluster scheduling system; the cluster scheduling system is used to: receive the message reported by the edge device within a first processing period; perform feature extraction on the message to obtain a message feature vector; input the extracted message feature vector into a constructed message matching resource prediction model to obtain resource information required by the edge device; match cluster resources based on the resource information required by the edge device, so as to process the message reported by the edge device within the first processing period through the cluster resources, and push it to the subscriber-end device.
[0021] According to the fourth aspect of the present disclosure, an electronic device is also provided, which includes: a processor; and a memory for storing executable instructions of the processor; wherein the processor is configured to execute the message processing method for an edge device described in any one of the above-mentioned first aspects by executing the executable instructions.
[0022] According to a fifth aspect of the present disclosure, a computer-readable storage medium is also provided, on which a computer program is stored. When the computer program is executed by a processor, the message processing method for an edge device described in any one of the first aspects above is implemented.
[0023] According to a sixth aspect of the present disclosure, a computer program product is also provided, including a computer program, which, when executed by a processor, implements the message processing method for edge devices described in any one of the first aspects above.
[0024] The message processing method for edge devices provided in the embodiments of the present disclosure extracts features of messages reported by edge devices in the first processing period to obtain message feature vectors, inputs the extracted message feature vectors into the constructed message matching resource prediction model to obtain resource information required by edge devices, and then matches cluster resources based on the resource information required by edge devices, so as to process messages reported by edge devices in the first processing period through cluster resources. When receiving messages reported by edge devices, cluster resources can be provided in a timely and sufficient manner for the server to process messages reported by edge devices in a timely manner, thereby avoiding message accumulation and improving the service performance of the server.
[0025] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] The accompanying drawings herein are incorporated into the specification and constitute a part of the specification, illustrate embodiments consistent with the present disclosure, and together with the specification are used to explain the principles of the present disclosure. Obviously, the accompanying drawings described below are only some embodiments of the present disclosure, and for ordinary technicians in this field, other accompanying drawings can be obtained based on these accompanying drawings without creative work.
[0027] Figure 1 A schematic diagram of an edge device-oriented message processing system architecture in an embodiment of the present disclosure is shown.
[0028] Figure 2 A schematic diagram of the functional application of a message processing system for edge devices in an embodiment of the present disclosure is shown.
[0029] Figure 3 A schematic flow chart of a message processing method for edge devices in an embodiment of the present disclosure is shown.
[0030] Figure 4 A schematic flow chart of a message processing method for edge devices in some embodiments of the present disclosure is shown.
[0031] Figure 5 A schematic diagram showing a specific implementation process of S308 in some embodiments of the present disclosure is shown.
[0032] Figure 6 A flow chart of a message processing method for edge devices in some other embodiments of the present disclosure is shown.
[0033] Figure 7 A schematic flow chart of a message processing method for edge devices in some other embodiments of the present disclosure is shown.
[0034] Figure 8A schematic flow chart of a message processing method for edge devices in some further embodiments of the present disclosure is shown.
[0035] Fig. 9 A schematic diagram of the implementation process of the message processing method for edge devices in a specific example in the embodiment of the present disclosure is shown.
[0036] Fig.10 A schematic diagram of a message processing device for edge devices in an embodiment of the present disclosure is shown.
[0037] Fig.11 A structural block diagram of an electronic device in an embodiment of the present disclosure is shown. DETAILED DESCRIPTION
[0038] Example embodiments will now be described more fully with reference to the accompanying drawings. However, example embodiments can be implemented in a variety of forms and should not be construed as limited to the examples set forth herein; rather, these embodiments are provided so that the disclosure will be more comprehensive and complete and to fully convey the concepts of the example embodiments to those skilled in the art. The described features, structures, or characteristics may be combined in any suitable manner in one or more embodiments.
[0039] In addition, the accompanying drawings are only schematic illustrations of the present disclosure and are not necessarily drawn to scale. The same reference numerals in the figures represent the same or similar parts, and their repeated description will be omitted. Some of the block diagrams shown in the accompanying drawings are functional entities and do not necessarily correspond to physically or logically independent entities. These functional entities can be implemented in software form, or implemented in one or more hardware modules or integrated circuits, or implemented in different networks and / or processor devices and / or microcontroller devices.
[0040] The specific implementation of the embodiment of the present disclosure is described in detail below with reference to the accompanying drawings.
[0041] Figure 1 FIG. 1 shows a schematic diagram of a message processing system for edge devices that can be applied in the embodiments of the present disclosure. Figure 1 As shown, the system architecture may include: an edge device 10, a cluster scheduling system 20, and a subscriber device 30. Two devices in the system are connected via a network, which may be a wireless network.
[0042] Optionally, the wireless network described above uses standard communication technologies and / or protocols. The network is typically the Internet, but may also be any network, including but not limited to a local area network (LAN), a metropolitan area network (MAN), a wide area network (WAN), a mobile or wireless network, a dedicated network, or any combination of a virtual private network). In some embodiments, technologies and / or formats including Hyper Text Mark-up Language (HTML), Extensible Markup Language (XML), etc. are used to represent data exchanged over the network. In addition, conventional encryption technologies such as Secure Socket Layer (SSL), Transport Layer Security (TLS), Virtual Private Network (VPN), Internet Protocol Security (IPSec), etc. may be used to encrypt all or some links. In other embodiments, customized and / or dedicated data communication technologies may also be used to replace or supplement the above data communication technologies.
[0043] In some embodiments of the present disclosure, the subscription end device 30 is used to subscribe to the message reported by the edge device 10 to the cluster scheduling system 20. It should be noted that the edge device 10 mainly refers to the switch, router, routing switch, IAD and various MAN / WAN devices installed on the edge network, which are responsible for the data packet transmission between the access device and the core / backbone network device. The edge device is a physical device that applies the data link layer (second layer) and network layer (third layer) technology. The edge device 10 reports a message to the cluster scheduling system 20. For example, when the edge device 10 is a camera, the monitoring video message is reported to the cluster scheduling system 20, which may include: monitoring period, camera number, monitoring video data, QoS (Quality of Service) level, customer subscription number and cluster resource requirement number (that is, the number of cluster resources required to process this monitoring video message); for example, when the edge device 10 is a smoke sensor, the smoke sensor detection message is reported to the cluster scheduling system 20, which may include: detection period, smoke sensor number, sensor detection data, QoS level, customer subscription number and cluster resource requirement number. Those skilled in the art will appreciate that the above are merely examples, the edge device 10 may be other specific devices, and the uploaded messages may also be adaptively adjusted according to actual conditions.
[0044] After receiving the message reported by the edge device 10, the cluster scheduling system 20 processes the message and allocates corresponding resources to process and push it to the subscription device 30 corresponding to the message for the customer to view, that is, the edge device 10 acts as the producer of the message, and the cluster scheduling system 20 acts as the consumer of the message, notifying the subscription device 30 of the content contained in the message. Specifically, the subscription device 30 can be a terminal device, that is, various electronic devices, including but not limited to smart phones, tablet computers, laptops, desktop computers, smart speakers, smart watches, wearable devices, augmented reality devices, virtual reality devices, etc. Optionally, the client of the application installed in different terminal devices is the same, or the client of the same type of application based on different operating systems. Based on different terminal platforms, the specific form of the client of the application can also be different. For example, the application client can be a mobile client, a PC client, etc. The subscription-end device 30 may be a server, or a server that provides various services. Optionally, the server may be an independent physical server, or a server cluster or distributed system composed of multiple physical servers. It may also be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, CDN (Content Delivery Network), and big data and artificial intelligence platforms.
[0045] It should be noted that the cluster scheduling system 20 is used to: receive messages reported by edge devices 10 within a first processing period; extract features from messages to obtain message feature vectors; input the extracted message feature vectors into a constructed message matching resource prediction model to obtain resource information required by edge devices 10; match cluster resources based on the resource information required by edge devices 10, so as to process messages reported by edge devices 10 within the first processing period through cluster resources, so as to push them to the subscriber device 30. It should be noted that the first processing period is a pre-set period for message reporting, which may be 5 minutes, 10 minutes or 30 minutes, for example. The cluster scheduling system 20 extracts features from one or more messages received within this period, and then uses the constructed message matching resource prediction model to predict the cluster resources required for each message, so as to match cluster resources with the prediction results to process one or more received messages.
[0046] In some embodiments of the present disclosure, the cluster scheduling system 20 may be an MQTT service cluster, and the cluster resources are resources based on the Serverless architecture. Figure 2As shown, the MQTT service cluster can be divided into the following according to functions: the MQTT cluster interacts with the edge device 10 to receive messages reported by the edge device 10; the message queue interacts with the subscriber device 30 to push messages to the corresponding subscriber device 30; Serverless elastic resources are used to provide sufficient and appropriate cluster resources to process the received messages reported by the edge device 10.
[0047] Further, in order to build a message matching resource prediction model, the message processing system for edge devices also sets up a far edge data center and a near edge application system. The near edge application system is included in the cluster scheduling system 20. The far edge data center can be set in the cluster scheduling system 20, or it can be set on other server clusters to reduce the amount of data and resources that the cluster scheduling system 20 needs to process. Specifically, the server resources of the far edge data center are relatively abundant, and can undertake a certain scale of model training tasks. After the training is completed, the model is deployed on the near edge application system. The far edge data center receives the training data collected by the MQTT service cluster, cleans and extracts the training data, and sends the extracted feature vectors to the LSTM (Long Short-Term Memory, long short-term memory model) for training to obtain a trained message matching resource prediction model. It should be noted that the training data collected by the MQTT service cluster can be the received messages collected before the message matching resource prediction model is built, or it can be the received messages collected within a period of time after the message matching resource prediction model is built and initially trained. The collected data is sent to the far edge data center to retrain the message matching resource prediction model to update the message matching resource prediction model. The near-edge application system uses the trained model for prediction, namely near-edge LSTM reasoning, and provides a classified Serverless resource pool for the MQTT service cluster to call Serverless elastic resources. It should be noted that LSTM is a special recurrent neural network (RNN), which is particularly suitable for processing sequence data, such as time series and text data.
[0048] In some embodiments of the present disclosure, a new edge device 10 may appear in the message processing system for edge devices. Since the new edge device 10 is connected to the cluster scheduling system 20 for the first time and may not report any message to the cluster scheduling system 20, the cluster scheduling system 20 needs to obtain the historical private data of the new edge device 10 from a third-party platform, such as a private cloud service platform to which the new edge device 10 has historically connected, and use the historical private data to preheat cluster resources so as to promptly process the messages reported by the new edge device 10 in the future.
[0049] like Figure 1As shown, an edge device 10 and a message receiving subscriber device 30 are taken as examples, and the provided interaction method of the message processing system for edge devices includes:
[0050] S102 , the edge device 10 reports a message to the cluster scheduling system 20 within a first processing period.
[0051] S104 , the cluster scheduling system 20 extracts features from the message to obtain a message feature vector, and inputs the message feature vector into the constructed message matching resource prediction model to obtain resource information required by the edge device 10 .
[0052] S106 , the cluster scheduling system 20 matches cluster resources based on the resource information required by the edge device 10 , and processes the message reported by the edge device 10 in the first processing period through the cluster resources.
[0053] S108 , push the message to the subscription end device 30 .
[0054] S110 , when the cluster scheduling system 20 detects the presence of a new edge device 10 , the cluster scheduling system 20 obtains historical private data of the new edge device 10 from a third-party platform.
[0055] S112 , the cluster scheduling system 20 extracts features from the historical private data to obtain an estimated message feature vector, and inputs the estimated message feature vector into the constructed message matching resource prediction model to obtain resource information required by the newly added edge device 10 .
[0056] S114, matching cluster resources based on resource information required by the newly added edge device 10, and preheating the matched cluster resources.
[0057] It can be understood by those skilled in the art that, in specific implementation, the execution order of the above steps is not limited. Figure 1 This is just an example, for example, S110 to S114 may be performed after S102 to S108, may be performed synchronously with S102 to S108, or may be performed before S102 to S108. The examples of different execution orders of steps are not described one by one in the embodiments of the present disclosure.
[0058] Those skilled in the art will know that Figure 1 The number of edge devices 10, cluster scheduling system 20 and subscriber end devices 30 is only illustrative, and any number of edge devices 10, cluster scheduling system 20 and subscriber end devices 30 may be provided according to actual needs. The embodiments of the present disclosure are not limited to this.
[0059] Under the above system architecture, a message processing method for edge devices is provided in an embodiment of the present disclosure. In some embodiments, the message processing method for edge devices provided in an embodiment of the present disclosure can be implemented by the cluster scheduling system 20, or by the interaction between the edge device 10 and the cluster scheduling system 20, or by the interaction between the edge device 10, the cluster scheduling system 20 and the subscription end device 30.
[0060] like Figure 3 As shown, a message processing method for edge devices provided in an embodiment of the present disclosure includes the following steps S302 to S308.
[0061] S302: Receive a message reported by an edge device within a first processing period.
[0062] S304, extracting features from the message to obtain a message feature vector.
[0063] S306: Input the extracted message feature vector into the constructed message matching resource prediction model to obtain resource information required by the edge device.
[0064] S308 , matching cluster resources based on resource information required by the edge device, so as to process the message reported by the edge device in the first processing period through the cluster resources.
[0065] It can be seen from the above steps that the message processing method for edge devices provided in the embodiments of the present disclosure extracts features of messages reported by edge devices in the first processing period to obtain message feature vectors, inputs the extracted message feature vectors into the constructed message matching resource prediction model to obtain resource information required by edge devices, and then matches cluster resources based on the resource information required by edge devices, so as to process messages reported by edge devices in the first processing period through cluster resources. When receiving messages reported by edge devices, cluster resources can be provided in a timely and sufficient manner for the server to process messages reported by edge devices in a timely manner, thereby avoiding message accumulation and improving the service performance of the server.
[0066] In some embodiments of the present disclosure, when the message is a consumer subscription message, the dimension of the message feature vector includes at least one of the following: message upload time, device identification, message upload data volume, QoS level, number of subscriptions, and number of resource requirements of the message queue telemetry transmission protocol MQTT. Among them, the message upload time refers to the time when the message is uploaded, which is generally embodied in the form of a timestamp. Each moment can be converted into a unique timestamp in the computer system, which is used to locate the time scale of the message upload time in the first processing period; the device identification is a unique identification of the edge device, such as a label that can distinguish the edge device, and the device identification is one-to-one corresponding to the device; the message upload data volume refers to the data size value of the message when it is uploaded, such as a section of the content in the reported message is about 4kB, and 4kB is the message upload data volume of this message; the QoS level refers to the service quality level of the message; the number of subscriptions refers to the number of subscriptions of the subscribing device; the MQTT resource requirement number refers to the number of MQTT resources required to process this message. It can be understood by those skilled in the art that the dimensions of the above message feature vector are only examples, and other data features or parameter features that affect resource prediction may also be included in actual applications, and the present disclosure is not limited here.
[0067] In some embodiments of the present disclosure, the message processing method for edge devices provided further includes, before S306: constructing a message matching resource prediction model. Figure 4 As shown, the following steps S402 to S406 are included.
[0068] S402, obtaining historical messages reported by multiple edge devices and historical resource information required by multiple edge devices.
[0069] It should be noted that multiple edge devices have been connected to the edge device-oriented message processing system for a period of time and there are relevant historical data, including: reported historical messages and historical resource information required by each edge device, that is, messages uploaded during the historical operation of multiple edge devices and resource information actually used by each message when it is processed. Resource information includes at least one of the number of resources and the type of resources.
[0070] S404, extracting features from historical messages to obtain multiple message feature vectors.
[0071] It should be noted that the message feature vector corresponds to the historical message one-to-one, that is, one message feature vector is extracted from one historical message, and the extracted message feature vector dimensions include at least one of the following: message upload time, device identification, message upload data volume, QoS level, number of subscriptions, and number of MQTT resource requirements.
[0072] S406, using multiple message feature vectors as input data and historical resource information required by multiple edge devices as output data, constructing a message matching resource prediction model.
[0073] It should be noted that, when S406 is specifically implemented, the long short-term memory model LSTM is trained using multiple message feature vectors and historical resource information required by multiple edge devices to obtain a message matching resource prediction model to predict the MQTT cluster resources and MQTT cluster resource types required by a certain edge device within a certain prediction period. The resource information required by the edge device includes at least one of the following: the number of resources required by the edge device and the resource type required by the edge device.
[0074] It should be noted that the resource types based on the Serverless architecture generally include: computing resources, memory resources, storage load resources, and computing memory hybrid resources. Different resources have different characteristics and are adapted to different messages. Therefore, when using the message matching resource prediction model for prediction, different resource types are matched according to the characteristics of different messages to maximize the use of resources and avoid unnecessary resource waste. For example, messages with high CPU requirements correspond to computing resources, messages with heavy backend loads correspond to storage load resources, messages with strong consumption capabilities correspond to memory resources, and messages with unclear characteristics correspond to computing memory hybrid resources. For example, for messages with high real-time consumption capabilities but low backend storage requirements, memory resources can be allocated to avoid wasting computing resources and backend storage, saving edge resources.
[0075] It should be noted that cluster resources are based on the Serverless architecture. Figure 5 As shown, steps S502 to S504 are included.
[0076] S502: Determine a cluster resource type based on the resource type required by the edge device.
[0077] S504: Select a corresponding number of cluster resources from a resource pool of the determined cluster resource type based on the number of resources required by the edge device to preheat the service.
[0078] It should be noted that the resource pool is pre-divided according to resource types so that when elastic expansion is required, a corresponding number of resources are selected from the resource pool of a determined cluster resource type to preheat the service, that is, to perform operations including synchronizing backend data and adjusting load balancing on the allocated resources.
[0079] It should be noted that after the message matching resource prediction model is constructed, as the usage time increases, the message matching resource prediction model may have inaccurate predictions, and the constructed message matching resource prediction model needs to be retrained. In specific implementation, the message matching resource prediction model can be retrained regularly at fixed time periods, such as 3 months, 6 months, or 8 months. In a specific embodiment of the present disclosure, a message processing method for edge devices is provided, which also includes: obtaining resource information required by edge devices within a first processing period; using the extracted message feature vector and the resource information required by the edge device within the first processing period to retrain the constructed message matching resource prediction model. That is, the resource information actually used in processing messages within the first processing period and the extracted message feature vector are obtained, and the message matching resource prediction model is retrained so that the message matching resource prediction model is continuously updated and the prediction is more accurate. Since edge devices do not change much over a long period of time (e.g., 1 to 3 months, or even half a year), the appropriate increase in the retraining interval has a relatively small impact on the accuracy of the prediction, and more resources are required for retraining. In another disclosed specific embodiment, the resource information required by edge devices in multiple first processing periods can be obtained, and the constructed message matching resource prediction model can be retrained using the corresponding extracted message feature vectors and the resource information required by edge devices in multiple first processing periods. In other words, the message matching resource prediction model is retrained every multiple first processing periods, and the number of predictions is reduced as much as possible, the amount of data processing is reduced, and the cost investment is reduced while improving the accuracy of the prediction.
[0080] It should be noted that the edge device does not change much over a long period of time (for example, 1 to 3 months, or even half a year). If it is determined in advance that the edge device has not changed significantly, then after receiving the message sent by the edge device, it is not necessary to use the message matching resource prediction model for prediction every time, and the previous prediction result can be used to match the cluster resources. In some embodiments of the present disclosure, a message processing method for edge devices is provided, such as Figure 6 As shown, steps S602 to S604 are included before S306.
[0081] S602: Determine a reference message feature vector corresponding to the edge device in the first processing period.
[0082] It should be noted that the reference message feature vector corresponding to the edge device in the first processing period is the message feature vector input when the message matching resource prediction model was used for prediction for the last time before the first processing period. It may be the message feature vector in the previous period before the first processing period, or it may be the message feature vector in several periods before the first processing period.
[0083] S604, comparing the extracted message feature vector with the reference message feature vector corresponding to the edge device to obtain the similarity between the two.
[0084] Accordingly, S306 is changed to S306 ′: when the similarity is lower than a preset threshold, the extracted message feature vector is input into the constructed message matching resource prediction model to obtain resource information required by the edge device.
[0085] It should be noted that the preset threshold is pre-set, for example, it can be 85%, 80% or 75%, which is a predetermined minimum similarity value that can continue to use the previous prediction results. If it is lower than this preset threshold, it is necessary to input the message feature vector into the constructed message matching resource prediction model to predict the resource information required by the edge device. If it is higher than or equal to the preset threshold, it means that the previous prediction result can be used without predicting again, and the resource information required by the edge device corresponding to the reference message feature vector corresponding to the edge device can be used. Accordingly, if Figure 6 As shown, step S606 is also included.
[0086] S606: When the similarity is higher than or equal to a preset threshold, determine the resource information required by the edge device according to the reference message feature vector corresponding to the edge device.
[0087] It should be noted that, when S306' is implemented, the reference message feature vector corresponding to the edge device needs to be updated, such as Figure 7 As shown, the message processing method for edge devices is provided. Figure 6 On the basis of, after S306', step S702 is also included.
[0088] S702: Use the message feature vector extracted in the first processing period as a reference message feature vector corresponding to the edge device in the second processing period.
[0089] It should be noted that the second processing period is an adjacent period after the first processing period.
[0090] In some embodiments of the present disclosure, a message processing method for edge devices is also provided. Figure 8 As shown, steps S802 to S810 are also included.
[0091] S802, monitor whether a new edge device appears.
[0092] It should be noted that the newly added edge device refers to an edge device that is connected to the service cluster for the first time and has not reported any message to the service cluster.
[0093] S804, when a new edge device is detected, historical private data of the new edge device is obtained from a third-party platform.
[0094] It should be noted that before the newly added edge device is connected to the service cluster, it may be connected to a third-party platform, such as a private cloud, and there is relevant operation data. The historical private data of the newly added edge device can be obtained from the third-party platform, that is, the messages reported by the newly added edge device when it is connected to the third-party platform and the message processing related data.
[0095] S806, extracting features from the historical private data to obtain an estimated message feature vector.
[0096] It should be noted that since the newly added edge device has not been connected to the service cluster, if the message feature vector is extracted, there will be a situation where relevant information is missing. The feature vector can be extracted from the historical private data by analogy with the reported message. For example, the dimensions of the estimated message feature vector include at least one of the following: message upload time, device identification, message upload data volume, service quality level, number of subscriptions, and message queue telemetry transmission protocol MQTT resource requirements. The message upload time refers to the time when the message is uploaded, which is reflected in the form of a timestamp. Since the newly added edge device has not uploaded the message, the time when the message is uploaded can be given or estimated to obtain the timestamp; the device identification is a unique identification of the edge device, such as a label that can distinguish the edge device, such as a number; the message upload data volume refers to the data size value of the message when it is uploaded, which is estimated based on the historical private data; the QoS level refers to the service quality level of the message; the number of subscriptions refers to the number of subscriptions of the subscribing device; the MQTT resource requirement refers to the number of MQTT resources required to process this message, which is an estimated amount, based on the estimated amount of historical private data.
[0097] S808, input the estimated message feature vector into the constructed message matching resource prediction model to obtain resource information required by the newly added edge device.
[0098] S810, matching cluster resources based on resource information required by the newly added edge device, and preheating the matched cluster resources to process messages reported by the newly added edge device.
[0099] It should be noted that since the extracted message feature vector is an estimated one, it may be different from the message feature vector extracted from the message reported during the actual operation of the newly added edge device. After the new edge device has been running for a period of time, the actually reported messages and the resource information actually used to process these messages can be collected, and the message matching resource prediction model can be retrained to better match accurate cluster resources for the newly added edge device.
[0100] By monitoring the newly added edge devices, when the new edge devices are detected, the resource information that may be needed by the new edge devices can be immediately predicted. In other words, the impact of the new edge devices can be predicted in advance, and resources can be preheated in advance to avoid the new edge devices competing for the cluster resources required by the original edge devices and to avoid affecting other stable edge businesses.
[0101] In order to better illustrate the message processing method for edge devices provided by the embodiment of the present disclosure, a specific example is now given for further explanation. Figure 2 The message processing system architecture for edge devices is shown in Fig. 9 As shown, the specific implementation process of this specific instance of the message processing method for edge devices provided based on the embodiment of the present disclosure is shown.
[0102] like Figure 2 As shown in the figure, different edge devices (device 1, device 2, device 3, etc.) publish messages to the MQTT service cluster, and the MQTT service cluster consumes load after receiving the message. With the surge in edge traffic, the near-edge resource expansion capacity is insufficient, and the Serverless architecture is used to expand resources. LSTM is used to predict the elastic expansion of Serverless, and the Serverless resource pool is classified by type. The MQTT cluster resources are expanded according to the predicted number of cluster resources and the predicted cluster resource classification. At the same time, when adding new edge devices (devices 11 and 12 in the figure), the LSTM model is used to predict the required number of cluster resources and / or cluster resource types, so that cluster resources can be preheated in time.
[0103] like Fig. 9 As shown in the figure, the specific workflow includes:
[0104] The MQTT service cluster pre-determines whether there is a training requirement. If so, the training data will be collected and sent to the remote edge data center for cleaning and processing.
[0105] The far edge data center (training side) extracts the MQTT six-element feature vector group (message upload time, device identification, message upload data volume, QoS level, number of subscriptions, and number of MQTT resource requirements) and feeds it into the LSTM model for training. The trained message matching resource prediction model and the classification strategy of the Serverless resource pool are deployed to the near edge.
[0106] It should be noted that the classification strategy of the Serverless resource pool is: messages with high CPU requirements correspond to computing resources, messages with heavy backend load correspond to storage load resources, messages with strong consumption capabilities correspond to memory resources, and messages with unclear characteristics correspond to computing and memory mixed resources.
[0107] The near edge (inference side) extracts the MQTT six-element feature vector group for LSTM inference.
[0108] Determine whether the inference object is a newly added edge device. For non-newly added edge devices, you can choose to use the more stable original Serverless deployment strategy or re-initiate inference based on the similarity between the edge device and the reference MQTT six-element vector group. For example, after the edge device changes its working scenario, the original Serverless deployment strategy cannot be used, and you need to re-initiate inference.
[0109] If a new edge device is added, it is necessary to initiate model reasoning at the near edge to determine the Serverless deployment strategy for the new edge device in the short term and the required Serverless resource types.
[0110] The near edge reports the inference result strategy to the Serverless resource pool and allocates the required number of standard Serverless resources in resource pools of different categories.
[0111] Preheat the MQTT service for the allocated standard Serverless resources, including synchronizing backend data and adjusting load balancing.
[0112] From the above process, it can be seen that the MQTT service cluster distributes the application content of the edge device message consumption, uses the combination of near edge and far edge, uses LSTM to predict the resource behavior and time trend of the MQTT service cluster, preheats the resources, and seamlessly elastically scales up and down based on the Serverless architecture. Use LSTM to train the messages reported by the edge device to obtain the behavior prediction model of the MQTT service cluster when processing different types of reported messages within a certain period of time, thereby avoiding the existing method of adding resources in batches, and can elastically scale up the cluster resources in one step. Different types of reported messages require different cluster resources. The current Serverless architecture generally provides unified specifications for resource expansion. In contrast, this specific example allocates cluster resources of the appropriate type to the message, saving edge resources. Since the frequent addition and deletion of edge devices will greatly affect the consumption capacity of MQTT, by predicting the behavior trend of the newly added edge devices and preheating the corresponding cluster resources in advance, it can avoid the problem of competing for resources with existing stable businesses.
[0113] It can be seen that this specific example can avoid the problems of untimely resource preheating and unbalanced consumption traffic caused by a surge in edge traffic. It optimizes the resource usage cost while improving the daily consumption capacity of the MQTT cluster.
[0114] It should be noted that the acquisition, storage, use, and processing of data in the technical solution disclosed in this disclosure are in compliance with the relevant provisions of national laws and regulations.
[0115] Based on the same inventive concept, the present disclosure also provides a message processing device for edge devices, as described in the following embodiments. Since the principle of solving the problem in the device embodiment is similar to that in the above method embodiment, the implementation of the device embodiment can refer to the implementation of the above method embodiment, and the repeated parts will not be repeated.
[0116] Fig.10 A schematic diagram of a message processing device for edge devices in an embodiment of the present disclosure is shown. Fig.10 As shown, the device comprises:
[0117] The message receiving module 1001 is used to receive messages reported by edge devices within a first processing period.
[0118] The feature extraction module 1002 is used to extract features from the message to obtain a message feature vector.
[0119] The resource information prediction module 1003 is used to input the extracted message feature vector into the constructed message matching resource prediction model to obtain the resource information required by the edge device.
[0120] The resource matching module 1004 is used to match cluster resources based on resource information required by the edge device, so as to process the message reported by the edge device in the first processing period through the cluster resources.
[0121] It should be noted that the message receiving module 1001, feature extraction module 1002, resource information prediction module 1003 and resource matching module 1004 correspond to S302 to S308 in the method embodiment, and the examples and application scenarios implemented by the above modules and corresponding steps are the same, but are not limited to the contents disclosed in the above method embodiment. It should be noted that the above modules as part of the device can be executed in a computer system such as a set of computer executable instructions.
[0122] In some embodiments of the present disclosure, it also includes: a prediction model construction module, which is used to: construct a message matching resource prediction model. In specific implementation, the prediction model construction module is used to: obtain historical messages reported by multiple edge devices and historical resource information required by multiple edge devices; extract features from historical messages to obtain multiple message feature vectors; wherein the message feature vectors correspond one-to-one to the historical messages; use multiple message feature vectors as input data and the historical resource information required by multiple edge devices as output data to construct a message matching resource prediction model. Furthermore, the prediction model construction module is specifically used to: train the long short-term memory model using multiple message feature vectors and the historical resource information required by multiple edge devices to obtain a message matching resource prediction model.
[0123] In some embodiments of the present disclosure, the resource matching module 1004 is specifically used to: determine the cluster resource type based on the resource type required by the edge device; and select a corresponding number of cluster resources for service preheating based on the number of resources required by the edge device in the resource pool of the determined cluster resource type.
[0124] In some embodiments of the present disclosure, it also includes: a model retraining module, which is used to: obtain resource information required by edge devices within a first processing period; and retrain the constructed message matching resource prediction model using the extracted message feature vector and the resource information required by edge devices within the first processing period.
[0125] In some embodiments of the present disclosure, it also includes: a feature vector comparison module, which is used to: determine the reference message feature vector corresponding to the edge device in the first processing period; compare the extracted message feature vector with the reference message feature vector corresponding to the edge device to obtain the similarity between the two.
[0126] Furthermore, the resource information prediction module 1003 is specifically used to: when the similarity is lower than a preset threshold, input the extracted message feature vector into the constructed message matching resource prediction model to obtain the resource information required by the edge device.
[0127] Accordingly, in some embodiments of the present disclosure, the message processing device for edge devices further includes: a resource information determination module, which is used to: when the similarity is higher than or equal to a preset threshold, determine the resource information required by the edge device based on the reference message feature vector corresponding to the edge device.
[0128] In some embodiments of the present disclosure, the message processing apparatus for edge devices further includes: a reference message feature vector update module, configured to use the message feature vector extracted in the first processing time period as the reference message feature vector corresponding to the edge device in the second processing time period; wherein the second processing time period is an adjacent time period after the first processing time period.
[0129] In some embodiments of the present disclosure, it also includes: a new edge device management module, which is used to: monitor whether a new edge device appears; when a new edge device is detected, obtain the historical private data of the new edge device from a third-party platform; perform feature extraction on the historical private data to obtain an estimated message feature vector; input the estimated message feature vector into a constructed message matching resource prediction model to obtain resource information required by the new edge device; match cluster resources based on the resource information required by the new edge device, and preheat the matched cluster resources to process messages reported by the new edge device.
[0130] Those skilled in the art will appreciate that various aspects of the present disclosure may be implemented as systems, methods or program products. Therefore, various aspects of the present disclosure may be specifically implemented in the following forms, namely: complete hardware implementation, complete software implementation (including firmware, microcode, etc.), or a combination of hardware and software, which may be collectively referred to herein as "circuits", "modules" or "systems".
[0131] Refer to the following Fig.11 1100 according to this embodiment of the present disclosure is described. Fig.11 The electronic device 1100 shown is merely an example and should not bring any limitation to the functions and scope of use of the embodiments of the present disclosure.
[0132] like Fig.11 As shown, the electronic device 1100 is in the form of a general computing device. The components of the electronic device 1100 may include but are not limited to: at least one processing unit 1110, at least one storage unit 1120, and a bus 1130 connecting different system components (including the storage unit 1120 and the processing unit 1110).
[0133] The storage unit stores a program code, which can be executed by the processing unit 1110, so that the processing unit 1110 performs the steps of various exemplary embodiments of the present disclosure described in the above “Exemplary Method” section of this specification. For example, the processing unit 1110 can perform the following steps of the above method embodiment:
[0134] Receive messages reported by edge devices within a first processing period; extract features from messages to obtain message feature vectors; input the extracted message feature vectors into a constructed message matching resource prediction model to obtain resource information required by edge devices; match cluster resources based on the resource information required by edge devices, so as to process messages reported by edge devices within the first processing period through cluster resources.
[0135] The storage unit 1120 may include a readable medium in the form of a volatile storage unit, such as a random access storage unit (RAM) 11201 and / or a cache storage unit 11202 , and may further include a read-only storage unit (ROM) 11203 .
[0136] The storage unit 1120 may also include a program / utility 11204 having a set (at least one) of program modules 11205, such program modules 11205 including but not limited to: an operating system, one or more application programs, other program modules, and program data, each of which or some combination may include an implementation of a network environment.
[0137] Bus 1130 may represent one or more of several types of bus structures, including a memory unit bus or memory unit controller, a peripheral bus, an accelerated graphics port, a processing unit, or a local bus using any of a variety of bus architectures.
[0138] The electronic device 1100 may also communicate with one or more external devices 1140 (e.g., keyboards, pointing devices, Bluetooth devices, etc.), may also communicate with one or more devices that enable a user to interact with the electronic device 1100, and / or may communicate with any device that enables the electronic device 1100 to communicate with one or more other computing devices (e.g., routers, modems, etc.). Such communication may be performed through an input / output (I / O) interface 1150. In addition, the electronic device 1100 may also communicate with one or more networks (e.g., local area networks (LANs), wide area networks (WANs), and / or public networks, such as the Internet) through a network adapter 1160. As shown, the network adapter 1160 communicates with other modules of the electronic device 1100 through a bus 1130. It should be understood that, although not shown in the figure, other hardware and / or software modules may be used in conjunction with the electronic device 1100, including but not limited to: microcode, device drivers, redundant processing units, external disk drive arrays, RAID systems, tape drives, and data backup storage systems, etc.
[0139] Through the description of the above implementation, it is easy for those skilled in the art to understand that the example implementation described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, and includes a number of instructions to enable a computing device (which can be a personal computer, a server, a terminal device, or a network device, etc.) to execute the method according to the implementation of the present disclosure.
[0140] In particular, according to an embodiment of the present disclosure, the process described with reference to the flowchart above may be implemented as a computer program product, which includes: a computer program, which implements the above-mentioned message processing method for edge devices when executed by a processor.
[0141] In an exemplary embodiment of the present disclosure, a computer-readable storage medium is also provided, which may be a readable signal medium or a readable storage medium. In some possible implementations, various aspects of the present disclosure may also be implemented in the form of a program product, which includes a program code, and when the program product is run on a terminal device, the program code is used to enable the terminal device to execute the steps according to various exemplary implementations of the present disclosure described in the above “Exemplary Method” section of this specification.
[0142] More specific examples of computer-readable storage media in the present disclosure may include, but are not limited to, an electrical connection having one or more conductors, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
[0143] In the present disclosure, a computer readable storage medium may include a data signal propagated in baseband or as part of a carrier wave, wherein a readable program code is carried. Such propagated data signals may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. A readable signal medium may also be any readable medium other than a readable storage medium, which may send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.
[0144] Alternatively, the program code contained on the computer-readable storage medium may be transmitted using any appropriate medium, including but not limited to wireless, wired, optical cable, RF, etc., or any suitable combination of the foregoing.
[0145] In specific implementation, the program code for performing the operation of the present disclosure may be written in any combination of one or more programming languages, including object-oriented programming languages such as Java, C++, etc., and conventional procedural programming languages such as "C" language or similar programming languages. The program code may be executed entirely on the user computing device, partially on the user device, as an independent software package, partially on the user computing device and partially on a remote computing device, or entirely on a remote computing device or server. In the case of a remote computing device, the remote computing device may be connected to the user computing device through any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computing device (e.g., using an Internet service provider to connect through the Internet).
[0146] It should be noted that, although several modules or units of the device for action execution are mentioned in the above detailed description, this division is not mandatory. In fact, according to the embodiments of the present disclosure, the features and functions of two or more modules or units described above can be embodied in one module or unit. On the contrary, the features and functions of one module or unit described above can be further divided into multiple modules or units to be embodied.
[0147] In addition, although the steps of the method in the present disclosure are described in a specific order in the drawings, this does not require or imply that the steps must be performed in this specific order, or that all the steps shown must be performed to achieve the desired results. Additionally or alternatively, some steps may be omitted, multiple steps may be combined into one step, and / or one step may be decomposed into multiple steps, etc.
[0148] Through the description of the above implementation modes, it is easy for those skilled in the art to understand that the example implementation modes described here can be implemented by software, or by software combined with necessary hardware. Therefore, the technical solution according to the implementation mode of the present disclosure can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.) or on a network, and includes several instructions to enable a computing device (which can be a personal computer, a server, a mobile terminal, or a network device, etc.) to execute the method according to the implementation mode of the present disclosure.
[0149] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. The present disclosure is intended to cover any variations, uses or adaptations of the present disclosure, which follow the general principles of the present disclosure and include common knowledge or customary techniques in the art that are not disclosed in the present disclosure. The description and examples are intended to be exemplary only, and the true scope and spirit of the present disclosure are indicated by the appended claims.
Claims
1. A message processing method for edge devices, It is characterized in that include: Receive a message reported by an edge device within a first processing period; Extracting features from the message to obtain a message feature vector; Determine a reference message feature vector corresponding to the edge device in a first processing period; Comparing the extracted message feature vector with the reference message feature vector corresponding to the edge device to obtain a similarity between the two; When the similarity is lower than a preset threshold, the extracted message feature vector is input into the constructed message matching resource prediction model to obtain the resource information required by the edge device; Matching cluster resources based on resource information required by the edge device, so as to process messages reported by the edge device in the first processing period through the cluster resources; Wherein, matching cluster resources based on resource information required by the edge device includes: Determine a cluster resource type based on the resource type required by the edge device; In a resource pool of the determined cluster resource type, a corresponding number of cluster resources are selected based on the number of resources required by the edge device to preheat the service.
2. The message processing method for edge devices according to claim 1, It is characterized in that Before inputting the extracted message feature vector into the constructed message matching resource prediction model to obtain the resource information required by the edge device, the method further includes: Construct the message matching resource prediction model.
3. The message processing method for edge devices according to claim 2, It is characterized in that Constructing the message matching resource prediction model includes: Obtain historical messages reported by multiple edge devices and historical resource information required by multiple edge devices; Extracting features from the historical messages to obtain a plurality of message feature vectors; the message feature vectors correspond one-to-one to the historical messages; The message matching resource prediction model is constructed by taking the multiple message feature vectors as input data and taking the historical resource information required by the multiple edge devices as output data.
4. The message processing method for edge devices according to claim 3, It is characterized in that The message matching resource prediction model is constructed by taking the multiple message feature vectors as input data and the historical resource information required by the multiple edge devices as output data, including: The long short-term memory model is trained using the multiple message feature vectors and the historical resource information required by the multiple edge devices to obtain the message matching resource prediction model.
5. The message processing method for edge devices according to any one of claims 1 to 4, It is characterized in that When the message is a consumption subscription message, the dimension of the message feature vector includes at least one of the following: Message upload time, device identification, message upload data volume, service quality level, number of subscriptions, and number of resource requirements for the message queue telemetry transport protocol MQTT.
6. The message processing method for edge devices according to any one of claims 1 to 4, It is characterized in that The resource information required by the edge device includes at least one of the following: The quantity of resources required by the edge device and the type of resources required by the edge device.
7. The message processing method for edge devices according to claim 6, It is characterized in that The cluster resources are resources based on a serverless computing architecture.
8. The message processing method for edge devices according to claim 2, It is characterized in that Also includes: Obtaining resource information required by the edge device during the first processing period; The constructed message matching resource prediction model is retrained using the extracted message feature vector and the resource information required by the edge device in the first processing period.
9. The message processing method for edge devices according to claim 8, It is characterized in that Also includes: Monitor whether new edge devices have appeared; When a new edge device is detected, historical private data of the new edge device is obtained from a third-party platform; Performing feature extraction on the historical private data to obtain an estimated message feature vector; Inputting the estimated message feature vector into the constructed message matching resource prediction model to obtain resource information required by the newly added edge device; Cluster resources are matched based on resource information required by the newly added edge device, and the matched cluster resources are preheated to process messages reported by the newly added edge device.
10. The message processing method for edge devices according to claim 1, It is characterized in that Also includes: When the similarity is higher than or equal to a preset threshold, resource information required by the edge device is determined according to the reference message feature vector corresponding to the edge device.
11. The message processing method for edge devices according to claim 1, It is characterized in that After the extracted message feature vector is input into the constructed message matching resource prediction model to obtain the resource information required by the edge device, the method further includes: The message feature vector extracted in the first processing period is used as a reference message feature vector corresponding to the edge device in the second processing period; The second processing period is an adjacent period after the first processing period.
12. A message processing device for edge devices, It is characterized in that include: A message receiving module, used to receive messages reported by edge devices within a first processing period; A feature extraction module, used to extract features from the message to obtain a message feature vector; A resource information prediction module is used to determine a reference message feature vector corresponding to the edge device in a first processing period; compare the extracted message feature vector with the reference message feature vector corresponding to the edge device to obtain a similarity between the two; when the similarity is lower than a preset threshold, input the extracted message feature vector into a constructed message matching resource prediction model to obtain resource information required by the edge device; A resource matching module, configured to match cluster resources based on resource information required by the edge device, so as to process messages reported by the edge device within a first processing period through the cluster resources; Wherein, the resource matching module is specifically used for: Determine a cluster resource type based on the resource type required by the edge device; In a resource pool of the determined cluster resource type, a corresponding number of cluster resources are selected based on the number of resources required by the edge device to preheat the service.
13. A message processing system for edge devices, It is characterized in that include: Edge devices, cluster scheduling systems, and subscriber devices; The subscriber device is used to subscribe to the message reported by the edge device to the cluster scheduling system; The cluster scheduling system is used for: Receive a message reported by an edge device within a first processing period; Extracting features from the message to obtain a message feature vector; Determine a reference message feature vector corresponding to the edge device in a first processing period; Comparing the extracted message feature vector with the reference message feature vector corresponding to the edge device to obtain a similarity between the two; When the similarity is lower than a preset threshold, the extracted message feature vector is input into the constructed message matching resource prediction model to obtain the resource information required by the edge device; Matching cluster resources based on resource information required by the edge device, so as to process the message reported by the edge device in the first processing period through the cluster resource, and push it to the subscribing device; Wherein, matching cluster resources based on resource information required by the edge device includes: Determine a cluster resource type based on the resource type required by the edge device; In a resource pool of the determined cluster resource type, a corresponding number of cluster resources are selected based on the number of resources required by the edge device to preheat the service.
14. An electronic device, It is characterized in that include: processor; as well as A memory, configured to store executable instructions of the processor; The processor is configured to execute the message processing method for edge devices according to any one of claims 1 to 11 by executing the executable instructions.
15. A computer-readable storage medium having a computer program stored thereon, It is characterized in that When the computer program is executed by a processor, the message processing method for edge devices described in any one of claims 1 to 11 is implemented.
16. A computer program product, include: A computer program or instruction, characterized in that when the computer program or instruction is executed by a processor, it implements the message processing method for edge devices described in any one of claims 1 to 11.
