WO2020181913A1 - Message distribution processing method, device, equipment, and storage medium - Google Patents

Message distribution processing method, device, equipment, and storage medium Download PDF

Info

Publication number
WO2020181913A1
WO2020181913A1 PCT/CN2020/070692 CN2020070692W WO2020181913A1 WO 2020181913 A1 WO2020181913 A1 WO 2020181913A1 CN 2020070692 W CN2020070692 W CN 2020070692W WO 2020181913 A1 WO2020181913 A1 WO 2020181913A1
Authority
WO
WIPO (PCT)
Prior art keywords
message
distribution
client
distributor
target
Prior art date
Application number
PCT/CN2020/070692
Other languages
French (fr)
Chinese (zh)
Inventor
王岳晨
Original Assignee
北京字节跳动网络技术有限公司
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 北京字节跳动网络技术有限公司 filed Critical 北京字节跳动网络技术有限公司
Publication of WO2020181913A1 publication Critical patent/WO2020181913A1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • G06F9/546Message passing systems or structures, e.g. queues
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3003Monitoring arrangements specially adapted to the computing system or computing system component being monitored
    • G06F11/302Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system component is a software system
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3051Monitoring arrangements for monitoring the configuration of the computing system or of the computing system component, e.g. monitoring the presence of processing resources, peripherals, I/O links, software programs
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/50Allocation of resources, e.g. of the central processing unit [CPU]
    • G06F9/5005Allocation of resources, e.g. of the central processing unit [CPU] to service a request
    • G06F9/5011Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals
    • G06F9/5016Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resources being hardware resources other than CPUs, Servers and Terminals the resource being the memory
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/54Interprogram communication
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/45Network directories; Name-to-address mapping
    • H04L61/4505Network directories; Name-to-address mapping using standardised directories; using standardised directory access protocols
    • H04L61/4511Network directories; Name-to-address mapping using standardised directories; using standardised directory access protocols using domain name system [DNS]
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/50Network services
    • H04L67/55Push-based network services
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/50Indexing scheme relating to G06F9/50
    • G06F2209/5018Thread allocation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/50Indexing scheme relating to G06F9/50
    • G06F2209/508Monitor

