Message pushing method and device and computer readable storage medium

A message push center with an MQTT channel prioritization and switchable system channels addresses the inefficiencies of current mobile push functions, reducing costs and ensuring reliable, secure message delivery.

CN119211345APending Publication Date: 2024-12-27ZHEJIANG GEELY HLDG GRP CO LTD +2

Patent Information

Application Number
CN202411327540.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-23
Publication Date
2024-12-27

AI Technical Summary

Technical Problem

Current mobile push function implementations require developers to connect to multiple commercial push services and mobile phone manufacturer-specific services, leading to repeated code, high development and maintenance costs, and reliance on third-party systems that limit delivery immediacy and security.

Method used

A message push center is introduced that processes and delivers messages, using an MQTT channel as a priority, with switchable system channels to ensure timely and secure delivery, decoupling business systems and optimizing performance.

Benefits of technology

This approach reduces development costs, ensures message delivery reliability, enhances security, and allows for tailored performance optimization, improving user experience and reducing reliance on third-party systems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119211345A_ABST
    Figure CN119211345A_ABST
Patent Text Reader

Abstract

The invention provides a message pushing method and device and a computer readable storage medium, and the method comprises the steps: receiving a target message which is sent by a business system in communication connection with a message pushing center and is used for being pushed to a designated client; then, a target push channel is determined from a plurality of message channels registered in the message push center by the specified client, the target push channel is used for pushing the target message to the specified client based on the target push channel, and the message is transmitted to the push center by introducing the message push center and the service center. Therefore, follow-up delivery of the message is not concerned any more, the problem of system coupling is solved, and service logic is clearer. Meanwhile, the plurality of message channels comprise an mqtt channel which communicates with the specified client through an mqtt protocol; by introducing the mqtt channel, the effect of using multiple terminals through one-time development is achieved, and manpower and financial resources consumed by repeated development are saved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the technical field of message push, and in particular to a message push method, device and computer-readable storage medium. Background Art

[0002] In today's mobile Internet era, the message push function is crucial for various mobile applications. With the continuous development and popularization of mobile applications, the demand for timely receiving application messages is also increasing.

[0003] At present, there are two common ways to implement the push function on mobile terminals: one is to access commercial push services, such as Jiguang Push, etc.; the other is to use the push services provided by various mobile phone manufacturers (such as Xiaomi Push, APNS (Apple Push Notification Service)), etc. However, this situation has brought a series of problems.

[0004] When different application services need to use push service functions, developers need to connect to each commercial push service or the push service provided by each mobile phone manufacturer separately, which leads to a large amount of repeated code and repeated work, and a long development cycle. In addition, each manufacturer will charge a service fee, which increases the cost of system development and maintenance, making the development of message push functions consume a lot of manpower and financial resources.

[0005] Therefore, there are many drawbacks in the current implementation of the mobile push function, and a more efficient message push solution is needed to meet the ever-evolving needs of mobile applications. Summary of the invention

[0006] To overcome the problems existing in the related art, this specification provides a message push method, device and computer-readable storage medium.

[0007] According to a first aspect of an embodiment of this specification, a message push method is provided, which is applied to a message push center, and the method includes:

[0008] Receiving a target message sent by a business system in communication with the message push center for pushing to a designated client;

[0009] Determine a target push channel from a plurality of message channels registered by the designated client in the message push center, wherein the plurality of message channels include an MQTT channel that communicates with the designated client through an MQTT protocol;

[0010] The target message is pushed to the designated client based on the target push channel.

[0011] According to a message push method provided by the present application, the message push center is connected to a server supporting the MQTT protocol in communication.

[0012] The pushing the target message to the designated client based on the target push channel includes:

[0013] When the target push channel is the MQTT channel, push the target message and the device identifier corresponding to the designated client to the MQTT server, so that the MQTT server pushes the target message to the designated client through the channel corresponding to the device identifier;

[0014] The device identifier is information used to uniquely identify the client, which is obtained by the designated client after registering with the message push center.

