[go: up one dir, main page]

CN120751004A - Message push method, device, equipment and storage medium - Google Patents

Message push method, device, equipment and storage medium

Info

Publication number
CN120751004A
CN120751004A CN202510904229.6A CN202510904229A CN120751004A CN 120751004 A CN120751004 A CN 120751004A CN 202510904229 A CN202510904229 A CN 202510904229A CN 120751004 A CN120751004 A CN 120751004A
Authority
CN
China
Prior art keywords
pushing
message
pushed
target
binding
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202510904229.6A
Other languages
Chinese (zh)
Inventor
苏宇
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Merchants Bank Co Ltd
Original Assignee
China Merchants Bank Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Merchants Bank Co Ltd filed Critical China Merchants Bank Co Ltd
Priority to CN202510904229.6A priority Critical patent/CN120751004A/en
Publication of CN120751004A publication Critical patent/CN120751004A/en
Pending legal-status Critical Current

Links

Landscapes

  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The application discloses a message pushing method, a device, equipment and a storage medium, and relates to the technical field of message pushing, wherein the method comprises the steps of binding tenant identification information, user identification information, grouping label information and a connection channel of a connected client in each tenant to generate connection binding information of each tenant; the method comprises the steps of receiving a message to be pushed, analyzing the message to be pushed, determining a pushing range and a pushing strategy of the message to be pushed, wherein the pushing strategy is any one of a unicast pushing strategy, a multicast pushing strategy, a tenant broadcasting pushing strategy and a global broadcasting strategy, determining a target connection channel in connection binding information based on the pushing range and the pushing strategy of the message to be pushed, and pushing the message to be pushed to a target client based on the target connection channel. By the mode, multiple pushing granularities of a single user, a grouping user, a tenant-level user, a global user and the like are supported, all business scenes are covered, and accurate pushing under different scenes is realized.

Description