Definitions

  • the embodiments of the present disclosure relate to computer technology, for example, to a message distribution processing method, device, device, and storage medium.
  • the application software client When the application software client is in use, it often receives various messages pushed by the server, so that related objects in the client can process the received messages.
  • an application client running on the iOS operating system when it receives a message pushed by the server, it does not have an effective message distribution processing mechanism, and mainly relies on one or more object processes currently running in the client (for example, interface Or a pop-up window, etc.) respectively analyze and process each received message to determine whether it belongs to the message processed by the target process, and obtain information matching the target process for processing.
  • object processes currently running in the client for example, interface Or a pop-up window, etc.
  • the disadvantage of the related technical solutions is that all object processes need to parse and process each message received, which not only takes up a large amount of memory resources, but also reduces the efficiency of message distribution processing.
  • the embodiments of the present disclosure provide a message distribution processing method, device, equipment, and storage medium, so as to save memory resources and improve the efficiency of message distribution processing.
  • the embodiment of the present disclosure provides a message distribution processing method, including:
  • the client receives the target message pushed by the server through the message distributor;
  • the client parses the target message through the message distributor, and generates a distribution message according to the message type and message data in the target message;
  • the client terminal notifies at least one observer object of the message distributor of the distribution message through the message distributor;
  • the client uses the at least one observer object to process the monitored distribution message according to a set processing mode.
  • the embodiment of the present disclosure also provides a message distribution processing device, which is configured in the client, and the device includes:
  • the message receiving module is set to receive the target message pushed by the server through the message distributor;
  • a message parsing module configured to parse the target message through the message distributor, and generate a distribution message according to the message type and message data in the target message;
  • a message distribution module configured to notify at least one observer object of the message distributor of the distribution message through the message distributor
  • the message processing module is configured to process the monitored distribution message according to the set processing mode through the at least one observer object.
  • the embodiment of the present disclosure also provides a message distribution processing device, which is configured in a client, and the device includes: a message distributor and at least one observer object;
  • the message distributor is set to receive the target message pushed by the server; parse the target message, and generate a distribution message according to the message type and message data in the target message; notify the message of the distribution message At least one observer object of the dispatcher;
  • the at least one observer object is set to process the monitored distribution message according to a set processing mode.
  • the embodiment of the present disclosure also provides a terminal device, which includes:
  • One or more processing devices are One or more processing devices;
  • Storage device set to store one or more programs
  • the one or more processing devices When the one or more programs are executed by the one or more processing devices, the one or more processing devices implement the message distribution processing method according to any one of the embodiments of the present disclosure.
  • the embodiment of the present disclosure also provides a computer-readable storage medium on which a computer program is stored, and when the program is executed by a processing device, the method for message distribution processing as described in any of the embodiments of the present disclosure is implemented.
  • FIG. 1 is a schematic flowchart of a message distribution processing method provided by Embodiment 1 of the present disclosure
  • FIG. 2 is a schematic flowchart of a message distribution processing method provided by Embodiment 2 of the present disclosure
  • FIG. 3 is a schematic structural diagram of a message distribution processing apparatus provided by Embodiment 3 of the present disclosure.
  • FIG. 4 is a schematic diagram of the hardware structure of a terminal device provided in the fourth embodiment of the present disclosure.
  • each embodiment provides optional features and examples at the same time. Multiple features recorded in the embodiments can be combined to form multiple alternative solutions. Each numbered embodiment should not be regarded as It is a technical solution.
  • FIG. 1 is a schematic flowchart of a message distribution processing method according to Embodiment 1 of the present disclosure. This method can be applied to the case where the client distributes the received message.
  • the method can be executed by a terminal device such as a mobile phone or a tablet computer running an application client, and includes the following steps:
  • the client receives the target message pushed by the server through the message distributor.
  • the target message may be personal information such as private messages and notifications pushed by the server to the client.
  • the iOS operating system in related technologies does not have an effective message distribution processing mechanism, when the client receives the target message pushed by the server, it can only rely on all the objects (also called processes or instances, etc.) in the client. Analyze each received message to determine whether the object is the processor of the message, so that each object needs to perform a repeated analysis process for each message.
  • the client occupies a large amount of memory resources, which makes the operation of the client stalled, and at the same time, it reduces the efficiency of message distribution processing.
  • a message dispatcher (MessageDispatcher) is set in the client, which is specifically used to parse and distribute received push messages.
  • the message distributor can be a processing thread written in the client program.
  • the server pushes the target message to the client, the client can receive the target message through the message distributor.
  • the client involved in this embodiment may refer to a mobile application (Application, APP) or a web page, which is not limited here.
  • APP Application, APP
  • web page which is not limited here.
  • the client includes: an application client adapted to the iOS operating system. That is, the client involved in this embodiment can be installed in the iOS operating system to make up for the lack of an effective message distribution processing mechanism in the iOS operating system.
  • the client can also be adapted to the Android operating system.
  • the application client, etc., this embodiment does not limit this.
  • the client parses the target message through the message distributor, and generates a distribution message according to the message type and message data in the target message.
  • the client after receiving the target message pushed by the server, the client can use the message distributor to uniformly analyze the target message.
  • the client can split or recognize the target message into message data and its corresponding message type through the message distributor.
  • the parsed message data and message type can be generated according to a preset format to generate a distribution message.
  • the preset format can be "message type + message data" so that the message can be processed directly in the subsequent steps. Identify the distribution message according to the message type.
  • the client informs at least one observer object of the message distributor of the distribution message through the message distributor.
  • the observer object may be an object in the client that needs to receive distribution messages, and the object includes, but is not limited to, a web page, a pop-up window, etc. in the client.
  • the client after the client generates a distribution message through the message distributor, it can notify each observer object of the message distributor of the distribution message, so that the observer object can process the pushed message.
  • a listener thread may be set for each observer object to listen to the distribution message generated in the message distributor.
  • the client terminal notifies at least one observer object of the message distributor of the distribution message through the message distributor, including: the client terminal notifies the distribution message to the message type according to the message type through the message distributor. At least one observer object of the matched message distributor.
  • the message distributor can notify the corresponding observer object capable of processing the message type according to the message type, so that the corresponding observer object pairs The monitored distribution message is processed directly.
  • the corresponding relationship between the message type and the observer object can be preset, and the message distributor can determine to notify the corresponding observer object of the distribution messages of different message types through the corresponding relationship.
  • the client notifies at least one observer object of the message distributor of the distribution message through the message distributor, including: the client notifies the distribution message in the message distributor in advance through the message distributor. At least one observer object registered.
  • At least one object in the client needs to receive a message pushed by the server, it can be registered in the message distributor in advance.
  • the target webpage can be automatically registered in the message distributor as an observer object.
  • the target pop-up window can also be automatically registered in the message distributor as another observer object.
  • the objects in the client that are interested in the messages pushed by the server are registered in the message distributor in advance, when the message distributor generates a distribution message, only the registered observer object can receive the distribution message notification, which can avoid all All objects listen to messages indiscriminately, reducing the waste of memory resources and improving the performance of the device where the client is located.
  • S140 The client uses at least one observer object to process the monitored distribution message according to a set processing mode.
  • the distribution messages monitored by the observer object may only include messages that can be processed by itself, or may also include other messages. In this case, you can follow the set processing method to Distribute messages for processing.
  • the observer object when the observer object listens to the distribution message, it can display or respond to the message that it can handle, and discard the message that cannot be processed.
  • the client uses at least one observer object to process the monitored distribution message according to the set processing mode, including: the client uses at least one observer The object processes the distribution messages that it monitors.
  • the distribution message monitored by the observer object is a message notified by the message distributor according to the message type
  • the distribution message monitored by the observer object only includes the messages that it can process, and only the distribution message is required Perform the corresponding message processing.
  • the client uses at least one observer object to process the monitored distribution message according to the set processing mode, including: the client uses at least one observer The object determines the processing mode of the distribution message according to the message type in the monitored distribution message, and processes the distribution message according to the processing mode.
  • the distribution message monitored by the observer object is the distribution message for the indiscriminate notification of the message distributor
  • the observer object monitors the distribution message generated by the message distributor through the monitoring thread, it can be based on the message type included in the distribution message, Different processing methods are adopted for distributed messages.
  • the message type it can process can be the notification type; when the observer object is a web page, the message type it can process can be the private message type, and so on.
  • the processing method for the distribution message includes but is not limited to discarding, displaying, responding, etc., which are not limited herein, wherein the processing method for the distribution message can be determined according to the message type in the distribution message.
  • the client determines the processing mode of the distribution message according to the message type in the monitored distribution message through at least one observer object, and processing the distribution message according to the processing mode includes: the client verifies the at least one observer object Whether the message type of the monitored distribution message is the preset target monitoring type; when the message type of the distribution message is the preset target monitoring type, the message data in the monitored distribution message is processed, and the If the message type of the message is not the preset target monitoring type, the distribution message that is monitored is discarded.
  • the types of messages that can be processed by different objects may be different, different observer objects can correspondingly set different target listening types.
  • the message types that can be processed by an observer object can include one or more types, and correspondingly, the target monitoring types also include one or more types.
  • the observer object determines that the message type of the monitored distribution message is the preset target monitoring type corresponding to it, it means that the observer object is the processor of the distribution message, and the distribution message can be When the observer object determines that the message type of the monitored distribution message does not belong to the corresponding preset target monitoring type, it means that the observer object is not the processor of the distribution message. Discard the monitored distribution message directly.
  • the message distributor is used to receive the target message pushed by the server, and the target message is parsed, and the distribution message is generated according to the message type and message data in the target message , And then notify the distribution message to at least one observer object in the message distributor, and process the monitored distribution message according to the set processing method through the at least one observer object, and use the separate message distributor to complete the process.
  • the message parsing and distribution process solves the problems of related technologies that all objects in the client need to parse each message received, which causes a large amount of memory, reduces the efficiency of message distribution and processing, and saves memory resources. Improve the efficiency of message distribution processing.
  • the message distributor exposes the protocol method to the outside; at least one observer object completes the monitoring of the message notified by the message distributor by implementing the protocol method exposed by the message distributor.
  • an externally exposed protocol method can be pre-defined in the message distributor as an interface for the message distributor to publish and distribute message notifications, and the observer object can implement the protocol method by calling to monitor the interface.
  • the protocol method may be a global method, including parameters used to carry the distribution message.
  • FIG. 2 is a schematic flowchart of a message distribution processing method provided by Embodiment 2 of the disclosure. This embodiment is described on the basis of the optional solutions in the above embodiments, and provides an optional message distribution processing method.
  • the client Before the client receives the target message pushed by the server through the message distributor, it also includes: the client sends the message according to the server Establish a long connection between the target domain name and the server.
  • the client receives the target message pushed by the server through the message distributor, including: the client receives the target message pushed by the server through the message distributor using a long connection.
  • the client establishes a persistent connection with the server according to the target domain name issued by the server.
  • a long connection means that multiple data packets can be sent continuously on one connection.
  • both parties need to send link detection packets.
  • Long connections are mostly used for frequent operations, point-to-point communication, and the number of connections cannot be too many. Since each Transmission Control Protocol (TCP) connection requires a three-way handshake, which requires a lot of time, if each operation is a short connection, the processing speed will be greatly reduced, so after each operation is completed On, the data packet can be sent directly during the next processing without re-establishing the TCP connection.
  • TCP Transmission Control Protocol
  • the server since the server continuously pushes messages to the client during the use of the client, a long connection can be established between the client and the server, so as to save communication time and increase the message transmission speed.
  • the server may be correspondingly set with multiple domain names, and when the server delivers the domain name to the client, it can select the most suitable target domain name for the client, so that the client establishes a persistent connection with the server according to the target domain name.
  • the beneficial effect of adopting a dynamic domain name for server connection in this embodiment is that the optimal data transmission path can be selected at any time according to changes in the location of the client, which improves Message push efficiency.
  • the client before the client establishes a persistent connection with the server according to the target domain name issued by the server, it also includes: the client sends a domain name request to the server when detecting the client start instruction; the domain name request is used to instruct the server to use the preset
  • the speed measurement algorithm of the server determines the target domain name matching the client from at least two candidate domain names corresponding to the server, and delivers the target domain name to the client.
  • the server in this embodiment is a server cluster, including multiple server rooms, and the server rooms are located in different locations, and one server room corresponds to a domain name
  • the server can choose the best for the client. Suitable server room for connection.
  • the client start command can be detected.
  • it can send a domain name request to the server.
  • the server After the server receives the domain name request, it can select the client from multiple server rooms according to the preset speed measurement algorithm
  • the server room with the fastest access speed is used as the server to be connected to the client, and the domain name corresponding to the server room is issued to the client as the target domain name, so that the client establishes a connection with the server according to the target domain name.
  • the preset speed measurement algorithm may be that the domain names corresponding to several server rooms that are close to the client are used as candidate domain names, and the client sends the candidate domain names to the candidate domain names respectively.
  • the server determines the speed of each link according to the receiving and sending time, and then selects the fastest candidate domain name as the target domain name and sends it to the client.
  • the preset speed measurement algorithm may be to use the domain names corresponding to several server rooms close to the client as candidate domain names, and calculate each candidate The number of router nodes in the link corresponding to the domain name, so that the candidate domain name with the least number of router nodes passed is delivered to the client as the target domain name.
  • S220 The client receives the target message pushed by the server through a long connection through the message distributor.
  • the client when it obtains the target domain name issued by the server, it can establish a long connection with the server according to the target domain name, and use the long connection link to receive the target message pushed by the server, which improves the message push efficiency.
  • the client parses the target message through the message distributor, and generates a distribution message according to the message type and message data in the target message.
  • the client informs at least one observer object pre-registered in the message distributor of the distribution message through the message distributor.
  • the client determines a processing method for the distribution message according to the message type in the monitored distribution message through at least one observer object.
  • the technical solution of this embodiment establishes a persistent connection with the server according to the issued target domain name, and uses the persistent connection to receive the target message pushed by the server.
  • the message distributor is used to parse the target message, according to the message in the target message Type and message data to generate a distribution message, and then notify the distribution message to at least one observer object pre-registered in the message atmosphere.
  • at least one observer object determines the processing of the distribution message according to the message type in the monitored distribution message
  • the server is used to dynamically issue the target domain name for the client, and the message pushed by the server is received in a long connection mode, which improves the efficiency of message push, thereby shortening the time of message distribution processing, and improving the efficiency of message distribution processing.
  • it further includes: in the case that the client detects an object destruction instruction matching the target observer object, in the message distributor, destroy the registered target observer object .
  • the target observer object when the target observer object exits, such as when the user closes the target webpage, it means that the target observer object no longer needs to receive the message pushed by the server. At this time, it can be determined that an object destruction instruction matching the target observer object is detected . In order to save memory space and release memory resources, when an object destruction instruction matching the target observer object is detected, the registered target observer object in the message distributor can be removed and destroyed.
  • FIG. 3 is a schematic structural diagram of a message distribution processing apparatus provided in Embodiment 3 of the disclosure.
  • the message distribution processing device provided in this embodiment can be configured in the client.
  • the message distribution processing device includes: a message receiving module 310, a message parsing module 320, a message distribution module 330, and a message processing module 340. Each module is explained.
  • the message receiving module 310 is configured to receive the target message pushed by the server through the message distributor; the message parsing module 320 is configured to parse and process the target message through the message distributor, and according to the message type and message in the target message The data generates a distribution message; the message distribution module 330 is configured to notify the distribution message to at least one observer object of the message distributor through the message distributor; the message processing module 340 is configured to pass at least one observer object according to the design Processing the monitored distribution message in a predetermined processing manner.
  • the message distribution processing apparatus uses the message distributor to receive the target message pushed by the server by setting the message distributor in the client, and parses the target message according to the message type and message data in the target message Generate a distribution message, and then notify the distribution message to at least one observer object in the message distributor, and process the monitored distribution message according to the set processing method through the at least one observer object, and use the separately set message distribution
  • the server completes the message parsing and distribution process in a unified manner, which solves the problem that all objects in the client need to parse each message received, which causes a large amount of memory and reduces the efficiency of message distribution processing, saving Memory resources improve the efficiency of message distribution processing.
  • the message distribution module 330 is configured to notify at least one observer object of the message distributor that matches the message type of the distribution message according to the message type through the message distributor;
  • the message processing module 340 is configured to process the monitored distribution message through at least one observer object.
  • the message distribution module 330 is configured to notify at least one observer object pre-registered in the message distributor of the distribution message through the message distributor; correspondingly, the message processing module 340 is configured to The steps are: determining a processing mode for the distribution message according to the message type in the distribution message monitored by at least one observer object, and processing the distribution message according to the processing mode.
  • the device may further include: a link establishment module configured to establish a persistent connection with the server according to the target domain name issued by the server before receiving the target message pushed by the server through the message distributor; the message receiving module 310 is set It is: receiving the target message pushed by the server through the message distributor using the long connection.
  • a link establishment module configured to establish a persistent connection with the server according to the target domain name issued by the server before receiving the target message pushed by the server through the message distributor
  • the message receiving module 310 is set It is: receiving the target message pushed by the server through the message distributor using the long connection.
  • the device may further include: a request sending module, configured to send the domain name to the server when the client start instruction is detected before establishing a long connection with the server according to the target domain name issued by the server Request; the domain name request is used to instruct the server to use a preset speed measurement algorithm, determine a target domain name matching the client in at least two candidate domain names corresponding to the server, and combine the target domain name Deliver to the client.
  • a request sending module configured to send the domain name to the server when the client start instruction is detected before establishing a long connection with the server according to the target domain name issued by the server Request
  • the domain name request is used to instruct the server to use a preset speed measurement algorithm, determine a target domain name matching the client in at least two candidate domain names corresponding to the server, and combine the target domain name Deliver to the client.
  • the message distributor exposes the protocol method to the outside in advance; the at least one observer object completes the monitoring of the message notified by the message distributor by implementing the protocol method exposed by the message distributor.
  • the mode determining module 340 is configured to verify whether the message type of the distribution message monitored is a preset target monitoring type through at least one observer object; when the message type of the distribution message is the In the case of the preset target monitoring type, the message data in the monitored distribution message is processed, and if the message type of the distribution message is not the preset target monitoring type, the monitoring is discarded Of the distribution message.
  • the device may further include: a target destruction module, configured to: in the message distributor, when the client detects an object destruction instruction matching the target observer object, the registered all The target observer object is destroyed.
  • a target destruction module configured to: in the message distributor, when the client detects an object destruction instruction matching the target observer object, the registered all The target observer object is destroyed.
  • the client includes: an application client adapted to the iOS operating system.
  • the above-mentioned product can execute the method provided by any embodiment of the present disclosure, and has corresponding functional modules and beneficial effects for executing the method.
  • the third embodiment of the present disclosure also provides a message distribution processing device, which is configured in the client and includes: a message distributor and at least one observer object; the message distributor is set to receive the target message pushed by the server; The target message is parsed and processed, and a distribution message is generated according to the message type and message data in the target message; the distribution message is notified to at least one observer object of the message distributor; the at least one observer object is set To process the monitored distribution message according to the set processing mode.
  • a message distribution processing device which is configured in the client and includes: a message distributor and at least one observer object; the message distributor is set to receive the target message pushed by the server; The target message is parsed and processed, and a distribution message is generated according to the message type and message data in the target message; the distribution message is notified to at least one observer object of the message distributor; the at least one observer object is set To process the monitored distribution message according to the set processing mode.
  • FIG. 4 shows a schematic structural diagram of a terminal device 400 suitable for implementing embodiments of the present disclosure.
  • the terminal devices in the embodiments of the present disclosure may include, but are not limited to, mobile phones, notebook computers, digital broadcast receivers, personal digital assistants (Personal Digital Assistant, PDA), tablet computers (PAD), and portable multimedia players (Portable Media Player). , PMP), mobile terminals such as in-vehicle terminals (for example, in-vehicle navigation terminals), and fixed terminals such as digital televisions (Television, TV), desktop computers, etc.
  • PMP Personal Digital Assistant
  • PMP Personal Digital Assistant
  • mobile terminals such as in-vehicle terminals (for example, in-vehicle navigation terminals)
  • fixed terminals such as digital televisions (Television, TV), desktop computers, etc.
  • the terminal device shown in FIG. 4 is only an example, and should not bring any limitation to the function and scope of use of the embodiments of the present disclosure.
  • the terminal device 400 may include a processing device (such as a central processing unit, a graphics processor, etc.) 401, which may be based on a program stored in a read-only memory (Read-Only Memory, ROM) 402 or from a storage device 408 A program loaded into a random access memory (Random Access Memory, RAM) 403 executes various appropriate actions and processes. In the RAM 403, various programs and data required for the operation of the terminal device 400 are also stored.
  • the processing device 401, ROM 402, and RAM 403 are connected to each other through a bus 404.
  • An input/output (Input/Output, I/O) interface 405 is also connected to the bus 404.
  • the following devices can be connected to the I/O interface 405: including input devices 406 such as touch screen, touch panel, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; including, for example, a liquid crystal display (LCD) , Output devices 407 such as speakers, vibrators, etc.; storage devices 408 such as magnetic tapes, hard disks, etc.; and communication devices 409.
  • the communication device 409 may allow the terminal device 400 to perform wireless or wired communication with other devices to exchange data.
  • FIG. 4 shows a terminal device 400 having multiple devices, it is not required to implement or have all the illustrated devices. It may alternatively be implemented or provided with more or fewer devices.
  • the process described above with reference to the flowchart may be implemented as a computer software program.
  • the embodiments of the present disclosure include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart.
  • the computer program may be downloaded and installed from the network through the communication device 409, or installed from the storage device 408, or installed from the ROM 402.
  • the processing device 401 the above-mentioned functions defined in the method of the embodiment of the present disclosure are executed.
  • the aforementioned computer-readable medium in the present disclosure may be a computer-readable signal medium or a computer-readable storage medium or any combination of the two.
  • the computer-readable storage medium may be, for example, but not limited to, an electric, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the above.
  • Examples of computer-readable storage media may include, but are not limited to: electrical connections with one or more wires, portable computer disks, hard disks, RAM, ROM, Erasable Programmable Read-Only Memory (EPROM) Or flash memory), optical fiber, CD-ROM (Compact Disc Read-Only Memory), optical storage device, magnetic storage device, or any suitable combination of the above.
  • a computer-readable storage medium may be any tangible medium that contains or stores a program, and the program may be used by or in combination with an instruction execution system, apparatus, or device.
  • a computer-readable signal medium may include a data signal propagated in a baseband or as a part of a carrier wave, and a computer-readable program code is carried therein. This propagated data signal can take many forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the foregoing.
  • the computer-readable signal medium may also be any computer-readable medium other than the computer-readable storage medium.
  • the computer-readable signal medium may send, propagate, or transmit the program for use by or in combination with the instruction execution system, apparatus, or device .
  • the program code contained on the computer-readable medium can be transmitted by any suitable medium, including but not limited to: wire, optical cable, radio frequency (RF), etc., or any suitable combination of the above.
  • the above-mentioned computer-readable medium may be included in the above-mentioned terminal device; or it may exist alone without being assembled into the terminal device.
  • the above-mentioned computer-readable medium carries one or more programs, and when the above-mentioned one or more programs are executed by the terminal device, the client in the terminal device: receives the target message pushed by the server through the message distributor; The message distributor parses the target message, and generates a distribution message according to the message type and message data in the target message; at least one of the message distributors is notified of the distribution message through the message distributor Observer object; the at least one observer object is used to process the monitored distribution message according to a set processing mode.
  • the computer program code used to perform the operations of the present disclosure may be written in one or more programming languages or a combination thereof.
  • the above-mentioned programming languages include object-oriented programming languages—such as Java, Smalltalk, C++, and also conventional Procedural programming language-such as "C" language or similar programming language.
  • the program code can be executed entirely on the user's computer, partly on the user's computer, executed as an independent software package, partly on the user's computer and partly executed on a remote computer, or entirely executed on the remote computer or server.
  • the remote computer can be connected to the user's computer through any kind of network-including Local Area Network (LAN) or Wide Area Network (WAN)-or it can be connected to an external computer (for example, use an Internet service provider to connect via the Internet).
  • LAN Local Area Network
  • WAN Wide Area Network
  • each block in the flowchart or block diagram can represent a module, program segment, or part of code, and the module, program segment, or part of code contains one or more for realizing the specified logical function Executable instructions.
  • the functions marked in the block may also occur in a different order from the order marked in the drawings. For example, two blocks shown in succession can actually be executed substantially in parallel, or they can sometimes be executed in the reverse order, depending on the functions involved.
  • each block in the block diagram and/or flowchart, and the combination of the blocks in the block diagram and/or flowchart can be implemented by a dedicated hardware-based system that performs the specified functions or operations Or it can be realized by a combination of dedicated hardware and computer instructions.
  • the modules or units involved in the described embodiments of the present disclosure can be implemented in software or hardware.
  • the name of the module or unit does not constitute a limitation on the module or unit itself in one case.
  • the message receiving module can also be described as "a module for receiving target messages pushed by the server through a message distributor" .

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computing Systems (AREA)
  • Quality & Reliability (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mathematical Physics (AREA)
  • Information Transfer Between Computers (AREA)

Abstract

A message distribution processing method, device, equipment and a storage medium. The method comprises: a client receives a target message pushed by a server through a message distributor (S110); the client parses the target message through the message distributor, and generates a distributed message according to the message type and message data in the target message (S120); the client notifies the distributed message to at least one observer object of the message distributor through the message distributor (S130); the client processes the monitored distributed message through the at least one observer object according to a set processing mode (S140).

Description

消息分发处理方法、装置、设备及存储介质Message distribution processing method, device, equipment and storage medium
本申请要求在2019年03月13日提交中国专利局、申请号为201910189864.5的中国专利申请的优先权,该申请的全部内容通过引用结合在本申请中。This application claims the priority of a Chinese patent application filed with the Chinese Patent Office with an application number of 201910189864.5 on March 13, 2019. The entire content of the application is incorporated into this application by reference.
技术领域Technical field
本公开实施例涉及计算机技术,例如涉及一种消息分发处理方法、装置、设备及存储介质。The embodiments of the present disclosure relate to computer technology, for example, to a message distribution processing method, device, device, and storage medium.
背景技术Background technique
应用软件客户端在使用过程中,经常会收到服务器推送的多种消息,以使客户端中相关的对象对接收的消息进行处理。When the application software client is in use, it often receives various messages pushed by the server, so that related objects in the client can process the received messages.
相关技术中,运行在iOS操作系统上的应用客户端在接收到服务器推送的消息时,没有有效的消息分发处理机制,主要依靠客户端中的当前运行的一个或者多个对象进程(例如,界面或者弹窗等)分别对每一个接收的消息进行解析处理,从而确定是否属于本对象进程对应处理的消息,并获取与本对象进程匹配的信息进行处理。In related technologies, when an application client running on the iOS operating system receives a message pushed by the server, it does not have an effective message distribution processing mechanism, and mainly relies on one or more object processes currently running in the client (for example, interface Or a pop-up window, etc.) respectively analyze and process each received message to determine whether it belongs to the message processed by the target process, and obtain information matching the target process for processing.
相关技术方案的缺陷在于,所有对象进程均需要对接收的每条消息进行解析处理,不仅占用大量的内存资源,同时也降低了消息分发处理的效率。The disadvantage of the related technical solutions is that all object processes need to parse and process each message received, which not only takes up a large amount of memory resources, but also reduces the efficiency of message distribution processing.
发明内容Summary of the invention
本公开实施例提供一种消息分发处理方法、装置、设备及存储介质,以实现节约内存资源,提高消息分发处理的效率。The embodiments of the present disclosure provide a message distribution processing method, device, equipment, and storage medium, so as to save memory resources and improve the efficiency of message distribution processing.
本公开实施例提供了一种消息分发处理方法,包括:The embodiment of the present disclosure provides a message distribution processing method, including:
客户端通过消息分发器接收服务器推送的目标消息;The client receives the target message pushed by the server through the message distributor;
所述客户端通过所述消息分发器对所述目标消息进行解析处理,并根据所述目标消息中的消息类型以及消息数据生成分发消息;The client parses the target message through the message distributor, and generates a distribution message according to the message type and message data in the target message;
所述客户端通过所述消息分发器将所述分发消息通知给所述消息分发器的至少一个观察者对象;The client terminal notifies at least one observer object of the message distributor of the distribution message through the message distributor;
所述客户端通过所述至少一个观察者对象按照设定的处理方式对监听到的所述分发消息进行处理。The client uses the at least one observer object to process the monitored distribution message according to a set processing mode.
本公开实施例还提供了一种消息分发处理装置,配置于客户端中,该装置 包括:The embodiment of the present disclosure also provides a message distribution processing device, which is configured in the client, and the device includes:
消息接收模块,设置为通过消息分发器接收服务器推送的目标消息;The message receiving module is set to receive the target message pushed by the server through the message distributor;
消息解析模块,设置为通过所述消息分发器对所述目标消息进行解析处理,并根据所述目标消息中的消息类型以及消息数据生成分发消息;A message parsing module, configured to parse the target message through the message distributor, and generate a distribution message according to the message type and message data in the target message;
消息分发模块,设置为通过所述消息分发器将所述分发消息通知给所述消息分发器的至少一个观察者对象;A message distribution module, configured to notify at least one observer object of the message distributor of the distribution message through the message distributor;
消息处理模块,设置为通过所述至少一个观察者对象按照设定的处理方式对监听到的所述分发消息进行处理。The message processing module is configured to process the monitored distribution message according to the set processing mode through the at least one observer object.
本公开实施例还提供了一种消息分发处理装置,配置于客户端中,该装置包括:消息分发器和至少一个观察者对象;The embodiment of the present disclosure also provides a message distribution processing device, which is configured in a client, and the device includes: a message distributor and at least one observer object;
所述消息分发器设置为接收服务器推送的目标消息;对所述目标消息进行解析处理,并根据所述目标消息中的消息类型以及消息数据生成分发消息;将所述分发消息通知给所述消息分发器的至少一个观察者对象;The message distributor is set to receive the target message pushed by the server; parse the target message, and generate a distribution message according to the message type and message data in the target message; notify the message of the distribution message At least one observer object of the dispatcher;
所述至少一个观察者对象设置为按照设定的处理方式对监听到的所述分发消息进行处理。The at least one observer object is set to process the monitored distribution message according to a set processing mode.
本公开实施例还提供了一种终端设备,该设备包括:The embodiment of the present disclosure also provides a terminal device, which includes:
一个或多个处理装置;One or more processing devices;
存储装置,设置为存储一个或多个程序;Storage device, set to store one or more programs;
当所述一个或多个程序被所述一个或多个处理装置执行,使得所述一个或多个处理装置实现如本公开实施例中任一所述的消息分发处理方法。When the one or more programs are executed by the one or more processing devices, the one or more processing devices implement the message distribution processing method according to any one of the embodiments of the present disclosure.
本公开实施例还提供了一种计算机可读存储介质,其上存储有计算机程序,该程序被处理装置执行时实现如本公开实施例中任一所述的消息分发处理方法。The embodiment of the present disclosure also provides a computer-readable storage medium on which a computer program is stored, and when the program is executed by a processing device, the method for message distribution processing as described in any of the embodiments of the present disclosure is implemented.
附图说明Description of the drawings
图1是本公开实施例一提供的一种消息分发处理方法的流程示意图;FIG. 1 is a schematic flowchart of a message distribution processing method provided by Embodiment 1 of the present disclosure;
图2是本公开实施例二提供的一种消息分发处理方法的流程示意图;2 is a schematic flowchart of a message distribution processing method provided by Embodiment 2 of the present disclosure;
图3是本公开实施例三提供的一种消息分发处理装置的结构示意图;FIG. 3 is a schematic structural diagram of a message distribution processing apparatus provided by Embodiment 3 of the present disclosure;
图4是本公开实施例四提供的一种终端设备的硬件结构示意图。FIG. 4 is a schematic diagram of the hardware structure of a terminal device provided in the fourth embodiment of the present disclosure.
具体实施方式detailed description
下面结合附图和实施例对本公开进行说明。此处所描述的具体实施例仅仅用于解释本公开,而非对本公开的限定。为了便于描述,附图中仅示出了与本公开相关的部分而非全部结构。The present disclosure will be described below with reference to the drawings and embodiments. The specific embodiments described here are only used to explain the present disclosure, but not to limit the present disclosure. For ease of description, only a part of the structure related to the present disclosure is shown in the accompanying drawings instead of all of the structure.
下述实施例中,每个实施例中同时提供了可选特征和示例,实施例中记载的多个特征可进行组合,形成多个可选方案,不应将每个编号的实施例仅视为一个技术方案。In the following embodiments, each embodiment provides optional features and examples at the same time. Multiple features recorded in the embodiments can be combined to form multiple alternative solutions. Each numbered embodiment should not be regarded as It is a technical solution.
实施例一Example one
图1为本公开实施例一提供的一种消息分发处理方法的流程示意图。该方法可适用于客户端对接收的消息进行分发处理的情况,该方法可以由运行应用程序客户端的手机、或者平板电脑等终端设备来执行,包括如下步骤:FIG. 1 is a schematic flowchart of a message distribution processing method according to Embodiment 1 of the present disclosure. This method can be applied to the case where the client distributes the received message. The method can be executed by a terminal device such as a mobile phone or a tablet computer running an application client, and includes the following steps:
S110、客户端通过消息分发器接收服务器推送的目标消息。S110. The client receives the target message pushed by the server through the message distributor.
本实施例中,目标消息可以是服务器向客户端推送的私信、通知等个人信息。由于相关技术中的iOS操作系统中,没有有效的消息分发处理机制,当客户端收到服务器推送的目标消息时,只能依靠客户端中所有的对象(也可称为进程或者实例等)分别对每一个接收的消息进行解析处理,从而确定本对象是否为消息的处理者,这样使得每个对象都需要对每个消息进行重复的解析过程,当同时收到大量推送消息时,会导致客户端占用大量的内存资源,使得客户端的运行变得卡顿,同时,也降低了消息分发处理的效率。In this embodiment, the target message may be personal information such as private messages and notifications pushed by the server to the client. Since the iOS operating system in related technologies does not have an effective message distribution processing mechanism, when the client receives the target message pushed by the server, it can only rely on all the objects (also called processes or instances, etc.) in the client. Analyze each received message to determine whether the object is the processor of the message, so that each object needs to perform a repeated analysis process for each message. When a large number of push messages are received at the same time, it will cause customers The client occupies a large amount of memory resources, which makes the operation of the client stalled, and at the same time, it reduces the efficiency of message distribution processing.
为了解决上述问题,本实施例在客户端中设置消息分发器(MessageDispatcher),专门用于对接收的推送消息进行解析和分发。其中,消息分发器可以是编写在客户端程序中的一条处理线程。当服务器向客户端推送目标消息时,客户端可通过该消息分发器接收该目标消息。In order to solve the above-mentioned problem, in this embodiment, a message dispatcher (MessageDispatcher) is set in the client, which is specifically used to parse and distribute received push messages. Among them, the message distributor can be a processing thread written in the client program. When the server pushes the target message to the client, the client can receive the target message through the message distributor.
本实施例所涉及的客户端可以是指移动应用程序(Application,APP),也可以是指网页端,在此不作限制。The client involved in this embodiment may refer to a mobile application (Application, APP) or a web page, which is not limited here.
可选的,客户端包括:适配于iOS操作系统的应用客户端。也即,本实施例所涉及的客户端可以安装在iOS操作系统中,以弥补iOS操作系统中没有有效的消息分发处理机制的不足,当然,所述客户端还可以为适配于Android操作系统的应用客户端等,本实施例对此并不进行限制。Optionally, the client includes: an application client adapted to the iOS operating system. That is, the client involved in this embodiment can be installed in the iOS operating system to make up for the lack of an effective message distribution processing mechanism in the iOS operating system. Of course, the client can also be adapted to the Android operating system. The application client, etc., this embodiment does not limit this.
S120、客户端通过消息分发器对目标消息进行解析处理,并根据目标消息中的消息类型以及消息数据生成分发消息。S120. The client parses the target message through the message distributor, and generates a distribution message according to the message type and message data in the target message.
本实施例中,客户端在接收到服务器推送的目标消息之后,可利用消息分 发器统一对目标消息进行解析处理。一实施例中,客户端可通过消息分发器将目标消息拆分为或识别为消息数据及其对应的消息类型。In this embodiment, after receiving the target message pushed by the server, the client can use the message distributor to uniformly analyze the target message. In an embodiment, the client can split or recognize the target message into message data and its corresponding message type through the message distributor.
示例性的,可将解析得到的消息数据以及消息类型,按照预设格式生成分发消息,例如,预设格式可以是“消息类型+消息数据”,以便在后续步骤中进行消息处理时,可以直接根据消息类型对分发消息进行识别处理。Exemplarily, the parsed message data and message type can be generated according to a preset format to generate a distribution message. For example, the preset format can be "message type + message data" so that the message can be processed directly in the subsequent steps. Identify the distribution message according to the message type.
S130、客户端通过消息分发器将分发消息通知给消息分发器的至少一个观察者对象。S130. The client informs at least one observer object of the message distributor of the distribution message through the message distributor.
本实施例中,观察者对象可以是本客户端中需要接收分发消息的对象,该对象包括但不限于客户端中的一个网页、一个弹窗等。示例性的,客户端通过消息分发器生成分发消息后,可将该分发消息通知给消息分发器的每一个观察者对象,以便于该观察者对象对推送的消息进行处理。一实施例中,可为每一个观察者对象设置一个监听线程,用于监听消息分发器中生成的分发消息。In this embodiment, the observer object may be an object in the client that needs to receive distribution messages, and the object includes, but is not limited to, a web page, a pop-up window, etc. in the client. Exemplarily, after the client generates a distribution message through the message distributor, it can notify each observer object of the message distributor of the distribution message, so that the observer object can process the pushed message. In an embodiment, a listener thread may be set for each observer object to listen to the distribution message generated in the message distributor.
在一种可选实施方式中,客户端通过消息分发器将分发消息通知给消息分发器的至少一个观察者对象,包括:客户端通过消息分发器,按照消息类型将分发消息通知给与消息类型匹配的消息分发器的至少一个观察者对象。In an optional implementation manner, the client terminal notifies at least one observer object of the message distributor of the distribution message through the message distributor, including: the client terminal notifies the distribution message to the message type according to the message type through the message distributor. At least one observer object of the matched message distributor.
由于不同的观察者对象可以处理的消息类型可能不尽相同,因此,消息分发器可按照消息类型,将分发消息通知给对应的能够处理该消息类型的观察者对象,以便对应的观察者对象对监听到的分发消息直接进行处理。一实施例中,可预先设置消息类型与观察者对象之间的对应关系,消息分发器通过该对应关系可确定将不同消息类型的分发消息通知给对应的观察者对象。Since the types of messages that can be processed by different observer objects may not be the same, the message distributor can notify the corresponding observer object capable of processing the message type according to the message type, so that the corresponding observer object pairs The monitored distribution message is processed directly. In an embodiment, the corresponding relationship between the message type and the observer object can be preset, and the message distributor can determine to notify the corresponding observer object of the distribution messages of different message types through the corresponding relationship.
在另一种可选实施方式中,客户端通过消息分发器将分发消息通知给消息分发器的至少一个观察者对象,包括:客户端通过消息分发器将分发消息通知给在消息分发器中预先注册的至少一个观察者对象。In another optional implementation manner, the client notifies at least one observer object of the message distributor of the distribution message through the message distributor, including: the client notifies the distribution message in the message distributor in advance through the message distributor. At least one observer object registered.
当客户端中的至少一个对象需要接收服务器推送的消息时,可预先在消息分发器中进行注册。举一个实际例子,若检测到用户针对客户端中目标网页的打开操作时,可自动在消息分发器中注册该目标网页,作为观察者对象。同理,若检测到用户针对客户端中目标弹窗的打开操作时,也可自动在消息分发器中注册该目标弹窗,作为另一个观察者对象。When at least one object in the client needs to receive a message pushed by the server, it can be registered in the message distributor in advance. For a practical example, if the user's opening operation for the target webpage in the client is detected, the target webpage can be automatically registered in the message distributor as an observer object. Similarly, if the user's opening operation for the target pop-up window in the client is detected, the target pop-up window can also be automatically registered in the message distributor as another observer object.
由于客户端中对服务器推送的消息感兴趣的对象,均会预先注册在消息分发器中,在消息分发器生成分发消息时,仅注册的观察者对象能够接到分发消息通知,从而可以避免所有对象均无差别的对消息进行监听,减少了对内存资源的浪费,提升了客户端所在设备的性能。Since the objects in the client that are interested in the messages pushed by the server are registered in the message distributor in advance, when the message distributor generates a distribution message, only the registered observer object can receive the distribution message notification, which can avoid all All objects listen to messages indiscriminately, reducing the waste of memory resources and improving the performance of the device where the client is located.
S140、客户端通过至少一个观察者对象按照设定的处理方式对监听到的分 发消息进行处理。S140: The client uses at least one observer object to process the monitored distribution message according to a set processing mode.
由于客户端中不同对象所能够处理的消息可能不同,而观察者对象监听到的分发消息可能只包括自己能够处理的消息,也可能还包括其他消息,此时可按照设定的处理方式,对分发消息进行处理。Since the messages that can be processed by different objects in the client may be different, and the distribution messages monitored by the observer object may only include messages that can be processed by itself, or may also include other messages. In this case, you can follow the set processing method to Distribute messages for processing.
示例性的,当观察者对象监听到分发消息时,可对自己能够处理的消息进行显示或响应,对无法处理的消息进行丢弃等。Exemplarily, when the observer object listens to the distribution message, it can display or respond to the message that it can handle, and discard the message that cannot be processed.
在上述步骤S130中,第一种可选实施方式下,相应的,客户端通过至少一个观察者对象按照设定的处理方式对监听到的分发消息进行处理,包括:客户端通过至少一个观察者对象对监听到的分发消息进行处理。In the above step S130, in the first optional implementation manner, correspondingly, the client uses at least one observer object to process the monitored distribution message according to the set processing mode, including: the client uses at least one observer The object processes the distribution messages that it monitors.
该种情况下,由于观察者对象监听到的分发消息是消息分发器根据消息类型进行通知的消息,因此,观察者对象监听到的分发消息只包括其能够处理的消息,仅需要对该分发消息进行相应的消息处理即可。In this case, because the distribution message monitored by the observer object is a message notified by the message distributor according to the message type, the distribution message monitored by the observer object only includes the messages that it can process, and only the distribution message is required Perform the corresponding message processing.
在上述步骤S130中,第二种可选实施方式下,相应的,客户端通过至少一个观察者对象按照设定的处理方式对监听到的分发消息进行处理,包括:客户端通过至少一个观察者对象根据监听到的分发消息中的消息类型,确定对分发消息的处理方式,根据处理方式对分发消息进行处理。In the above step S130, in the second optional implementation manner, correspondingly, the client uses at least one observer object to process the monitored distribution message according to the set processing mode, including: the client uses at least one observer The object determines the processing mode of the distribution message according to the message type in the monitored distribution message, and processes the distribution message according to the processing mode.
由于观察者对象监听到的分发消息是消息分发器无差别通知的分发消息,因此,当观察者对象通过监听线程监听到消息分发器生成的分发消息时,可根据分发消息中包括的消息类型,对分发消息采取不同的处理方式。Since the distribution message monitored by the observer object is the distribution message for the indiscriminate notification of the message distributor, when the observer object monitors the distribution message generated by the message distributor through the monitoring thread, it can be based on the message type included in the distribution message, Different processing methods are adopted for distributed messages.
例如,当观察者对象为弹窗时,其所能够处理的消息类型可以是通知类型;当观察者对象为网页时,其所能够处理的消息类型可以是私信类型等等。示例性的,对分发消息的处理方式包括但不限于丢弃、显示、响应等,在此不作限定,其中,对分发消息的处理方式可以根据分发消息中的消息类型来决定。For example, when the observer object is a pop-up window, the message type it can process can be the notification type; when the observer object is a web page, the message type it can process can be the private message type, and so on. Exemplarily, the processing method for the distribution message includes but is not limited to discarding, displaying, responding, etc., which are not limited herein, wherein the processing method for the distribution message can be determined according to the message type in the distribution message.
可选的,客户端通过至少一个观察者对象根据监听到的分发消息中的消息类型,确定对分发消息的处理方式,根据处理方式对分发消息进行处理包括:客户端通过至少一个观察者对象验证监听到的分发消息的消息类型是否为预设的目标监听类型;在分发消息的消息类型为预设的目标监听类型的情况下,则对监听到的分发消息中的消息数据进行处理,在分发消息的消息类型不为预设的目标监听类型的情况下,丢弃监听到的分发消息。Optionally, the client determines the processing mode of the distribution message according to the message type in the monitored distribution message through at least one observer object, and processing the distribution message according to the processing mode includes: the client verifies the at least one observer object Whether the message type of the monitored distribution message is the preset target monitoring type; when the message type of the distribution message is the preset target monitoring type, the message data in the monitored distribution message is processed, and the If the message type of the message is not the preset target monitoring type, the distribution message that is monitored is discarded.
本实施例中,由于不同对象所能够处理的消息类型可能不同,因此,不同的观察者对象可对应设置不同的目标监听类型。另外,一个观察者对象能够处理的消息类型可以包括一种或多种,相应的,目标监听类型也包括一种或多种。In this embodiment, since the types of messages that can be processed by different objects may be different, different observer objects can correspondingly set different target listening types. In addition, the message types that can be processed by an observer object can include one or more types, and correspondingly, the target monitoring types also include one or more types.
示例性的,当观察者对象确定监听到的分发消息的消息类型为与其对应预 设的目标监听类型时,则说明该观察者对象为该分发消息的处理者,可对监听到的分发消息中的消息数据进行显示、响应等处理;当观察者对象确定监听到的分发消息的消息类型不属于与其对应预设的目标监听类型时,则说明该观察者对象不是该分发消息的处理者,可直接丢弃该监听到的分发消息。Exemplarily, when the observer object determines that the message type of the monitored distribution message is the preset target monitoring type corresponding to it, it means that the observer object is the processor of the distribution message, and the distribution message can be When the observer object determines that the message type of the monitored distribution message does not belong to the corresponding preset target monitoring type, it means that the observer object is not the processor of the distribution message. Discard the monitored distribution message directly.
本实施例的技术方案,通过在客户端中设置消息分发器,使用消息分发器接收服务器推送的目标消息,并对该目标消息进行解析处理,根据目标消息中的消息类型以及消息数据生成分发消息,然后将该分发消息通知给在消息分发器的至少一个观察者对象,通过该至少一个观察者对象按照设定的处理方式对监听到的分发消息进行处理,利用单独设置的消息分发器统一完成消息的解析和分发过程,解决了相关技术中因客户端内所有对象均需要对接收的每条消息都进行解析处理,而导致内存大量占用、降低消息分发处理效率的问题,节约了内存资源,提高了消息分发处理的效率。In the technical solution of this embodiment, by setting a message distributor in the client, the message distributor is used to receive the target message pushed by the server, and the target message is parsed, and the distribution message is generated according to the message type and message data in the target message , And then notify the distribution message to at least one observer object in the message distributor, and process the monitored distribution message according to the set processing method through the at least one observer object, and use the separate message distributor to complete the process. The message parsing and distribution process solves the problems of related technologies that all objects in the client need to parse each message received, which causes a large amount of memory, reduces the efficiency of message distribution and processing, and saves memory resources. Improve the efficiency of message distribution processing.
在上述实施例的基础上,可选的,消息分发器预先对外暴露协议方法;至少一个观察者对象通过实现消息分发器暴露的协议方法完成对消息分发器所通知的消息的监听。On the basis of the foregoing embodiment, optionally, the message distributor exposes the protocol method to the outside; at least one observer object completes the monitoring of the message notified by the message distributor by implementing the protocol method exposed by the message distributor.
示例性的,可在消息分发器中预先定义一个对外暴露的协议方法,作为消息分发器对外发布分发消息通知的接口,观察者对象可通过调用实现该协议方法,实现对该接口的监听。其中,该协议方法可以是全局的方法,包括用于承载分发消息的参数。Exemplarily, an externally exposed protocol method can be pre-defined in the message distributor as an interface for the message distributor to publish and distribute message notifications, and the observer object can implement the protocol method by calling to monitor the interface. Wherein, the protocol method may be a global method, including parameters used to carry the distribution message.
实施例二Example two
图2为本公开实施例二提供的一种消息分发处理方法的流程示意图。本实施例以上述实施例中可选方案为基础进行说明,提供了可选的消息分发处理方法,客户端在通过消息分发器接收服务器推送的目标消息之前,还包括:客户端根据服务器下发的目标域名与服务器建立长连接。客户端通过消息分发器接收服务器推送的目标消息,包括:客户端通过消息分发器采用长连接接收服务器推送的目标消息。FIG. 2 is a schematic flowchart of a message distribution processing method provided by Embodiment 2 of the disclosure. This embodiment is described on the basis of the optional solutions in the above embodiments, and provides an optional message distribution processing method. Before the client receives the target message pushed by the server through the message distributor, it also includes: the client sends the message according to the server Establish a long connection between the target domain name and the server. The client receives the target message pushed by the server through the message distributor, including: the client receives the target message pushed by the server through the message distributor using a long connection.
本实施例提供的消息分发处理方法包括如下步骤:The message distribution processing method provided in this embodiment includes the following steps:
S210、客户端根据服务器下发的目标域名与服务器建立长连接。S210. The client establishes a persistent connection with the server according to the target domain name issued by the server.
本实施例中,长连接是指在一个连接上可以连续发送多个数据包,在连接保持期间,如果没有数据包发送,需要双方发链路检测包。长连接多用于操作频繁,点对点的通讯,而且连接数不能太多的情况。由于每个传输控制协议(Transmission Control Protocol,TCP)连接都需要三步握手,需要大量时间, 因此,如果每个操作都是短连接,处理速度会大幅度降低,所以每个操作完后都不断开,下次处理时就可以直接发送数据包,不用再重新建立TCP连接。In this embodiment, a long connection means that multiple data packets can be sent continuously on one connection. During the connection maintenance period, if no data packets are sent, both parties need to send link detection packets. Long connections are mostly used for frequent operations, point-to-point communication, and the number of connections cannot be too many. Since each Transmission Control Protocol (TCP) connection requires a three-way handshake, which requires a lot of time, if each operation is a short connection, the processing speed will be greatly reduced, so after each operation is completed On, the data packet can be sent directly during the next processing without re-establishing the TCP connection.
本实施例中,由于客户端在使用过程中,服务器会不断推送消息给客户端,因此,可在客户端与服务器之间建立长连接,以便节约通讯时间,提高消息传输速度。一实施例中,服务器可对应设置有多个域名,服务器在向客户端下发域名时,可选择最适合该客户端的目标域名,以使客户端根据该目标域名与服务器建立长连接。In this embodiment, since the server continuously pushes messages to the client during the use of the client, a long connection can be established between the client and the server, so as to save communication time and increase the message transmission speed. In one embodiment, the server may be correspondingly set with multiple domain names, and when the server delivers the domain name to the client, it can select the most suitable target domain name for the client, so that the client establishes a persistent connection with the server according to the target domain name.
相对于相关技术中为每个客户端配置固定域名以进行服务器连接的方式,本实施例采用动态域名进行服务器连接的有益效果在于,可以根据客户端位置的变化随时选择最优数据传输路径,提高消息推送效率。Compared with the manner in which a fixed domain name is configured for each client for server connection in related technologies, the beneficial effect of adopting a dynamic domain name for server connection in this embodiment is that the optimal data transmission path can be selected at any time according to changes in the location of the client, which improves Message push efficiency.
可选的,客户端在根据服务器下发的目标域名与服务器建立长连接之前,还包括:客户端在检测到客户端启动指令时,向服务器发送域名请求;域名请求用于指示服务器采用预设的测速算法,在服务器对应的至少两个备选域名中确定出与客户端匹配的目标域名,并将目标域名下发至客户端。Optionally, before the client establishes a persistent connection with the server according to the target domain name issued by the server, it also includes: the client sends a domain name request to the server when detecting the client start instruction; the domain name request is used to instruct the server to use the preset The speed measurement algorithm of the server determines the target domain name matching the client from at least two candidate domain names corresponding to the server, and delivers the target domain name to the client.
示例性的,若本实施例中服务器为一个服务器集群,包括多个服务器机房,且服务器机房遍布于不同的地点,一个服务器机房对应于一个域名,为了提高访问速度,服务器可为客户端选择最适合的服务器机房进行连接。当客户端启动时,可检测到客户端启动指令,此时,可向服务器发送域名请求,服务器接收到该域名请求后,可从多个服务器机房中按照预设的测速算法,选取该客户端访问速度最快的服务器机房作为客户端的待连接服务器,并将该服务器机房对应的域名作为目标域名下发给客户端,以使客户端根据该目标域名与服务器建立连接。Exemplarily, if the server in this embodiment is a server cluster, including multiple server rooms, and the server rooms are located in different locations, and one server room corresponds to a domain name, in order to improve the access speed, the server can choose the best for the client. Suitable server room for connection. When the client is started, the client start command can be detected. At this time, it can send a domain name request to the server. After the server receives the domain name request, it can select the client from multiple server rooms according to the preset speed measurement algorithm The server room with the fastest access speed is used as the server to be connected to the client, and the domain name corresponding to the server room is issued to the client as the target domain name, so that the client establishes a connection with the server according to the target domain name.
在本实施例的一种可选实施方式中,预设的测速算法可以是,将与客户端距离较近的几个服务器机房对应的域名作为备选域名,并通过客户端向备选域名分别发送测速数据包,服务器根据收发时间来确定每条链路的速度,从而选择速度最快的备选域名作为目标域名下发给客户端。In an optional implementation of this embodiment, the preset speed measurement algorithm may be that the domain names corresponding to several server rooms that are close to the client are used as candidate domain names, and the client sends the candidate domain names to the candidate domain names respectively. When sending speed measurement data packets, the server determines the speed of each link according to the receiving and sending time, and then selects the fastest candidate domain name as the target domain name and sends it to the client.
一实施例中,在另一种可选实施方式中,预设的测速算法可以是,将与客户端距离较近的几个服务器机房对应的域名作为备选域名,并通过计算每个备选域名对应的链路中路由器节点的个数,从而将所经路由器节点个数最少的备选域名作为目标域名下发给客户端。In an embodiment, in another optional implementation manner, the preset speed measurement algorithm may be to use the domain names corresponding to several server rooms close to the client as candidate domain names, and calculate each candidate The number of router nodes in the link corresponding to the domain name, so that the candidate domain name with the least number of router nodes passed is delivered to the client as the target domain name.
S220、客户端通过消息分发器采用长连接接收服务器推送的目标消息。S220: The client receives the target message pushed by the server through a long connection through the message distributor.
示例性的,当客户端获取到服务器下发的目标域名时,可根据该目标域名与服务器建立长连接,并采用该长连接链路接收服务器推送的目标消息,提高 了消息推送效率。Exemplarily, when the client obtains the target domain name issued by the server, it can establish a long connection with the server according to the target domain name, and use the long connection link to receive the target message pushed by the server, which improves the message push efficiency.
S230、客户端通过消息分发器对目标消息进行解析处理,并根据目标消息中的消息类型以及消息数据生成分发消息。S230. The client parses the target message through the message distributor, and generates a distribution message according to the message type and message data in the target message.
S240、客户端通过消息分发器将分发消息通知给在消息分发器中预先注册的至少一个观察者对象。S240. The client informs at least one observer object pre-registered in the message distributor of the distribution message through the message distributor.
S250、客户端通过至少一个观察者对象根据监听到的分发消息中的消息类型,确定对分发消息的处理方式。S250: The client determines a processing method for the distribution message according to the message type in the monitored distribution message through at least one observer object.
本实施例的技术方案,通过根据下发的目标域名与服务器建立长连接,并采用长连接接收服务器推送的目标消息,之后,使用消息分发器对目标消息进行解析处理,根据目标消息中的消息类型以及消息数据生成分发消息,再将分发消息通知给在消息风气中预先注册的至少一个观察者对象,最后通过至少一个观察者对象根据监听的分发消息中的消息类型,确定对分发消息的处理方式,利用服务器为客户端动态下发目标域名,并采用长连接的方式接收服务器推送的消息,提高了消息推送效率,从而缩短了消息分发处理的时间,提高了消息分发处理的效率。The technical solution of this embodiment establishes a persistent connection with the server according to the issued target domain name, and uses the persistent connection to receive the target message pushed by the server. After that, the message distributor is used to parse the target message, according to the message in the target message Type and message data to generate a distribution message, and then notify the distribution message to at least one observer object pre-registered in the message atmosphere. Finally, at least one observer object determines the processing of the distribution message according to the message type in the monitored distribution message In this way, the server is used to dynamically issue the target domain name for the client, and the message pushed by the server is received in a long connection mode, which improves the efficiency of message push, thereby shortening the time of message distribution processing, and improving the efficiency of message distribution processing.
在上述实施例的基础上,可选的,还包括:在客户端检测到与目标观察者对象匹配的对象销毁指令的情况下,在消息分发器中,将已注册的目标观察者对象进行销毁。On the basis of the foregoing embodiment, optionally, it further includes: in the case that the client detects an object destruction instruction matching the target observer object, in the message distributor, destroy the registered target observer object .
示例性的,当目标观察者对象退出时,例如用户关闭目标网页时,说明该目标观察者对象已无需接收服务器推送的消息,此时,可确定检测到与目标观察者对象匹配的对象销毁指令。为了节约内存空间,释放内存资源,可在检测到与目标观察者对象匹配的对象销毁指令时,将消息分发器中已注册的目标观察者对象进行移除销毁。Exemplarily, when the target observer object exits, such as when the user closes the target webpage, it means that the target observer object no longer needs to receive the message pushed by the server. At this time, it can be determined that an object destruction instruction matching the target observer object is detected . In order to save memory space and release memory resources, when an object destruction instruction matching the target observer object is detected, the registered target observer object in the message distributor can be removed and destroyed.
实施例三Example three
图3为本公开实施例三提供的一种消息分发处理装置的结构示意图。本实施例提供的消息分发处理装置可配置于客户端中,参考图3,该消息分发处理装置包括:消息接收模块310、消息解析模块320、消息分发模块330以及消息处理模块340,下面对每个模块进行说明。FIG. 3 is a schematic structural diagram of a message distribution processing apparatus provided in Embodiment 3 of the disclosure. The message distribution processing device provided in this embodiment can be configured in the client. Referring to FIG. 3, the message distribution processing device includes: a message receiving module 310, a message parsing module 320, a message distribution module 330, and a message processing module 340. Each module is explained.
消息接收模块310,设置为通过消息分发器接收服务器推送的目标消息;消息解析模块320,设置为通过消息分发器对所述目标消息进行解析处理,并根据所述目标消息中的消息类型以及消息数据生成分发消息;消息分发模块330,设置为通过消息分发器将所述分发消息通知给所述消息分发器的至少一个观察者 对象;消息处理模块340,设置为通过至少一个观察者对象按照设定的处理方式对监听到的所述分发消息进行处理。The message receiving module 310 is configured to receive the target message pushed by the server through the message distributor; the message parsing module 320 is configured to parse and process the target message through the message distributor, and according to the message type and message in the target message The data generates a distribution message; the message distribution module 330 is configured to notify the distribution message to at least one observer object of the message distributor through the message distributor; the message processing module 340 is configured to pass at least one observer object according to the design Processing the monitored distribution message in a predetermined processing manner.
本实施例提供的消息分发处理装置,通过在客户端中设置消息分发器,使用消息分发器接收服务器推送的目标消息,并对该目标消息进行解析处理,根据目标消息中的消息类型以及消息数据生成分发消息,然后将该分发消息通知给在消息分发器的至少一个观察者对象,通过该至少一个观察者对象按照设定的处理方式对监听到的分发消息进行处理,利用单独设置的消息分发器统一完成消息的解析和分发过程,解决了相关技术中因客户端内所有对象均需要对接收的每条消息都进行解析处理,而导致内存大量占用、降低消息分发处理效率的问题,节约了内存资源,提高了消息分发处理的效率。The message distribution processing apparatus provided in this embodiment uses the message distributor to receive the target message pushed by the server by setting the message distributor in the client, and parses the target message according to the message type and message data in the target message Generate a distribution message, and then notify the distribution message to at least one observer object in the message distributor, and process the monitored distribution message according to the set processing method through the at least one observer object, and use the separately set message distribution The server completes the message parsing and distribution process in a unified manner, which solves the problem that all objects in the client need to parse each message received, which causes a large amount of memory and reduces the efficiency of message distribution processing, saving Memory resources improve the efficiency of message distribution processing.
可选的,消息分发模块330是设置为:通过所述消息分发器,按照所述消息类型将所述分发消息通知给与所述消息类型匹配的所述消息分发器的至少一个观察者对象;相应的,消息处理模块340是设置为:通过至少一个观察者对象对监听到的所述分发消息进行处理。Optionally, the message distribution module 330 is configured to notify at least one observer object of the message distributor that matches the message type of the distribution message according to the message type through the message distributor; Correspondingly, the message processing module 340 is configured to process the monitored distribution message through at least one observer object.
可选的,消息分发模块330是设置为:通过所述消息分发器将所述分发消息通知给在所述消息分发器中预先注册的至少一个观察者对象;相应的,消息处理模块340是设置为:通过至少一个观察者对象根据监听到的所述分发消息中的消息类型,确定对所述分发消息的处理方式,根据所述处理方式对所述分发消息进行处理。Optionally, the message distribution module 330 is configured to notify at least one observer object pre-registered in the message distributor of the distribution message through the message distributor; correspondingly, the message processing module 340 is configured to The steps are: determining a processing mode for the distribution message according to the message type in the distribution message monitored by at least one observer object, and processing the distribution message according to the processing mode.
可选的,该装置还可以包括:链接建立模块,设置为在通过消息分发器接收服务器推送的目标消息之前,根据服务器下发的目标域名与所述服务器建立长连接;消息接收模块310是设置为:通过消息分发器采用所述长连接接收所述服务器推送的所述目标消息。Optionally, the device may further include: a link establishment module configured to establish a persistent connection with the server according to the target domain name issued by the server before receiving the target message pushed by the server through the message distributor; the message receiving module 310 is set It is: receiving the target message pushed by the server through the message distributor using the long connection.
可选的,该装置还可以包括:请求发送模块,设置为在根据服务器下发的目标域名与所述服务器建立长连接之前,在检测到客户端启动指令的情况下,向所述服务器发送域名请求;所述域名请求用于指示所述服务器采用预设的测速算法,在所述服务器对应的至少两个备选域名中确定出与所述客户端匹配的目标域名,并将所述目标域名下发至所述客户端。Optionally, the device may further include: a request sending module, configured to send the domain name to the server when the client start instruction is detected before establishing a long connection with the server according to the target domain name issued by the server Request; the domain name request is used to instruct the server to use a preset speed measurement algorithm, determine a target domain name matching the client in at least two candidate domain names corresponding to the server, and combine the target domain name Deliver to the client.
可选的,所述消息分发器预先对外暴露协议方法;所述至少一个观察者对象通过实现所述消息分发器暴露的所述协议方法完成对所述消息分发器所通知的消息的监听。Optionally, the message distributor exposes the protocol method to the outside in advance; the at least one observer object completes the monitoring of the message notified by the message distributor by implementing the protocol method exposed by the message distributor.
可选的,方式确定模块340,是设置为:通过至少一个观察者对象验证监听到的所述分发消息的消息类型是否为预设的目标监听类型;在所述分发消息的 消息类型为所述预设的目标监听类型的情况下,对监听到的所述分发消息中的消息数据进行处理,在所述分发消息的消息类型不为所述预设的目标监听类型的情况下,丢弃监听到的所述分发消息。Optionally, the mode determining module 340 is configured to verify whether the message type of the distribution message monitored is a preset target monitoring type through at least one observer object; when the message type of the distribution message is the In the case of the preset target monitoring type, the message data in the monitored distribution message is processed, and if the message type of the distribution message is not the preset target monitoring type, the monitoring is discarded Of the distribution message.
可选的,该装置还可以包括:目标销毁模块,设置为在所述客户端检测到与目标观察者对象匹配的对象销毁指令的情况下,在所述消息分发器中,将已注册的所述目标观察者对象进行销毁。Optionally, the device may further include: a target destruction module, configured to: in the message distributor, when the client detects an object destruction instruction matching the target observer object, the registered all The target observer object is destroyed.
可选的,所述客户端包括:适配于iOS操作系统的应用客户端。Optionally, the client includes: an application client adapted to the iOS operating system.
上述产品可执行本公开任意实施例所提供的方法,具备执行方法相应的功能模块和有益效果。The above-mentioned product can execute the method provided by any embodiment of the present disclosure, and has corresponding functional modules and beneficial effects for executing the method.
本公开实施例三还提供的一种消息分发处理装置,配置于客户端中,包括:消息分发器和至少一个观察者对象;所述消息分发器设置为接收服务器推送的目标消息;对所述目标消息进行解析处理,并根据所述目标消息中的消息类型以及消息数据生成分发消息;将所述分发消息通知给所述消息分发器的至少一个观察者对象;所述至少一个观察者对象设置为按照设定的处理方式对监听到的所述分发消息进行处理。The third embodiment of the present disclosure also provides a message distribution processing device, which is configured in the client and includes: a message distributor and at least one observer object; the message distributor is set to receive the target message pushed by the server; The target message is parsed and processed, and a distribution message is generated according to the message type and message data in the target message; the distribution message is notified to at least one observer object of the message distributor; the at least one observer object is set To process the monitored distribution message according to the set processing mode.
实施例四Example four
下面参考图4,图4示出了适于用来实现本公开实施例的终端设备400的结构示意图。本公开实施例中的终端设备可以包括但不限于诸如移动电话、笔记本电脑、数字广播接收器、个人数字助理(Personal Digital Assistant,PDA)、平板电脑(PAD)、便携式多媒体播放器(Portable Media Player,PMP)、车载终端(例如车载导航终端)等等的移动终端以及诸如数字电视机(Television,TV)、台式计算机等等的固定终端。图4示出的终端设备仅仅是一个示例,不应对本公开实施例的功能和使用范围带来任何限制。Referring now to FIG. 4, FIG. 4 shows a schematic structural diagram of a terminal device 400 suitable for implementing embodiments of the present disclosure. The terminal devices in the embodiments of the present disclosure may include, but are not limited to, mobile phones, notebook computers, digital broadcast receivers, personal digital assistants (Personal Digital Assistant, PDA), tablet computers (PAD), and portable multimedia players (Portable Media Player). , PMP), mobile terminals such as in-vehicle terminals (for example, in-vehicle navigation terminals), and fixed terminals such as digital televisions (Television, TV), desktop computers, etc. The terminal device shown in FIG. 4 is only an example, and should not bring any limitation to the function and scope of use of the embodiments of the present disclosure.
如图4所示,终端设备400可以包括处理装置(例如中央处理器、图形处理器等)401,其可以根据存储在只读存储器(Read-Only Memory,ROM)402中的程序或者从存储装置408加载到随机访问存储器(Random Access Memory,RAM)403中的程序而执行多种适当的动作和处理。在RAM 403中,还存储有终端设备400操作所需的多种程序和数据。处理装置401、ROM 402以及RAM 403通过总线404彼此相连。输入/输出(Input/Output,I/O)接口405也连接至总线404。As shown in FIG. 4, the terminal device 400 may include a processing device (such as a central processing unit, a graphics processor, etc.) 401, which may be based on a program stored in a read-only memory (Read-Only Memory, ROM) 402 or from a storage device 408 A program loaded into a random access memory (Random Access Memory, RAM) 403 executes various appropriate actions and processes. In the RAM 403, various programs and data required for the operation of the terminal device 400 are also stored. The processing device 401, ROM 402, and RAM 403 are connected to each other through a bus 404. An input/output (Input/Output, I/O) interface 405 is also connected to the bus 404.
通常,以下装置可以连接至I/O接口405:包括例如触摸屏、触摸板、键盘、鼠标、摄像头、麦克风、加速度计、陀螺仪等的输入装置406;包括例如液晶显 示器(Liquid Crystal Display,LCD)、扬声器、振动器等的输出装置407;包括例如磁带、硬盘等的存储装置408;以及通信装置409。通信装置409可以允许终端设备400与其他设备进行无线或有线通信以交换数据。虽然图4示出了具有多种装置的终端设备400,并不要求实施或具备所有示出的装置。可以替代地实施或具备更多或更少的装置。Generally, the following devices can be connected to the I/O interface 405: including input devices 406 such as touch screen, touch panel, keyboard, mouse, camera, microphone, accelerometer, gyroscope, etc.; including, for example, a liquid crystal display (LCD) , Output devices 407 such as speakers, vibrators, etc.; storage devices 408 such as magnetic tapes, hard disks, etc.; and communication devices 409. The communication device 409 may allow the terminal device 400 to perform wireless or wired communication with other devices to exchange data. Although FIG. 4 shows a terminal device 400 having multiple devices, it is not required to implement or have all the illustrated devices. It may alternatively be implemented or provided with more or fewer devices.
根据本公开的实施例,上文参考流程图描述的过程可以被实现为计算机软件程序。例如,本公开的实施例包括一种计算机程序产品,其包括承载在计算机可读介质上的计算机程序,该计算机程序包含用于执行流程图所示的方法的程序代码。在这样的实施例中,该计算机程序可以通过通信装置409从网络上被下载和安装,或者从存储装置408被安装,或者从ROM 402被安装。在该计算机程序被处理装置401执行时,执行本公开实施例的方法中限定的上述功能。According to an embodiment of the present disclosure, the process described above with reference to the flowchart may be implemented as a computer software program. For example, the embodiments of the present disclosure include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program contains program code for executing the method shown in the flowchart. In such an embodiment, the computer program may be downloaded and installed from the 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-mentioned functions defined in the method of the embodiment of the present disclosure are executed.
本公开上述的计算机可读介质可以是计算机可读信号介质或者计算机可读存储介质或者是上述两者的任意组合。计算机可读存储介质例如可以是——但不限于——电、磁、光、电磁、红外线、或半导体的系统、装置或器件,或者任意以上的组合。计算机可读存储介质的例子可以包括但不限于:具有一个或多个导线的电连接、便携式计算机磁盘、硬盘、RAM、ROM、可擦式可编程只读存储器(Erasable Programmable Read-Only Memory,EPROM或闪存)、光纤、便携式紧凑磁盘只读存储器(Compact Disc Read-Only Memory,CD-ROM)、光存储器件、磁存储器件、或者上述的任意合适的组合。在本公开中,计算机可读存储介质可以是任何包含或存储程序的有形介质,该程序可以被指令执行系统、装置或者器件使用或者与其结合使用。而在本公开中,计算机可读信号介质可以包括在基带中或者作为载波一部分传播的数据信号,其中承载了计算机可读的程序代码。这种传播的数据信号可以采用多种形式,包括但不限于电磁信号、光信号或上述的任意合适的组合。计算机可读信号介质还可以是计算机可读存储介质以外的任何计算机可读介质,该计算机可读信号介质可以发送、传播或者传输用于由指令执行系统、装置或者器件使用或者与其结合使用的程序。计算机可读介质上包含的程序代码可以用任何适当的介质传输,包括但不限于:电线、光缆、射频(Radio Frequency,RF)等等,或者上述的任意合适的组合。The aforementioned computer-readable medium in the present disclosure may be a computer-readable signal medium or a computer-readable storage medium or any combination of the two. The computer-readable storage medium may be, for example, but not limited to, an electric, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination of the above. Examples of computer-readable storage media may include, but are not limited to: electrical connections with one or more wires, portable computer disks, hard disks, RAM, ROM, Erasable Programmable Read-Only Memory (EPROM) Or flash memory), optical fiber, CD-ROM (Compact Disc Read-Only Memory), optical storage device, magnetic storage device, or any suitable combination of the above. In the present disclosure, a computer-readable storage medium may be any tangible medium that contains or stores a program, and the program may be used by or in combination with an instruction execution system, apparatus, or device. In the present disclosure, a computer-readable signal medium may include a data signal propagated in a baseband or as a part of a carrier wave, and a computer-readable program code is carried therein. This propagated data signal can take many forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the foregoing. The computer-readable signal medium may also be any computer-readable medium other than the computer-readable storage medium. The computer-readable signal medium may send, propagate, or transmit the program for use by or in combination with the instruction execution system, apparatus, or device . The program code contained on the computer-readable medium can be transmitted by any suitable medium, including but not limited to: wire, optical cable, radio frequency (RF), etc., or any suitable combination of the above.
上述计算机可读介质可以是上述终端设备中所包含的;也可以是单独存在,而未装配入该终端设备中。The above-mentioned computer-readable medium may be included in the above-mentioned terminal device; or it may exist alone without being assembled into the terminal device.
上述计算机可读介质承载有一个或者多个程序,当上述一个或者多个程序被该终端设备执行时,使得该终端设备中的客户端:通过消息分发器接收服务器推送的目标消息;通过所述消息分发器对所述目标消息进行解析处理,并根 据所述目标消息中的消息类型以及消息数据生成分发消息;通过所述消息分发器将所述分发消息通知给所述消息分发器的至少一个观察者对象;通过所述至少一个观察者对象按照设定的处理方式对监听到的所述分发消息进行处理。The above-mentioned computer-readable medium carries one or more programs, and when the above-mentioned one or more programs are executed by the terminal device, the client in the terminal device: receives the target message pushed by the server through the message distributor; The message distributor parses the target message, and generates a distribution message according to the message type and message data in the target message; at least one of the message distributors is notified of the distribution message through the message distributor Observer object; the at least one observer object is used to process the monitored distribution message according to a set processing mode.
可以以一种或多种程序设计语言或其组合来编写用于执行本公开的操作的计算机程序代码,上述程序设计语言包括面向对象的程序设计语言—诸如Java、Smalltalk、C++,还包括常规的过程式程序设计语言—诸如“C”语言或类似的程序设计语言。程序代码可以完全地在用户计算机上执行、部分地在用户计算机上执行、作为一个独立的软件包执行、部分在用户计算机上部分在远程计算机上执行、或者完全在远程计算机或服务器上执行。在涉及远程计算机的情形中,远程计算机可以通过任意种类的网络——包括局域网(Local Area Network,LAN)或广域网(Wide Area Network,WAN)—连接到用户计算机,或者,可以连接到外部计算机(例如利用因特网服务提供商来通过因特网连接)。The computer program code used to perform the operations of the present disclosure may be written in one or more programming languages or a combination thereof. The above-mentioned programming languages include object-oriented programming languages—such as Java, Smalltalk, C++, and also conventional Procedural programming language-such as "C" language or similar programming language. The program code can be executed entirely on the user's computer, partly on the user's computer, executed as an independent software package, partly on the user's computer and partly executed on a remote computer, or entirely executed on the remote computer or server. In the case of a remote computer, the remote computer can be connected to the user's computer through any kind of network-including Local Area Network (LAN) or Wide Area Network (WAN)-or it can be connected to an external computer ( For example, use an Internet service provider to connect via the Internet).
附图中的流程图和框图,图示了按照本公开实施例的系统、方法和计算机程序产品的可能实现的体系架构、功能和操作。在这点上,流程图或框图中的每个方框可以代表一个模块、程序段、或代码的一部分,该模块、程序段、或代码的一部分包含一个或多个用于实现规定的逻辑功能的可执行指令。也应当注意,在有些作为替换的实现中,方框中所标注的功能也可以以不同于附图中所标注的顺序发生。例如,两个接连地表示的方框实际上可以基本并行地执行,它们有时也可以按相反的顺序执行,这依所涉及的功能而定。也要注意的是,框图和/或流程图中的每个方框、以及框图和/或流程图中的方框的组合,可以用执行规定的功能或操作的专用的基于硬件的系统来实现,或者可以用专用硬件与计算机指令的组合来实现。The flowcharts and block diagrams in the accompanying drawings illustrate the possible implementation of the system architecture, functions, and operations of the system, method, and computer program product according to the embodiments of the present disclosure. In this regard, each block in the flowchart or block diagram can represent a module, program segment, or part of code, and the module, program segment, or part of code contains one or more for realizing the specified logical function Executable instructions. It should also be noted that, in some alternative implementations, the functions marked in the block may also occur in a different order from the order marked in the drawings. For example, two blocks shown in succession can actually be executed substantially in parallel, or they can sometimes be executed in the reverse order, depending on the functions involved. It should also be noted that each block in the block diagram and/or flowchart, and the combination of the blocks in the block diagram and/or flowchart, can be implemented by a dedicated hardware-based system that performs the specified functions or operations Or it can be realized by a combination of dedicated hardware and computer instructions.
描述于本公开实施例中所涉及到的模块或单元可以通过软件的方式实现,也可以通过硬件的方式来实现。其中,模块或单元的名称在一种情况下并不构成对该模块或单元本身的限定,例如,消息接收模块还可以被描述为“用于通过消息分发器接收服务器推送的目标消息的模块”。The modules or units involved in the described embodiments of the present disclosure can be implemented in software or hardware. Among them, the name of the module or unit does not constitute a limitation on the module or unit itself in one case. For example, the message receiving module can also be described as "a module for receiving target messages pushed by the server through a message distributor" .

