Message processing method and device, electronic equipment, storage medium and computer product

CN122994301APending Publication Date: 2026-10-27GUANGDONG STARTHING TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510522967.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-24
Publication Date
2026-10-27

AI Technical Summary

Technical Problem

为此,本申请提出一种消息处理方法、装置、电子设备、存储介质及计算机产品,用以解决当前随着设备数量的增加和消息量的增长,设备集群服务的负载也在不断增加的问题,实现降低消息处理延迟

Benefits of technology

在接收到用户设备通过消息服务器转发的数据消息后,通过对数据消息进行信息提取,并根据提取信息从本地处理、转发至业务服务与转发至设备集群服务中确定目标消息处理方式,进而可以根据目标消息处理方式,对数据消息进行消息处理,由此,通过接收、筛选和分流消息,从而减少设备集群服务的处理负载,可以降低消息处理延迟。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122994301A_ABST
    Figure CN122994301A_ABST
Patent Text Reader

Abstract

The application relates to the technical field of communication, and provides a message processing method and device, electronic equipment, storage medium and computer product. The method comprises the following steps: receiving a data message forwarded by a user equipment through a message server, extracting information from the data message to obtain extracted information; determining a target message processing mode from local processing, forwarding to a service service and forwarding to a device cluster service according to the extracted information; and processing the data message according to the target message processing mode. The application can reduce the processing load of the device cluster service by receiving, screening and shunting the message, and can reduce the message processing delay.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of communication technology, and in particular to a message processing method, apparatus, electronic device, storage medium, and computer product. Background Technology

[0002] With the rapid development of IoT technology, more and more devices are being connected to networks and communicating with servers via the Message Queuing Telemetry Transport (MQTT) protocol. MQTT is a lightweight messaging protocol designed for low-bandwidth, high-latency, or unreliable network environments. In such environments, devices need a message server (such as Emqx) as a gateway for publishing and subscribing to messages. Emqx is an open-source MQTT message server that supports large-scale distributed deployment and provides high availability and high throughput message processing capabilities. However, as the number of devices and the volume of messages increase, a single Emqx instance may face performance bottlenecks, especially when processing a large number of messages reported by devices and business commands.

[0003] To solve this problem, a device cluster service called DeviceHub is typically needed to handle downstream business. DeviceHub acts as middleware, receiving device messages forwarded by Emqx, decoding them, performing necessary business processing, and then forwarding the results to the business system. Simultaneously, DeviceHub also receives instructions from the business system, encodes them, and sends them to the corresponding devices via Emqx.

[0004] However, as the number of devices and the volume of messages increase, the load on the device cluster service also increases, leading to higher message processing latency. Summary of the Invention

[0005] This application aims to address at least one of the technical problems existing in the related art. To this end, this application proposes a message processing method, apparatus, electronic device, storage medium, and computer product to solve the problem that the load on device cluster services is constantly increasing with the increase in the number of devices and the growth in message volume, thereby reducing message processing latency.

[0006] The message processing method according to the first aspect of this application includes: Upon receiving a data message forwarded by a user equipment through a message server, information is extracted from the data message to obtain extracted information; Based on the extracted information, the target message processing method is determined from local processing, forwarding to business services, and forwarding to device cluster services; The data message is processed according to the target message processing method.

[0007] According to one embodiment of this application, the message processing of the data message according to the target message processing method includes: If the target message processing method is to forward to the device cluster service, the data message is forwarded to the distributed stream processing platform; if the device cluster service has subscribed to the topic of the distributed stream processing platform, it consumes the data message from the distributed stream processing platform.

[0008] According to one embodiment of this application, after the device cluster service consumes the data message from the distributed stream processing platform, it forwards the data message to the business system corresponding to the data message.

[0009] According to one embodiment of this application, the step of processing the data message according to the target message processing method further includes: If the target message processing method is to forward it to a business service, the target business service is determined from each business service in the preset business service set based on the extracted information; The data message is forwarded to the target business service.

[0010] According to one embodiment of this application, the data message includes at least one of device messages and device online / offline event messages.

[0011] According to one embodiment of this application, the message processing method further includes: Consume service instructions from the distributed stream processing platform. If the service instruction passes verification, forward the service instruction to the user device corresponding to the service instruction via a message server. The service instruction is received by the device cluster service from the business system and sent to the distributed stream processing platform.