Message pushing method, device, equipment and storage medium
Technical Field
The present application relates to the field of message pushing technologies, and in particular, to a message pushing method, device, equipment and storage medium.
Background
The message pushing technology of the current SaaS (Software operation service) system mainly relies on two modes, unicast pushing and broadcast pushing, wherein the unicast pushing is to push a message to a single user equipment based on WebSocket (protocol for full duplex communication over a single TCP connection) or HTTP (Hypertext Transfer Protocol ) long poll, and the broadcast pushing is to send the same message to all subscribing clients. Because only single-user or full-user broadcasting is supported, logical grouping in tenants or cross-tenant isolated multicasting cannot be carried out, the pushing granularity is single, because the broadcasting mode is easy to cause redundant flow, the unicast mode cannot meet the requirement of mass-sending, so that the resource efficiency is low, the tenant exclusive grouping strategy is lacking, the tenant isolation capability is not available, and the tenant-level pushing range control cannot be realized.
The foregoing is provided merely for the purpose of facilitating understanding of the technical solutions of the present invention and is not intended to represent an admission that the foregoing is prior art.
Disclosure of Invention
The application mainly aims to provide a message pushing method, device, equipment and storage medium, and aims to solve the technical problems that in the prior art, only a unicast pushing mode and a broadcast pushing mode are used for message pushing, the pushing granularity is single, and accurate pushing under all service scenes is difficult to realize.
In order to achieve the above object, the present application provides a message pushing method, which includes:
Binding tenant identification information, user identification information, grouping label information and a connection channel of the connected clients in each tenant to generate connection binding information of each tenant;
Receiving a message to be pushed, analyzing the message to be pushed, and determining a pushing range and a pushing strategy of the message to be pushed, wherein the pushing strategy is any one of a unicast pushing strategy, a multicast pushing strategy, a tenant broadcasting pushing strategy and a global broadcasting strategy;
Determining a target connection channel in the connection binding information based on the pushing range and the pushing strategy of the message to be pushed;
and pushing the message to be pushed to the target client based on the target connection channel.
In an embodiment, the connection binding information at least includes a binding relationship between packet tag information and user identification information and a binding relationship between user identification information and a connection channel, and the step of receiving a message to be pushed, analyzing the message to be pushed, and determining a pushing policy of the message to be pushed includes:
when a received message to be pushed carries target user identification information, determining that the pushing range of the message to be pushed is a single user, and determining that the pushing strategy of the message to be pushed is a unicast pushing strategy;
when a received message to be pushed carries target tenant identification information and target grouping label information, determining that a pushing range of the message to be pushed is a grouping user in a tenant, and determining that a pushing strategy of the message to be pushed is a multicast pushing strategy;
when the received message to be pushed carries the identification information of the target tenant and does not carry the label information of the target packet, determining that the pushing range of the message to be pushed is a full user in the tenant, and determining that the pushing strategy of the message to be pushed is a tenant broadcasting pushing strategy;
When the received message to be pushed carries global identification information, determining that the pushing range of the message to be pushed is a global user, and determining that the pushing strategy of the message to be pushed is a global broadcast pushing strategy.
In an embodiment, the step of determining the target connection channel in the connection binding information based on the push scope and the push policy of the message to be pushed includes:
When the pushing strategy of the message to be pushed is a multicast pushing strategy, determining target connection binding information based on the target tenant identification information;
determining binding user identification information corresponding to the target grouping label information based on the binding relation between the grouping label information and the user identification information in the target connection binding information;
de-duplicating the binding user identification information corresponding to the target grouping label information to obtain de-reuse user identification information;
determining a binding connection channel corresponding to the de-reuse user identification information based on a binding relationship between the user identification information and the connection channel in the target connection binding information;
And selecting the target connection channel from the binding connection channels corresponding to the de-reuse user identification information, wherein one de-reuse user identification information corresponds to one target connection channel.
In an embodiment, the step of determining the target connection channel in the connection binding information based on the push scope and the push policy of the message to be pushed includes:
When the pushing strategy of the message to be pushed is a tenant broadcasting pushing strategy, determining target connection binding information based on the target tenant identification information;
Determining a binding connection channel corresponding to the target tenant identification information based on the binding relation between the user identification information and the connection channel in the target connection binding information;
And screening an effective channel from the binding connection channels to serve as the target connection channel.
In an embodiment, the step of determining the target connection channel in the connection binding information based on the push scope and the push policy of the message to be pushed includes:
When the pushing strategy of the message to be pushed is a unicast pushing strategy, searching the binding relation between the grouping label information and the user identification information in the connection binding information based on the target user identification information, and determining a binding connection channel corresponding to the target user identification information;
When the target user identification information is provided with a plurality of binding connection channels, randomly selecting one binding connection channel as the target connection channel;
And when the target user identification information has a single binding connection channel, the binding connection channel is used as the target connection channel.
In an embodiment, the step of binding the tenant identification information, the user identification information, the packet label information and the connection channel of the connected client in each tenant, and generating connection binding information of each tenant further includes:
determining a subscription grouping label of a connected client based on grouping request information of the connected client, wherein the subscription grouping label at least comprises a department grouping label and a role grouping label;
Determining an associated grouping label of the connected client based on the role grouping label of the connected client;
Determining customized temporary rule information based on tenant identification information of the connected client, and determining a temporary grouping label which is met by the connected client based on the customized temporary rule information;
And generating packet label information of the connected client based on the subscription packet label, the association packet label and the temporary packet label.
In an embodiment, the step of pushing the message to be pushed to the target client based on the target connection channel further includes:
acquiring the latest activity time of a connection channel of the connected client;
Determining the activity interval duration of the connection channel of the connected client based on the latest activity time of the connection channel of the connected client;
When the activity interval time length of the connection channel of the connected client is greater than a preset time length threshold, determining that the connection channel of the connected client is an idle channel;
and releasing the idle channel and updating the connection binding information.
In addition, in order to achieve the above object, the present application also provides a message pushing device, including:
The tenant management module is used for binding tenant identification information, user identification information, grouping label information and connection channels of the connected clients in each tenant to generate connection binding information of each tenant;
The message pushing module is used for receiving a message to be pushed, analyzing the message to be pushed, and determining a pushing range and a pushing strategy of the message to be pushed, wherein the pushing strategy is any one of a unicast pushing strategy, a multicast pushing strategy, a tenant broadcasting pushing strategy and a global broadcasting strategy;
The message pushing module is further configured to determine a target connection channel in the connection binding information based on a pushing range and a pushing policy of the message to be pushed;
The message pushing module is further configured to push the message to be pushed to the target client based on the target connection channel.
In addition, in order to achieve the above object, the application also proposes a message pushing device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, the computer program being configured to implement the steps of the message pushing method as described above.
In addition, in order to achieve the above object, the present invention also proposes a storage medium, which is a computer-readable storage medium, on which a computer program is stored, which when being executed by a processor implements the steps of the message pushing method as described above.
Furthermore, to achieve the above object, the present application provides a computer program product comprising a computer program which, when executed by a processor, implements the steps of the message pushing method as described above.
The application provides a message pushing method, which comprises the steps of binding tenant identification information, user identification information, grouping label information and a connection channel of a connected client in each tenant to generate connection binding information of each tenant, receiving a message to be pushed, analyzing the message to be pushed, determining a pushing range and a pushing strategy of the message to be pushed, wherein the pushing strategy is any one of a unicast pushing strategy, a multicast pushing strategy, a tenant broadcasting pushing strategy and a global broadcasting strategy, determining a target connection channel in the connection binding information based on the pushing range and the pushing strategy of the message to be pushed, and pushing the message to be pushed to a target client based on the target connection channel. The application groups the users in all tenants, binds the relation between the users and the connection, the relation between the groups and the users, and can find the corresponding physical connection through the grouping, and push the message to the appointed client, thereby realizing the multicast pushing on the basis of the unicast pushing and the broadcast pushing, further covering all business scenes through a plurality of pushing granularities of single users, grouped users, tenant-level users, global users and the like, realizing the accurate pushing in different scenes, and solving the technical problems that the message pushing is carried out only by using the unicast pushing and the broadcast pushing modes, the pushing granularity is single, and the accurate pushing in all business scenes is difficult to realize.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the application and together with the description, serve to explain the principles of the application.
In order to more clearly illustrate the embodiments of the application or the technical solutions of the prior art, the drawings which are used in the description of the embodiments or the prior art will be briefly described, and it will be obvious to a person skilled in the art that other drawings can be obtained from these drawings without inventive effort.
FIG. 1 is a flow chart of a message pushing method according to a first embodiment of the present application;
fig. 2 is a schematic diagram of an overall architecture of a message pushing method according to a first embodiment of the present application;
fig. 3 is a schematic flow chart of a second embodiment of a message pushing method according to the present application;
Fig. 4 is a schematic diagram of a multicast push flow of a message push method according to a second embodiment of the present application;
fig. 5 is a schematic flow chart of a third embodiment of a message pushing method according to the present application;
Fig. 6 is a schematic block diagram of a message pushing device according to an embodiment of the present application;
Fig. 7 is a schematic device structure diagram of a hardware operating environment related to a message pushing method in an embodiment of the present application.
The achievement of the objects, functional features and advantages of the present application will be further described with reference to the accompanying drawings, in conjunction with the embodiments.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the technical solution of the present application and are not intended to limit the present application.
For a better understanding of the technical solution of the present application, the following detailed description will be given with reference to the drawings and the specific embodiments.
The method comprises the steps of binding tenant identification information, user identification information, grouping label information and connection channels of connected clients in all tenants to generate connection binding information of all tenants, receiving information to be pushed, analyzing the information to be pushed, determining a pushing range and a pushing strategy of the information to be pushed, wherein the pushing strategy is any one of a unicast pushing strategy, a multicast pushing strategy, a tenant broadcasting pushing strategy and a global broadcasting strategy, determining a target connection channel in the connection binding information based on the pushing range and the pushing strategy of the information to be pushed, and pushing the information to be pushed to the target clients based on the target connection channel.
At present, the SaaS system only uses a unicast pushing mode and a broadcast pushing mode to push messages, the pushing granularity is single, for a tenant-level pushing range or a smaller pushing range, the broadcast mode has more redundant messages, the unicast mode cannot meet the group sending requirement, long polling is required continuously, accurate pushing cannot be achieved, and the resource utilization rate is lower.
The application provides a solution, users in all tenants are grouped, the relation between the users and the connection, the relation between the grouping and the users are bound, the corresponding physical connection can be found through grouping, and the message is pushed to a designated client, so that multicast pushing is realized on the basis of unicast pushing and broadcast pushing, and further, all business scenes can be covered through various pushing granularities of single users, grouping users, tenant-level users, global users and the like, and the accurate pushing under different scenes is realized, and the technical problems that the message pushing is carried out only by using a unicast pushing and broadcast pushing mode, the pushing granularity is single, and the accurate pushing under all business scenes is difficult to realize are solved.
It should be noted that, the execution body of the embodiment may be a computing service device having functions of data processing, network communication and program running, for example, a tablet computer, a personal computer, a mobile phone, or an electronic device, a message pushing device, or the like capable of implementing the above functions, which is not limited in this embodiment. The present embodiment and the following embodiments will be described below by taking a message pushing device of a server (SaaS system) as an example.
An embodiment of the present application provides a message pushing method, referring to fig. 1, fig. 1 is a schematic flow chart of a first embodiment of the message pushing method of the present application.
In this embodiment, the message pushing method includes steps S10 to S40:
Step S10, binding tenant identification information, user identification information, grouping label information and a connection channel of connected clients in each tenant to generate connection binding information of each tenant;
Note that, the tenant is usually an enterprise/platform that rents/uses SaaS to push messages, and in this embodiment, the number of tenants may be single or multiple (two or more), which is determined according to practical situations, and this is not limited specifically.
Additionally, it should be noted that a connected client, i.e., a client/browser that has successfully established a connection, typically corresponds to one user (the same user may be considered as different users using multiple clients/browsers). The connection needs to be established before the message is pushed, that is, the connected client can push the message.
In a feasible implementation mode, the step of establishing connection comprises the steps of receiving a connection request initiated by a client to be authenticated based on identity authentication information, carrying out security authentication on the connection request of the client to be authenticated, wherein the identity authentication information at least comprises tenant identification information, user identification information and grouping request information, establishing connection with the client to be authenticated when the connection request of the client to be authenticated passes the security authentication, and adding the client to be authenticated into a connected client.
It should be noted that, the client to be authenticated is a client/browser requesting connection, the client to be authenticated actively initiates a WebSocket/HTTP connection request, the connection request carries identity authentication information, and the identity authentication information is related information for security authentication, and at least includes tenant identification information, user identification information and packet request information. The tenant identification information, that is, the identification number of the tenant to which the client belongs, may be a tenant ID (Identity Document, identity card identification number), and the user identification information, that is, the identification number of the user corresponding to the client, may be a user ID, which is not specifically limited in this embodiment.
It will be appreciated that security authentication generally comprises two parts, identity authentication and token authentication. And (3) carrying out identity authentication by using the tenant ID and the user ID, if the identity authentication passes, returning a token to the client to be authenticated by the server, wherein the client to be authenticated initiates connection by using the token, and if the token passes verification, the security authentication is proved to pass, and at the moment, the server establishes connection with the client to be authenticated, and the client to be authenticated is added into the connected client.
It should be appreciated that multiple packets may be set for each tenant. The packet request information, that is, the packet requested to join by the client, may be a single packet or may be a plurality of packets, and is determined according to practical situations. Illustratively, the connection request is "(tenant 01, [ groupId01, groupId02 ])" which indicates that the user userId01 belongs to the tenant01, needs to join groupId01 and groupId02 packets, and the request connection is "(tenant 01, userId02, [ groupId01 ])" which indicates that the user userId02 belongs to the tenant01, needs to join groupId01 packets.
It can be understood that after the connection is successfully established, the server caches tenant identification information, user identification information, packet label information and connection channel of the connected client, and binds, when the server needs to push a message to the client, the server finds bound connection information (i.e. connection binding information) from the cache, and at this time, the message to be pushed can be pushed to the corresponding client according to the connection binding information. The packet label information, that is, the packet condition of the connected client, may be considered as all packet labels of the connected client, and other labels may be set in addition to the label of the packet request information.
Further, in a possible implementation manner, a subscription packet label of the connected client is determined based on packet request information of the connected client, the subscription packet label at least comprises a department packet label and a role packet label, an association packet label of the connected client is determined based on the role packet label of the connected client, customized temporary rule information is determined based on tenant identification information of the connected client, a temporary packet label which is met by the connected client is determined based on the customized temporary rule information, and packet label information of the connected client is generated based on the subscription packet label, the association packet label and the temporary packet label.
It should be noted that, the subscription packet tag is a tag of a packet subscribed to by the connected client, that is, a tag of a packet to which joining is requested in the packet request information. The subscription group is usually a predefined logical group, that is, a group forcedly configured by the server, and the subscription group tag at least includes a department group tag (dept) and a role group tag (role), where the department group tag is a tag representing a department to which the user belongs, for example, dept:dev (development part), dept:finance (accounting part), dept:supply_chain (supply chain part), and the role tag is a tag representing a role to which the user belongs, for example, role:admin (administrator), role: approver (approver), and role: warehouse _manager (warehouse administrator). The association packet tag is a tag associated with the subscription packet tag, and if a client joins the packet a, and a rule defines that the client needs to join the packet B, the client automatically joins the packet B, and the packet B is the association packet, and the tag of the packet B is the association packet tag.
It will be appreciated that the customized temporary rule information, i.e. the packet rules that the tenant is customized to maintain for a specified time, typically corresponds to different packets, and therefore, the corresponding temporary packet label, i.e. the packet label maintained for the specified time, is determined according to the rules that the connected client conforms to. Illustratively, temporary promotion packets are created during promotion and corresponding grouping rules are set, and clients conforming to the grouping rules are added to the promotion packets so that active messages can be pushed for the clients of the promotion packets during promotion. And generating packet label information of each connected client according to the subscription packet label, the associated packet label and the temporary packet label.
It should be understood that the connection channels, i.e. the physical channels used for establishing connection between the client and the server, each connection channel has a corresponding number, for example, socket001 and socket002, which are not limited in particular. The embodiment binds the user identification information and the grouping label information to obtain a binding relation between the grouping label information and the user identification information, binds the user identification information and the connection channel to obtain a binding relation between the user identification information and the connection channel, and thus obtains the connection binding information of each tenant. The connection binding information at least comprises a binding relation between the grouping label information and the user identification information, and a binding relation between the user identification information and the connection channel. Illustratively, tenant identification information of the connected client C is tenant01, user identification information userId01, packet tag information is groupId01 and groupId02, a connection channel is socket001, tenant identification information of the connected client D is tenant01, user identification information userId02, packet tag information is groupId01, and a connection channel is socket002, and connection binding information of the tenant01 is userId01-socket001, userId02-socket002, groupId01- [ userId01, userId02], groupId02- [ userId01].
Step S20, receiving a message to be pushed, analyzing the message to be pushed, and determining a pushing range and a pushing strategy of the message to be pushed, wherein the pushing strategy is any one of a unicast pushing strategy, a multicast pushing strategy, a tenant broadcasting pushing strategy and a global broadcasting strategy;
It should be noted that, the message to be pushed is a message that needs to be pushed, and in this embodiment, the message to be pushed may be any one of a unicast message, a multicast message, and a broadcast message. The push policy is a push usage manner, and in this embodiment, the push policy is any one of a unicast push policy, a multicast push policy, a tenant broadcast push policy, and a global broadcast policy. And the unicast pushing strategy is a unicast pushing mode, and pushes the message to be pushed to a single user. The multicast push policy, i.e. the multicast push manner, pushes the message to be pushed to all users in a single/multiple packet, which may be a packet in a single tenant or a packet in multiple tenants (a packet across tenants). And the tenant broadcasts a push strategy, namely a broadcast push mode in the tenant, and pushes the message to be pushed to all users in the single/multiple tenants. And the global broadcast pushing strategy is a global broadcast pushing mode, and pushes the message to be pushed to all connected users.
In a possible implementation manner, the step S20 may include determining that a push scope of a message to be pushed is a single user and determining that a push policy of the message to be pushed is a unicast push policy when the received message to be pushed carries target user identification information, determining that the push scope of the message to be pushed is a group of packet users and determining that the push policy of the message to be pushed is a multicast push policy when the received message to be pushed carries target tenant identification information and does not carry target packet label information, determining that the push scope of the message to be pushed is an intra-tenant whole user and determining that the push policy of the message to be pushed is a tenant broadcast push policy when the received message to be pushed carries global identification information, and determining that the push scope of the message to be pushed is a global user and determining that the push policy of the message to be pushed is a global broadcast push policy.
It should be noted that the target user identification information is the identification code of the target user, that is, the target user ID. The target tenant identification information is the identification code of the target tenant, namely the target tenant ID. The target packet label information is the label of the target packet. The global identification information, i.e. global identification/flag, can be set according to actual requirements, and is not particularly limited.
It can be understood that if the message to be pushed carries a single target user ID, it is indicated that the message to be pushed needs to be pushed to a single user, the push scope at this time is a single user, the push policy adopts a unicast push policy, if the message to be pushed carries a "target tenant id+a label of a target packet", it is indicated that the message to be pushed needs to be pushed to a user of the target packet in the target tenant, the push scope at this time is a packet user in the tenant, the push policy adopts a multicast push policy, if the message to be pushed only carries a single/multiple target tenant IDs, it is indicated that the message to be pushed needs to be pushed to all users in the target tenant, the push policy adopts a tenant broadcast push policy, and if the message to be pushed carries a global identifier, it is indicated that the message to be pushed to all connected users, the push scope at this time is a global user, and the push policy adopts a global broadcast push policy.
Step S30, determining a target connection channel in the connection binding information based on the pushing range and the pushing strategy of the message to be pushed;
it should be noted that, the target client is a client/browser that needs to push a message, and the target connection channel is a physical channel used by the server to push the message to the target client.
It can be understood that if the push policy is a multicast push policy, firstly, a label of a target packet is found, the connection binding information is utilized to find a corresponding user ID, then the connection binding information is utilized to find a corresponding connection channel, finally, merging and deduplication are performed on the found channels, each user only reserves one connection channel as the target connection channel, if different packets have the same user, the connection channels can be shared, resource occupation is reduced, and multiplexing rate of the connection channels is improved. And the separation of the tenant exclusive grouping strategy from the logic channel ensures that the message is only sent to the target tenant.
In a possible implementation manner, when the pushing policy of the message to be pushed is tenant broadcasting pushing policy, determining target connection binding information based on the target tenant identification information, determining a binding connection channel corresponding to the target tenant identification information based on a binding relationship between user identification information and a connection channel in the target connection binding information, and screening an effective channel from the binding connection channels as the target connection channel.
It should be understood that the deduplication connection channel is a bound connection channel that has been deduplicated. If the pushing strategy is a tenant broadcasting pushing strategy, target connection binding information is found according to the target tenant ID, all connection channels bound with the target tenant are found by using the target connection binding information, then duplication removal is carried out, and an effective connection channel is found from the binding connection channels after duplication removal to serve as a final target connection channel. And the separation of the tenant exclusive grouping strategy from the logic channel ensures that the message is only sent to the target tenant.
In a possible implementation manner, when the pushing policy of the message to be pushed is a unicast pushing policy, based on the target user identification information, searching a binding relationship between grouping tag information and user identification information in the connection binding information to determine a binding connection channel corresponding to the target user identification information, when the target user identification information has a plurality of binding connection channels, randomly selecting one binding connection channel as the target connection channel, and when the target user identification information has a single binding connection channel, taking the binding connection channel as the target connection channel.
It can be understood that if the push policy is a unicast push policy, searching is performed according to the target user ID to find a connection channel bound with the target user ID, that is, a binding connection channel, and a unique connection channel is selected from the binding connection channels as the target connection channel.
In a possible implementation manner, when the pushing policy of the message to be pushed is a global broadcast pushing policy, a global effective connection channel is obtained, and the global effective connection channel is used as the target connection channel.
It can be appreciated that the global active connection channel is the active channel of the connection channels of all tenants. If the push strategy is a global broadcast push strategy, all the effective channels are directly used as target connection channels.
Step S40, pushing the message to be pushed to the target client based on the target connection channel.
It should be noted that, the message to be pushed is pushed to the target client through the target connection channel.
In specific implementation, referring to fig. 2, the overall architecture of the server includes a client access layer, a bottom network layer, a message routing layer, a tenant management layer, and a service gateway. The client access layer is used for maintaining long connection of the client and supporting access of a Websocket protocol. The bottom network layer is the bottom network channel, and keeps the connection active through a heartbeat mechanism. The message routing layer can support the pushing of unicast messages, broadcast messages and multicast messages, and the messages are pushed to the corresponding connection channels through different pushing strategies. The tenant management layer is used for managing tenant grouping strategies (such as departments and roles), supporting dynamic updating grouping rules, registering groups when long connection is established, and cleaning grouping information after connection is disconnected. The business gateway is the entrance of business service push message, and performs authority check before pushing the message.
The embodiment provides a message pushing method, which comprises the steps of binding tenant identification information, user identification information, grouping label information and connection channels of connected clients in all tenants to generate connection binding information of all tenants, receiving messages to be pushed, analyzing the messages to be pushed, determining a pushing range and a pushing strategy of the messages to be pushed, wherein the pushing strategy is any one of a unicast pushing strategy, a multicast pushing strategy, a tenant broadcasting pushing strategy and a global broadcasting strategy, determining a target connection channel in the connection binding information based on the pushing range and the pushing strategy of the messages to be pushed, and pushing the messages to be pushed to a target client based on the target connection channel. According to the embodiment, users in all tenants are grouped, the relation between the users and the connection, the relation between the grouping and the users are bound, the corresponding physical connection can be found through grouping, and the message is pushed to the appointed client, so that multicast pushing is realized on the basis of unicast pushing and broadcast pushing, and further all service scenes can be covered through multiple pushing granularities of single users, grouped users, tenant-level users, global users and the like, and accurate pushing under different scenes is realized.
In the second embodiment of the present application, the same or similar content as in the first embodiment of the present application may be referred to the above description, and will not be repeated. On this basis, referring to fig. 3, step S30 may include steps S301 to S305:
step S301, when the push policy of the message to be pushed is a multicast push policy, determining target connection binding information based on the target tenant identification information;
It should be noted that, each tenant has corresponding connection binding information, and the connection binding information of the target tenant, that is, the target connection binding information, is found according to the target tenant ID.
Step S302, based on the binding relation between the grouping label information and the user identification information in the target connection binding information, the binding user identification information corresponding to the target grouping label information is determined;
it can be understood that each piece of packet label information has a bound user ID, and the user ID bound with the target packet label, i.e., the bound user identification information, is found according to the binding relationship between the packet label information and the user identification information in the target connection binding information.
Step S303, de-duplicating the binding user identification information corresponding to the target grouping label information to obtain de-duplicated user identification information;
It should be noted that, since one user may join in multiple packets, there may be duplication of the user in the target packet, that is, there may be duplication of the binding user identification information corresponding to the target packet label information, at this time, duplication needs to be removed, and the binding user identification information after duplication is the duplication removing user identification information, that is, the duplication removing user ID, so as to avoid the duplication occupying the channel resource.
Step S304, based on the binding relation between the user identification information and the connection channel in the target connection binding information, determining the binding connection channel corresponding to the de-user identification information;
It can be understood that each user ID has a binding connection channel, and a connection channel bound with the de-user ID, i.e., a binding connection channel, is found according to the binding relationship between the user identification information and the connection channel in the target connection binding information.
Step S305, selecting the target connection channel from the binding connection channels corresponding to the de-reuse user identification information, where one de-reuse user identification information corresponds to one target connection channel.
It can be understood that if a user ID binds a plurality of connection channels, all of the connection channels serve as target connection channels to push messages, which may result in resource waste, and therefore, one of the connection channels needs to be selected as a target connection channel, and an effective connection channel is generally selected. In this embodiment, according to a mode that one de-reuse user identifier corresponds to one target connection channel, the target connection channel is selected from all the binding connection channels.
It should be appreciated that assuming N users per packet, if each packet maintains a connection channel independently, N packets would require N x N connection channels. In this embodiment, when a multicast push mode is adopted, the connection channel and the packet are connected by maintaining the relationship between the packet and the user, and if different packets have the same user, the connection channel can be shared, so as to reduce the resource occupation, improve the multiplexing rate of the connection channel (improve by 30% -50%), and reduce the bandwidth consumption. Illustratively, it is assumed that user A belongs to both the "finance department" group and the "administrator" group, where only 1 connection channel is required to carry multiple grouped messages.
In particular implementation, referring to fig. 4, the overall flow includes three phases, a connection establishment phase, a message push phase, and a connection reclamation phase. In the connection establishment stage, the client initiates WebSocket connection with the tenant ID, the user ID and the subscription label, and the tenant management layer verifies the authority and binds the user to the corresponding multicast channel. In the message pushing stage, the business service calls a background service gateway API (Application Programming Interface ), a pushing range is designated, and the message routing layer matches a subscription list according to a grouping strategy and pushes the messages in batches through a physical channel. And in the connection recovery stage, when the client is disconnected, the subscription relation is automatically cleaned and the channel resources are released.
The embodiment provides a message pushing method, which comprises the steps of determining target connection binding information based on target tenant identification information when a pushing strategy of a message to be pushed is a multicast pushing strategy, determining binding user identification information corresponding to target grouping label information based on binding relation between grouping label information and user identification information in the target connection binding information, de-duplicating the binding user identification information corresponding to the target grouping label information to obtain de-reuse user identification information, determining binding connection channels corresponding to the de-reuse user identification information based on binding relation between the user identification information and the connection channels in the target connection binding information, and selecting the target connection channels in the binding connection channels corresponding to the de-reuse user identification information, wherein one de-reuse user identification information corresponds to one target connection channel. In the embodiment, users in all tenants are grouped, the relation between the users and the connection, the relation between the groups and the users are bound, the corresponding physical connection can be found through the grouping to push the message, the multicast pushing is realized on the basis of unicast pushing and broadcast pushing, in the process, if different groups have the same users, the connection channels can be shared, the resource occupation is reduced, and the multiplexing rate of the connection channels is improved.
In the third embodiment of the present application, the same or similar contents as those of the above embodiment can be referred to the above description, and the description thereof will not be repeated. On this basis, referring to fig. 5, step S40 may include steps S501 to S503:
Step S501, obtaining the latest activity time of the connection channel of the connected client, and determining the activity interval duration of the connection channel of the connected client based on the latest activity time of the connection channel of the connected client;
It should be noted that, the last activity time is the time when the connection channel last performs the activity, and according to the last activity time of the connection channel, the interval between the last activity time and the current time, that is, the activity interval duration, can be calculated.
Step S502, when the active interval time length of the connection channel of the connected client is longer than a preset time length threshold, determining that the connection channel of the connected client is an idle channel;
It can be understood that the preset duration threshold, that is, the preset threshold, for example, 30s, which is not specifically limited in this embodiment, can be flexibly adjusted according to actual requirements. If the time length of the active interval is smaller than or equal to the preset time length threshold value, the connection channel is in the idle state, and is used as the idle channel, and if the time length of the active interval is smaller than or equal to the preset time length threshold value, the connection channel is in the non-idle state.
Step S503, releasing the idle channel and updating the connection binding information.
It can be understood that the embodiment sets an idle channel timeout releasing mechanism, releases the active interval of the connection channel when the active interval is longer than a preset duration threshold, and synchronously adjusts the connection binding information.
Further, when the disconnected client exists in the connected clients, deleting the disconnected client from the connected clients, deleting the related information of the disconnected client in the connection binding information, and releasing channel resources.
The embodiment provides a message pushing method, which comprises the steps of obtaining the latest activity time of a connecting channel of a connected client, determining the activity interval duration of the connecting channel of the connected client based on the latest activity time of the connecting channel of the connected client, determining the connecting channel of the connected client as an idle channel when the activity interval duration of the connecting channel of the connected client is greater than a preset duration threshold, releasing the idle channel and updating connection binding information. According to the embodiment, through an idle channel timeout release mechanism, the occupation of resources is reduced, and the load of a server is reduced.
It should be noted that the foregoing examples are only for understanding the present application, and are not meant to limit the message pushing method of the present application, and more forms of simple transformation based on the technical concept are all within the scope of the present application.
The present application also provides a message pushing device, referring to fig. 6, the message pushing device includes:
the tenant management module 10 is configured to bind tenant identification information, user identification information, packet label information and connection channels of connected clients in each tenant, and generate connection binding information of each tenant;
The message pushing module 20 is configured to receive a message to be pushed, analyze the message to be pushed, and determine a pushing range and a pushing policy of the message to be pushed, where the pushing policy is any one of a unicast pushing policy, a multicast pushing policy, a tenant broadcasting pushing policy, and a global broadcasting policy;
The message pushing module 20 is further configured to determine a target connection channel in the connection binding information based on a pushing range and a pushing policy of the message to be pushed;
the message pushing module 20 is further configured to push the message to be pushed to the target client based on the target connection channel.
In a possible implementation manner, the message pushing module 20 is further configured to determine, when the received message to be pushed carries the target user identification information, that the pushing range of the message to be pushed is a single user, and determine that the pushing policy of the message to be pushed is a unicast pushing policy;
when a received message to be pushed carries target tenant identification information and target grouping label information, determining that a pushing range of the message to be pushed is a grouping user in a tenant, and determining that a pushing strategy of the message to be pushed is a multicast pushing strategy;
when the received message to be pushed carries the identification information of the target tenant and does not carry the label information of the target packet, determining that the pushing range of the message to be pushed is a full user in the tenant, and determining that the pushing strategy of the message to be pushed is a tenant broadcasting pushing strategy;
When the received message to be pushed carries global identification information, determining that the pushing range of the message to be pushed is a global user, and determining that the pushing strategy of the message to be pushed is a global broadcast pushing strategy.
In a possible implementation manner, the message pushing module 20 is further configured to determine, when the pushing policy of the message to be pushed is a multicast pushing policy, target connection binding information based on the target tenant identification information;
determining binding user identification information corresponding to the target grouping label information based on the binding relation between the grouping label information and the user identification information in the target connection binding information;
de-duplicating the binding user identification information corresponding to the target grouping label information to obtain de-reuse user identification information;
determining a binding connection channel corresponding to the de-reuse user identification information based on a binding relationship between the user identification information and the connection channel in the target connection binding information;
And selecting the target connection channel from the binding connection channels corresponding to the de-reuse user identification information, wherein one de-reuse user identification information corresponds to one target connection channel.
In a possible implementation manner, the message pushing module 20 is further configured to determine, when the pushing policy of the message to be pushed is a tenant broadcast pushing policy, target connection binding information based on the target tenant identification information;
Determining a binding connection channel corresponding to the target tenant identification information based on the binding relation between the user identification information and the connection channel in the target connection binding information;
And screening an effective channel from the binding connection channels to serve as the target connection channel.
In a possible implementation manner, the message pushing module 20 is further configured to, when the pushing policy of the message to be pushed is a unicast pushing policy, retrieve, based on the target user identification information, a binding relationship between packet label information and user identification information in the connection binding information, and determine a binding connection channel corresponding to the target user identification information;
When the target user identification information is provided with a plurality of binding connection channels, randomly selecting one binding connection channel as the target connection channel;
And when the target user identification information has a single binding connection channel, the binding connection channel is used as the target connection channel.
In a possible implementation manner, the tenant management module 10 is further configured to determine a subscription packet label of the connected client based on packet request information of the connected client, where the subscription packet label includes at least a department packet label and a role packet label;
Determining an associated grouping label of the connected client based on the role grouping label of the connected client;
Determining customized temporary rule information based on tenant identification information of the connected client, and determining a temporary grouping label which is met by the connected client based on the customized temporary rule information;
And generating packet label information of the connected client based on the subscription packet label, the association packet label and the temporary packet label.
In a possible implementation manner, the message pushing module 20 is further configured to obtain a latest activity time of a connection channel of the connected client;
Determining the activity interval duration of the connection channel of the connected client based on the latest activity time of the connection channel of the connected client;
When the activity interval time length of the connection channel of the connected client is greater than a preset time length threshold, determining that the connection channel of the connected client is an idle channel;
and releasing the idle channel and updating the connection binding information.
The message pushing device provided by the application can solve the technical problems that the message pushing is carried out only by using a unicast pushing and broadcasting pushing mode, the pushing granularity is single, and the accurate pushing under all service scenes is difficult to realize by adopting the message pushing method in the embodiment. Compared with the prior art, the beneficial effects of the message pushing device provided by the application are the same as those of the message pushing method provided by the embodiment, and other technical features in the message pushing device are the same as those disclosed by the method of the embodiment, and are not repeated herein.
The application provides a message pushing device which comprises at least one processor and a memory in communication connection with the at least one processor, wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute the message pushing method in the first embodiment.
Referring now to fig. 7, a schematic diagram of a message pushing device suitable for use in implementing embodiments of the present application is shown. The message pushing device in the embodiment of the present application may include, but is not limited to, mobile terminals such as mobile phones, notebook computers, digital broadcast receivers, PDAs (Personal DIGITAL ASSISTANT: personal digital assistants), PADs (Portable Application Description: tablet computers), PMPs (Portable MEDIA PLAYER: portable multimedia players), vehicle terminals (e.g., car navigation terminals), and the like, and fixed terminals such as digital TVs, desktop computers, and the like. The message pushing device shown in fig. 7 is only an example, and should not impose any limitation on the functionality and scope of use of the embodiments of the present application.
As shown in fig. 7, the message pushing apparatus may include a processing device 1001 (e.g., a central processor, a graphic processor, etc.) which may perform various appropriate actions and processes according to a program stored in a ROM (Read Only Memory) 1002 or a program loaded from a storage device 1003 into a RAM (Random Access Memory ) 1004. In the RAM1004, various programs and data required for the operation of the message pushing device are also stored. The processing device 1001, the ROM1002, and the RAM1004 are connected to each other by a bus 1005. An input/output (I/O) interface 1006 is also connected to the bus. In general, a system including an input device 1007 such as a touch screen, a touch pad, a keyboard, a mouse, an image sensor, a microphone, an accelerometer, a gyroscope, etc., an output device 1008 including a Liquid crystal display (LCD: liquid CRYSTAL DISPLAY), a speaker, a vibrator, etc., a storage device 1003 including a magnetic tape, a hard disk, etc., and a communication device 1009 may be connected to the I/O interface 1006. The communication means 1009 may allow the message pushing device to communicate wirelessly or by wire with other devices to exchange data. While a message pushing device having various systems is shown in the figures, it should be understood that not all of the illustrated systems are required to be implemented or provided. More or fewer systems may alternatively be implemented or provided.
In particular, according to embodiments of the present disclosure, the processes described above with reference to flowcharts may be implemented as computer software programs. For example, embodiments of the present disclosure include a computer program product comprising a computer program embodied on a computer readable medium, the computer program comprising program code for performing the method shown in the flow chart. In such an embodiment, the computer program may be downloaded and installed from a network through a communication device, or installed from the storage device 1003, or installed from the ROM 1002. The above-described functions defined in the method of the disclosed embodiment of the application are performed when the computer program is executed by the processing device 1001.
The message pushing equipment provided by the application can solve the technical problems that the message pushing is carried out only by using a unicast pushing and broadcast pushing mode, the pushing granularity is single, and the accurate pushing under all service scenes is difficult to realize by adopting the message pushing method in the embodiment. Compared with the prior art, the beneficial effects of the message pushing device provided by the application are the same as those of the message pushing method provided by the embodiment, and other technical features of the message pushing device are the same as those disclosed by the method of the previous embodiment, and are not repeated here.
It is to be understood that portions of the present disclosure may be implemented in hardware, software, firmware, or a combination thereof. In the description of the above embodiments, particular features, structures, materials, or characteristics may be combined in any suitable manner in any one or more embodiments or examples.
The foregoing is merely illustrative of the present application, and the present application is not limited thereto, and any person skilled in the art will readily appreciate variations or alternatives within the scope of the present application. Therefore, the protection scope of the application is subject to the protection scope of the claims.
The present application provides a computer readable storage medium having computer readable program instructions (i.e., a computer program) stored thereon for performing the message pushing method of the above-described embodiments.
The computer readable storage medium provided by the present application may be, for example, a U disk, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, or device, or a combination of any of the foregoing. More specific examples of a computer-readable storage medium may include, but are not limited to, an electrical connection having one or more wires, a portable computer diskette, a hard disk, a random access Memory (RAM: random Access Memory), a Read-Only Memory (ROM), an erasable programmable Read-Only Memory (EPROM: erasable Programmable Read Only Memory or flash Memory), an optical fiber, a portable compact disc Read-Only Memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing. In this embodiment, a computer-readable storage medium may be any tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, or device. Program code embodied on a computer readable storage medium may be transmitted using any appropriate medium, including but not limited to electrical wiring, fiber optic cable, RF (Radio Frequency) and the like, or any suitable combination of the foregoing.
The computer readable storage medium may be included in the message pushing device or may exist alone without being assembled into the message pushing device.
The computer readable storage medium carries one or more programs, when the one or more programs are executed by the message pushing device, the message pushing device is caused to bind tenant identification information, user identification information, grouping label information and connection channels of connected clients in each tenant to generate connection binding information of each tenant, receive a message to be pushed, analyze the message to be pushed, determine a pushing range and a pushing strategy of the message to be pushed, wherein the pushing strategy is any one of a unicast pushing strategy, a multicast pushing strategy, a tenant broadcasting pushing strategy and a global broadcasting strategy, determine a target connection channel in the connection binding information based on the pushing range and the pushing strategy of the message to be pushed, and push the message to be pushed to the target client based on the target connection channel.
Computer program code for carrying out operations of the present application may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, smalltalk, C ++ and conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the case of remote computers, the remote computer may be connected to the user's computer through any kind of network, including a local area network (LAN: local Area Network) or a wide area network (WAN: wide Area Network), or may be connected to an external computer (for example, through the Internet using an Internet service provider).
The flowcharts and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present application. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems which perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
The modules involved in the embodiments of the present application may be implemented in software or in hardware. Wherein the name of the module does not constitute a limitation of the unit itself in some cases.
The readable storage medium provided by the application is a computer readable storage medium, and the computer readable storage medium stores computer readable program instructions (namely computer programs) for executing the message pushing method, so that the technical problems that the message pushing is carried out only by using a unicast pushing mode and a broadcast pushing mode, the pushing granularity is single, and accurate pushing under all service scenes is difficult to realize can be solved. Compared with the prior art, the beneficial effects of the computer readable storage medium provided by the application are the same as those of the message pushing method provided by the above embodiment, and are not described herein.
The application also provides a computer program product comprising a computer program which, when executed by a processor, implements the steps of a message pushing method as described above.
The computer program product provided by the application can solve the technical problems that the message pushing is carried out only by using a unicast pushing and broadcast pushing mode, the pushing granularity is single, and the accurate pushing under all service scenes is difficult to realize. Compared with the prior art, the beneficial effects of the computer program product provided by the application are the same as those of the message pushing method provided by the above embodiment, and are not described herein.
The foregoing is only a part of embodiments of the present application, and is not intended to limit the scope of the present application, and all the equivalent structural changes made by the description and drawings of the present application or the direct/indirect application in other related technical fields are included in the scope of the present application.