Claims (12)

  1. 一种消息分发处理方法,包括:A message distribution processing method, including:
    客户端通过消息分发器接收服务器推送的目标消息;The client receives the target message pushed by the server through the message distributor;
    所述客户端通过所述消息分发器对所述目标消息进行解析处理,并根据所述目标消息中的消息类型以及消息数据生成分发消息;The client parses the target message through the message distributor, and generates a distribution message according to the message type and message data in the target message;
    所述客户端通过所述消息分发器将所述分发消息通知给所述消息分发器的至少一个观察者对象;The client terminal notifies at least one observer object of the message distributor of the distribution message through the message distributor;
    所述客户端通过所述至少一个观察者对象按照设定的处理方式对监听到的所述分发消息进行处理。The client uses the at least one observer object to process the monitored distribution message according to a set processing mode.
  2. 根据权利要求1所述的方法,其中,所述客户端通过所述消息分发器将所述分发消息通知给所述消息分发器的至少一个观察者对象,包括:The method according to claim 1, wherein the client notifying the distribution message to at least one observer object of the message distributor through the message distributor comprises:
    所述客户端通过所述消息分发器,按照所述消息类型将所述分发消息通知给与所述消息类型匹配的所述消息分发器的至少一个观察者对象;The client, through the message distributor, notifies at least one observer object of the message distributor matching the message type of the distribution message according to the message type;
    所述客户端通过所述至少一个观察者对象按照设定的处理方式对监听到的所述分发消息进行处理,包括:The client processing the monitored distribution message according to the set processing mode through the at least one observer object includes:
    所述客户端通过所述至少一个观察者对象对监听到的所述分发消息进行处理。The client uses the at least one observer object to process the monitored distribution message.
  3. 根据权利要求1所述的方法,其中,所述客户端通过所述消息分发器将所述分发消息通知给所述消息分发器的至少一个观察者对象,包括:The method according to claim 1, wherein the client notifying the distribution message to at least one observer object of the message distributor through the message distributor comprises:
    所述客户端通过所述消息分发器将所述分发消息通知给在所述消息分发器中预先注册的至少一个观察者对象;The client informs at least one observer object pre-registered in the message distributor of the distribution message through the message distributor;
    所述客户端通过所述至少一个观察者对象按照设定的处理方式对监听到的所述分发消息进行处理,包括:The client processing the monitored distribution message according to the set processing mode through the at least one observer object includes:
    所述客户端通过所述至少一个观察者对象根据监听到的所述分发消息中的消息类型,确定对所述分发消息的处理方式,根据所述处理方式对所述分发消息进行处理。The client determines a processing mode for the distribution message according to the monitored message type in the distribution message through the at least one observer object, and processes the distribution message according to the processing mode.
  4. 根据权利要求1所述的方法,在所述客户端在通过消息分发器接收服务器推送的目标消息之前,还包括:The method according to claim 1, before the client receives the target message pushed by the server through the message distributor, further comprising:
    所述客户端根据所述服务器下发的目标域名与所述服务器建立长连接;The client establishes a persistent connection with the server according to the target domain name issued by the server;
    所述客户端通过消息分发器接收服务器推送的目标消息,包括:The client receiving the target message pushed by the server through the message distributor includes:
    所述客户端通过所述消息分发器采用所述长连接接收所述服务器推送的所述目标消息。The client receives the target message pushed by the server through the message distributor using the long connection.
  5. 根据权利要求4所述的方法,在所述客户端根据所述服务器下发的目标域名与所述服务器建立长连接之前,还包括:The method according to claim 4, before the client establishes a persistent connection with the server according to the target domain name issued by the server, further comprising:
    所述客户端在检测到客户端启动指令的情况下,向所述服务器发送域名请求;The client sends a domain name request to the server when the client start instruction is detected;
    所述域名请求用于指示所述服务器采用预设的测速算法,在所述服务器对应的至少两个备选域名中确定出与所述客户端匹配的目标域名,并将所述目标域名下发至所述客户端。The domain name request is used to instruct the server to adopt a preset speed measurement algorithm, determine a target domain name matching the client from at least two candidate domain names corresponding to the server, and deliver the target domain name To the client.
  6. 根据权利要求1-5任一项所述的方法,还包括:The method according to any one of claims 1-5, further comprising:
    所述客户端通过所述消息分发器预先对外暴露协议方法;The client terminal exposes the protocol method to the outside in advance through the message distributor;
    所述客户端通过所述至少一个观察者对象实现所述消息分发器暴露的所述协议方法完成对所述消息分发器所通知的消息的监听。The client implements the protocol method exposed by the message distributor through the at least one observer object to complete the monitoring of the message notified by the message distributor.
  7. 根据权利要求3所述的方法,其中,所述客户端通过所述至少一个观察者对象根据监听到的所述分发消息中的消息类型,确定对所述分发消息的处理方式,根据所述处理方式对所述分发消息进行处理包括:The method according to claim 3, wherein the client determines the processing mode for the distribution message according to the message type in the distribution message monitored by the at least one observer object, and according to the processing Ways to process the distribution message include:
    所述客户端通过所述至少一个观察者对象验证监听到的所述分发消息的消息类型是否为预设的目标监听类型;The client verifies whether the message type of the distribution message monitored by the at least one observer object is a preset target monitoring type;
    在所述分发消息的消息类型为所述预设的目标监听类型的情况下,对监听到的所述分发消息中的消息数据进行处理;In the case that the message type of the distribution message is the preset target monitoring type, processing the message data in the monitored distribution message;
    在所述分发消息的消息类型不为所述预设的目标监听类型的情况下,丢弃监听到的所述分发消息。In the case that the message type of the distribution message is not the preset target monitoring type, discard the monitored distribution message.
  8. 根据权利要求1-5任一项所述的方法,还包括:The method according to any one of claims 1-5, further comprising:
    在所述客户端检测到与目标观察者对象匹配的对象销毁指令的情况下,在所述消息分发器中,将已注册的所述目标观察者对象进行销毁。In the case that the client detects an object destruction instruction that matches the target observer object, in the message distributor, the registered target observer object is destroyed.
  9. 一种消息分发处理装置,配置于客户端中,包括:A message distribution processing device, configured in a client, includes:
    消息接收模块,设置为通过消息分发器接收服务器推送的目标消息;The message receiving module is set to receive the target message pushed by the server through the message distributor;
    消息解析模块,设置为通过所述消息分发器对所述目标消息进行解析处理,并根据所述目标消息中的消息类型以及消息数据生成分发消息;A message parsing module, configured to parse the target message through the message distributor, and generate a distribution message according to the message type and message data in the target message;
    消息分发模块,设置为通过所述消息分发器将所述分发消息通知给所述消息分发器的至少一个观察者对象;A message distribution module, configured to notify at least one observer object of the message distributor of the distribution message through the message distributor;
    消息处理模块,设置为通过所述至少一个观察者对象按照设定的处理方式对监听到的所述分发消息进行处理。The message processing module is configured to process the monitored distribution message according to the set processing mode through the at least one observer object.
  10. 一种消息分发处理装置,配置于客户端中,包括:消息分发器和至少一个观察者对象;A message distribution processing device, configured in a client, includes: a message distributor and at least one observer object;
    所述消息分发器设置为接收服务器推送的目标消息;对所述目标消息进行解析处理,并根据所述目标消息中的消息类型以及消息数据生成分发消息;将所述分发消息通知给所述消息分发器的至少一个观察者对象;The message distributor is set to receive the target message pushed by the server; parse the target message, and generate a distribution message according to the message type and message data in the target message; notify the message of the distribution message At least one observer object of the dispatcher;
    所述至少一个观察者对象设置为按照设定的处理方式对监听到的所述分发消息进行处理。The at least one observer object is set to process the monitored distribution message according to a set processing mode.
  11. 一种终端设备,包括:A terminal device, including:
    一个或多个处理装置;One or more processing devices;
    存储装置,设置为存储一个或多个程序;Storage device, set to store one or more programs;
    当所述一个或多个程序被所述一个或多个处理装置执行,使得所述一个或多个处理装置实现如权利要求1-8中任一所述的消息分发处理方法。When the one or more programs are executed by the one or more processing devices, the one or more processing devices implement the message distribution processing method according to any one of claims 1-8.
  12. 一种计算机可读存储介质,存储有计算机程序,所述程序被处理装置执行时实现如权利要求1-8中任一所述的消息分发处理方法。A computer-readable storage medium storing a computer program, which when executed by a processing device, realizes the message distribution processing method according to any one of claims 1-8.
