A method, device, terminal device and storage medium for offline message consumption

CN115242640BActive Publication Date: 2026-08-21SHENZHEN OCEANS KING LIGHTING ENG CO LTD +12
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210848942.X
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-07-19
Publication Date
2026-08-21
Estimated Expiration
2042-07-19

AI Technical Summary

Technical Problem

[0003]本申请实施例提供了一种离线消息消费的方法、装置、终端设备及存储介质,可以解决终端设备在上线后无法及时根据对应的离线消息运行设备的问题

Benefits of technology

[0052] This application provides a method, apparatus, terminal device, and storage medium for offline message consumption. First, the grouping type of the terminal device is determined based on grouping requirements. Then, a device grouping number is determined based on the grouping type, and the device grouping number is sent to the terminal device. Next, an offline message is determined based on the message grouping number and the corresponding message consumption strategy. The message grouping number is set by the message topic. Then, the device grouping number sent by the terminal device is received, a target message grouping number matching the device grouping number is selected, and a corresponding target offline message is selected based on the target message grouping number. Finally, the target offline message is sent to the terminal device, enabling the terminal device to consume the target offline message after coming online. This method improves message processing efficiency and accelerates the operating speed of the terminal device after coming online by grouping the terminal device to obtain device grouping numbers, grouping offline messages according to the message topic to obtain message grouping numbers, and searching for message grouping numbers matching the device grouping numbers, allowing the terminal device to receive offline messages corresponding to the message grouping numbers.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115242640B_ABST
    Figure CN115242640B_ABST
Patent Text Reader

Abstract

The application is suitable for the technical field of data processing, and provides a method and device for offline message consumption, terminal equipment and storage medium, comprising determining the grouping type of the terminal equipment based on grouping requirements, determining the equipment grouping number of the terminal equipment according to the grouping type, sending the equipment grouping number to the terminal equipment, determining the offline message based on the message grouping number and the message consumption strategy corresponding to the message grouping number, receiving the equipment grouping number sent by the terminal equipment, selecting the target message grouping number same as the equipment grouping number, selecting the corresponding target offline message according to the target message grouping number, and sending the target offline message to the terminal equipment. The method groups the terminal equipment to obtain the equipment grouping number, groups the offline message to obtain the message grouping number, and finds the offline message according to the equipment grouping number and the message grouping number, and sends the offline message to the terminal equipment, thereby improving the efficiency of message processing and increasing the running speed of the terminal equipment after being online.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application belongs to the field of data processing technology, and in particular relates to a method, apparatus, terminal device and storage medium for offline message consumption. Background Technology

[0002] Currently, after a terminal device goes online, it needs to receive a large number of offline messages. However, it is not possible to find the offline messages that match the terminal device in a timely manner, which results in the terminal device being unable to run the device in a timely manner based on the corresponding offline messages after going online. Summary of the Invention

[0003] This application provides a method, apparatus, terminal device, and storage medium for offline message consumption, which can solve the problem that the terminal device cannot run the device in a timely manner according to the corresponding offline messages after going online.

[0004] In a first aspect, embodiments of this application provide a method for offline message consumption, including:

[0005] The packet type of the terminal device is determined based on the packet requirements, the device packet number of the terminal device is determined according to the packet type, and the device packet number is sent to the terminal device.

[0006] Offline messages are determined based on the message group number and the message consumption strategy corresponding to the message group number; the message group number is set by the message topic.

[0007] Receive the device group number sent by the terminal device, select the target message group number that is the same as the device group number, and select the corresponding target offline message according to the target message group number;

[0008] Send the target offline message to the terminal device so that the terminal device can consume the target offline message after coming online.

[0009] Optionally, the grouping requirements include equipment organization grouping requirements, equipment area grouping requirements, and equipment type grouping requirements;

[0010] The packet type of the terminal device is determined based on the packet requirements, including:

[0011] Determine the organization type of the terminal equipment according to the equipment organization and grouping requirements;

[0012] Determine the region type of the terminal device according to the device region grouping requirements;

[0013] Determine the device type of the terminal device according to the device type grouping requirements;

[0014] The grouping type of the terminal device is determined based on the organization type, region type, and device type.

[0015] Optionally, the device group number of the terminal device is determined according to the group type, including:

[0016] Determine the organization device group number of the terminal device based on the organization type;

[0017] Determine the regional device group number of the terminal device based on the region type;

[0018] Determine the type and group number of the terminal device based on the device type;

[0019] The equipment group number is obtained by combining the organization equipment group number, the area equipment group number, and the type equipment group number.