Claims (10)

1. A message pushing method, characterized in that the method comprises:
Binding tenant identification information, user identification information, grouping label information and a connection channel of the connected clients in each tenant to generate connection binding information of each tenant;
Receiving a message to be pushed, analyzing the message to be pushed, and determining a pushing range and a pushing strategy of the message to be pushed, wherein the pushing strategy is any one of a unicast pushing strategy, a multicast pushing strategy, a tenant broadcasting pushing strategy and a global broadcasting strategy;
Determining a target connection channel in the connection binding information based on the pushing range and the pushing strategy of the message to be pushed;
and pushing the message to be pushed to the target client based on the target connection channel.
2. The method of claim 1, wherein the connection binding information includes at least a binding relationship between packet tag information and user identification information and a binding relationship between user identification information and a connection channel, the step of receiving a message to be pushed, analyzing the message to be pushed, and determining a push policy of the message to be pushed includes:
when a received message to be pushed carries target user identification information, determining that the pushing range of the message to be pushed is a single user, and determining that the pushing strategy of the message to be pushed is a unicast pushing strategy;
when a received message to be pushed carries target tenant identification information and target grouping label information, determining that a pushing range of the message to be pushed is a grouping user in a tenant, and determining that a pushing strategy of the message to be pushed is a multicast pushing strategy;
when the received message to be pushed carries the identification information of the target tenant and does not carry the label information of the target packet, determining that the pushing range of the message to be pushed is a full user in the tenant, and determining that the pushing strategy of the message to be pushed is a tenant broadcasting pushing strategy;
When the received message to be pushed carries global identification information, determining that the pushing range of the message to be pushed is a global user, and determining that the pushing strategy of the message to be pushed is a global broadcast pushing strategy.
3. The method of claim 2, wherein the step of determining a target connection channel in the connection binding information based on the push scope and push policy of the message to be pushed comprises:
When the pushing strategy of the message to be pushed is a multicast pushing strategy, determining target connection binding information based on the target tenant identification information;
determining binding user identification information corresponding to the target grouping label information based on the binding relation between the grouping label information and the user identification information in the target connection binding information;
de-duplicating the binding user identification information corresponding to the target grouping label information to obtain de-reuse user identification information;
determining a binding connection channel corresponding to the de-reuse user identification information based on a binding relationship between the user identification information and the connection channel in the target connection binding information;
And selecting the target connection channel from the binding connection channels corresponding to the de-reuse user identification information, wherein one de-reuse user identification information corresponds to one target connection channel.
4. The method of claim 2, wherein the step of determining a target connection channel in the connection binding information based on the push scope and push policy of the message to be pushed comprises:
When the pushing strategy of the message to be pushed is a tenant broadcasting pushing strategy, determining target connection binding information based on the target tenant identification information;
Determining a binding connection channel corresponding to the target tenant identification information based on the binding relation between the user identification information and the connection channel in the target connection binding information;
And screening an effective channel from the binding connection channels to serve as the target connection channel.
5. The method of claim 2, wherein the step of determining a target connection channel in the connection binding information based on the push scope and push policy of the message to be pushed comprises:
When the pushing strategy of the message to be pushed is a unicast pushing strategy, searching the binding relation between the grouping label information and the user identification information in the connection binding information based on the target user identification information, and determining a binding connection channel corresponding to the target user identification information;
When the target user identification information is provided with a plurality of binding connection channels, randomly selecting one binding connection channel as the target connection channel;
And when the target user identification information has a single binding connection channel, the binding connection channel is used as the target connection channel.
6. The method of claim 1, wherein the step of binding tenant identification information, user identification information, packet label information, and connection channels of the connected clients in each tenant, and generating connection binding information of each tenant further comprises, before:
determining a subscription grouping label of a connected client based on grouping request information of the connected client, wherein the subscription grouping label at least comprises a department grouping label and a role grouping label;
Determining an associated grouping label of the connected client based on the role grouping label of the connected client;
Determining customized temporary rule information based on tenant identification information of the connected client, and determining a temporary grouping label which is met by the connected client based on the customized temporary rule information;
And generating packet label information of the connected client based on the subscription packet label, the association packet label and the temporary packet label.
7. The method according to any one of claims 1 to 6, wherein the step of pushing the message to be pushed to the target client based on the target connection channel further comprises:
acquiring the latest activity time of a connection channel of the connected client;
Determining the activity interval duration of the connection channel of the connected client based on the latest activity time of the connection channel of the connected client;
When the activity interval time length of the connection channel of the connected client is greater than a preset time length threshold, determining that the connection channel of the connected client is an idle channel;
and releasing the idle channel and updating the connection binding information.
8. A message pushing device, the device comprising:
The tenant management module is used for binding tenant identification information, user identification information, grouping label information and connection channels of the connected clients in each tenant to generate connection binding information of each tenant;
The message pushing module is used for receiving a message to be pushed, analyzing the message to be pushed, and determining a pushing range and a pushing strategy of the message to be pushed, wherein the pushing strategy is any one of a unicast pushing strategy, a multicast pushing strategy, a tenant broadcasting pushing strategy and a global broadcasting strategy;
The message pushing module is further configured to determine a target connection channel in the connection binding information based on a pushing range and a pushing policy of the message to be pushed;
The message pushing module is further configured to push the message to be pushed to the target client based on the target connection channel.
9. A message pushing device, characterized in that the device comprises a memory, a processor and a computer program stored on the memory and executable on the processor, the computer program being configured to implement the steps of the message pushing method according to any of claims 1 to 7.
10. A storage medium, characterized in that the storage medium is a computer-readable storage medium, on which a computer program is stored, which computer program, when being executed by a processor, carries out the steps of the message pushing method according to any of claims 1 to 7.
CN202510904229.6A 2025-07-01 2025-07-01 Message push method, device, equipment and storage medium Pending CN120751004A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202510904229.6A CN120751004A (en) 2025-07-01 2025-07-01 Message push method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202510904229.6A CN120751004A (en) 2025-07-01 2025-07-01 Message push method, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN120751004A true CN120751004A (en) 2025-10-03