[0015] According to a message push method provided by the present application, the message channel also includes a system channel set when the mobile terminal where the designated client is located is developed;

[0016] The step of determining a target push channel from a plurality of message channels registered by the designated client at the message push center comprises:

[0017] Determine the target push channel according to the priority of the message channel;

[0018] Among them, the priority of the mqtt channel is greater than that of the system channel.

[0019] According to a message push method provided by the present application, the pushing of the target message to the designated client based on the target push channel includes:

[0020] Monitoring and feeding back status information of information transmission capability of the target push channel;

[0021] Analyzing the status information;

[0022] When the status information indicates that the current target push channel does not meet the preset transmission condition, the target push channel is updated according to the system channel and the other channel of the mqtt channel, and the target message is pushed to the designated client based on the updated target push channel.

[0023] According to a message push method provided by the present application, the target message is pushed to the designated client based on the target push channel, further comprising:

[0024] Obtain the number of times the target information is pushed by the current target push channel;

[0025] If the number reaches a preset value, the target push channel is updated according to the system channel and the other channel of the mqtt channel, and the target message is pushed to the designated client based on the updated target push channel.

[0026] According to a message push method provided by the present application, before receiving a target message sent by a business system in communication connection with the message push center and pushed to a designated client, the method further includes:

[0027] Receiving device information and a user identifier sent by the designated client, wherein the user identifier is determined by user information input when the designated client connects to the message push center;

[0028] Binding the device information and the user identification to generate the device identifier for pushing and receiving the target message;

[0029] The device identifier is sent to the designated client to complete the registration of the designated client in the message push center.

[0030] According to a message push method provided by the present application, before determining a target push channel from a plurality of message channels registered by the designated client in the message push center, the method further includes:

[0031] Verify whether the specified client is registered in the message push center;

[0032] If it has been registered, executing the step of determining a target push channel from a plurality of message channels registered by the designated client at the message push center;

[0033] If not registered, the target message is stored, and after the designated client completes registration, the target message is pushed to the designated client based on the target push channel.

[0034] According to a message push method provided by the present application, the pushing of the target message to the designated client based on the target push channel includes:

[0035] Adjust the structure of the target message according to the message structure requirements of the target push channel;

[0036] The adjusted target message is pushed to the designated client.

[0037] According to a message push method provided by the present application, after pushing the target message to the designated client based on the target push channel, the method further includes:

[0038] Receive the message push result returned by the specified client, and update the status of the target message;

[0039] If no push result indicating that the target message has reached the designated client is received within the set time period, the step of pushing the target message to the designated client based on the target push channel is re-executed.

[0040] According to a message push method provided by the present application, after receiving a target message sent by a business system in communication connection with the message push center and used for pushing to a designated client, the method further includes:

[0041] A message identifier is set for the target message, and the message identifier is sent to the business system, so that the business system tracks the state of the target message according to the message identifier.

[0042] The present application also provides a message pushing device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the program, the message pushing method described above is implemented.

[0043] The present application also provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the message pushing method as described in any one of the above is implemented.

[0044] In the embodiments of this specification, the message push method, device and computer-readable storage medium are different from the current situation that when different application services need to use the push function, they need to connect to each commercial push service or the push service provided by each mobile phone manufacturer separately, which increases the system development and maintenance costs, so that the developed message push function needs to consume a lot of manpower and financial resources. Compared with this, the present application receives the target message sent by the business system connected to the message push center for communication to the specified client; then, from the multiple message channels registered by the specified client in the message push center, the target push channel is determined, which is used to push the target message to the specified client based on the target push channel. By introducing the message push center, the business center passes the message to the push center and no longer cares about the subsequent delivery of the message, which solves the problem of system coupling and makes the business logic clearer. At the same time, the multiple message channels include the MQTT channel that communicates with the specified client through the MQTT protocol; by introducing the MQTT channel, the effect of one-time development and multi-terminal use is achieved, saving the manpower and financial resources consumed by repeated development.

[0045] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present specification. BRIEF DESCRIPTION OF THE DRAWINGS

[0046] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the specification and, together with the description, serve to explain the principles of the specification.

[0047] Figure 1 This is a schematic diagram of a process of pushing a message by a business system according to an exemplary embodiment of this specification;

[0048] Figure 2 is a flowchart of a message push method according to an exemplary embodiment of the present specification;

[0049] Figure 3 is a schematic diagram of a client registration process according to an exemplary embodiment of this specification;

[0050] Figure 4 is an interaction diagram between an mqtt server and a message push center shown in this specification according to an exemplary embodiment;

[0051] Figure 5 is a schematic diagram of a message push device according to an exemplary embodiment of this specification;

[0052] Figure 6 It is a schematic block diagram of a message push device shown in this specification according to an exemplary embodiment. DETAILED DESCRIPTION

[0053] Here, the technical solutions in the embodiments (or "implementations") of the present application will be described clearly and completely in conjunction with the accompanying drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements.

[0054] If there are terms involving directional indications or positional relationships in the embodiments of the present application (such as up, down, left, right, front, back, inside, outside, top, bottom, center, vertical, horizontal, longitudinal, transverse, length, width, counterclockwise, clockwise, axial, radial, circumferential, etc.), such terms are only used to explain the relative positional relationship, movement, etc. between the components under a certain specific posture (as shown in the accompanying drawings); if the specific posture changes, the directional indication or positional relationship will also change accordingly. In addition, the terms "first", "second", etc. involved in the embodiments of the present application are only used for the purpose of convenience of description and cannot be understood as indicating or implying relative importance.

[0055] The present application provides a message push method, device and computer readable storage medium. The present application is described in detail below in conjunction with the accompanying drawings. In the absence of conflict, the features of the following embodiments and implementations can be combined with each other.

[0056] At present, most of the mobile push functions are implemented by connecting to commercial push services (such as Jiguang Push) or using push services provided by various mobile phone manufacturers (such as Xiaomi Push and APNS Apple System Push Notification Service). When different application services need to use the push function, they need to connect to each commercial push service or the push service provided by each mobile phone manufacturer separately. There are a lot of duplicate codes and repeated work expenses in the middle. In summary, the developed message push function requires a lot of manpower and financial resources, and the final push effect is limited by the carrying capacity of the third-party service and cannot be controlled by itself.

[0057] When the system needs to have the function of message push, it needs to be developed separately for different systems and different mobile phone manufacturers, resulting in a long development cycle, and each manufacturer will charge a service fee, which increases the cost of system development and maintenance. Due to reliance on third-party systems, the immediacy and success rate of message delivery will be limited by the stability and service capabilities of the third-party system. If the third-party service fails, the network is unstable, or the load is too high, it may cause problems such as message push delays and uncontrollable losses, affecting the accuracy and timely progress of the business. Today, companies pay more and more attention to information security. Passing customer information or internal system information to external third parties will greatly increase the risk of information leakage.

[0058] In order to solve the above technical problems, this specification provides a message pushing method.

[0059] A message push center is introduced. When the business center needs to send a message, the message will be passed to the message push center, which will push the message to the application / client that receives the message based on the matching channel.

[0060] Among them, the message push center described in this article refers to a system that processes messages and delivers them.

[0061] In one embodiment, if Figure 1 As shown, Figure 1 The schematic diagram of the process of pushing messages by the business system provided in the embodiment of this specification. The message push center also includes a push scheduling service module and a push distribution service module.

[0062] The message push process includes:

[0063] Step 1: When the business system pushes a target message to a designated client (or a target user who logs in to a designated client), the target message is first sent to a push scheduling service module of a message push center;

[0064] Step 1.1, set a message identifier for the target message. The push scheduling service module marks the target message with a unique identifier GUID;

[0065] Step 1.2, the push scheduling service module matches the target push channel according to the available channels (such as system channels, mqtt channels, etc.);

[0066] Step 1.3, the push scheduling service module stores the target message;

[0067] Step 1.4, sending the message identifier to the business system so that the business system can track the status of the target message according to the message identifier. The push scheduling service module returns the unique identifier GUID of the target message to the designated client;