[0020] Optionally, before determining offline messages based on message group numbers and the message consumption strategy corresponding to those message group numbers, the following steps are included:

[0021] The message group number of an offline message is determined based on the message topic; the message topic includes the device organization topic, the device region topic, and the device type topic.

[0022] The offline message group number is set based on the device's organization topic;

[0023] Set the region message group number for offline messages based on the device region topic;

[0024] Set the type message group number for offline messages based on device type topic;

[0025] The message group number is obtained by combining the organization message group number, the region message group number, and the type message group number.

[0026] Optionally, offline messages are determined based on the message group number and the message consumption strategy corresponding to the message group number, including:

[0027] Set the organizational message consumption policy for offline messages based on the organizational message group number, and determine the organizational offline messages based on the organizational message consumption policy;

[0028] Set the regional message consumption strategy for offline messages based on the regional message group number, and determine the regional offline messages based on the regional message consumption strategy;

[0029] Set the type message consumption strategy for offline messages based on the type message group number, and determine the type of offline message based on the type message consumption strategy.

[0030] Optionally, the device group number sent by the terminal device is received, a target message group number with the same device group number is selected, and a corresponding target offline message is selected according to the target message group number, including:

[0031] The receiving terminal device's device group number; wherein, the device group number includes the organization device group number, the region device group number, and the type device group number;

[0032] Based on the organization device group number, find the target organization message group number among the message group numbers that have the same value as the organization device group number;

[0033] Based on the regional device group number, find the target regional message group number among the message group numbers that match the regional device group number.

[0034] Based on the type device group number, find the target type message group number among the message group numbers that match the type device group number value;

[0035] The target message group number is obtained by combining the target organization message group number, the target region message group number, and the target type message group number.

[0036] Select the target offline message based on the target message group number.

[0037] Secondly, embodiments of this application provide an offline message consumption apparatus, comprising:

[0038] The device group number determination module is used to determine the group type of the terminal device based on the grouping requirements, determine the device group number of the terminal device according to the group type, and send the device group number to the terminal device.

[0039] The offline message determination module is used to determine offline messages based on the message group number and the message consumption strategy corresponding to the message group number; wherein, the message group number is set by the message topic;

[0040] The target offline message selection module is used to receive the device group number sent by the terminal device, select the target message group number that is the same as the device group number, and select the corresponding target offline message according to the target message group number.

[0041] The target offline message sending module is used to send target offline messages to terminal devices so that the terminal devices can consume the target offline messages after coming online.

[0042] Optionally, the grouping requirements include equipment organization grouping requirements, equipment area grouping requirements, and equipment type grouping requirements;

[0043] The group number determination module includes:

[0044] The organization type determination unit is used to determine the organization type of terminal equipment according to the equipment organization and grouping requirements.

[0045] The region type determination unit is used to determine the region type of the terminal device according to the device region grouping requirements.

[0046] The device type determination unit is used to determine the device type of the terminal device according to the device type grouping requirements.

[0047] The grouping type determination unit is used to determine the grouping type of the terminal device based on the organization type, region type, and device type.

[0048] Thirdly, embodiments of this application provide a terminal device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the offline message consumption method described in any one of the first aspects above.

[0049] Fourthly, embodiments of this application provide a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the offline message consumption method described in any of the first aspects above.

[0050] Fifthly, embodiments of this application provide a computer program product that, when run on a terminal device, causes the terminal device to execute the offline message consumption method described in any one of the first aspects.

[0051] The beneficial effects of the embodiments in this application compared with the prior art are:

[0052] This application provides a method, apparatus, terminal device, and storage medium for offline message consumption. First, the grouping type of the terminal device is determined based on grouping requirements. Then, a device grouping number is determined based on the grouping type, and the device grouping number is sent to the terminal device. Next, an offline message is determined based on the message grouping number and the corresponding message consumption strategy. The message grouping number is set by the message topic. Then, the device grouping number sent by the terminal device is received, a target message grouping number matching the device grouping number is selected, and a corresponding target offline message is selected based on the target message grouping number. Finally, the target offline message is sent to the terminal device, enabling the terminal device to consume the target offline message after coming online. This method improves message processing efficiency and accelerates the operating speed of the terminal device after coming online by grouping the terminal device to obtain device grouping numbers, grouping offline messages according to the message topic to obtain message grouping numbers, and searching for message grouping numbers matching the device grouping numbers, allowing the terminal device to receive offline messages corresponding to the message grouping numbers. Attached Figure Description

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

[0054] Figure 1 This is a flowchart illustrating the offline message consumption method provided in an embodiment of this application;

[0055] Figure 2 This is a flowchart illustrating step S101 of the offline message consumption method provided in this application embodiment;

[0056] Figure 3 This is a flowchart illustrating step S103 of the offline message consumption method provided in this application embodiment;

[0057] Figure 4 This is a schematic diagram of the structure of the offline message consumption device provided in the embodiments of this application;

[0058] Figure 5 This is a schematic diagram of the structure of the terminal device provided in the embodiments of this application. Detailed Implementation

[0059] In the following description, specific details such as particular system architectures and techniques are set forth for illustrative purposes and not for limitation, in order to provide a thorough understanding of the embodiments of this application. However, those skilled in the art will understand that this application may also be implemented in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, apparatuses, circuits, and methods have been omitted so as not to obscure the description of this application with unnecessary detail.

[0060] It should be understood that, when used in this application specification and the appended claims, the term "comprising" indicates the presence of the described features, integrals, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integrals, steps, operations, elements, components and / or a collection thereof.

[0061] It should also be understood that the term “and / or” as used in this application specification and the appended claims means any combination of one or more of the associated listed items and all possible combinations, and includes such combinations.

[0062] As used in this application specification and the appended claims, the term "if" may be interpreted, depending on the context, as "when," "once," "in response to determination," or "in response to detection." Similarly, the phrase "if determined" or "if detected [the described condition or event]" may be interpreted, depending on the context, as meaning "once determined," "in response to determination," "once detected [the described condition or event]," or "in response to detection [the described condition or event]."

[0063] Furthermore, in the description of this application and the appended claims, the terms "first," "second," "third," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.

[0064] References to "one embodiment" or "some embodiments" as described in this specification mean that one or more embodiments of this application include a specific feature, structure, or characteristic described in connection with that embodiment. Therefore, the phrases "in one embodiment," "in some embodiments," "in other embodiments," "in still other embodiments," etc., appearing in different parts of this specification do not necessarily refer to the same embodiment, but rather mean "one or more, but not all, embodiments," unless otherwise specifically emphasized. The terms "comprising," "including," "having," and variations thereof mean "including but not limited to," unless otherwise specifically emphasized.

[0065] Figure 1 The flowchart illustrating the offline message consumption method provided in this application is shown as an example and not a limitation; this method can be applied to a server.

[0066] S101: Determine the packet type of the terminal device based on the packet requirements, determine the device packet number of the terminal device according to the packet type, and send the device packet number to the terminal device.

[0067] Specifically, the server determines the grouping type of the terminal devices based on grouping requirements, including device organization grouping requirements, device region grouping requirements, and device type grouping requirements. First, the device organization grouping requirements determine the organization type of the terminal devices, which is based on floor levels; terminal devices on floor one are classified as first-level organization terminal devices, and terminal devices on floor two are classified as second-level organization terminal devices. Then, the device region grouping requirements determine the region type of the terminal devices, which is based on device regions. Finally, the device type grouping requirements determine the device type of the terminal devices, for example, they can be divided into lighting devices such as LED lights and non-lighting devices such as air conditioners.

[0068] The terminal device's organizational device group number is determined based on its organizational type, its regional device group number based on its regional type, and its type device group number based on its device type. These three group numbers are then combined to obtain the terminal device's device group number. This device group number is then sent to the terminal device.

[0069] When the terminal device is a home appliance, such as an air conditioner in the living room area of ​​floor one, the air conditioner's organization type is determined to be "First Organization" based on its floor (floor one), and its area type is determined to be "First Area Type" based on the living room area it is in. The air conditioner is a non-lighting device. The device group number corresponding to the First Organization is 011, the area device group number corresponding to the First Area is 021, and the type device group number corresponding to non-lighting devices is 032. Therefore, the air conditioner's device group number is determined to be 011021032. The server sends the air conditioner's device group number to the air conditioner.

[0070] Specifically, when the terminal device is used for industrial lighting, such as fluorescent lights in the work area of ​​the second floor of an industrial plant, the second organization to which the lighting equipment belongs can be determined based on the second floor where the fluorescent light is located. Equipment area grouping requirements divide the work area into the first area and the non-work area into the second area. Therefore, the area type of the fluorescent light is the first area type, and the equipment type is lighting equipment. The equipment group number corresponding to the second organization is 012, the area equipment group number corresponding to the first area is 021, and the type equipment group number corresponding to the fluorescent light as lighting equipment is 031. Thus, the equipment group number of the fluorescent light is determined to be 012021031. The equipment group number of the fluorescent light is then sent to the fluorescent light.