Family

ID=97184841

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202510904229.6A Pending CN120751004A (en) 2025-07-01 2025-07-01 Message push method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN120751004A (en)

Similar Documents

Publication Publication Date Title
CN109582310B (en) Data processing method and device, electronic equipment and computer readable storage medium
CN106357811B (en) Method, device and system for deleting backup data
JP7494311B2 (en) INTERACTION METHOD, DEVICE AND ELECTRONIC DEVICE
CN113521728A (en) Cloud application implementation method and device, electronic equipment and storage medium
JPWO2015049825A1 (en) Terminal authentication registration system, terminal authentication registration method and program
CN113553178A (en) Task processing method, device and electronic device
CN111314433A (en) Message transmission method and device and electronic equipment
US8521902B2 (en) Shared buffer for connectionless transfer protocols
CN109309583B (en) Information acquisition method and device based on distributed system, electronic equipment and medium
CN109981778B (en) Method, device, equipment and storage medium for realizing service of content distribution network
CN106528337B (en) Data backup method, device and system
CN110233791B (en) Data deduplication method and device
CN111290861B (en) Message processing method and device and electronic equipment
CN110708238B (en) Method and apparatus for processing information
CN120751004A (en) Message push method, device, equipment and storage medium
CN114020412B (en) A message processing method, device, equipment and storage medium
CN110855655A (en) Information verification method, device, equipment and storage medium
CN111444457B (en) Data release method and device, storage medium and electronic equipment
CN111970338A (en) Request processing method and device based on cloud function and computer readable medium
CN111367590A (en) Interrupt event processing method and device
JP7729997B2 (en) Multimedia sharing method, device, equipment and medium
CN116450370B (en) Method and device for inter-process communication
CN119449897B (en) Grayscale traffic verification method, device, equipment, storage medium and program product
CN113783830B (en) Method and apparatus for data communication
CN114338792B (en) Application message push method, electronic device and storage medium

Legal Events

Date Code Title Description
PB01 Publication