Message transmission method and apparatus, and electronic device and storage medium
By grouping target object information and generating messages, the problems of server resource waste and client memory overflow in point-to-point message transmission are solved, achieving more efficient message transmission.
Patent Information
- Application Number
- PCT/CN2025/099110
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-06-05
- Filing Date
- 2025-06-04
- Publication Date
- 2025-12-11
AI Technical Summary
Existing technologies suffer from server resource waste and client memory overflow issues in peer-to-peer message transmission, especially in live streaming services where the number of target objects is large. Traditional peer-to-peer message transmission methods lead to excessive server resource consumption and bandwidth waste.
By grouping target object information, generating corresponding target messages, and determining target candidate objects for message transmission based on group identifiers and candidate object information sets, the server processing load and client memory usage are reduced.
It effectively saves server resources, reduces bandwidth consumption, avoids client memory overflow, and improves message transmission efficiency.
Smart Images

Figure CN2025099110_11122025_PF_FP_ABST
Abstract
Description
Message transmission method and device, electronic device, and storage medium
[0001] This application claims priority to Chinese Patent Application No. 202410726423.5, filed on June 5, 2024, the disclosure of which is incorporated herein in its entirety as part of the present application. TECHNICAL FIELD
[0002] Embodiments of the present disclosure relate to a message transmission method and device, an electronic device, and a storage medium. BACKGROUND
[0003] Message distribution refers to the process of delivering messages from a sender to a receiver. The message transmission method currently used for message distribution is point-to-point message transmission. Point-to-point message transmission refers to the transmission of messages from a sender to a receiver in a communication system. If the number of receivers is large, a large number of resources need to be reserved at the sender, such as a server, to support the point-to-point message transmission function, which causes a certain waste of server resources. SUMMARY
[0004] The present disclosure provides a message transmission method, device, electronic device, and storage medium, which realizes message transmission while saving server resources.
[0005] In a first aspect, embodiments of the present disclosure provide a message transmission method, comprising:
[0006] grouping target object information sets to determine multiple groups of target object information and a group identifier of each group of target object information, wherein the target object information set includes multiple target object information;
[0007] generating a corresponding target message for each group of target object information, wherein the target object information indicates a target object corresponding to the target message;
[0008] for each target message, determining a target candidate object corresponding to the target message based on the group identifier corresponding to the target message and a candidate object information set, and transmitting the target message to the target candidate object, wherein the candidate object information set includes target object information included in the target object information set.
[0009] In a second aspect, embodiments of the present disclosure also provide a message transmission device, comprising:
[0010] an information set grouping module configured to group target object information sets to determine multiple groups of target object information and a group identifier of each group of target object information, wherein the target object information set includes multiple target object information;
[0011] a target message generation module, configured to generate a corresponding target message for each set of target object information, the target object information indicating a target object corresponding to the target message;
[0012] a target message transmission module, configured to, for each target message, determine a target candidate object corresponding to the target message based on the group identifier corresponding to the target message and the candidate object information set, and transmit the target message to the target candidate object, the candidate object information set including the target object information included in the target object information set.
[0013] In a third aspect, the present disclosure also provides an electronic device, which comprises:
[0014] one or more processing devices;
[0015] a storage device configured to store one or more programs,
[0016] When the one or more programs are executed by the one or more processing devices, the one or more processing devices implement a message transmission method provided by the present disclosure.
[0017] In a fourth aspect, the present disclosure also provides a storage medium of computer executable instructions, which, when executed by a computer processing device, are configured to perform a message transmission method provided by the present disclosure. BRIEF DESCRIPTION OF DRAWINGS
[0018] The above and other features, advantages, and aspects of the present disclosure will become more apparent with regard to the following detailed description, taken in conjunction with the accompanying drawings. Throughout the drawings, the same or similar reference numerals represent the same or similar elements. It should be understood that the drawings are schematic, and the sizes of the original and elements are not necessarily drawn according to the scale.
[0019] FIG. 1 is a flow diagram of a message transmission method provided by an embodiment of the present disclosure;
[0020] FIG. 2 is a flow diagram of a room message transmission provided by an embodiment of the present disclosure;
[0021] FIG. 3 is a flow diagram of a point-to-point message transmission provided by an embodiment of the present disclosure;
[0022] FIG. 4 is a flow diagram of a point-to-point message to room message transmission provided by an embodiment of the present disclosure;
[0023] FIG. 5 is a flow diagram of another message transmission method provided by an embodiment of the present disclosure;
[0024] FIG. 6 is a structural diagram of a message transmission device provided by an embodiment of the present disclosure; and
[0025] FIG. 7 is a structural schematic diagram of an electronic device provided by an embodiment of the present disclosure. DETAILED DESCRIPTION
[0026] Embodiments of the present disclosure will be described in more detail with reference to the drawings. Although some embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure can be implemented in various forms and should not be construed as being limited to the embodiments set forth herein, but rather the embodiments are provided so that the present disclosure can be more thoroughly and completely understood. It should be understood that the drawings and embodiments of the present disclosure are only for illustrative purposes and are not intended to limit the scope of protection of the present disclosure.
[0027] It should be understood that each of the steps recited in the method embodiments of the present disclosure can be performed in different orders and / or in parallel. In addition, the method embodiments can include additional steps and / or omit the steps shown. The scope of the present disclosure is not limited in this respect.
[0028] The term "comprising" and variations thereof as used herein are open-ended, that is, "comprising but not limited to." The term "based on" is "based, at least in part, on." The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments." Related terms are defined in the following description.
[0029] It should be noted that the concepts of "first", "second", etc. mentioned in the present disclosure are only used to distinguish different devices, modules or units, and are not intended to limit the order or interdependence of the functions performed by these devices, modules or units.
[0030] It should be noted that the modification of "one" or "multiple" mentioned in the present disclosure is illustrative rather than limiting, and those skilled in the art should understand that, unless otherwise explicitly indicated in the context, it should be understood as "one or more".
[0031] The names of the messages or information exchanged between the plurality of devices in the embodiments of the present disclosure are only for illustrative purposes, and are not intended to limit the scope of the messages or information.
[0032] It can be understood that, before using the technical solutions disclosed in the embodiments of the present disclosure, the type of personal information involved in the present disclosure, the scope of use, the use scenario, etc. should be informed to the user and the authorization of the user should be obtained through appropriate means in accordance with relevant laws and regulations.
[0033] For example, in response to receiving an active request of a user, prompt information is sent to the user to explicitly prompt the user that the operation requested to be performed will require obtaining and using personal information of the user. Thus, the user can autonomously select whether to provide personal information to the software or hardware, such as an electronic device, an application program, a server or a storage medium, performing the operation of the technical solution of the present disclosure according to the prompt information.
[0034] As an optional but non-limiting implementation, in response to receiving an active request of a user, the manner of sending prompt information to the user may, for example, be a pop-up window manner, in which the prompt information can be presented in a text manner. In addition, the pop-up window can also carry selection controls for the user to select "agree" or "disagree" to provide personal information to the electronic device.
[0035] It can be understood that the above notification and obtaining user authorization process is only illustrative and does not limit the implementation of the present disclosure, and other manners meeting relevant laws and regulations can also be applied to the implementation of the present disclosure.
[0036] It can be understood that the data involved in the technical solution (including but not limited to the data itself, the obtaining or use of the data) should comply with the requirements of relevant laws and regulations and relevant provisions.
[0037] The message system is a necessary component in a communication service. Taking a live broadcast service as an example, a live broadcast message system is responsible for delivering interactive messages generated in a live broadcast room, notification messages generated by the system, and the like to a client in real time. Delivery of live broadcast room messages includes room messages and point-to-point messages. The room messages are suitable for a room broadcast scenario, and the point-to-point messages are suitable for an on-demand scenario.
[0038] The room message (Room Message) is a message sent to all objects in a live broadcast room. The object can be understood as a user or a device used by the user. When the message is delivered, only the room identifier needs to be specified, and all objects in the live broadcast room will receive the message. The point-to-point message (Person Message) is a message sent to a specific device in a live broadcast room. The receiver is one or a batch of specific objects, which are identified by corresponding identifiers. Each object needs to be delivered individually.
[0039] There is a special scenario in the service that needs to be delivered to a part of objects in a live broadcast room that meet a condition. In order to avoid errors in delivery of the server, the target message content delivered can include target object information. When the client receives the target message, it will first verify whether the currently logged-in object is the target object. If so, the target message or the content corresponding to the target message is displayed.
[0040] In essence, the target message only needs to be received by a small number of objects in the live room (the number of objects < 1000), and therefore, the target message only needs to be sent to the target objects point-to-point. However, the number of target objects is large, and in this case, if the point-to-point message transmission mode is still used, the sending end needs to make 10w times of interface calls for sending point-to-point messages within 1 second, and needs to consume 2-3 times of server resources; in addition, if the frequency of sending target messages is low, the server reserves a large amount of resources for this scenario, and there is a problem of waste of resources.
[0041] If the message body size is not considered, the transmission mode of the room message is used, the target object information of all target objects in the live room is put into a target message (room message) for sending, each target object information is an 8-byte integer, and only the target object information is considered, the message size is 8 byte*10w = 100 KB, which brings two problems: first, this mode sends the message to all objects in the live room, and if the target object is only 10% of the total number of objects in the live room, 90% of the bandwidth is wasted; second, the client processes the room message with a large message body at a time, and there is a risk of memory overflow (Out Of Memory, OOM) caused by excessive memory consumption.
[0042] FIG. 1 is a flowchart of a message transmission method provided by an embodiment of the present disclosure. The embodiment of the present disclosure is applicable to a scenario of forming a target message and corresponding transmission. The method can be executed by a message transmission device. The device can be implemented in the form of software and / or hardware. The message transmission device can be integrated on an electronic device. The electronic device can be a mobile terminal, a PC terminal, or a server (server end), etc.
[0043] The present disclosure can be applicable to a scenario of message forwarding. Taking message forwarding in a live broadcast service scenario as an example, in the live broadcast service scenario, point-to-point messages and room messages are usually used to realize message transmission from a server to a client. The server includes a business end and a message system. A virtual room can be a virtual room corresponding to a live room in a client application program. The business end can provide services related to a business, such as various functions and application programs provided to meet specific business needs. The message system is a necessary component in a communication service. Taking a live broadcast service as an example, the message system is responsible for sending interactive messages generated in a live room, notification messages generated by a system, and the like to a client in real time.
[0044] FIG. 2 is a flowchart of room message transmission provided by an embodiment of the present disclosure. As shown in FIG. 2, the business end forms a room message and sends a notification of the room message to the message system. The message system sends the room message to a virtual room. At this time, all objects in the virtual room will receive the message.
[0045] FIG. 3 is a flow diagram of a point-to-point message transmission according to an embodiment of the present disclosure. As shown in FIG. 3, a service end forms a point-to-point message and sends a notification of the point-to-point message to a message system. The message system sends the point-to-point message to object a and object b. Other objects in a virtual room cannot receive the message.
[0046] Different from the room message and the point-to-point message, the present embodiment provides a transmission method of converting a point-to-point message into a room message. FIG. 4 is a flow diagram of a point-to-point message transmission according to an embodiment of the present disclosure. As shown in FIG. 4, target object information is grouped, and target messages are generated based on the grouped target object information to realize message grouping. For each target message, corresponding object matching is performed, and the target message is transmitted to the corresponding matched object. For example, a first target message is sent to object 1, object 11, object 21, and other objects corresponding to the target message. It can be understood that object 1, object 11, object 21, and the like are examples of objects.
[0047] As shown in FIG. 1, the method includes:
[0048] S110, grouping target object information sets to determine multiple groups of target object information and a group identifier of each group of target object information. The target object information set includes multiple target object information.
[0049] The target object information set can be understood as a set formed by the target object information. The target object information can be understood as the identification information of the target object. The target object can be understood as a user or a device used by the user. The target object is a part of an object set that meets a condition. The group identifier can be understood as identification information for identifying each group of target object information. The object set can be a set of all objects in a live room, such as a candidate object information set.
[0050] It can be understood that a target object information set corresponds to a content (such as a live room) in a service business. For example, the target object information set is a set formed by the target object information in a live room.
[0051] When the application scenario of the present embodiment is a live broadcast service scenario, the target object is an object that meets a set condition (such as a follow condition) in all objects in a live room. The target object information is the ID of the target object in the live room. The target object information set can be a set of target object information corresponding to the target object in the live room in the live broadcast service. The present embodiment can simultaneously execute corresponding message transmission methods based on multiple target object information sets respectively corresponding to multiple live rooms. The present embodiment describes the target object information set corresponding to one live room.
[0052] Specifically, the target object information set includes a plurality of identifications of corresponding target objects, the target object information set is grouped based on a preset grouping manner, a plurality of groups of target object information corresponding to the number of the grouping manner are determined, and a group identification of each group of target object information corresponding to the grouping manner is determined, so as to transmit a message to the target object.
[0053] For example, the preset grouping manner can be a hash algorithm, or other algorithms or manners, and the embodiments of the present disclosure do not limit this. When the grouping manner is a hash algorithm, the number of groups is taken as an example of 10, the hash value of the target object information set is subjected to a modulo operation of 10, 10 modulo results are obtained, each modulo result corresponds to a group of target object information, and the numerical result corresponding to the modulo result is taken as the group identification.
[0054] S120, generating a corresponding target message for each group of target object information.
[0055] The target message can be understood as a message to be transmitted to the target object corresponding to the group of target object information. The target message can include the target object information corresponding to the group, and the target message can be directed to a virtual room corresponding to the entire group of target object information. The target object information can be understood as identification information of the target object, indicating the target object corresponding to the target message.
[0056] Here, the method of generating the target message is not limited, as long as a corresponding target message can be generated for each group of target object information, for example, a group of target object information and a notification message to be transmitted are encapsulated into a target message for a group of target object information, or a message tag is formed based on a group of target object information, and a corresponding target message is generated based on the message tag and the notification message to be transmitted. Finally, a target message corresponding to the number of groups is generated, for example, ten target messages are generated based on ten groups of target object information. Each target message includes all target object information in the corresponding group.
[0057] S130, for each target message, determining a target candidate object corresponding to the target message based on the group identification corresponding to the target message and the candidate object information set, and transmitting the target message to the target candidate object, the candidate object information set including the target object information included in the target object information set.
[0058] The candidate object information set can be understood as a set formed by candidate object information. The candidate object information can be understood as identification information of a candidate object. The candidate object can be understood as a user or a device used by the user, and is all objects in a certain object set, such as all objects in a live broadcast room. The candidate object includes a target object, and accordingly, the candidate object information set includes target object information included in the target object information set. The target candidate object can be understood as a candidate object determined from each candidate object and satisfying a corresponding transmission condition. The transmission condition may, for example, be that a group identifier corresponding to the target message is consistent with an identifier corresponding to the candidate object information.
[0059] When the application scenario of the embodiment of the present disclosure is a live broadcast service scenario, the candidate object is all objects in a live broadcast room, and the candidate object information is identification information of each object in the live broadcast room.
[0060] Specifically, the candidate object information set is divided based on the same grouping manner as the target object information set. For each target message, a group identifier corresponding to the target message is compared with an identifier corresponding to each candidate object information after division. When the identifiers are consistent, the candidate object corresponding to the candidate object information is determined as a target candidate object, and the target message is transmitted to the target candidate object.
[0061] The technical solution of the embodiment of the present disclosure includes the following steps: grouping a target object information set to determine a plurality of groups of target object information and a group identifier of each group of target object information, the target object information set including a plurality of target object information; generating a corresponding target message for each group of target object information, the target object information indicating a target object corresponding to the target message; for each target message, determining a target candidate object corresponding to the target message based on a group identifier corresponding to the target message and a candidate object information set, and transmitting the target message to the target candidate object, the candidate object information set including target object information included in the target object information set. The above technical solution solves the problem of server resource waste. The grouping of target object information and the generation of a corresponding target message are performed. The target message corresponds to a group of target object information, rather than a single target object information. A processor does not need to be added to process a large number of delivery tasks, thereby saving server resources. The target message is transmitted to a matched candidate object, thereby reducing bandwidth overhead and saving client memory resources.
[0062] On the basis of the above embodiment, a variant embodiment of the above embodiment is proposed. It should be noted that, in order to make the description brief, only the differences from the above embodiment are described in the variant embodiment.
[0063] FIG. 5 is a flowchart of another message transmission method provided by an embodiment of the present disclosure. As shown in FIG. 5, the method includes the following steps.
[0064] S210, for each target object information in the target object information set, performing modulo operation on the hash value corresponding to the target object information to obtain a first processing result.
[0065] The first processing result can be understood as a numerical value obtained by performing modulo operation on the hash value corresponding to the target object.
[0066] Specifically, for each target object information in the target object information set, the hash value corresponding to the target object information is processed by modulo operation hash(ID) % m = X to obtain the corresponding first processing result X, where m is a self-defined grouping number, for example, m = 10. It can be understood that the available value of X corresponds to the grouping number, for example, when m = 10, X ∈ [0, 9].
[0067] After performing modulo operation on the hash value corresponding to each target object information, a first processing result corresponding to the number of target object information is obtained.
[0068] S220, the target object information corresponding to the same first processing result in the target object information set is divided into the same group.
[0069] Specifically, the target object information corresponding to the same first processing result in the target object information set is divided into the same group, and m groups of target object information are obtained by division.
[0070] For example, the target object information set includes 100 target object information, and the numerical value of the first processing result corresponding to 5 target object information is 1. The 5 target object information is divided into the same group, and m groups of target object information can be obtained.
[0071] S230, for each group of target object information, the corresponding first processing result is taken as the group identifier of the group of target object information.
[0072] The group of target object information represents a set formed by the target object information with the same first processing result.
[0073] Specifically, for each group of target object information, the corresponding first processing result is taken as the group identifier of the group of target object information, and the group identifier corresponding to each group of target object information is obtained, such as m group identifiers.
[0074] According to the above example, the numerical value of the first processing result is 1, and 1 is taken as the group identifier of the group formed by the 5 target object information.
[0075] S240, for each group of target object information, a target message is generated based on the room identifier of the virtual room corresponding to the group of target object information.
[0076] In the embodiment, the virtual room can be understood as a virtual object collection space, such as a live broadcast room, and the room identifier is a room number, which is unique. The target message is directed to the virtual room corresponding to the target object information.
[0077] Specifically, each live broadcast virtual room has a corresponding room identifier, and the transmission of the target message can be based on the room identifier. Therefore, for each group of target object information, the group of target object information and the notification message to be transmitted are encapsulated into a target message based on the room identifier of the virtual room corresponding to the group of target object information; or a message tag is formed based on the group of target object information and the room identifier of the virtual room corresponding to the group of target object information, and a corresponding target message is generated based on the message tag and the notification message to be transmitted. The target message generated based on the above steps can directly point to the corresponding virtual room in the subsequent transmission process.
[0078] S250, through the message system corresponding to the live broadcast service in the service end, obtaining the target message determined by the business end in the service end and the group identifier corresponding to each target message, for each target message, determining the target candidate object corresponding to the target message based on the group identifier corresponding to the target message and the candidate object information set, and transmitting the target message to the target candidate object.
[0079] The service end can be the main body for performing grouping, message generation, candidate object determination, and message transmission in the embodiments of the present disclosure, including the business end and the message system. The business end is used to perform grouping and message generation corresponding to steps S210-S240, and the message system is used to perform candidate object determination and message transmission corresponding to step S250.
[0080] Specifically, the business end in the service end performs steps S210-S240 to obtain a plurality of target messages and the group identifier corresponding to each target message. There can be one or more message systems in the service end, and each message system can correspond to different service businesses, or one message system can provide different service businesses. Through the message system corresponding to the live broadcast service in the service end, the target message transmitted by the business end in the service end and the group identifier corresponding to each target message are obtained. The message system divides the candidate object information set based on the same grouping manner as the target object information set, and for each target message, the group identifier corresponding to the target message is compared with the identifier corresponding to each candidate object information after division. When the identifiers are consistent, the candidate object corresponding to the candidate object information is determined as the target candidate object, and the target message is transmitted to the target candidate object.
[0081] In the operation, the business end can transmit the target message, the group identifier, and the grouping manner to the message system.
[0082] The technical scheme of the embodiments of the present disclosure is that, for each target object information in the target object information set, a modulo operation is performed on the hash value corresponding to the target object information to obtain a first processing result; target object information corresponding to the same first processing result in the target object information set is divided into the same group; for each group of target object information, the corresponding first processing result is taken as the group identifier of the group of target object information; for each group of target object information, a target message is generated based on the room identifier of the virtual room corresponding to the group of target object information; through the message system corresponding to the live streaming service in the server, the target message determined by the service end and the group identifier corresponding to each target message are obtained, for each target message, the target candidate object corresponding to the target message is determined based on the group identifier corresponding to the target message and the candidate object information set, and the target message is transmitted to the target candidate object. The above technical scheme groups the target object information based on the modulo operation through the service end, ensuring the safety and reliability of the grouping, generates the target message based on the room identifier corresponding to the group of target object information, ensuring the accuracy of the target message transmission path, and converts a large amount of target object information into a small amount of target message in the service end, without the need to increase an additional processor to process a large number of delivery tasks, saving server resources; the message system transmits the target message based on the group identifier, ensuring the accuracy of the matching between the target message and the target object in the candidate object, improving the efficiency of message transmission, reducing the bandwidth cost of message transmission, and saving the memory resources of the client.
[0083] In one embodiment, for each target message, the target candidate object corresponding to the target message is determined based on the group identifier corresponding to the target message and the candidate object information set, including:
[0084] a1) determining the candidate identifier corresponding to each candidate object information in the candidate object information set.
[0085] The candidate identifier can be an identifier identifying the group to which the candidate object information belongs, for example, the candidate identifier can be a value obtained by performing a modulo operation on the candidate object information, which is used for matching with the group identifier.
[0086] Specifically, the candidate object information set includes a large amount of candidate object information, the hash value of each candidate object information is subjected to a modulo operation to obtain a corresponding value, and the value is determined as the candidate identifier X'.
[0087] b1) for each target message, selecting a candidate identifier matching the group identifier corresponding to the target message from the candidate identifiers, and taking the candidate object corresponding to the selected candidate identifier as the target candidate object corresponding to the target message, the candidate object corresponding to the selected candidate identifier being the candidate object indicated by the candidate object information corresponding to the selected candidate identifier.
[0088] Specifically, each target information corresponds to a group identifier, for each target information, the group identifier corresponding to the target information is compared with all candidate identifiers, and the candidate object indicated by the candidate object information corresponding to the candidate identifier consistent with the group identifier (X' = X) is determined as the target candidate object corresponding to the target information.
[0089] In one embodiment, determining the candidate identifier corresponding to each candidate object information in the candidate object information set comprises:
[0090] Processing each candidate object information in the candidate object information set according to the processing manner adopted when grouping the target object information set, obtaining a second processing result, and taking the second processing result as the candidate identifier corresponding to the candidate object information.
[0091] The second processing result can be understood as a processing result obtained by processing the candidate object information in the same grouping manner as the target object information, such as a numerical value obtained by taking modulo of the hash value corresponding to the candidate object information.
[0092] For example, for each candidate object information in the candidate object information set, the hash value corresponding to the candidate object information is taken modulo by hash(ID) % m = X', to obtain the corresponding second processing result X', where m is a self-defined grouping number, for example, 10. It can be understood that the m value adopted when processing the candidate object information is the same as the m value adopted when processing the target object information.
[0093] FIG. 6 is a schematic diagram of a message transmission device structure provided by an embodiment of the present disclosure, as shown in FIG. 6, the device comprises an information set grouping module 310, a target message generation module 320, and a target message transmission module 330.
[0094] The information set grouping module 310 is configured to group the target object information set, determine multiple groups of target object information and the group identifier of each group of target object information, and the target object information set comprises multiple target object information.
[0095] The target message generation module 320 is configured to generate a corresponding target message for each group of target object information, and the target object information indicates the target object corresponding to the target message.
[0096] The target message transmission module 330 is configured to determine the target candidate object corresponding to each target message based on the group identifier corresponding to the target message and the candidate object information set, and transmit the target message to the target candidate object, and the candidate object information set comprises the target object information included in the target object information set.
[0097] The technical solution provided by the embodiments of the present disclosure solves the problem of server resource waste, groups target object information and generates corresponding target messages, the target messages correspond to a group of target object information rather than one target object information, without increasing the processor to process a large number of delivery tasks, thereby saving server resources; the target messages are transmitted to matched candidate objects, reducing bandwidth overhead and saving client memory resources.
[0098] In one embodiment, the information set grouping module 310 is specifically configured to:
[0099] For each target object information in the target object information set, the hash value corresponding to the target object information is subjected to modulo processing to obtain a first processing result;
[0100] The target object information corresponding to the same first processing result in the target object information set is divided into the same group;
[0101] For each group of target object information, the corresponding first processing result is taken as the group identifier of the group of target object information.
[0102] In one embodiment, the target message generation module 320 is specifically configured to:
[0103] For each group of target object information, a target message is generated based on the room identifier of the virtual room corresponding to the group of target object information.
[0104] In one embodiment, the target message transmission module 330 includes:
[0105] The target message transmission submodule acquires, through a message system corresponding to a live streaming service in a server, the target message determined by a business end in the server and the group identifier corresponding to each target message, determines, for each target message, the target candidate object corresponding to the target message based on the group identifier corresponding to the target message and the candidate object information set, and transmits the target message to the target candidate object.
[0106] In one embodiment, the target message transmission module 330 or the target message transmission submodule includes:
[0107] The candidate identifier determination unit is configured to determine the candidate identifier corresponding to each candidate object information in the candidate object information set;
[0108] The candidate object determination unit is configured to, for each target message, select a candidate identifier matching the group identifier corresponding to the target message from the candidate identifiers, and take the candidate object corresponding to the selected candidate identifier as the target candidate object corresponding to the target message, the candidate object corresponding to the selected candidate identifier being indicated by the candidate object information corresponding to the selected candidate identifier.
[0109] In an embodiment, the candidate identifier determination unit is specifically configured to:
[0110] The candidate object information set is processed according to the processing manner adopted when grouping the target object information set, to obtain a second processing result, and the second processing result is taken as the candidate identifier corresponding to the candidate object information.
[0111] In an embodiment, the target message includes the target object information of the corresponding group.
[0112] The message transmission apparatus provided by the embodiments of the present disclosure can perform the message transmission method provided by any of the embodiments of the present disclosure, and has the corresponding function modules and beneficial effects of performing the method.
[0113] It is worth noting that each unit and module included in the above apparatus is only divided according to the function logic, but is not limited to the above division, as long as the corresponding function can be realized; in addition, the specific name of each functional unit is only for convenient mutual distinction, and is not used to limit the protection scope of the embodiments of the present disclosure.
[0114] FIG. 7 is a structural schematic diagram of an electronic device provided by an embodiment of the present disclosure. Referring to FIG. 7, a structural schematic diagram of an electronic device (for example, a terminal device or a server in FIG. 7) 400 suitable for implementing the embodiments of the present disclosure is shown.
[0115] The electronic device 400 includes one or more processing apparatuses 401;
[0116] The storage apparatus 408 is configured to store one or more programs,
[0117] When the one or more programs are executed by the one or more processing apparatuses 401, the one or more processing apparatuses 401 implement the message transmission method of the embodiments of the present disclosure.
[0118] The terminal device in the embodiments of the present disclosure can include, but is not limited to, a mobile terminal such as a mobile phone, a notebook computer, a digital broadcast receiver, a PDA (Personal Digital Assistant), a PAD (Tablet Personal Computer), a PMP (Portable Multimedia Player), a vehicle terminal (for example, a car navigation terminal), and the like, and a stationary terminal such as a digital TV, a desktop computer, and the like. The electronic device 400 shown in FIG. 7 is merely an example, and should not impose any limitation on the functions and the range of use of the embodiments of the present disclosure.
[0119] As shown in FIG. 7, the electronic device 400 can include a processing device (for example, a central processing unit, a graphic processing unit, or the like) 401, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 402 or a program loaded into a random access memory (RAM) 403 from a storage device 408. In the RAM 403, various programs and data required for the operation of the electronic device 400 are also stored. The processing device 401, the ROM 402, and the RAM 403 are connected to each other through a bus 404. An input / output (I / O) interface 405 is also connected to the bus 404.
[0120] Generally, the following devices can be connected to the I / O interface 405: an input device 406 including, for example, a touch screen, a touch pad, a keyboard, a mouse, a camera, a microphone, an accelerometer, a gyroscope, and the like; an output device 407 including, for example, a liquid crystal display (LCD), a speaker, a vibrator, and the like; a storage device 408 including, for example, a magnetic tape, a hard disk, and the like; and a communication device 409. The communication device 409 can allow the electronic device 400 to communicate with other devices wirelessly or by wire to exchange data. Although FIG. 7 shows the electronic device 400 having various devices, it should be understood that all of the shown devices are not required to be implemented or provided. More or less devices can be alternatively implemented or provided.
[0121] In particular, according to the embodiments of the present disclosure, the processes described above with reference to the flowcharts can be implemented as a computer software program. For example, the embodiments of the present disclosure include a computer program product including a computer program carried on a non-transitory computer readable medium, the computer program containing program codes for executing the methods shown in the flowcharts. In such embodiments, the computer program can be downloaded and installed from a network through the communication device 409, or installed from the storage device 408, or installed from the ROM 402. When the computer program is executed by the processing device 401, the above-described functions defined in the methods of the embodiments of the present disclosure are performed.
[0122] The names of messages or information exchanged between the plurality of devices in the embodiments of the present disclosure are used only for illustrative purposes, and are not intended to limit the scope of the messages or information.
[0123] The electronic device provided by the embodiments of the present disclosure and the message transmission method provided by the above embodiments belong to the same inventive concept, and the technical details not described in detail in the present embodiment can be referred to the above embodiments, and the present embodiment has the same beneficial effects as the above embodiments.
[0124] The present disclosure provides a computer storage medium, which stores a computer program, and the program is executed by a processing device to implement the message transmission method provided by the above embodiments.
[0125] It should be noted that the computer readable medium of the present disclosure can be a computer readable signal medium or a computer readable storage medium or any combination of the above two.
[0126] The computer storage medium can be a storage medium of computer executable instructions, and the computer executable instructions are used to execute the method provided by the present disclosure when executed by a computer processing device.
[0127] The computer readable storage medium may, for example, be, but is not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or apparatus, or any combination of the above. More specific examples of the computer readable storage medium can 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), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present disclosure, the computer readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, device or apparatus. In the present disclosure, the computer readable signal medium can include a data signal carried in a baseband or as a part of a carrier wave, which carries computer readable program code. Such a propagated data signal can take many forms, including but not limited to an electromagnetic signal, an optical signal or any suitable combination of the above. The computer readable signal medium can also be any computer readable medium other than the computer readable storage medium, which can send, propagate or transmit a program for use by or in conjunction with an instruction execution system, device or apparatus. The program code contained in the computer readable medium can be transmitted by any suitable medium, including but not limited to a wire, a cable, a RF (radio frequency) or the like, or any suitable combination of the above.
[0128] In some embodiments, the client, server, or other computing machines utilized by the system can communicate over any known or later developed network protocol, such as the Hypertext Transfer Protocol (HTTP), and can be interconnected with any form or medium of digital data communication (for example, a communication network). Examples of communication networks include a local area network ("LAN"), a wide area network ("WAN"), the Internet, and peer-to-peer networks (for example, ad hoc peer-to-peer networks), as well as any then-current or later developed networks.
[0129] The computer-readable medium described above can be included in the electronic device described above; alternatively, the computer-readable medium can exist as a standalone entity.
[0130] The computer-readable medium described above carries one or more programs, which, when executed by the electronic device, cause the electronic device to: group target object information sets, determine a plurality of groups of target object information and a group identifier of each group of target object information, the target object information sets including a plurality of target object information;
[0131] generate, for each group of target object information, a corresponding target message, the target object information indicating a target object corresponding to the target message;
[0132] For each target message, determine a target candidate object corresponding to the target message based on the group identifier corresponding to the target message and a candidate object information set, the candidate object information set including target object information included in the target object information sets, and transmit the target message to the target candidate object.
[0133] Computer program code for carrying out operations of the present disclosure can be written in any of one or more programming languages, including object or visual object oriented programming languages, such as Java, Smalltalk, C++, or conventional procedural programming languages, such as the "C" programming language or similar programming languages. The program code can 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 latter scenario, the remote computer can be connected to the user's computer through any type of network, including a local area network ("LAN") or a wide area network ("WAN"), or the connection can be made to an external computer (for example, through the Internet using an Internet Service Provider).
[0134] The computer program product of the first aspect can include one or more non-transitory computer-readable media storing instructions for telecommunications, computing, or processing that, when executed by one or more processors, configure the one or more processors to perform the steps of the method of the first aspect.
[0135] The modules or units related in the embodiments of the disclosure can be implemented by software, or by hardware. In some cases, the name of the module or unit does not constitute a limitation on the module or unit itself.
[0136] The functions described in this document can be performed at least in part by one or more hardware logic components. For example, and without limitation, example types of hardware logic components that can be used include Field-programmable Gate Arrays (FPGAs), Program-specific Integrated Circuits (ASICs), Application-specific Standard Products (ASSPs), System-on-a-chip systems (SOCs), Complex Programmable Logic Devices (CPLDs), etc.
[0137] In the context of the present disclosure, a machine-readable medium can be a tangible medium that contains or stores a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium can be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium can include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium will include one or more lines of electrical connections, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or Flash memory), optical fibers, portable compact disc read-only memories (CD-ROMs), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.
[0138] According to one or more embodiments of the present disclosure, example 1 provides a message transmission method, comprising:
[0139] grouping target object information sets, determining multiple groups of target object information and a group identifier of each group of target object information, the target object information set including multiple target object information;
[0140] generating a corresponding target message for each group of target object information, the target object information indicating a target object corresponding to the target message;
[0141] for each target message, determining a target candidate object corresponding to the target message based on the group identifier corresponding to the target message and a candidate object information set, and transmitting the target message to the target candidate object, the candidate object information set including target object information included in the target object information set.
[0142] According to one or more embodiments of the present disclosure, example 2, the method according to example 1,
[0143] grouping target object information sets, determining multiple groups of target object information and a group identifier of each group of target object information, includes:
[0144] for each target object information in the target object information set, performing modulo processing on the hash value corresponding to the target object information to obtain a first processing result;
[0145] target object information corresponding to the same first processing result in the target object information set is divided into the same group;
[0146] for each group of target object information, the corresponding first processing result is taken as the group identifier of the group of target object information.
[0147] According to one or more embodiments of the present disclosure, example 3, the method according to example 1,
[0148] generating a corresponding target message for each group of target object information, includes:
[0149] for each group of target object information, generating a target message based on the room identifier of the virtual room corresponding to the group of target object information.
[0150] According to one or more embodiments of the present disclosure, example 4, the method according to example 1,
[0151] for each target message, determining a target candidate object corresponding to the target message based on the group identifier corresponding to the target message and a candidate object information set, and transmitting the target message to the target candidate object, includes:
[0152] The target message and the group identifier corresponding to each target message determined by the service end are acquired through a message system corresponding to the live service in the service end, for each target message, the target candidate object corresponding to the target message is determined based on the group identifier corresponding to the target message and the candidate object information set, and the target message is transmitted to the target candidate object.
[0153] According to one or more embodiments of the present disclosure, example 5 provides a method according to example 1 or example 4,
[0154] For each target message, the target candidate object corresponding to the target message is determined based on the group identifier corresponding to the target message and the candidate object information set, including:
[0155] Determining the candidate identifier corresponding to each candidate object information in the candidate object information set;
[0156] For each target message, the candidate identifier matching the group identifier corresponding to the target message is selected from the candidate identifiers, and the candidate object corresponding to the selected candidate identifier is taken as the target candidate object corresponding to the target message, and the candidate object corresponding to the selected candidate identifier is the candidate object indicated by the candidate object information corresponding to the selected candidate identifier.
[0157] According to one or more embodiments of the present disclosure, example 6 provides a method according to example 5,
[0158] Determining the candidate identifier corresponding to each candidate object information in the candidate object information set, including:
[0159] Each candidate object information in the candidate object information set is processed according to the processing mode adopted when the target object information set is grouped to obtain a second processing result, and the second processing result is taken as the candidate identifier corresponding to the candidate object information.
[0160] According to one or more embodiments of the present disclosure, example 7 provides a method according to example 1, and the target message includes the target object information of the corresponding group.
[0161] According to one or more embodiments of the present disclosure, example 8 provides a message transmission device, including:
[0162] The information set grouping module is used for grouping the target object information set, determining a plurality of groups of target object information and a group identifier of each group of target object information, and the target object information set includes a plurality of target object information;
[0163] The target message generation module is used for generating a corresponding target message for each group of target object information, and the target object information indicates the target object corresponding to the target message.
[0164] a target message transmission module, configured to, for each target message, determine a target candidate object corresponding to the target message based on the group identifier corresponding to the target message and the candidate object information set, and transmit the target message to the target candidate object, the candidate object information set including target object information included in the target object information set.
[0165] According to one or more embodiments of the present disclosure, example 9 provides an electronic device, comprising:
[0166] one or more processing devices;
[0167] a storage device storing one or more programs;
[0168] when the one or more programs are executed by the one or more processing devices, the one or more processing devices implement the method according to any one of examples 1-7.
[0169] According to one or more embodiments of the present disclosure, example 10 provides a computer readable medium having stored thereon a computer program, which, when executed by a processing device, implement the method according to any one of examples 1-7.
[0170] The above description merely illustrates the preferred embodiments of the present disclosure and the principles of the applied technologies. It should be understood by those skilled in the art that the disclosed scope of the present disclosure is not limited to the technical solutions formed by the specific combinations of the above technical features, and should also cover other technical solutions formed by the combinations of the above technical features or their equivalent features without departing from the above disclosed concept. For example, the technical solutions formed by the mutual replacement of the above features and the technical features disclosed in the present disclosure (but not limited to) having similar functions.
[0171] Further, while operations are depicted in a particular, chronological sequence, this should not be understood as requiring such order unless otherwise specified. In some cases, the activities of multiple embodiments can be performed in parallel. Similarly, while the above discussion has included several specific examples, these should not be construed as limiting the scope of the disclosure. Certain features that are described in the context of separate embodiments can also be implemented in combination in a single embodiment. Conversely, various features that are described in the context of a single embodiment can also be implemented in multiple embodiments separately or in any suitable sub-combination.
[0172] Although the subject matter has been described in language specific to structural features and / or methodological acts, it is to be understood that the subject matter defined in the appended claims is not necessarily limited to the specific features or acts described above. Rather, the specific features and acts described above are disclosed as example forms of implementing the claims.
Claims
1. A message transmission method, comprising: grouping target object information sets to determine multiple groups of target object information and group identifiers of each group of target object information, wherein the target object information sets comprise multiple target object information; generating a corresponding target message for each group of target object information, wherein the target object information indicates a target object corresponding to the target message; for each target message, determining a target candidate object corresponding to the target message based on the group identifier corresponding to the target message and a candidate object information set, and transmitting the target message to the target candidate object, wherein the candidate object information set comprises target object information included in the target object information sets.
2. The method of claim 1, wherein, The grouping of target object information sets to determine multiple groups of target object information and group identifiers of each group of target object information comprises: for each target object information in the target object information sets, performing modulo processing on a hash value corresponding to the target object information to obtain a first processing result; dividing target object information corresponding to the same first processing result in the target object information sets into the same group; for each group of target object information, taking the corresponding first processing result as the group identifier of the group of target object information.
3. The method of claim 1 or 2, wherein, The generating of a corresponding target message for each group of target object information comprises: for each group of target object information, generating a target message based on a room identifier of a virtual room corresponding to the group of target object information.
4. The method of claim 1, wherein, The determining of a target candidate object corresponding to each target message based on the group identifier corresponding to the target message and a candidate object information set, and the transmitting of the target message to the target candidate object, comprises: acquiring, through a message system corresponding to a live streaming service in a server, the target messages determined by a service end in the server and the group identifiers corresponding to the target messages, and for each target message, determining a target candidate object corresponding to the target message based on the group identifier corresponding to the target message and a candidate object information set, and transmitting the target message to the target candidate object.
5. The method of claim 1 or 4, wherein, The determining of a target candidate object corresponding to each target message based on the group identifier corresponding to the target message and a candidate object information set comprises: determining a candidate identifier corresponding to each candidate object information in the candidate object information set; for each target message, selecting a candidate identifier matching the group identifier corresponding to the target message from the candidate identifiers, and taking a candidate object corresponding to the selected candidate identifier as a target candidate object corresponding to the target message, wherein the candidate object corresponding to the selected candidate identifier is a candidate object indicated by a candidate object information corresponding to the selected candidate identifier.
6. The method of claim 5, wherein, The determining of a candidate identifier corresponding to each candidate object information in the candidate object information set comprises: processing each candidate object information in the candidate object information set according to a processing manner adopted when the target object information sets are grouped to obtain a second processing result, and taking the second processing result as the candidate identifier corresponding to the candidate object information.
7. The method according to any one of claims 1 to 6, wherein, The target message comprises target object information corresponding to the group.
8. An apparatus for message transmission, comprising: an information set grouping module configured to group target object information sets, determine a plurality of groups of target object information and a group identifier for each group of target object information, the target object information sets comprising a plurality of target object information; a target message generation module configured to generate a corresponding target message for each group of target object information, the target object information indicating a target object corresponding to the target message; a target message transmission module configured to, for each target message, determine a target candidate object corresponding to the target message based on the group identifier corresponding to the target message and a candidate object information set comprising the target object information included in the target object information sets, and transmit the target message to the target candidate object.
9. An electronic device, comprising: one or more processing devices; a storage device configured to store one or more programs, wherein the one or more programs, when executed by the one or more processing devices, cause the one or more processing devices to implement a message transmission method according to any one of claims 1-7.
10. A storage medium containing computer-executable instructions, wherein, the computer executable instructions, when executed by a computer processing device, are for performing a message transmission method according to any one of claims 1-7.
Citation Information
Patent Citations
Message processing method, message processing device and processing server
CN105991408A
Message sending method and device, electronic equipment and storage medium
CN113992460A
Message distribution method, readable medium and electronic equipment
CN115022110A
Integration of Live Streaming Content with Television Programming
US20190208272A1