[0071] S102: Determine offline messages based on message group number and the message consumption strategy corresponding to the message group number; wherein, the message group number is set by the message topic.

[0072] Specifically, message topics include device organization topics, device region topics, device type topics, and instruction topics. The organization message group number for offline messages is set according to the device organization topic, the region message group number for offline messages is set according to the device region topic, and the type message group number for offline messages is set according to the device type topic.

[0073] Specifically, the offline message consumption strategy is set according to the organization message group number; the offline message consumption strategy is set according to the region message group number; and the offline message consumption strategy is set according to the type message group number.

[0074] S103: Receive the device group number sent by the terminal device, select the target message group number that is the same as the device group number, and select the corresponding target offline message according to the target message group number.

[0075] Specifically, the target message group number is selected based on the device group number of the terminal device. For example, if the device group number of the fluorescent lamp is 012021031, then a message group number matching 012021031 is searched and selected as the target message group number. The message consumption strategy corresponding to the offline message is determined based on the target message group number, and the corresponding target offline message is selected according to the message consumption strategy.

[0076] S104: Send the target offline message to the terminal device so that the terminal device can consume the target offline message after coming online.

[0077] Specifically, the server sends the target offline message to the terminal device via the MQTT (Message Queuing Telemetry Transport) protocol, so that the terminal device can consume the offline message after coming online.

[0078] In one embodiment, step S101 includes:

[0079] S1011: Determine the organization type of the terminal equipment according to the equipment organization and grouping requirements;

[0080] S1012: Determine the region type of the terminal device according to the device region grouping requirements;

[0081] S1013: Determine the device type of the terminal device according to the device type grouping requirements;

[0082] S1014: Determine the grouping type of the terminal device based on the organization type, region type, and device type.

[0083] Specifically, the grouping requirements include equipment organization grouping requirements, equipment area grouping requirements, and equipment type grouping requirements. Equipment organization grouping requirements are based on the floor where the terminal equipment is located, with the organization type of terminal equipment on floor one designated as the first organization type, and the organization type of terminal equipment on floor two designated as the second organization type. Equipment area grouping requirements are based on the area where the terminal equipment is located. If the terminal equipment is a home appliance, the equipment area can be divided into living room area, kitchen area, and bedroom area, etc., with the area type of terminal equipment in the living room area designated as the first area type, the area type of terminal equipment in the kitchen area as the second area type, and the area type of terminal equipment in the bedroom area as the third area type. If the terminal equipment is located in an industrial plant, the equipment area can be divided into working area and non-working area, with the area type of terminal equipment in the working area designated as the first area type, and the area type of terminal equipment in the non-working area as the second area type.

[0084] Specifically, the equipment type grouping requirement categorizes terminal equipment into lighting equipment type and non-lighting equipment type based on whether the terminal equipment is lighting equipment. The grouping type of the terminal equipment is determined according to the organization type, area type, and equipment type. For example, if the terminal equipment is a fluorescent lamp in the second work area of ​​an industrial plant, then the grouping type of the fluorescent lamp is the second organization type, the first area type, and the lighting equipment type.

[0085] In one embodiment, such as Figure 2 As shown, step S101 further includes:

[0086] S1015: Determine the organization device group number of the terminal device based on the organization type;

[0087] S1016: Determine the regional device group number of the terminal device based on the regional type;

[0088] S1017: Determine the type and device group number of the terminal device based on the device type;

[0089] S1018: Combine the organization equipment group number, the area equipment group number, and the type equipment group number to obtain the equipment group number.

[0090] Specifically, when the terminal device's organization type is the first organization type, the corresponding organization device group number is 011; when the organization type is the second organization type, the corresponding organization device group number is 012. When the terminal device's region type is the first region type, the corresponding region device group number is 021; when the region type is the second region type, the corresponding region device group number is 022; when the region type is the third region type, the corresponding region device group number is 023. When the terminal device's device type is a lighting device, the corresponding type device group number is 031; when the device type is a non-lighting device, the corresponding type device group number is 032. Combining the organization device group number, the region device group number, and the type device group number yields the terminal device's device group number.

[0091] For example, when the terminal device is a fluorescent lamp in the second work area of ​​an industrial plant, the corresponding grouping type is the second organization type, the first area type, and the lighting equipment type. The device grouping number determined according to the grouping type is 012021031.

[0092] In one embodiment, prior to step S102, the following is included:

[0093] S1021: Determine the message group number of the offline message based on the message topic; wherein, the message topic includes the device organization topic, the device region topic, and the device type topic;

[0094] S1022: Set the organization message group number for offline messages based on the device organization topic;

[0095] S1023: Set the region message group number for offline messages based on the device region topic;

[0096] S1024: Set the type message group number for offline messages based on device type topic;

[0097] S1025: Combine the organization message group number, the area message group number, and the type message group number to obtain the message group number.

[0098] Specifically, the message topic includes device organization topic, device region topic, and device type topic. The message group number for offline messages is set according to the message topic. When the message topic is a device organization topic, it is divided into a first organization topic and a second organization topic. The organization message group number for offline messages corresponding to the first organization topic is 011, and the organization message group number for offline messages corresponding to the second organization topic is 012. When the message topic is a device region topic, it is divided into a first region topic and a second region topic. The region message group number for offline messages corresponding to the first region topic is 021, and the region message group number for offline messages corresponding to the second region topic is 022. When the message topic is a device type topic, it is divided into lighting device topic and non-lighting device topic. The type message group number for offline messages corresponding to the lighting device topic is 031, and the type message group number for offline messages corresponding to the non-lighting device topic is 032. The message group number is obtained by combining the organization message group number, region message group number, and type message group number of the offline message.

[0099] In one embodiment, step S102 includes:

[0100] S1026: Set the organizational message consumption strategy for offline messages based on the organizational message group number, and determine the organizational offline messages based on the organizational message consumption strategy;

[0101] S1027: Set the regional message consumption strategy for offline messages according to the regional message group number, and determine the regional offline messages based on the regional message consumption strategy;

[0102] S1028: Set the type message consumption strategy for offline messages according to the type message group number, and determine the type of offline message based on the type message consumption strategy.

[0103] Specifically, a message consumption strategy is determined based on the message group number, and the decision on whether offline messages need to be consumed is based on the message consumption strategy. Specifically, offline messages matching the organization's message group number are determined based on the organization's message consumption strategy, offline messages matching the region's message group number are determined based on the region's message consumption strategy, and offline messages matching the group type's message group number are determined based on the type's message consumption strategy.

[0104] For example, when the offline messages that match the type message group number include device switch instructions, data acquisition instructions, and device inspection instructions, the corresponding device switch offline message is selected according to the type message consumption strategy and the device switch instruction, the corresponding data acquisition offline message is selected according to the data acquisition instruction, and the corresponding device inspection offline message is selected according to the device inspection instruction.

[0105] In one embodiment, such as Figure 3 As shown, step S103 includes:

[0106] S1031: Device group number of the receiving terminal device; wherein, the device group number includes organization device group number, area device group number and type device group number;

[0107] S1032: Based on the organization device group number, find the target organization message group number among the message group numbers that have the same value as the organization device group number;

[0108] S1033: Based on the area device group number, find the target area message group number among the message group numbers that match the area device group number;

[0109] S1034: Based on the type device group number, find the target type message group number among the message group numbers that match the type device group number value;

[0110] S1035: Combine the target organization message group number, the target area message group number, and the target type message group number to obtain the target message group number;

[0111] S1036: Select the target offline message according to the target message group number.

[0112] Specifically, the server receives the device packet number sent from the terminal device. Based on the terminal device's device packet number, it searches the server for the target message packet number corresponding to that device packet number. Then, it selects the corresponding target offline message based on the target message packet number. Specifically, it searches for the organization message packet number with the same value as the organization device packet number in the device packet number, using it as the target organization message packet number. Similarly, it searches for the region message packet number with the same value as the region device packet number, using it as the target region message packet number. Finally, it searches for the type message packet number with the same value as the type device packet number, using it as the target type message packet number. The target organization message packet number, target region message packet number, and target type message packet number are combined to obtain the target message packet number. The server then searches for the corresponding target offline message based on this target message packet number.

[0113] This application first determines the grouping type of the terminal device based on grouping requirements, then determines the device grouping number of the terminal device based on the grouping type, and sends the device grouping number to the terminal device. Next, it determines the offline message based on the message grouping number and the corresponding message consumption strategy. The message grouping number is set by the message topic. Then, it receives the device grouping number sent by the terminal device, selects a target message grouping number that matches the device grouping number, selects the corresponding target offline message based on the target message grouping number, and finally sends the target offline message to the terminal device, enabling the terminal device to consume the target offline message after going online. This method improves message processing efficiency and speeds up the operation of the terminal device after going online by grouping terminal devices to obtain device grouping numbers, grouping offline messages according to the message topic to obtain message grouping numbers, and searching for message grouping numbers that match the device grouping numbers, allowing the terminal device to receive the offline message corresponding to the message grouping number.