PCT/CN2020/070692 2019-03-13 2020-01-07 Message distribution processing method, device, equipment, and storage medium WO2020181913A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910189864.5A CN111694674B (en) 2019-03-13 2019-03-13 Message distribution processing method, device, equipment and storage medium
CN201910189864.5 2019-03-13

Publications (1)

Publication Number Publication Date
WO2020181913A1 true WO2020181913A1 (en) 2020-09-17

Family

ID=72427136

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/070692 WO2020181913A1 (en) 2019-03-13 2020-01-07 Message distribution processing method, device, equipment, and storage medium

Country Status (2)

Country Link
CN (1) CN111694674B (en)
WO (1) WO2020181913A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113132489A (en) * 2021-04-22 2021-07-16 中国工商银行股份有限公司 Method, device, computing equipment and medium for downloading file

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113312189A (en) * 2021-03-26 2021-08-27 统信软件技术有限公司 Message processing method, computing device and storage medium
CN113050922A (en) * 2021-03-31 2021-06-29 深圳追一科技有限公司 Customer service message processing method, system, device and readable storage medium
CN113254839B (en) * 2021-06-18 2021-09-28 每日互动股份有限公司 Layer-by-layer message distribution method, electronic client and medium
CN113852667A (en) * 2021-08-27 2021-12-28 青岛海尔科技有限公司 Message pushing method and device, storage medium and electronic device
CN114003471B (en) * 2022-01-04 2022-04-08 深圳市明源云科技有限公司 Page loading analysis method and device and readable storage medium
CN114500535A (en) * 2022-01-21 2022-05-13 北京百度网讯科技有限公司 Message processing method and device, electronic equipment and storage medium
CN116662040B (en) * 2023-07-28 2023-09-29 百家云集团有限公司 Message distribution method and device, electronic equipment and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050165834A1 (en) * 2001-06-08 2005-07-28 Nadeau Thomas D. Method and apparatus for controlled access of requests from virtual private network devices to managed information objects using simple network management protocol and multi-topology routing
US7099947B1 (en) * 2001-06-08 2006-08-29 Cisco Technology, Inc. Method and apparatus providing controlled access of requests from virtual private network devices to managed information objects using simple network management protocol
CN106648570A (en) * 2015-11-03 2017-05-10 深圳市中兴微电子技术有限公司 Multi-task display processing method and device for mobile terminal
CN107659664A (en) * 2017-10-30 2018-02-02 珠海格力电器股份有限公司 A kind of method for message transmission, apparatus and system
CN108023808A (en) * 2017-12-07 2018-05-11 深圳乐信软件技术有限公司 message distributing method and device in application program

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8630624B2 (en) * 2009-02-25 2014-01-14 Apple Inc. Managing notification messages
CN101925021B (en) * 2009-06-11 2014-03-19 中兴通讯股份有限公司 Method/system for processing messages and convergence service system
CN101917525A (en) * 2010-09-15 2010-12-15 烽火通信科技股份有限公司 Method and device for processing notification message tasks in presence service
CN102591658B (en) * 2011-12-28 2016-07-06 北京奇虎科技有限公司 A kind of message treatment method and device
CN108156205B (en) * 2016-12-06 2021-01-22 阿里巴巴(中国)有限公司 Message pushing method, client, server and programmable device
CN106933686A (en) * 2017-03-10 2017-07-07 广东欧珀移动通信有限公司 A kind of method for adjusting broadcast message queue, device and terminal
CN108833950B (en) * 2018-06-29 2021-05-28 武汉斗鱼网络科技有限公司 Barrage message issuing method, server, system and storage medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20050165834A1 (en) * 2001-06-08 2005-07-28 Nadeau Thomas D. Method and apparatus for controlled access of requests from virtual private network devices to managed information objects using simple network management protocol and multi-topology routing
US7099947B1 (en) * 2001-06-08 2006-08-29 Cisco Technology, Inc. Method and apparatus providing controlled access of requests from virtual private network devices to managed information objects using simple network management protocol
CN106648570A (en) * 2015-11-03 2017-05-10 深圳市中兴微电子技术有限公司 Multi-task display processing method and device for mobile terminal
CN107659664A (en) * 2017-10-30 2018-02-02 珠海格力电器股份有限公司 A kind of method for message transmission, apparatus and system
CN108023808A (en) * 2017-12-07 2018-05-11 深圳乐信软件技术有限公司 message distributing method and device in application program

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113132489A (en) * 2021-04-22 2021-07-16 中国工商银行股份有限公司 Method, device, computing equipment and medium for downloading file