[0012] A message processing apparatus according to a second aspect embodiment of this application includes: The extraction module is used to receive data messages forwarded by the user equipment through the message server, extract information from the data messages, and obtain extracted information. The determination module is used to determine the target message processing method from local processing, forwarding to business services, and forwarding to device cluster services based on the extracted information; The processing module is used to process the data message according to the target message processing method.

[0013] An electronic device according to a third aspect of this application includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement any of the message processing methods described above.

[0014] According to a fourth aspect of this application, the storage medium is a non-transitory computer-readable storage medium storing a computer program thereon, which, when executed by a processor, implements the message processing method as described above.

[0015] A computer program product according to a fifth aspect of this application includes a computer program that, when executed by a processor, implements the message processing method as described above.

[0016] The above-described one or more technical solutions in the embodiments of this application have at least the following technical effects: After receiving a data message forwarded by a user device through a message server, information is extracted from the data message. Based on the extracted information, the target message processing method is determined from local processing, forwarding to the business service, and forwarding to the device cluster service. Then, the data message is processed according to the target message processing method. Thus, by receiving, filtering, and distributing messages, the processing load of the device cluster service is reduced, and message processing latency can be reduced.

[0017] Additional aspects and advantages of this application will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of this application. Attached Figure Description

[0018] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0019] Figure 1 This is a flowchart illustrating the message processing method provided in an embodiment of this application.

[0020] Figure 2 This is one of the scenario interaction diagrams of the message processing method provided in the embodiments of this application.

[0021] Figure 3 This is the second scenario interaction diagram of the message processing method provided in the embodiments of this application.

[0022] Figure 4 This is a schematic diagram of the structure of the electronic device provided in this application. Detailed Implementation

[0023] The embodiments of this application will be described in further detail below with reference to the accompanying drawings and examples. The following examples are used to illustrate this application, but should not be used to limit the scope of this application.

[0024] In the description of the embodiments of this application, it should be noted that the terms "center," "longitudinal," "lateral," "upper," "lower," "front," "rear," "left," "right," "vertical," "horizontal," "top," "bottom," "inner," and "outer," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. They are only for the convenience of describing the embodiments of this application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on the embodiments of this application. In addition, the terms "first," "second," and "third" are used for descriptive purposes only and should not be construed as indicating or implying relative importance.

[0025] In the description of the embodiments of this application, it should be noted that, unless otherwise explicitly specified and limited, the terms "connected" and "linked" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium. Those skilled in the art can understand the specific meaning of the above terms in the embodiments of this application based on the specific circumstances.

[0026] In the embodiments of this application, unless otherwise expressly specified and limited, "above" or "below" the second feature can mean that the first feature is in direct contact with the second feature, or that the first feature is in indirect contact with the second feature through an intermediate medium. Furthermore, "above," "on top of," and "over" the second feature can mean that the first feature is directly above or diagonally above the second feature, or simply that the first feature is at a higher horizontal level than the second feature. "Below," "below," and "under" the second feature can mean that the first feature is directly below or diagonally below the second feature, or simply that the first feature is at a lower horizontal level than the second feature.

[0027] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., refer to specific features, structures, materials, or characteristics described in connection with that embodiment or example, which are included in at least one embodiment or example of the embodiments of this application. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of different embodiments or examples.

[0028] This application discloses a message processing method, apparatus, electronic device, storage medium, and computer product.

[0029] Figure 1 This is a flowchart illustrating the message processing method provided in an embodiment of this application, as shown below. Figure 1 As shown, the message processing method includes: Step 110: Receive the data message forwarded by the user equipment through the message server, extract information from the data message, and obtain the extracted information.

[0030] Step 120: Based on the extracted information, determine the target message processing method from local processing, forwarding to business services, and forwarding to device cluster services.

[0031] Step 130: Process the data message according to the target message processing method.

[0032] It should be noted that the execution subject of the message processing method provided in this application embodiment can be a computer device with a device cluster service deployed. The computer device can be, for example, a mobile phone, tablet computer, laptop computer, handheld computer, vehicle electronic device, wearable device, ultra-mobile personal computer (UMPC), netbook, or personal digital assistant (PDA), etc.

[0033] The device cluster service can be managed through a distributed management system such as Apollo. Apollo is used to uniformly manage the configuration parameters of applications in different environments (development, testing, and production), and supports functions such as dynamic push, version management, and access control. In this application, the device cluster service can specifically be DeviceHub (hereinafter also referred to as device-hub) as middleware, and this application can add a message bridge to the original device cluster service such as DeviceHub.

[0034] The computer device of this application may be equipped with or connected to a message processing device, thereby enabling the message processing device to execute the message processing method of this application.

[0035] It should be noted that after the message bridge is added, this application can receive, filter and distribute messages from user devices that were originally sent to the device cluster service through the message bridge.

[0036] Specifically, in this application, the user equipment can send data messages such as device messages and device online / offline event messages to a message server (e.g., Emqx) via the MQTT protocol.

[0037] Figure 2 This is one of the scenario interaction diagrams of the message processing method provided in the embodiments of this application, such as... Figure 2 As shown, the message bridge in this application can subscribe to shared topics and device online / offline event topics in Emqx.

[0038] Therefore, after receiving a data message, the message server can forward it to the message bridge.

[0039] In this application, after the message bridge receives a data message, it can parse the data message to extract the information carried in the data message and use it as the extracted information.

[0040] Furthermore, data messages can be categorized based on the extracted information, and then, based on the categorization results, a message processing method can be determined from multiple message processing methods such as local processing, forwarding to business services, and forwarding to device cluster services as the target message processing method.

[0041] Specifically, messages that need to be processed immediately or do not need to be forwarded (such as statistics, monitoring, or simple data transformation) can be processed directly in the message bridge, thus local processing is determined as the target message processing method.

[0042] For data messages that need to be uploaded to the business system or processed by the business system (such as data messages reported by the thermostat containing information such as the detected indoor temperature and humidity), the data will be forwarded to the device cluster service to determine the target message processing method.

[0043] For data messages that do not require processing by the business system but require processing by other business services (such as data messages containing log information, data messages containing maintenance data, data messages containing security alerts, etc.), they will be forwarded to the business service to determine the target message processing method.

[0044] In this application, data forwarding rules that need to be forwarded to business systems or device cluster services can also be set in the message bridge. If a data message does not meet the data forwarding rules, it is further determined whether the data message has a dedicated business service for processing it. If not, it is determined whether the data message can be processed locally. If the data message meets the data forwarding rules, forwarding to the device cluster service is determined as the target message processing method; if the data message has a dedicated business service for processing it, forwarding to the business service is determined as the target message processing method; if the data message can be processed locally, local processing is determined as the target message processing method. If none of the above conditions are met, a data anomaly message can be returned to the message server.

[0045] Furthermore, the message bridge can process data messages accordingly based on the target message processing method.

[0046] Specifically, if the target message processing method is to forward it to the device cluster service, then the data message will be forwarded to the device cluster service.

[0047] If the target message processing method is to forward it to a business service, then the data message will be forwarded to the corresponding business service.

[0048] If the target message processing method is local processing, then the data message is processed locally, such as performing data statistics, aggregation, or discarding based on the data message.

[0049] Therefore, data messages that do not fall within the preset scope will not be forwarded to the DeviceHub service by the message bridge. Instead, they will be forwarded to other business services or processed by the message bridge itself.

[0050] According to the message processing method of this application embodiment, after receiving a data message forwarded by a user equipment through a message server, information is extracted from the data message, and a target message processing method is determined from local processing, forwarding to a business service, and forwarding to a device cluster service based on the extracted information. Then, the data message is processed according to the target message processing method. Thus, by receiving, filtering, and distributing messages, the processing load of the device cluster service is reduced, and message processing latency can be reduced.

[0051] Based on the above embodiments, message processing is performed on the data message according to the target message processing method, including: If the target message processing method is to forward to the device cluster service, the data message is forwarded to the distributed stream processing platform; the device cluster service consumes data messages from the distributed stream processing platform if it has subscribed to the topic of the distributed stream processing platform.

[0052] Specifically, this application introduces a distributed stream processing platform, which may specifically be Kafka (hereinafter also referred to as Kafka). It should be noted that the device cluster service in this application can subscribe to topics in Kafka to consume data messages from Kafka.

[0053] Therefore, when the target message processing method is to forward it to the device cluster service, the message bridge can forward the data message to the distributed stream processing platform Kafka, so that the device cluster service can consume data messages from the distributed stream processing platform if it has subscribed to the topic of the distributed stream processing platform.

[0054] Furthermore, after consuming data messages from the distributed stream processing platform, the device cluster service can forward the data messages to the corresponding business system, enabling that business system to process the data messages accordingly.

[0055] This application introduces a distributed stream processing platform, enabling device cluster services to independently adjust their consumption rates and avoid being overwhelmed by sudden bursts of traffic from devices.

[0056] Based on the above embodiments, message processing of data messages according to the target message processing method further includes: If the target message processing method is to forward it to a business service, the target business service is determined from each business service in the preset business service set based on the extracted information; Forward the data message to the target business service.

[0057] Specifically, the target message processing method is to forward it to the business service, and determine the target business service from each business service in the preset business service set based on the extracted information.

[0058] For example: if the extracted information determines that the data message is log information, then the log analysis service in the preset business service set will be used as the target business service; if the extracted information determines that the data message is maintenance data, then the maintenance management service in the preset business service set will be used as the target business service; if the extracted information determines that the data message is a security alarm, then the security monitoring service in the preset business service set will be used as the target business service.

[0059] Furthermore, the data message is forwarded to the target business service.

[0060] For example, sending device-generated log information to the log analysis service, sending maintenance data to the maintenance management service, and sending security alerts to the security monitoring service.

[0061] This application reduces the processing load of the device cluster service by receiving, filtering, and distributing messages through a message bridge, thereby reducing message processing latency.

[0062] Based on the above embodiments, the message processing method includes: The system consumes business instructions from the distributed stream processing platform. If the business instruction is verified, it is forwarded to the user device corresponding to the business instruction via the message server. The business instruction is received by the device cluster service from the business system and sent to the distributed stream processing platform.

[0063] Specifically, the business system generates business instructions that need to be sent to the user's device based on business logic or user operations.

[0064] The business system sends the generated business instructions to the DeviceHub service.

[0065] After receiving the instruction, DeviceHub can perform necessary processing on the business instruction, such as encoding, formatting, or adding metadata.

[0066] DeviceHub sends the processed business instructions as messages to the distributed stream processing platform Kafka.

[0067] In this application, the message bridge subscribes to relevant topics from Kafka, and can then consume business commands from Kafka.

[0068] Furthermore, the message bridge processes the received business instructions, such as verifying the validity of the instructions and parsing the content of the instructions.

[0069] Furthermore, the message bridge forwards the processed business instructions to the message server Emqx.

[0070] After receiving the service instruction, Emqx then sends the service instruction to the corresponding user equipment based on the target device information in the service instruction.

[0071] This application introduces a distributed stream processing platform, enabling message bridges to independently adjust their consumption rate and avoid being overwhelmed by sudden traffic surges from business systems.

[0072] Based on the above embodiments, such as Figure 2 As shown, this application includes a shared message stream loop process, during which user devices can report messages to Emqx, and Emqx can share messages with the message bridge via a client library or tool, MqttClient. The message bridge can forward messages that meet the data forwarding rules to Kafka, thus solving the problem of device hub nodes processing all device messages by introducing Kafka.

[0073] This application also includes a loop process for device online / offline message streams. In this process, Emqx can send data messages of device online / offline events to the MessageBridge through the client library or the tool MqttClient. The MessageBridge can forward the data messages of device online / offline events to Kafka, where DeviceHub consumes the data messages from Kafka and maintains device dialogue based on online / offline events.

[0074] This application also includes a device authentication loop process, and may further include a Redis database. During this process, Emqx can perform device authentication through DeviceHub. The Redis database can synchronously store device authorization rules, which DeviceHub can then retrieve from Redis, perform device authentication according to the rules, and return the authentication result to Emqx.

[0075] Furthermore, Figure 3 This is a second scenario interaction diagram of the message processing method provided in the embodiments of this application, such as... Figure 3 As shown in the diagram, in this application, Emqx can act as a gateway layer to forward data messages to the MessageBridge. The MessageBridge can further forward device messages and related messages about device online / offline events. DeviceHub, as the message processing layer, performs tasks such as maintaining device authentication rules, authenticating devices, maintaining local and remote sessions, and handling message processing and forwarding.

[0076] It should be further noted that this application may include the following publishing and closing procedures.

[0077] Release process: 1. Add the configuration to Apollo that disables the switch by default (message.bridge.enabled=false), and it will take effect when the release is completed.

[0078] Setting message.bridge.enabled to false as the default value means that the message bridging function (device-message-bridge service) will not be enabled by default during the initial deployment of the system or if no value is explicitly specified for this configuration item. This ensures that the system will not perform unnecessary message forwarding operations by default, thus avoiding any impact on system stability.

[0079] "Effects upon release" means that when new configurations are released to the production environment, these configurations will take effect immediately. This means that when a new version is deployed, relevant configuration changes (such as the value of message.bridge.enabled) will be automatically applied to the system, thereby controlling whether the message bridging function is enabled.

[0080] 2. Configure Emqx: Add Redis authentication configuration (do not enable); This step involves configuring Redis as the authentication data source in Emqx, but it is not enabled initially; Configure authentication using a configuration file; this step refers to using a local configuration file to store authentication information, rather than relying on an external database such as Redis. Configure the authentication order; Emqx supports multiple authentication methods and allows you to set the authentication order, meaning that if one authentication method fails, the next authentication method will be tried.

[0081] 3. Publish device-hub (device cluster service, which is responsible for the encoding and decoding of information between services and devices).

[0082] 4. After the device-hub has started up successfully, publish the device-message-bridge (a newly set-up forwarding service used to subscribe to some messages from Emqx and forward these messages to the device-hub for processing via Kafka).

[0083] 5. (10-minute) Test: Test in disabled state (mainly tests OTA and some device startup processes): During the testing process, online connections were gradually shut down using a script.

[0084] 6. (1 minute) Configure Emqx: Enable Emqx Redis authentication and deny authorization if the configuration does not match; "deny authorization if authentication and configuration do not match" usually means that when Emqx queries the client's permission rules from Redis, if no matching rule is found, it decides whether to allow the client's operation based on the configuration. Turn off the Emqx hook.

[0085] 7. (1 minute) Turn on the switches for the two services (turn on device-hub first, then turn on device-message-bridge). (After turning on the switches, device-hub will stop receiving messages, and device-message-bridge will enable dynamic listening to Apollo configuration. After modification, it will start receiving messages.)

[0086] Start device-hub first, then device-message-bridge: This means starting the services in a specific order. First, start the device-hub service, then start the device-message-bridge service. This order may be based on dependencies or startup requirements. When the switch is turned on, the device hub stops receiving messages: when the device hub is turned on, it may not start processing messages immediately. This is to ensure that the device hub does not receive any new messages until the device message bridge is fully up and ready to forward messages; The device-message-bridge service is configured to dynamically listen to relevant configuration items in Apollo. This means it will periodically check for (or receive in real-time updates to) configuration items in Apollo. Once modified, message acceptance begins: The service will begin accepting and processing messages once the configuration in Apollo is modified to enable device-message-bridge (i.e., turn it on). This typically involves subscribing to messages from Emqx and forwarding those messages to device-hub via Kafka.

[0087] 8. (10-minute) Test: Test in the off state (mainly tests wireless download (Over-The-Air, OTA) and some device startup processes).

[0088] Closure process: 1. Enable Emqx hooks; 2. First turn off device-message-bridge, then turn off device-hub (set both to false). 3. Disable Emqx Redis authentication and grant authorization when configuration does not match.

[0089] Emqx hooks are an extension mechanism that allows developers to execute custom code at specific event points, thereby flexibly modifying or extending system functionality.

[0090] The message processing apparatus provided in this application is described below. The message processing apparatus described below and the message processing method described above can be referred to in correspondence.

[0091] Furthermore, this application also provides a message processing apparatus.

[0092] The message processing device includes: The extraction module is used to receive data messages forwarded by the user equipment through the message server, extract information from the data messages, and obtain extracted information. The determination module is used to determine the target message processing method from local processing, forwarding to business services, and forwarding to device cluster services based on the extracted information; The processing module is used to process the data message according to the target message processing method.

[0093] The message processing device of this application, after receiving a data message forwarded by a user equipment through a message server, extracts information from the data message and determines the target message processing method from local processing, forwarding to a business service, or forwarding to a device cluster service based on the extracted information. Then, it processes the data message according to the target message processing method. Thus, by receiving, filtering, and distributing messages, the processing load of the device cluster service is reduced, and message processing latency is reduced.

[0094] In one embodiment, the processing module is specifically used for: If the target message processing method is to forward to the device cluster service, the data message is forwarded to the distributed stream processing platform; if the device cluster service has subscribed to the topic of the distributed stream processing platform, it consumes the data message from the distributed stream processing platform.

[0095] In one embodiment, the processing module is further configured to: If the target message processing method is to forward it to a business service, the target business service is determined from each business service in the preset business service set based on the extracted information; The data message is forwarded to the target business service.