[0114] It should be understood that the sequence number of each step in the above embodiments does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.

[0115] Corresponding to the offline message consumption method in the above embodiment, Figure 4 This diagram illustrates the structure of an offline message consumption apparatus provided in an embodiment of this application. For ease of explanation, only the parts relevant to the embodiments of this application are shown.

[0116] Reference Figure 4 The device 400 includes:

[0117] The device group number determination module 401 is used to determine the group type of the terminal device based on the grouping requirements, determine the device group number of the terminal device according to the group type, and send the device group number to the terminal device.

[0118] The offline message determination module 402 is used to determine offline messages based on the message group number and the message consumption strategy corresponding to the message group number; wherein, the message group number is set by the message topic;

[0119] The target offline message selection module 403 is used to receive the device group number sent by the terminal device, select the target message group number that is the same as the device group number, and select the corresponding target offline message according to the target message group number.

[0120] The target offline message sending module 404 is used to send the target offline message to the terminal device so that the terminal device can consume the target offline message after coming online.

[0121] In one embodiment, the device group number determination module 401 includes: grouping requirements including device organization grouping requirements, device area grouping requirements, and device type grouping requirements;

[0122] The organization type determination unit is used to determine the organization type of terminal equipment according to the equipment organization and grouping requirements.

[0123] The region type determination unit is used to determine the region type of the terminal device according to the device region grouping requirements.

[0124] The device type determination unit is used to determine the device type of the terminal device according to the device type grouping requirements.

[0125] The grouping type determination unit is used to determine the grouping type of the terminal device based on the organization type, region type, and device type.

[0126] In one embodiment, the device group number determination module 401 further includes:

[0127] The organization device grouping number determination unit is used to determine the organization device grouping number of the terminal device based on the organization type.

[0128] The area device grouping number determination unit is used to determine the area device grouping number of the terminal device based on the area type.

[0129] The device type grouping number determination unit is used to determine the device type grouping number of the terminal device based on the device type.

[0130] The equipment grouping number determination unit is used to combine the organization equipment grouping number, the area equipment grouping number, and the type equipment grouping number to obtain the equipment grouping number.

[0131] In one embodiment, the offline message determination module 402 includes:

[0132] The message group number determination unit is used to determine the message group number of an offline message based on the message topic; wherein, the message topic includes the device organization topic, the device region topic, and the device type topic;

[0133] The organization message group number setting unit is used to set the organization message group number for offline messages based on the device organization topic;

[0134] The area message group number setting unit is used to set the area message group number for offline messages based on the device area theme.

[0135] The type message group number setting unit is used to set the type message group number of offline messages based on the device type topic;

[0136] The message group number combination unit is used to combine the organization message group number, the region message group number, and the type message group number to obtain the message group number.

[0137] In one embodiment, the offline message determination module 402 further includes:

[0138] The offline message determination unit is used to set the offline message consumption strategy based on the organizational message group number, and to determine the offline messages based on the organizational message consumption strategy.

[0139] The regional offline message determination unit is used to set the regional message consumption strategy for offline messages according to the regional message group number, and to determine the regional offline messages based on the regional message consumption strategy.

[0140] The offline message type determination unit is used to set the offline message type consumption strategy based on the offline message type group number, and to determine the offline message type based on the offline message type consumption strategy.

[0141] In one embodiment, the target offline message selection module 403 includes:

[0142] The device group number receiving unit is used to receive the device group number of the terminal device; wherein, the device group number includes the organization device group number, the area device group number, and the type device group number;

[0143] The target organization message group number determination unit is used to find the target organization message group number among the message group numbers that match the organization device group number based on the organization device group number.

[0144] The target area message group number determination unit is used to find the target area message group number among the message group numbers that match the value of the area device group number, based on the area device group number.

[0145] The target type message group number determination unit is used to find the target type message group number among the message group numbers that match the type device group number, based on the type device group number.

[0146] The target message group number combination unit is used to combine the target organization message group number, the target area message group number, and the target type message group number to obtain the target message group number.

[0147] The target offline message selection unit is used to select target offline messages based on the target message group number.

[0148] This application first determines the grouping type of the terminal device based on grouping requirements, then determines the device grouping number of the terminal device based on the grouping type, and sends the device grouping number to the terminal device. Next, it determines the offline message based on the message grouping number and the corresponding message consumption strategy. The message grouping number is set by the message topic. Then, it receives the device grouping number sent by the terminal device, selects a target message grouping number that matches the device grouping number, selects the corresponding target offline message based on the target message grouping number, and finally sends the target offline message to the terminal device, enabling the terminal device to consume the target offline message after going online. This method improves message processing efficiency and speeds up the operation of the terminal device after going online by grouping terminal devices to obtain device grouping numbers, grouping offline messages according to the message topic to obtain message grouping numbers, and searching for message grouping numbers that match the device grouping numbers, allowing the terminal device to receive the offline message corresponding to the message grouping number.