[0068] Step 1.5, the push scheduling service module submits an asynchronous push task to the push distribution service module to start pushing the target message according to the target push channel;

[0069] Step 1.5.1, compose a push instruction and process the message format based on the message structure requirements of the target push channel.

[0070] Step 1.5.2: Push messages through multiple message channels separately. MQTT channel is preferred for push. If push fails, switch to other message channels to push the target message to the specified client.

[0071] Step 1.5.3, specify that the client returns the "message received" information to the push distribution service module;

[0072] Step 1.6: The push scheduling service module updates the message status to ensure that the push is successful.

[0073] By introducing the message push center and MQTT, the effect of one-time development for multiple terminals is achieved, saving manpower and financial resources consumed by repeated development. And by pushing messages through the message push center, the business center no longer cares about the subsequent delivery of messages, solving the coupling problem of business systems, making business logic clearer, and performance can be optimized in a targeted manner to improve user experience.

[0074] Figure 2 The following is a flow chart of a message push method provided based on the above embodiment, comprising the following steps:

[0075] S100, receiving a target message sent by a business system in communication connection with the message push center for pushing to a designated client.

[0076] The business system described in this article is a software system used by the enterprise / supplier that applies the message push program to process specific business logic, data management, and interact with the outside world. Its functions include but are not limited to pushing messages to users to inform them of some important events or status changes. For example, the vehicle management system in a car company, the e-commerce business system, etc.

[0077] The client described in this article refers to an application installed on a user's device (such as a mobile phone, computer, etc.). It is an interface for the user to interact with the server. The user receives and sends messages by operating the client.

[0078] The business system interacts with the message push center through a specific interface (such as the API application programming interface provided by the message push center). The message push center receives the target message sent by the business system and further processes the target message, such as marking the target message with a unique identifier GUID, selecting a push channel, storing the message, etc., and then pushes the message to the target user.

[0079] In this embodiment, by establishing a message push center, the business system does not need to directly handle the message push process, but sends the message to the message push center, which receives and processes the message and pushes it to the specified client or the target user bound to the specified client. The business system is decoupled from the message push center, so that the business system can focus more on processing the core business logic, and the performance can be optimized in a targeted manner.

[0080] The client needs to register with the message push center to receive messages, and register the corresponding system channel and self-built MQTT channel according to the different systems and brands of the client.

[0081] In some embodiments, before receiving the target message sent by the business system in communication with the message push center and used for pushing to the designated client, the method further includes:

[0082] Step a1, receiving device information and user identification sent by the designated client, wherein the user identification is determined by user information input when the designated client connects to the message push center, and the device information refers to information of a mobile device on which the designated client is installed;

[0083] Among other things, the process includes:

[0084] like Figure 3 As shown, Figure 3 The diagram is a client registration process diagram. The message push center includes a push scheduling service module and a member service module.

[0085] Step 1: Initialize the client push SDK and establish a communication connection between the client and the message push center;

[0086] Step 2: The client collects basic messages and uploads them to the message push center, wherein the basic messages include device information of the mobile device on which the specified client is installed, such as device model information.

[0087] Step 2.1, the message push center stores the basic information;

[0088] Step 2.2: The message push center returns feedback information of receiving basic information to the client;

[0089] Step 3, the user logs in on the client;

[0090] Step 3.1: When the login is successful, collect the user login information, obtain the user ID partyId, and return the login information and user ID partyId to the client;

[0091] Step 4: The client calls the binding interface to push the device information and user identifier partyId to the message push center.

[0092] Step a2: Bind the device information with the user identification to generate the device identifier for pushing and receiving the target message.

[0093] Among other things, the process includes:

[0094] Step 4.1, the message push center identifies the mobile device and the user, generates a did device identifier, and implements the binding of the device information and the user identifier. The did represents the unique binding identifier of the device and the user.

[0095] Step a3: sending the device identifier to the designated client to complete the registration of the designated client in the message push center.

[0096] Among other things, the process includes:

[0097] Step 4.2: The message push center returns did to the client.

[0098] In some other embodiments, after receiving the target message sent by the business system in communication connection with the message push center and used for pushing to the designated client, the method further includes:

[0099] Verify whether the specified client is registered with the message push center.

[0100] After receiving the message, the message push center will check whether the push target client is registered in the message push center. If the specified client is not registered, the target message will be stored. After the specified client completes the registration, the target message will be pushed to the specified client based on the target push channel. The target message can be pushed together with other messages after the specified client completes the registration, or it can be pushed after the specified client completes the registration, which is not specifically limited here.

[0101] If the designated client has been registered, the registered did will be obtained as the identifier for subsequent pushes, and the message will be pushed through the message channel corresponding to the did. That is, the subsequent steps of determining the target push channel from the multiple message channels registered by the designated client in the message push center are executed, and the target message is pushed to the designated client based on the target push channel.

[0102] S200, determining a target push channel from a plurality of message channels registered by the designated client in the message push center, wherein the plurality of message channels include an MQTT channel that communicates with the designated client through an MQTT protocol.

[0103] In order to ensure the success rate of message push, the third push channel is still retained. During the message push process, one of the channels is selected as the target push channel according to actual needs.

[0104] Among them, the MQTT channel includes an MQTT server that is communicatively connected to the message push center, and the MQTT server supports the transmission of messages through the MQTT protocol. Messages can be pushed to any terminal through the MQTT channel, such as WEB services, car computers, smart homes, wearable devices, etc. In some examples, the message push center uses EMQX as the MQTT server. After the client registers with the message push center, it obtains the DID device identifier. The client establishes a long connection with EMQX and listens to the message channel corresponding to the DID. In the self-built MQTT channel, the business system usually does not interact directly with the MQTT server, but uses the MQTT channel to push messages through the message push center. The message push center will decide whether to use the MQTT channel and how to interact with the MQTT server based on business needs and push strategies.

[0105] The system channel is a channel set during the development of the mobile terminal (such as a mobile phone, computer, etc.) where the specified client is located, such as the push service provided by various mobile phone manufacturers.

[0106] It is understandable that when multiple message channels work together, in order to avoid conflicts, when pushing messages, it is necessary to match an adaptive channel from available channels as the target push channel for transmission. When the message push fails according to the current channel, other channels will be switched as the target push channel to push the message, thereby ensuring the success rate of message push. In some examples, the selection / switching of channels can be achieved through switch control.

[0107] In some embodiments, determining a target push channel from a plurality of message channels registered by the designated client at the message push center includes:

[0108] The target push channel is determined according to the priorities of the multiple message channels.

[0109] In addition, since the current push service relies on a third-party system, the immediacy and success rate of message delivery will be limited by the stability and service capabilities of the third-party system. If the third-party service fails, the network is unstable, or the load is too high, it may cause problems such as message push delays and uncontrollable loss, affecting the user experience.

[0110] The self-built MQTT channel avoids using the existing commercial push center on the market, which can ensure that information does not flow to third parties, ensure the absolute security of information, save the expenses incurred by using the commercial push center, and fully control the flow of information. It can be optimized for different business scenarios to ensure the efficiency of information delivery. Therefore, the priority of the MQTT channel is set higher than that of the system channel, and the MQTT channel is used as the target push channel first.

[0111] The MQTT channel is used to receive messages. In order to ensure the success rate of message push, the third-party push channel is still retained. The switch can be used to control whether to push the third-party push channel. This part will be introduced in detail in the next chapter when pushing the target message.

[0112] S300: Push the target message to the designated client based on the target push channel.

[0113] The message push center pushes the target message to the specified client that has subscribed to the corresponding topic through the target push channel.

[0114] In order to ensure successful push of the message, the structure of the target message needs to be adjusted according to different channel attributes to adapt to the target push channel. In some embodiments, the target message is pushed to the designated client based on the target push channel, including:

[0115] Adjust the structure of the target message according to the message structure requirements of the target push channel;