[0096] The message processing device includes: The forwarding module is used to consume business instructions from the distributed stream processing platform. If the business instruction is verified, the module forwards the business instruction to the user device corresponding to the business instruction through the message server. The business instruction is received by the device cluster service from the business system and sent to the distributed stream processing platform.

[0097] Figure 4 An example is a schematic diagram of the physical structure of an electronic device, such as... Figure 4 As shown, the electronic device may include a processor 410, a communications interface 420, a memory 430, and a communication bus 440, wherein the processor 410, the communications interface 420, and the memory 430 communicate with each other via the communication bus 440. The processor 410 can call logical instructions in the memory 430 to execute the following method: receiving a data message forwarded by the user equipment through a message server, extracting information from the data message, and obtaining extracted information; Based on the extracted information, the target message processing method is determined from local processing, forwarding to business services, and forwarding to device cluster services; The data message is processed according to the target message processing method.

[0098] Furthermore, the logical instructions in the aforementioned memory 430 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to related technologies, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0099] In another aspect, embodiments of this application also provide a non-transitory computer-readable storage medium storing a computer program thereon, which, when executed by a processor, is implemented to perform the methods provided in the above embodiments, such as: receiving a data message forwarded by a user equipment through a message server, extracting information from the data message, and obtaining extracted information; Based on the extracted information, the target message processing method is determined from local processing, forwarding to business services, and forwarding to device cluster services; The data message is processed according to the target message processing method.

[0100] In another aspect, embodiments of this application also provide a computer program product, on which a computer program is stored. When the computer program is executed by a processor, it is implemented to perform the methods provided in the above embodiments, such as: receiving a data message forwarded by a user equipment through a message server, extracting information from the data message, and obtaining extracted information; Based on the extracted information, the target message processing method is determined from local processing, forwarding to business services, and forwarding to device cluster services; The data message is processed according to the target message processing method.

[0101] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.

[0102] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the parts that contribute to the related technology, can be embodied in the form of software products. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.

[0103] Finally, it should be noted that the above embodiments are only used to illustrate this application and are not intended to limit this application. Although this application has been described in detail with reference to the embodiments, those skilled in the art should understand that various combinations, modifications, or equivalent substitutions of the technical solutions of this application do not depart from the spirit and scope of the technical solutions of this application.

Claims

1. A message processing method, characterized in that, include: Upon receiving a data message forwarded by a user equipment through a message server, information is extracted from the data message to obtain extracted information; Based on the extracted information, the target message processing method is determined from local processing, forwarding to business services, and forwarding to device cluster services; The data message is processed according to the target message processing method.

2. The message processing method according to claim 1, characterized in that, The step of processing the data message according to the target message processing method includes: If the target message processing method is to forward to the device cluster service, the data message is forwarded to the distributed stream processing platform; if the device cluster service has subscribed to the topic of the distributed stream processing platform, it consumes the data message from the distributed stream processing platform.

3. The message processing method according to claim 2, characterized in that, After consuming the data message from the distributed stream processing platform, the device cluster service forwards the data message to the business system corresponding to the data message.

4. The message processing method according to claim 2, characterized in that, The step of processing the data message according to the target message processing method further includes: If the target message processing method is to forward it to a business service, the target business service is determined from each business service in the preset business service set based on the extracted information; The data message is forwarded to the target business service.

5. The message processing method according to claim 1, characterized in that, The data message includes at least one of the following: device message and device online / offline event message.

6. The message processing method according to claim 1, characterized in that, The message processing method further includes: Consume service instructions from the distributed stream processing platform. If the service instruction passes verification, forward the service instruction to the user device corresponding to the service instruction via the message server. The service instruction is received by the device cluster service from the business system and sent to the distributed stream processing platform.

7. A message processing device, characterized in that, include: The extraction module is used to receive data messages forwarded by the user equipment through the message server, extract information from the data messages, and obtain extracted information. The determination module is used to determine the target message processing method from local processing, forwarding to business services, and forwarding to device cluster services based on the extracted information; The processing module is used to process the data message according to the target message processing method.

8. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the message processing method as described in any one of claims 1-6.

9. A storage medium, said storage medium being a non-transitory computer-readable storage medium, wherein a computer program is stored thereon, characterized in that, When the computer program is executed by a processor, it implements the message processing method as described in any one of claims 1-6.

10. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by a processor, it implements the message processing method according to any one of claims 1-6.