[0149] It should be noted that the information interaction and execution process between the above-mentioned devices / units are based on the same concept as the method embodiments of this application. For details on their specific functions and technical effects, please refer to the method embodiments section, and they will not be repeated here.

[0150] Figure 5 This is a schematic diagram of the structure of a terminal device provided in an embodiment of this application. Figure 5 As shown, the terminal device 500 of this embodiment includes: at least one processor 50 ( Figure 5 (Only one is shown in the diagram), memory 51, and computer program 52 stored in said memory 51 and executable on said at least one processor 50, wherein said processor 50 executes said computer program 52 to implement the steps in any of the above method embodiments.

[0151] The terminal device 500 can be a desktop computer, laptop, handheld computer, cloud server, or other computing device. This terminal device may include, but is not limited to, a processor 50 and a memory 51. Those skilled in the art will understand that... Figure 5 This is merely an example of terminal device 500 and does not constitute a limitation on terminal device 500. It may include more or fewer components than shown in the figure, or combine certain components, or different components, such as input / output devices, network access devices, etc.

[0152] The processor 50 may be a Central Processing Unit (CPU), or it may be other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor.

[0153] In some embodiments, the memory 51 may be an internal storage unit of the terminal device 500, such as a hard disk or memory of the terminal device 500. In other embodiments, the memory 51 may be an external storage device of the terminal device 500, such as a plug-in hard disk, smart media card (SMC), secure digital card (SD), flash card, etc., equipped on the terminal device 500. Furthermore, the memory 51 may include both internal and external storage units of the terminal device 500. The memory 51 is used to store the operating system, applications, bootloader, data, and other programs, such as the program code of the computer program. The memory 51 can also be used to temporarily store data that has been output or will be output.

[0154] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the above-described division of functional units and modules is merely an example. In practical applications, the above functions can be assigned to different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiments can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit. Furthermore, the specific names of the functional units and modules are only for easy differentiation and are not intended to limit the scope of protection of this application. The specific working process of the units and modules in the above system can be referred to the corresponding process in the foregoing method embodiments, and will not be repeated here.

[0155] This application also provides a network device, which includes: at least one processor, a memory, and a computer program stored in the memory and executable on the at least one processor, wherein the processor executes the computer program to implement the steps in any of the above method embodiments.

[0156] This application also provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps described in the various method embodiments above.

[0157] This application provides a computer program product that, when run on a mobile terminal, enables the mobile terminal to implement the steps described in the above-described method embodiments.

[0158] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, all or part of the processes in the methods of the above embodiments of this application can be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed by a processor, it can implement the steps of the various method embodiments described above. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or certain intermediate forms. The computer-readable medium can include at least: any entity or device capable of carrying computer program code to a photographing device / terminal device, a recording medium, a computer memory, a read-only memory (ROM), a random access memory (RAM), an electrical carrier signal, a telecommunication signal, and a software distribution medium. Examples include USB flash drives, portable hard drives, magnetic disks, or optical disks. In some jurisdictions, according to legislation and patent practice, computer-readable media cannot be electrical carrier signals or telecommunication signals.

[0159] In the above embodiments, the descriptions of each embodiment have different focuses. For parts that are not described in detail or recorded in a certain embodiment, please refer to the relevant descriptions of other embodiments.

[0160] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0161] In the embodiments provided in this application, it should be understood that the disclosed apparatus / network devices and methods can be implemented in other ways. For example, the apparatus / network device embodiments described above are merely illustrative. For instance, the division of modules or units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between devices or units may be electrical, mechanical, or other forms.

[0162] 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 units can be selected to achieve the purpose of this embodiment according to actual needs.

[0163] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and should all be included within the protection scope of this application.

Claims