[0116] The adjusted target message is pushed to the designated client.

[0117] In some embodiments, if the message push center first selects the MQTT channel for push and monitors the message push results, the message push center pushes the target message and did information to the MQTT server, and the MQTT server processes the message transmission of the MQTT protocol and pushes the target message to the client (or app) that has subscribed to the corresponding topic. Specifically, the MQTT server obtains the long link channel corresponding to the specified client through the did filter channel, and pushes the target message to the channel, and finally reaches the specified client.

[0118] Specifically, the pushing the target message to the designated client based on the target push channel includes:

[0119] When the target push channel is the MQTT channel, push the target message and the DID device identifier corresponding to the designated client to the MQTT server, so that the MQTT server pushes the target message to the designated client through the channel corresponding to the device identifier;

[0120] The message push center is connected to a server supporting the MQTT protocol. The device identifier is information used to uniquely identify the client obtained by the designated client after registering with the message push center.

[0121] As an example, Figure 4 As shown, Figure 4 This is the interaction diagram between the MQTT server and the message push center. The process includes:

[0122] Step b1, when the client registers with the message push center, the client establishes a connection with the message push center, and transmits device information and user information, and obtains the did device identifier returned by the message push center, the did;

[0123] Step b2, specify the client to establish a long connection with the mqtt server;

[0124] Step b3, the message push center pushes the target message sent to the designated client (or the target user who logs in to the designated client) to the MQTT server;

[0125] Step b4, the MQTT server returns feedback information indicating receipt of the target message to the message push center;

[0126] Step b5, the MQTT server finds the corresponding DID according to the user information given by the message push center, and sends the target message to the specified client (or the target user who logs in to the specified client);

[0127] Step b6, specifying the client to feedback the information of "message received" to the message push center;

[0128] Step b7, the message push center sends a confirmation that the message has been received;

[0129] Step b9, after the user reads the target message, the user notifies the message push center of the "read message";

[0130] Step b10, the message push center feeds back confirmation that the "read message" has been received.

[0131] It should be noted that the above description of the status of the feedback message (such as "read message", etc.) is only an example and is not a specific limitation.

[0132] In this embodiment, the MQTT channel is used as a self-built message push channel, which avoids the risk of information leakage, makes the entire link controllable and reliable, provides another self-built channel different from the third-party channel, increases the timeliness and stability of message push, and enhances the system's ability to undertake. And because the message push function is independent, developers can perform special tuning for its performance. The frequency, priority, concurrent processing capability and other parameters of message push can be adjusted according to different business needs and user scenarios.

[0133] In other embodiments, the MQTT channel is first used to receive the message. In order to ensure the success rate of message push, the third-party push channel is still retained, and the switch can be used to control whether to push the third-party push channel / system channel. The switch control can be manually controlled by the back-end administrator of the message push center, or automatically controlled according to the push status information, which is not specifically limited here.

[0134] Specifically, the pushing the target message to the designated client based on the target push channel includes:

[0135] Monitoring and feeding back status information of information transmission capability of the target push channel;

[0136] Analyzing the status information;

[0137] When the status information indicates that the current target push channel does not meet the preset transmission condition, the target push channel is updated according to the system channel and the other channel of the mqtt channel, and the target message is pushed to the designated client based on the updated target push channel.

[0138] In some embodiments, the status information of the transmission capability includes parameters such as the frequency, priority, and concurrent processing capability of message push. For example, when the target message is currently pushed based on the MQTT channel as the target push channel, there is too much load, which affects the immediacy and stability of the push. In this case, the switch control is used to switch to a third-party push channel / system channel as the target push channel to push the target message.

[0139] In other embodiments, the status information of the transmission capability also includes information such as push duration and number of pushes. If the push fails within the set duration and retry range, whether to push the third-party push channel / system channel will be controlled according to the switch.

[0140] Specifically, with respect to the number of pushes, the pushing of the target message to the designated client based on the target push channel further includes:

[0141] Obtain the number of times the target information is pushed by the current target push channel;