Also Published As

Publication number Publication date
CN111694674B (en) 2023-08-08
CN111694674A (en) 2020-09-22

Similar Documents

Publication Publication Date Title
WO2020181913A1 (en) Message distribution processing method, device, equipment, and storage medium
CN109152095B (en) Wireless network connection method for terminal
US11924298B2 (en) Message pushing method for a virtual gift and electronic device
CN110166791B (en) Connection establishing method, device, equipment and storage medium
JP7494311B2 (en) INTERACTION METHOD, DEVICE AND ELECTRONIC DEVICE
WO2020135776A1 (en) Interaction data transmission method, device, terminal and server
US11057475B2 (en) Methods, apparatus and systems for resuming transmission link
US20230124149A1 (en) Method and apparatus for establishing multimedia call, and electronic device
JP7377366B2 (en) Multicast service transmission method, transmission processing method, and related equipment
US20240022661A1 (en) Suppressing indications of events in user interfaces
WO2023000888A1 (en) Cloud application implementing method and apparatus, electronic device, and storage medium
CN115297164A (en) Network proxy method, device, electronic equipment and computer readable storage medium
CN112887420B (en) Message pushing method and device, computer readable storage medium and electronic equipment
WO2021147466A1 (en) Message processing method and apparatus, and electronic device
US20140095604A1 (en) Managing an electronic conference session
WO2013159492A1 (en) Method and system for reporting and downloading information
CN109981778B (en) Method, device, equipment and storage medium for realizing service of content distribution network
WO2022143857A1 (en) Video call method and apparatus, and electronic device and storage medium
CN113839828A (en) Network quality detection method, device, terminal equipment and medium
WO2023130845A1 (en) Communication method and apparatus, and computer-readable storage medium, electronic device and program product
CN111142740A (en) Data updating method, device and storage medium
CN116394958B (en) Driving function switching method, driving function switching device, electronic device and computer readable medium
WO2023131109A1 (en) Method and apparatus for registering broadcast
WO2024045877A1 (en) Device connection method and apparatus, and electronic device and storage medium
WO2023241686A1 (en) Live stream interactive connection method, apparatus, electronic device, storage medium, and program product

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 20770408

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205A DATED 210122)

122 Ep: pct application non-entry in european phase

Ref document number: 20770408

Country of ref document: EP

Kind code of ref document: A1