1. A method for offline message consumption, characterized in that, The offline message consumption method is applied in a server and includes: The group type of the terminal device is determined based on the grouping requirements, the device group number of the terminal device is determined according to the grouping type, and the device group number is sent to the terminal device. The message group number of the offline message is determined based on the message topic; wherein, the message topic includes a device organization topic, a device region topic, and a device type topic; the organization message group number of the offline message is set based on the device organization topic; the region message group number of the offline message is set based on the device region topic; the type message group number of the offline message is set based on the device type topic; the organization message group number, the region message group number, and the type message group number are combined to obtain the message group number; Determining offline messages based on message group numbers and corresponding message consumption policies includes: setting an organizational message consumption policy for the offline messages based on organizational message group numbers, and determining organizational offline messages based on the organizational message consumption policy; setting a regional message consumption policy for the offline messages based on regional message group numbers, and determining regional offline messages based on the regional message consumption policy; and setting a type message consumption policy for the offline messages based on type message group numbers, and determining type offline messages based on the type message consumption policy. Receive the device group number sent by the terminal device, select a target message group number that is the same as the device group number, and select the corresponding target offline message according to the target message group number; The target offline message is sent to the terminal device so that the terminal device can consume the target offline message after coming online.

2. The method as described in claim 1, characterized in that, The grouping requirements include equipment organization grouping requirements, equipment area grouping requirements, and equipment type grouping requirements; The process of determining the packet type of the terminal device based on packet requirements includes: The organization type of the terminal device is determined according to the device organization and grouping requirements; The region type of the terminal device is determined according to the device region grouping requirements; The device type of the terminal device is determined according to the device type grouping requirements; The grouping type of the terminal device is determined based on the organization type, the region type, and the device type.

3. The method as described in claim 2, characterized in that, Determining the device group number of the terminal device according to the group type includes: The organization device group number of the terminal device is determined based on the organization type; Determine the regional device group number of the terminal device based on the region type; Determine the type device group number of the terminal device based on the device type; The device group number is obtained by combining the organization device group number, the region device group number, and the type device group number.

4. The method as described in claim 1, characterized in that, The step of receiving the device group number sent by the terminal device, selecting a target message group number that is the same as the device group number, and selecting the corresponding target offline message according to the target message group number includes: Receive the device group number of the terminal device; wherein, the device group number includes an organization device group number, a region device group number, and a type device group number; Based on the organization device group number, find the target organization message group number among the message group numbers that have the same value as the organization device group number; Based on the area device group number, find the target area message group number among the message group numbers that have the same value as the area device group number; Based on the device type group number, find the target type message group number among the message group numbers that have the same value as the device type group number; The target message group number is obtained by combining the target organization message group number, the target region message group number, and the target type message group number. The target offline message is selected based on the target message group number.

5. An offline message consumption device, characterized in that, The offline message consumption device is configured in the server and includes: The device group number determination module is used to determine the group type of the terminal device based on the grouping requirements, determine the device group number of the terminal device according to the group type, and send the device group number to the terminal device; An offline message determination module is used to determine offline messages based on message group numbers and message consumption strategies corresponding to those message group numbers. Before determining offline messages based on message group numbers and message consumption strategies, the module includes: determining the message group number of the offline message based on a message topic; wherein the message topic includes a device organization topic, a device region topic, and a device type topic; setting an organization message group number for the offline message based on the device organization topic; setting a region message group number for the offline message based on the device region topic; setting a type message group number for the offline message based on the device type topic; and combining the organization message group number, the region message group number, and the type message group number to obtain the message group number. The determination of offline messages based on message group numbers and message consumption strategies includes: setting an organization message consumption strategy for the offline message based on the organization message group number; determining organization-level offline messages based on the organization message consumption strategy; setting a region message consumption strategy for the offline message based on the region message group number; determining region-level offline messages based on the region message consumption strategy; and setting a type message consumption strategy for the offline message based on the type message group number; determining type-level offline messages based on the type message consumption strategy. The target offline message selection module is used to receive the device group number sent by the terminal device, select a target message group number that is the same as the device group number, and select the corresponding target offline message according to the target message group number; The target offline message sending module is used to send the target offline message to the terminal device so that the terminal device can consume the target offline message after coming online.

6. The apparatus as claimed in claim 5, characterized in that, The grouping requirements include equipment organization grouping requirements, equipment area grouping requirements, and equipment type grouping requirements; The group number determination module includes: An organization type determination unit is used to determine the organization type of the terminal device according to the device organization grouping requirements; A region type determination unit is used to determine the region type of the terminal device according to the device region grouping requirements; A device type determination unit is used to determine the device type of the terminal device according to device type grouping requirements; A grouping type determination unit is used to determine the grouping type of the terminal device based on the organization type, the region type, and the device type.

7. A terminal 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 method as described in any one of claims 1 to 4.

8. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by a processor, it implements the method as described in any one of claims 1 to 4.

Citation Information

Patent Citations

  • Internet of Things offline message sending method and device, equipment and storage medium

    CN112559220A