[0142] If the number reaches a preset value, the target push channel is updated according to the system channel and the other channel of the mqtt channel, and the target message is pushed to the designated client based on the updated target push channel.

[0143] Specifically, with respect to the push duration, after pushing the target message to the designated client based on the target push channel, the method further includes:

[0144] Receive the message push result returned by the specified client, and update the status of the target message;

[0145] If no push result indicating that the target message has reached the designated client is received within the set time period, the step of pushing the target message to the designated client based on the target push channel is re-executed.

[0146] The above two situations can be applied independently or combined with each other. As an example, if the set duration is 10s, the preset number of pushes is 3 times, and the current target push channel is the mqtt channel. If no response is received from the designated client within 10s after the target message is pushed through the current target push channel, it will be pushed again based on the target push channel until the push fails 3 times. The channel will be switched and the third-party push channel / system channel will be controlled as the target push channel to continue pushing the target message to the designated client, thereby ensuring the success rate of message push.

[0147] The present application provides a message push method, device and computer-readable storage medium. Compared with the current situation that when different application services need to use the push function, they need to connect to each commercial push service or the push service provided by each mobile phone manufacturer separately, which increases the system development and maintenance costs, and makes the developed message push function consume a lot of manpower and financial resources. The present application receives the target message sent by the business system connected to the message push center for communication to the specified client; then, from the multiple message channels registered by the specified client in the message push center, the target push channel is determined, which is used to push the target message to the specified client based on the target push channel. By introducing the message push center, the business center passes the message to the push center and no longer cares about the subsequent delivery of the message, which solves the problem of system coupling and makes the business logic clearer. At the same time, the multiple message channels include the MQTT channel that communicates with the specified client through the MQTT protocol; by introducing the MQTT channel, the effect of one-time development and multi-terminal use is achieved, saving the manpower and financial resources consumed by repeated development.

[0148] Based on the same application concept as the above method, the present application embodiment also proposes a message push device, such as Figure 5 shown.

[0149] The device comprises:

[0150] A message receiving module 502 is used to receive a target message sent by a business system in communication with the message push center for pushing to a designated client;

[0151] A channel determination module 504 is used to determine a target push channel from a plurality of message channels registered by the designated client in the message push center, wherein the plurality of message channels include an MQTT channel that communicates with the designated client through an MQTT protocol;

[0152] The message push module 506 is used to push the target message to the designated client based on the target push channel.

[0153] The implementation process of the functions and effects of each module / submodule / unit in the above-mentioned device is specifically described in the implementation process of the corresponding steps in the above-mentioned method, and the same technical effect can be achieved, so it will not be repeated here.

[0154] Figure 6 The following is a schematic diagram of the physical structure of a message push device. Figure 6 As shown, the message push device may include: a processor 810, a communication interface 820, a memory 830 and a communication bus 840, wherein the processor 810, the communication interface 820 and the memory 830 communicate with each other through the communication bus 840. The processor 810 may call the logic instructions in the memory 830 to execute the message push method.

[0155] In addition, the logic instructions in the above-mentioned memory 830 can be implemented in the form of a software functional unit and can be stored in a computer-readable storage medium when it is sold or used as an independent product. Based on this understanding, the technical solution of the present application can be essentially or partly embodied in the form of a software product that contributes to the prior art, and the computer software product is stored in a storage medium, including several instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk, etc. Various media that can store program codes.

[0156] On the other hand, the present application also provides a computer program product, which includes a computer program. The computer program can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the message push methods provided by the above methods.

[0157] On the other hand, the present application also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which is implemented when the computer program is executed by a processor to execute the message push method provided by the above methods.

[0158] It should be noted that the technical solutions or technical features described in the above embodiments can be combined or supplemented with each other without causing conflicts. The scope of protection of this application is not limited to the precise structures described in the above embodiments and shown in the drawings; all modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of this application should be included in the scope of protection of this application.

Claims

1. A message push method, characterized in that: Applied to a message push center, the method includes: Receiving a target message sent by a business system in communication with the message push center for pushing to a designated client; Determine a target push channel from a plurality of message channels registered by the designated client in the message push center, wherein the plurality of message channels include an MQTT channel that communicates with the designated client through an MQTT protocol; The target message is pushed to the designated client based on the target push channel.

2. The message push method according to claim 1, characterized in that: The message push center is connected to a server supporting the MQTT protocol. The pushing the target message to the designated client based on the target push channel includes: When the target push channel is the MQTT channel, push the target message and the device identifier corresponding to the designated client to the MQTT server, so that the MQTT server pushes the target message to the designated client through the channel corresponding to the device identifier; The device identifier is information used to uniquely identify the client, which is obtained by the designated client after registering with the message push center.

3. The message push method according to claim 1, characterized in that: The message channel also includes a system channel set when the mobile terminal where the designated client is located is developed; The step of determining a target push channel from a plurality of message channels registered by the designated client at the message push center comprises: Determine the target push channel according to the priority of the message channel; Among them, the priority of the mqtt channel is greater than that of the system channel.

4. The message push method according to claim 3, characterized in that: The pushing the target message to the designated client based on the target push channel includes: Monitoring and feeding back status information of information transmission capability of the target push channel; Analyzing the status information; When the status information indicates that the current target push channel does not meet the preset transmission condition, the target push channel is updated according to the system channel and the other channel of the mqtt channel, and the target message is pushed to the designated client based on the updated target push channel.

5. The message push method according to claim 3, characterized in that: The pushing of the target message to the designated client based on the target push channel further includes: Obtain the number of times the target information is pushed by the current target push channel; If the number reaches a preset value, the target push channel is updated according to the system channel and the other channel of the mqtt channel, and the target message is pushed to the designated client based on the updated target push channel.

6. The message push method according to claim 2, characterized in that: Before receiving the target message sent by the business system in communication connection with the message push center and used for pushing to the designated client, the method further includes: Receiving device information and a user identifier sent by the designated client, wherein the user identifier is determined by user information input when the designated client connects to the message push center; Binding the device information and the user identification to generate the device identifier for pushing and receiving the target message; The device identifier is sent to the designated client to complete the registration of the designated client in the message push center.

7. The message push method according to claim 6, characterized in that: Before determining the target push channel from the multiple message channels registered by the designated client in the message push center, the method further includes: Verify whether the specified client is registered in the message push center; If it has been registered, executing the step of determining a target push channel from a plurality of message channels registered by the designated client at the message push center; If not registered, the target message is stored, and after the designated client completes registration, the target message is pushed to the designated client based on the target push channel.

8. The message push method according to claim 1, characterized in that: The pushing the target message to the designated client based on the target push channel includes: Adjust the structure of the target message according to the message structure requirements of the target push channel; The adjusted target message is pushed to the designated client.

9. The message push method according to claim 1, characterized in that: After pushing the target message to the designated client based on the target push channel, the method further includes: Receive the message push result returned by the specified client, and update the status of the target message; If no push result indicating that the target message has reached the designated client is received within the set time period, the step of pushing the target message to the designated client based on the target push channel is re-executed.

10. The message push method according to claim 1, characterized in that: After receiving the target message sent by the business system in communication connection with the message push center and used for pushing to the designated client, the method further includes: A message identifier is set for the target message, and the message identifier is sent to the business system, so that the business system tracks the state of the target message according to the message identifier.

11. A message push device, characterized in that: It includes a memory, a processor, and a message push program stored in the memory and executable on the processor. When the processor executes the message push program, the steps of the message push method according to any one of claims 1 to 10 are implemented.

12. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a message push program, which, when executed, implements the steps of the message push method according to any one of claims 1 to 10.

Citation Information

Patent Citations

  • Message pushing method and device

    CN110460638A

  • Message pushing method and device, equipment and medium

    CN110855792A

  • Message pushing method, system and device and storage medium

    CN116112547A

Cited By

  • EMQX-based message pushing system, method, equipment and medium

    CN119966939A

  • EMQX-based message pushing system, method, device and medium

    CN119966939B