CN115174512A - Message pushing method and device, storage medium and electronic device - Google Patents

Message pushing method and device, storage medium and electronic device Download PDF

Info

Publication number
CN115174512A
CN115174512A CN202210589233.4A CN202210589233A CN115174512A CN 115174512 A CN115174512 A CN 115174512A CN 202210589233 A CN202210589233 A CN 202210589233A CN 115174512 A CN115174512 A CN 115174512A
Authority
CN
China
Prior art keywords
message
pushed
pushing
template
push
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
CN202210589233.4A
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.)
Qingdao Haier Technology Co Ltd
Qingdao Haier Intelligent Home Appliance Technology Co Ltd
Haier Smart Home Co Ltd
Original Assignee
Qingdao Haier Technology Co Ltd
Qingdao Haier Intelligent Home Appliance Technology Co Ltd
Haier Smart Home 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 Qingdao Haier Technology Co Ltd, Qingdao Haier Intelligent Home Appliance Technology Co Ltd, Haier Smart Home Co Ltd filed Critical Qingdao Haier Technology Co Ltd
Priority to CN202210589233.4A priority Critical patent/CN115174512A/en
Publication of CN115174512A publication Critical patent/CN115174512A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L12/00Data switching networks
    • H04L12/28Data switching networks characterised by path configuration, e.g. LAN [Local Area Networks] or WAN [Wide Area Networks]
    • H04L12/2803Home automation networks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L51/00User-to-user messaging in packet-switching networks, transmitted according to store-and-forward or real-time protocols, e.g. e-mail
    • H04L51/07User-to-user messaging in packet-switching networks, transmitted according to store-and-forward or real-time protocols, e.g. e-mail characterised by the inclusion of specific contents
    • H04L51/10Multimedia information

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Automation & Control Theory (AREA)
  • Multimedia (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

The application discloses a message pushing method and device, a storage medium and an electronic device, and relates to the technical field of smart families, wherein the message pushing method comprises the following steps: the method comprises the steps of obtaining a message pushing request sent by a message pushing party, wherein the message pushing request carries message content to be pushed and indication information used for determining equipment to be pushed; determining a device to be pushed according to the indication information in the message pushing request, and embedding the message content in the message pushing request into a message pushing template corresponding to the message pushing request according to the capability information of the device to be pushed to obtain a message to be pushed; and pushing the message to be pushed to the equipment to be pushed. By adopting the technical scheme, the problem that the pushing efficiency is low because a message pushing template needs to be correspondingly developed to push the message for each device is solved.

Description

Message pushing method and device, storage medium and electronic device
Technical Field
The application relates to the technical field of smart homes, in particular to a message pushing method and device, a storage medium and an electronic device.
Background
In order to improve the activity of products, drive the utilization rate of functional modules, increase the viscosity of users, wake up sleeping users and improve the retention rate, messages are often irregularly pushed to equipment. Traditional message pushing is often only to push mobile phone applications, and the notification of activities initiated to users or service processing progress, arrival notification, and the like. However, after the popularization of intelligent household appliances, more message types appear, such as a 'hot water completion' notification sent by a water heater received by a mobile phone, a periodic report of power consumption of the household appliances, a monthly report of the household appliances, and the like; gradually, the intelligent household appliances start to use sound boxes or screen devices as home hubs, and the functions are more and more abundant, so that the pushed messages are not limited to characters, even pictures, audios or videos and the like. At this time, simple text type messages cannot meet the requirements, the content of message pushing is rich, but the category division is gradually clear, so a special message template is introduced as a standard pushing protocol for message pushing.
However, currently, based on template pushing, different message pushing templates need to be developed and defined for different devices, and then the corresponding message pushing template is used for message pushing for the devices, so that each device pushes a message, one template needs to be developed, and the working efficiency is low. Therefore, the traditional and simple pushing and the complex customized template pushing are difficult to improve the working efficiency, and have requirements on technical mastery degree and business familiarity degree.
Aiming at the problem that in the related art, each time a device pushes a message, a message pushing template needs to be correspondingly developed to push the message, so that the pushing efficiency is low, an effective solution is not provided at present.
Accordingly, there is a need for improvement in the related art to overcome the disadvantages of the related art.
Disclosure of Invention
The embodiment of the invention provides a message pushing method and device, a storage medium and an electronic device, and aims to at least solve the problem that the pushing efficiency is low because a message pushing template needs to be correspondingly developed to push a message every time a device pushes the message.
According to an aspect of the embodiments of the present invention, a message pushing method is provided, including: the method comprises the steps of obtaining a message pushing request sent by a message pushing party, wherein the message pushing request carries message content to be pushed and indication information used for determining equipment to be pushed; determining a device to be pushed according to the indication information in the message pushing request, and embedding the message content in the message pushing request into a message pushing template corresponding to the message pushing request according to the capability information of the device to be pushed to obtain a message to be pushed; and pushing the message to be pushed to the equipment to be pushed.
In an exemplary embodiment, before embedding the message content in the message push request into a message push template corresponding to the message push request according to the capability information of the device to be pushed, the method further includes: calling a template management service, and determining whether a message pushing template exists in the template management service, wherein the message pushing template supports filling of the message content, and the device to be pushed corresponding to the indication information allows the message pushing template to be used for pushing messages; and under the condition that the message pushing template exists in the template management service, acquiring the message pushing template from the template management service.
In an exemplary embodiment, embedding the message content in the message push request into a message push template corresponding to the message push request according to the capability information of the device to be pushed includes: determining target message content from the message content according to the capability information of the equipment to be pushed; embedding the target message content into the message pushing template, and determining whether the device to be pushed supports the display of the target message content in a target display mode according to the capability information of the device to be pushed; and under the condition that the equipment to be pushed supports the target message content displayed by using the target display mode, setting the display mode of the target message content in the message pushing template as the target display mode.
In an exemplary embodiment, before embedding the message content in the message push request into a message push template corresponding to the message push request according to the capability information of the device to be pushed, the method further includes: determining device type and capability information of each device in a plurality of devices under the condition that the device to be pushed comprises the plurality of devices; and grouping the plurality of devices according to the device types and the capability information to obtain a plurality of groups, wherein the devices in each group in the plurality of groups have the same device types and the same capability information.
In an exemplary embodiment, embedding the message content in the message pushing request into a message pushing template corresponding to the message pushing request according to the capability information of the device to be pushed, to obtain a message to be pushed, includes: when the situation that the equipment to be pushed comprises a plurality of pieces of equipment and the plurality of pieces of equipment are divided into a plurality of groups is determined, determining a target embedding mode corresponding to each group according to the equipment type and the capability information corresponding to each group in the plurality of groups; and embedding the message content into the message pushing template according to the target embedding mode corresponding to each group to obtain the message to be pushed corresponding to the equipment in each group.
In an exemplary embodiment, pushing the message to be pushed to the device to be pushed includes: creating a push task, wherein the push task comprises: the method comprises the steps that a device identifier of a device to be pushed, a message to be pushed corresponding to the device to be pushed, and a message channel for pushing the message to be pushed are obtained; and sending the push task to a target message queue so that a message push service subscribes the push task from the target message queue, and sending the message to be pushed to the device to be pushed through the message channel.
In an exemplary embodiment, the message content includes at least one of: text, picture, audio, video; the indication information includes at least one of: identification of the target object, equipment identification, equipment type and equipment attribute information; the capability information includes at least one of: whether the display of characters is supported, whether the display of pictures is supported, whether the playing of audio is executed, whether the playing of video is supported, and whether a target display mode is supported.
According to another aspect of the embodiments of the present invention, there is also provided a message pushing apparatus, including: the device comprises an acquisition module, a sending module and a sending module, wherein the acquisition module is used for acquiring a message pushing request sent by a message pushing party, and the message pushing request carries message content to be pushed and indication information used for determining equipment to be pushed; the processing module is used for determining equipment to be pushed according to the indication information in the message pushing request, and embedding the message content in the message pushing request into a message pushing template corresponding to the message pushing request according to the capacity information of the equipment to be pushed to obtain a message to be pushed; and the pushing module is used for pushing the message to be pushed to the equipment to be pushed.
According to another aspect of the embodiments of the present invention, there is also provided a computer-readable storage medium, in which a computer program is stored, where the computer program is configured to execute the above message pushing method when running.
According to another aspect of the embodiments of the present invention, there is also provided an electronic apparatus, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the message pushing method through the computer program.
According to the method and the device, the message content to be pushed is embedded into the message pushing template according to the capability information of the device to be pushed, so that the message to be pushed is obtained, and the message to be pushed is pushed to the device to be pushed. Because a universal message pushing template is used, and when message pushing is carried out, message contents to be pushed are embedded into the message pushing template for pushing according to the capability information of equipment to be pushed, the message pushing template does not need to be correspondingly developed for each equipment, the pushing efficiency is improved, the development cost is saved, and the problem that the pushing efficiency is lower because each equipment pushes messages and one message pushing template needs to be correspondingly developed for message pushing is solved.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and together with the description, serve to explain the principles of the application.
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly described below, and it is obvious for those skilled in the art to obtain other drawings without inventive exercise.
Fig. 1 is a schematic hardware environment diagram of a message pushing method according to an embodiment of the present application;
FIG. 2 is a flow chart of a message pushing method according to an embodiment of the invention;
FIG. 3 is a schematic diagram of a message push method according to an embodiment of the invention;
fig. 4 is a timing diagram of a message pushing method according to an embodiment of the present invention;
fig. 5 is a block diagram of a message push apparatus according to an embodiment of the present invention.
Detailed Description
In order to make the technical solutions better understood by those skilled in the art, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only partial embodiments of the present application, but not all embodiments. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments in the present application without making any creative effort shall fall within the protection scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and claims of this application and in the drawings described above are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used is interchangeable under appropriate circumstances such that the embodiments of the application described herein are capable of operation in sequences other than those illustrated or described herein. Moreover, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
According to one aspect of the embodiment of the application, a message pushing method is provided. The message pushing method is widely applied to full-House intelligent digital control application scenes such as Smart homes (Smart Home), intelligent homes, intelligent Home equipment ecology, intelligent residence (Intelligent House) ecology and the like. Alternatively, in this embodiment, the message pushing method described above may be applied to a hardware environment formed by the terminal device 102 and the server 104 as shown in fig. 1. As shown in fig. 1, the server 104 is connected to the terminal device 102 through a network, and may be configured to provide a service (e.g., an application service) for the terminal or a client installed on the terminal, set a database on the server or independent of the server, and provide a data storage service for the server 104, and configure a cloud computing and/or edge computing service on the server or independent of the server, and provide a data operation service for the server 104.
The network may include, but is not limited to, at least one of: wired networks, wireless networks. The wired network may include, but is not limited to, at least one of: wide area networks, metropolitan area networks, local area networks, which may include, but are not limited to, at least one of the following: WIFI (Wireless Fidelity), bluetooth. Terminal equipment 102 can be but not limited to be PC, the cell-phone, the panel computer, intelligent air conditioner, intelligent cigarette machine, intelligent refrigerator, intelligent oven, intelligent kitchen range, intelligent washing machine, intelligent water heater, intelligent washing equipment, intelligent dish washer, intelligent projection equipment, intelligent TV, intelligent clothes hanger, intelligent (window) curtain, intelligence audio-visual, smart jack, intelligent stereo set, intelligent audio amplifier, intelligent new trend equipment, intelligent kitchen guarding equipment, intelligent bathroom equipment, intelligence robot of sweeping the floor, intelligence robot of wiping the window, intelligence robot of mopping the ground, intelligent air purification equipment, intelligent steam ager, intelligent microwave oven, intelligent kitchen is precious, intelligent clarifier, intelligent water dispenser, intelligent lock etc..
In order to solve the above problem, in this embodiment, a message pushing method is provided, including but not limited to being applied in a cloud server, and fig. 2 is a flowchart of the message pushing method according to the embodiment of the present invention, where the flowchart includes the following steps:
step S202: the method comprises the steps of obtaining a message pushing request sent by a message pushing party, wherein the message pushing request carries message content to be pushed and indication information used for determining equipment to be pushed;
as an alternative example, the message pusher includes, but is not limited to, the operator of the product. The message pushing party can send a message pushing request to a message task service in the cloud server by calling a message pushing management service. If the message pushing party needs to push regularly, the message pushing request also comprises pushing time.
As an alternative example, the message content to be pushed includes, but is not limited to, a description of a certain product, including at least one of: text, picture, audio, video. The indication information includes at least one of: identification of the target object (the target object includes but is not limited to the user using the device), device identification, device type, device attribute information. For example, if the indication information is a user identifier, the determined devices to be pushed are all devices associated with the user. The device identifier includes but is not limited to a MAC address, etc., the device identifier may uniquely determine a device to be pushed, and the device types include but are not limited to: the information of the device attribute includes, but is not limited to, a refrigerator, an air conditioner, and the like, if the indication information is an air conditioner type, the determined device to be pushed is all air conditioners, and the device attribute information includes: the model of the device, the function of the device, etc. Optionally, if the indication information identifies the device type (e.g. air conditioner) and the user, the device to be pushed is determined to be devices of all device types (e.g. air conditioner) associated with the user.
It should be noted that the message push template is a general type of push message template developed in advance by a developer.
Step S204: determining a device to be pushed according to the indication information in the message pushing request, and embedding the message content in the message pushing request into a message pushing template corresponding to the message pushing request according to the capability information of the device to be pushed to obtain a message to be pushed;
it should be noted that, before the step S204 is executed, it is also necessary to determine whether a generic message push template exists. As an alternative example, this may be achieved by: calling a template management service, and determining whether a message pushing template exists in the template management service, wherein the message pushing template supports filling of the message content, and the device to be pushed corresponding to the indication information allows the message pushing template to be used for pushing messages; and under the condition that the message pushing template exists in the template management service, acquiring the message pushing template from the template management service.
It can be understood that, after receiving a message pushing request sent by a message pusher, a message task service in the cloud server invokes a template management service, and then determines whether a message pushing template exists through the template management service. Specifically, the message task service sends an inquiry request to the template management service, where the inquiry request includes message content to be pushed and corresponding indication information, and the template management service determines whether a message pushing template exists, which supports filling of the message content and supports use of equipment to be pushed corresponding to the indication information. Alternatively, assuming that the message content includes text, pictures and audio, the indication information is device type, and the template management service determines whether there is a generic message push template that allows filling of text, pictures and audio, and whether devices of device type (e.g., refrigerator) are allowed to use.
It should be noted that after the message task service acquires the general message push template, the device to be pushed is determined according to the indication information in the message push request, specifically, the message task service invokes the terminal management service, and determines the device to be pushed from the terminal management service according to the indication information. Optionally, the message task service acquires the device identifier of the device to be pushed from the terminal management service, and the determined device to be pushed may be one device or multiple devices. Optionally, when the message task service determines the device to be pushed from the terminal management service according to the indication information, the message channel corresponding to the device to be pushed may also be obtained.
Further, after determining the device to be pushed, the message task service invokes the terminal capability management service to query the capability information of the device, specifically, sends the device identifier of the device to be pushed to the terminal capability management service, and further obtains the capability information sent by the terminal capability management service.
As an optional example, the capability information comprises at least one of: whether the display of characters is supported, whether the display of pictures is supported, whether the playing of audio is executed, whether the playing of video is supported, and whether a target display mode is supported.
Further, after acquiring the general message pushing template, the message content to be pushed, and determining the device to be pushed and the corresponding capability information, the message task service may embed the message content in the message pushing request into the message pushing template corresponding to the message pushing request according to the capability information of the device to be pushed, which may be implemented by the following steps S11 to S13 as an optional example:
step S11: determining target message content from the message content according to the capability information of the equipment to be pushed;
for better understanding, as shown in fig. 3, it is assumed that the content of the message to be pushed is introduction of a product a, the devices to be pushed are the device 1 to be pushed and the device 2 to be pushed, and the determined capability information of the device 1 to be pushed is: and supporting characters and pictures and supporting a target display mode. The determined capability information of the device 2 to be pushed is: supporting video; then the device 1 to be pushed determines that the target message content is a text introduction and a picture introduction; the device to be pushed 2 determines the content of the target message as a video introduction.
Step S12: embedding the target message content into the message pushing template, and determining whether the device to be pushed supports the display of the target message content in a target display mode according to the capability information of the device to be pushed;
step S13: and under the condition that the equipment to be pushed supports the target message content displayed by using the target display mode, setting the display mode of the target message content in the message pushing template as the target display mode.
It can be understood that after the target message content is determined, the corresponding target message content is embedded into the message push template, and if the device to be pushed supports the target display mode, the display mode of the target message content in the message push template is set as the target display mode, for example, the display modes of the text introduction and the picture introduction are set as the target display mode in the message push template corresponding to the device to be pushed 1, and then the device to be pushed 1 displays the text introduction and the picture introduction in the target display mode after obtaining the message.
As an optional example, in order to avoid determining the target message content from the message content according to the capability information of the device to be pushed each time, before performing step S204, if it is determined that the device to be pushed includes a plurality of devices, the device type and capability information of each of the plurality of devices may be determined; and grouping the plurality of devices according to the device types and the capability information to obtain a plurality of groups, wherein the devices in each group in the plurality of groups have the same device types and the same capability information.
For example: there is now a push device: two water heaters (one with voice module and one without) and a television; the water heater and the television are firstly divided into two groups according to the type of the equipment, and then the two equipment are divided into two groups according to the capability information (whether the equipment supports audio or whether the equipment has the capability which other equipment does not have).
That is to say, the message task service may group a plurality of devices according to the device type and the capability information, and then the embedding manners of embedding the message content to be pushed into the message pushing template corresponding to the devices in the same group are the same, as long as the target embedding manner of embedding the message content to be pushed into the message pushing template corresponding to the group is determined, and as long as the device is determined to be in the group, the corresponding target embedding manner may be determined.
Further, in an alternative embodiment, the step S204 may be implemented by: when the device to be pushed comprises a plurality of devices and the devices are divided into a plurality of groups, determining a target embedding mode corresponding to each group according to the device type and the capability information corresponding to each group in the groups; and embedding the message content into the message pushing template according to the target embedding mode corresponding to each group to obtain the message to be pushed corresponding to the equipment in each group.
That is to say, for the devices in a group, since the target embedding manners are the same, after the content of the message to be pushed is embedded into the message pushing template according to the target embedding manner, the message to be pushed corresponding to the device in the group can be determined, and the message pushing efficiency is further improved.
Step S206: and pushing the message to be pushed to the equipment to be pushed.
As an alternative example, the above step S206 may be implemented by the following steps S21-S22:
step S21: creating a push task, wherein the push task comprises: the method comprises the steps of pushing a message channel of a message to be pushed by a device identifier of the device to be pushed, the message to be pushed corresponding to the device to be pushed;
step S22: and sending the push task to a target message queue so that a message push service subscribes the push task from the target message queue, and sending the message to be pushed to the device to be pushed through the message channel.
That is to say, the message task service may create a push task, send the push task to the target message queue, and then the message push service subscribes the push task from the target message queue and sends the message to be pushed to the device to be pushed through the message channel. Optionally, the target message queue includes but is not limited to: KAFKA.
Through the steps, the message content to be pushed is embedded into the message pushing template according to the capacity information of the device to be pushed, so that the message to be pushed is obtained, and the message to be pushed is pushed to the device to be pushed. The universal message pushing template is used, the message content to be pushed is embedded into the message pushing template according to the capability information of the device to be pushed for pushing when the message is pushed, the message pushing template does not need to be correspondingly developed for each device, the pushing efficiency is improved, the development cost is saved, and the problem that the pushing efficiency is low because one message pushing template needs to be correspondingly developed for pushing the message for each device is solved.
It is to be understood that the above-described embodiments are only a few, but not all, embodiments of the present invention. In order to better understand the above prompting method, the following describes the above process with reference to an embodiment, but is not limited to the technical solution of the embodiment of the present invention, specifically:
in an alternative embodiment, fig. 4 is a timing diagram of a message pushing method according to an embodiment of the present invention, as shown in fig. 4, an operator/backend service party (equivalent to the message pushing party in the foregoing embodiment) invokes a message pushing management service to initiate a pushing process, in which the message pushing party is required to provide a screening condition (equivalent to the indication information in the foregoing embodiment) of a target terminal that receives a message, such as a user identifier, a device type, and device attribute information; and message content including, but not limited to, text, pictures, audio, and video; it should be noted that if the operator/backend server needs to push at regular time, the push time may also be set.
After receiving the request for creating the push task, the message task service calls the template management service for verification, determines whether the request parameter is legal or not, determines whether a universal message push template exists or not, and if so, takes the analyzed template.
And the message task service calls the terminal management service to inquire the terminal meeting the conditions according to the analyzed screening conditions of the terminal. The terminal management service only stores the identifier, the message channel and the like of the terminal and does not contain the terminal capability.
The message task service queries the terminal capability (equivalent to the capability information of the device in the above embodiment) of the terminal capability management service according to the queried terminal identifier, such as whether the terminal supports audio and video, whether a customized display mode (equivalent to the target display mode in the above embodiment) exists, and the like.
The message task service classifies the terminals according to the terminal list and the capabilities of the terminals, and the terminals with the same equipment type and the same capabilities are divided into a group. If two water heaters (one with a voice module and one without) and one television exist at present, the water heaters and the television are firstly divided into two groups according to the types of the equipment, and then the two equipment are divided into two groups according to the capability information (whether the equipment supports audio or whether the equipment has the capability which other equipment does not have).
And then the message task service assembles different message contents according to the grouping result, the template content and the like. And creates a push task, sends the push task to KAFKA (the push task comprises a target terminal identifier, a channel identifier, message content and the like), and returns a task creation result to the message push management service.
Finally, the message push service subscribes to TOPIC corresponding to the push task from KAFKA and pushes.
In the embodiment, the high-availability reusable general message pushing template is automatically matched with the service capabilities of different terminals to push messages, so that the pushing working efficiency is improved, and the threshold of related services is reduced.
Through the above description of the embodiments, those skilled in the art can clearly understand that the method according to the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but the former is a better implementation mode in many cases. Based on such understanding, the technical solutions of the present invention or portions thereof contributing to the prior art may be embodied in the form of a software product, which is stored in a storage medium (such as ROM/RAM, magnetic disk, optical disk) and includes several instructions for enabling a terminal device (which may be a mobile phone, a computer, a server, or a network device, etc.) to execute the method of the embodiments of the present invention.
In this embodiment, a message pushing device is further provided, where the message pushing device is used to implement the foregoing embodiments and preferred embodiments, and details are not described again after the description. As used below, the term "module" may be a combination of software and/or hardware that implements a predetermined function. While the devices described in the embodiments below are preferably implemented in software, implementations in hardware, or a combination of software and hardware are also possible and contemplated.
Fig. 5 is a block diagram of a message pushing apparatus according to an embodiment of the present invention, the apparatus including:
an obtaining module 52, configured to obtain a message pushing request sent by a message pushing party, where the message pushing request carries a message content to be pushed and indication information used to determine a device to be pushed;
the processing module 54 is configured to determine a device to be pushed according to the indication information in the message push request, and embed the message content in the message push request into a message push template corresponding to the message push request according to the capability information of the device to be pushed, so as to obtain a message to be pushed;
a pushing module 56, configured to push the message to be pushed to the device to be pushed.
By the device, the message content to be pushed is embedded into the message pushing template according to the capability information of the device to be pushed, so that the message to be pushed is obtained, and the message to be pushed is pushed to the device to be pushed. Because a universal message pushing template is used, and when message pushing is carried out, message contents to be pushed are embedded into the message pushing template for pushing according to the capability information of equipment to be pushed, the message pushing template does not need to be correspondingly developed for each equipment, the pushing efficiency is improved, the development cost is saved, and the problem that the pushing efficiency is lower because each equipment pushes messages and one message pushing template needs to be correspondingly developed for message pushing is solved.
In an exemplary embodiment, the processing module 54 is further configured to, before embedding the message content in the message push request into a message push template corresponding to the message push request according to the capability information of the device to be pushed, invoke a template management service, and determine whether a message push template exists in the template management service, where the message push template supports filling of the message content, and the device to be pushed corresponding to the indication information allows the message to be pushed using the message push template; and acquiring the message pushing template from the template management service under the condition that the message pushing template exists in the template management service.
In an exemplary embodiment, the processing module 54 is further configured to determine target message content from the message content according to the capability information of the device to be pushed; embedding the target message content into the message pushing template, and determining whether the device to be pushed supports the display of the target message content in a target display mode according to the capability information of the device to be pushed; and under the condition that the equipment to be pushed supports the target message content displayed by using the target display mode, setting the display mode of the target message content in the message pushing template as the target display mode.
In an exemplary embodiment, the processing module 54 is further configured to, before embedding the message content in the message push request into the message push template corresponding to the message push request according to the capability information of the device to be pushed, determine, in a case that it is determined that the device to be pushed includes multiple devices, a device type and capability information of each of the multiple devices; and grouping the plurality of devices according to the device types and the capability information to obtain a plurality of groups, wherein the devices in each group in the plurality of groups have the same device types and the same capability information.
In an exemplary embodiment, the processing module 54 is further configured to, when it is determined that the device to be pushed includes multiple devices and the multiple devices are divided into multiple groups, determine, according to a device type and capability information corresponding to each of the multiple groups, a target embedding manner corresponding to each of the multiple groups; and embedding the message content into the message pushing template according to the target embedding mode corresponding to each group to obtain the message to be pushed corresponding to the equipment in each group.
In an exemplary embodiment, the push module 56 is further configured to create a push task, wherein the push task includes: the method comprises the steps that a device identifier of a device to be pushed, a message to be pushed corresponding to the device to be pushed, and a message channel for pushing the message to be pushed are obtained; and sending the push task to a target message queue so that a message push service subscribes the push task from the target message queue, and sending the message to be pushed to the device to be pushed through the message channel.
In an exemplary embodiment, the message content includes at least one of: text, picture, audio, video; the indication information includes at least one of: identification of the target object, equipment identification, equipment type and equipment attribute information; the capability information includes at least one of: whether the display of characters is supported, whether the display of pictures is supported, whether the playing of audio is executed, whether the playing of video is supported, and whether a target display mode is supported.
Embodiments of the present invention also provide a computer-readable storage medium having a computer program stored thereon, wherein the computer program is arranged to perform the steps of any of the above-mentioned method embodiments when executed.
Alternatively, in the present embodiment, the storage medium may be configured to store a computer program for executing the steps of:
the method comprises the steps of S1, obtaining a message pushing request sent by a message pushing party, wherein the message pushing request carries message contents to be pushed and indication information used for determining equipment to be pushed;
s2, determining equipment to be pushed according to the indication information in the message pushing request, and embedding the message content in the message pushing request into a message pushing template corresponding to the message pushing request according to the capability information of the equipment to be pushed to obtain a message to be pushed;
and S3, pushing the message to be pushed to the equipment to be pushed.
In an exemplary embodiment, the computer-readable storage medium may include, but is not limited to: various media capable of storing computer programs, such as a usb disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a removable hard disk, a magnetic disk, or an optical disk.
For specific examples in this embodiment, reference may be made to the examples described in the foregoing embodiments and exemplary implementations, and details of this embodiment are not repeated herein.
Embodiments of the present invention also provide an electronic device comprising a memory having a computer program stored therein and a processor arranged to run the computer program to perform the steps of any of the above method embodiments.
Optionally, in this embodiment, the processor may be configured to execute the following steps by a computer program:
the method comprises the steps of S1, obtaining a message pushing request sent by a message pushing party, wherein the message pushing request carries message contents to be pushed and indication information used for determining equipment to be pushed;
s2, determining equipment to be pushed according to the indication information in the message pushing request, and embedding the message content in the message pushing request into a message pushing template corresponding to the message pushing request according to the capability information of the equipment to be pushed to obtain a message to be pushed;
and S3, pushing the message to be pushed to the equipment to be pushed.
In an exemplary embodiment, the electronic apparatus may further include a transmission device and an input/output device, wherein the transmission device is connected to the processor, and the input/output device is connected to the processor.
For specific examples in this embodiment, reference may be made to the examples described in the above embodiments and exemplary embodiments, and details of this embodiment are not repeated herein.
It will be apparent to those skilled in the art that the various modules or steps of the invention described above may be implemented using a general purpose computing device, they may be centralized on a single computing device or distributed across a network of computing devices, and they may be implemented using program code executable by the computing devices, such that they may be stored in a memory device and executed by the computing device, and in some cases, the steps shown or described may be performed in an order different than that described herein, or they may be separately fabricated into various integrated circuit modules, or multiple ones of them may be fabricated into a single integrated circuit module. Thus, the present invention is not limited to any specific combination of hardware and software.
The foregoing is only a preferred embodiment of the present application and it should be noted that those skilled in the art can make several improvements and modifications without departing from the principle of the present application, and these improvements and modifications should also be considered as the protection scope of the present application.

Claims (10)

1. A message pushing method is characterized by comprising the following steps:
the method comprises the steps of obtaining a message pushing request sent by a message pushing party, wherein the message pushing request carries message content to be pushed and indication information used for determining equipment to be pushed;
determining a device to be pushed according to the indication information in the message pushing request, and embedding the message content in the message pushing request into a message pushing template corresponding to the message pushing request according to the capability information of the device to be pushed to obtain a message to be pushed;
and pushing the message to be pushed to the equipment to be pushed.
2. The method according to claim 1, wherein before embedding the message content in the message push request into the message push template corresponding to the message push request according to the capability information of the device to be pushed, the method further comprises:
calling a template management service, and determining whether a message pushing template exists in the template management service, wherein the message pushing template supports filling of the message content, and the device to be pushed corresponding to the indication information allows the message pushing template to be used for pushing messages;
and under the condition that the message pushing template exists in the template management service, acquiring the message pushing template from the template management service.
3. The method according to claim 1, wherein embedding the message content in the message push request into a message push template corresponding to the message push request according to the capability information of the device to be pushed comprises:
determining target message content from the message content according to the capability information of the equipment to be pushed;
embedding the target message content into the message pushing template, and determining whether the device to be pushed supports the display of the target message content in a target display mode according to the capability information of the device to be pushed;
and under the condition that the equipment to be pushed supports the target message content displayed by using the target display mode, setting the display mode of the target message content in the message pushing template as the target display mode.
4. The method according to claim 1, wherein before embedding the message content in the message push request into the message push template corresponding to the message push request according to the capability information of the device to be pushed, the method further comprises:
determining device type and capability information of each device in a plurality of devices under the condition that the device to be pushed comprises the plurality of devices;
and grouping the plurality of devices according to the device types and the capability information to obtain a plurality of groups, wherein the devices in each group in the plurality of groups have the same device types and the same capability information.
5. The method according to claim 1, wherein embedding the message content in the message pushing request into a message pushing template corresponding to the message pushing request according to the capability information of the device to be pushed to obtain the message to be pushed comprises:
when the device to be pushed comprises a plurality of devices and the devices are divided into a plurality of groups, determining a target embedding mode corresponding to each group according to the device type and the capability information corresponding to each group in the groups;
and embedding the message content into the message pushing template according to the target embedding mode corresponding to each group to obtain the message to be pushed corresponding to the equipment in each group.
6. The method according to claim 1, wherein pushing the message to be pushed to the device to be pushed comprises:
creating a push task, wherein the push task comprises: the method comprises the steps that a device identifier of a device to be pushed, a message to be pushed corresponding to the device to be pushed, and a message channel for pushing the message to be pushed are obtained;
and sending the push task to a target message queue so that a message push service subscribes the push task from the target message queue, and sending the message to be pushed to the device to be pushed through the message channel.
7. The method of claim 1, wherein the message content comprises at least one of: text, picture, audio, video; the indication information includes at least one of: identification of the target object, equipment identification, equipment type and equipment attribute information; the capability information includes at least one of: whether the display of characters is supported, whether the display of pictures is supported, whether the playing of audio is executed, whether the playing of video is supported, and whether a target display mode is supported.
8. A message push apparatus, comprising:
the device comprises an acquisition module, a sending module and a sending module, wherein the acquisition module is used for acquiring a message pushing request sent by a message pushing party, and the message pushing request carries message content to be pushed and indication information used for determining equipment to be pushed;
the processing module is used for determining equipment to be pushed according to the indication information in the message pushing request, and embedding the message content in the message pushing request into a message pushing template corresponding to the message pushing request according to the capacity information of the equipment to be pushed to obtain a message to be pushed;
and the pushing module is used for pushing the message to be pushed to the equipment to be pushed.
9. A computer-readable storage medium, comprising a stored program, wherein the program when executed performs the method of any one of claims 1 to 7.
10. An electronic device comprising a memory and a processor, characterized in that the memory has stored therein a computer program, the processor being arranged to execute the method of any of claims 1 to 7 by means of the computer program.
CN202210589233.4A 2022-05-27 2022-05-27 Message pushing method and device, storage medium and electronic device Pending CN115174512A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210589233.4A CN115174512A (en) 2022-05-27 2022-05-27 Message pushing method and device, storage medium and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210589233.4A CN115174512A (en) 2022-05-27 2022-05-27 Message pushing method and device, storage medium and electronic device

Publications (1)

Publication Number Publication Date
CN115174512A true CN115174512A (en) 2022-10-11

Family

ID=83484211

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210589233.4A Pending CN115174512A (en) 2022-05-27 2022-05-27 Message pushing method and device, storage medium and electronic device

Country Status (1)

Country Link
CN (1) CN115174512A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117097793A (en) * 2023-10-19 2023-11-21 荣耀终端有限公司 Message pushing method, terminal and server

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106027614A (en) * 2016-05-09 2016-10-12 百度在线网络技术(北京)有限公司 Information pushing method, device and system
US20170048345A1 (en) * 2014-05-01 2017-02-16 Sha LIU Precision push method for internet information
CN106603653A (en) * 2016-12-09 2017-04-26 天脉聚源(北京)传媒科技有限公司 News push method and device
CN110611691A (en) * 2018-06-15 2019-12-24 中兴通讯股份有限公司 Message pushing method, system and storage medium
CN111131415A (en) * 2019-12-12 2020-05-08 上海钧正网络科技有限公司 Information pushing method and device, computer equipment and storage medium
CN112822286A (en) * 2021-01-27 2021-05-18 湖南快乐阳光互动娱乐传媒有限公司 Message pushing method and device
CN113890895A (en) * 2021-08-27 2022-01-04 青岛海尔科技有限公司 Message pushing method and device, storage medium and electronic device

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170048345A1 (en) * 2014-05-01 2017-02-16 Sha LIU Precision push method for internet information
CN106027614A (en) * 2016-05-09 2016-10-12 百度在线网络技术(北京)有限公司 Information pushing method, device and system
CN106603653A (en) * 2016-12-09 2017-04-26 天脉聚源(北京)传媒科技有限公司 News push method and device
CN110611691A (en) * 2018-06-15 2019-12-24 中兴通讯股份有限公司 Message pushing method, system and storage medium
CN111131415A (en) * 2019-12-12 2020-05-08 上海钧正网络科技有限公司 Information pushing method and device, computer equipment and storage medium
CN112822286A (en) * 2021-01-27 2021-05-18 湖南快乐阳光互动娱乐传媒有限公司 Message pushing method and device
CN113890895A (en) * 2021-08-27 2022-01-04 青岛海尔科技有限公司 Message pushing method and device, storage medium and electronic device

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117097793A (en) * 2023-10-19 2023-11-21 荣耀终端有限公司 Message pushing method, terminal and server
CN117097793B (en) * 2023-10-19 2023-12-15 荣耀终端有限公司 Message pushing method, terminal and server

Similar Documents

Publication Publication Date Title
WO2015149471A1 (en) Information pushing method, system and device and computer storage medium
CN111970181B (en) Network distribution method and device for intelligent household equipment, electronic equipment and storage medium
CN115174512A (en) Message pushing method and device, storage medium and electronic device
CN102298590A (en) Home interconnected information display system and method, and display terminals and server for the same
CN115175152A (en) Intelligent device binding method and device, storage medium and electronic device
CN114697150A (en) Command issuing method and device, storage medium and electronic device
CN116107975A (en) Control method and device of equipment, storage medium and electronic device
CN116027937A (en) Rendering method and device of component to be edited, storage medium and electronic device
CN115309062A (en) Device control method, device, storage medium, and electronic apparatus
CN115687806A (en) Method and device for determining target equipment list, storage medium and electronic device
CN115345225A (en) Method and device for determining recommended scene, storage medium and electronic device
CN115296958B (en) Distribution method and device of equipment control tasks, storage medium and electronic device
CN107038170B (en) Method and device for recommending application program
CN115314549B (en) Offline equipment management method, storage medium and electronic device
CN115314332A (en) Method and device for setting equipment theme, storage medium and electronic device
WO2023202029A1 (en) Tag data adjustment method and apparatus, and storage medium
CN116723232A (en) Message pushing method and device, storage medium and electronic device
CN116248647A (en) Method and device for sending resource package, storage medium and electronic device
CN115694913A (en) Method and apparatus for transmitting device information, storage medium, and electronic apparatus
CN115174656A (en) Device configuration method and apparatus, storage medium, and electronic apparatus
CN115473756A (en) Message sending method, device, storage medium and electronic device
CN115174297A (en) Attribute information updating method and device, storage medium and electronic device
CN114815642A (en) Control method and device of intelligent equipment, storage medium and electronic device
CN115934200A (en) Resource pushing method and device, storage medium and electronic device
CN116545792A (en) Communication method and system of household equipment, storage medium and electronic device

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination