CN113485857A - Message processing method and device, electronic equipment and storage medium - Google Patents

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

Info

Publication number
CN113485857A
CN113485857A CN202111041338.8A CN202111041338A CN113485857A CN 113485857 A CN113485857 A CN 113485857A CN 202111041338 A CN202111041338 A CN 202111041338A CN 113485857 A CN113485857 A CN 113485857A
Authority
CN
China
Prior art keywords
message
service module
unread
new message
signal
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202111041338.8A
Other languages
Chinese (zh)
Other versions
CN113485857B (en
Inventor
李太友
任魁伟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tianjin Zhongxin Zhiguan Information Technology Co ltd
Original Assignee
Tianjin Zhongxin Zhiguan Information Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Tianjin Zhongxin Zhiguan Information Technology Co ltd filed Critical Tianjin Zhongxin Zhiguan Information Technology Co ltd
Priority to CN202111041338.8A priority Critical patent/CN113485857B/en
Publication of CN113485857A publication Critical patent/CN113485857A/en
Application granted granted Critical
Publication of CN113485857B publication Critical patent/CN113485857B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

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
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/54Indexing scheme relating to G06F9/54
    • G06F2209/541Client-server
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2209/00Indexing scheme relating to G06F9/00
    • G06F2209/54Indexing scheme relating to G06F9/54
    • G06F2209/548Queue

Abstract

The invention provides a message processing method, a message processing device, electronic equipment and a storage medium, which are applied to a server side, wherein the method comprises the following steps: receiving a new message signal sent by a service module in a target application; generating a data updating certificate of the business module according to the new message signal; determining an update value of the unread message number of the service module according to the data update certificate and the current value of the unread message number of the service module; and sending the updated value of the number of the unread messages to the client of the target application so as to display the updated value of the number of the unread messages at a preset position of the client. Embodiments of the present application provide a message processing method, an apparatus, an electronic device, and a storage medium, so as to reduce the complexity of an application program for processing an unread message and improve the accuracy of unread message statistics on the application program.

Description

Message processing method and device, electronic equipment and storage medium
Technical Field
The present invention relates to the field of information processing technologies, and in particular, to a message processing method and apparatus, an electronic device, and a storage medium.
Background
With the development of mobile internet technology, the variety of the application program is more and more, and the functions are more and more abundant. Currently, for an application installed in an electronic device, if an unread message exists in the application, a corner mark of the unread message is displayed on the application to remind a user to perform processing.
Typical applications are further divided into private and public locations. The private position is a service interface corresponding to different levels of service modules in the application program; the public position is a preset position of a display interface of the application program.
In the existing message processing technology, each service module of an application program calculates the number of unread messages, and on this basis, the application program needs to add the number of unread messages of each service module to obtain the final total number of unread messages, and display the total number of unread messages to the preset position of the display interface of the application program. On one hand, for the application program, the number of unread messages of the service module needs to be acquired for many times, and the operation is complicated; on the other hand, if the message counts of the same service module are statistically displayed at different positions of the page, the unread messages may be repeatedly calculated, and the total number of the unread messages of the application program obtained finally is inaccurate.
Disclosure of Invention
The invention aims to provide a message processing method, a message processing device, electronic equipment and a storage medium, so as to reduce the complexity of an application program in processing unread messages and improve the accuracy of unread message statistics of the application program.
In a first aspect, an embodiment of the present invention provides a message processing method, which is applied to a server, and the method includes: receiving a new message signal sent by a service module in a target application; the new message signal comprises a new message generation signal or a new message reading signal; generating a data updating certificate of the business module according to the new message signal; the data updating certificate is used for adjusting the number of unread messages of the service module; determining an update value of the unread message number of the service module according to the data update certificate and the current value of the unread message number of the service module; and sending the updated value of the number of the unread messages to the client of the target application so as to display the updated value of the number of the unread messages at a preset position of the client.
With reference to the first aspect, an embodiment of the present invention provides a first possible implementation manner of the first aspect, where the new message signal is a new message generation signal; the new message generation signal is sent by the service module by means of a message queue or hypertext transfer.
With reference to the first aspect, an embodiment of the present invention provides a second possible implementation manner of the first aspect, where the step of generating a data update credential of the service module according to the new message signal includes: acquiring the message state of the new message corresponding to the new message generation signal; the message status is read or unread; if the message state is unread, generating a first data updating certificate according to a preset display position code of the service module; each first data updating certificate is used for indicating that an operation is added to the number of the unread messages of the service module.
With reference to the first aspect, an embodiment of the present invention provides a third possible implementation manner of the first aspect, where the step of determining an updated value of the unread message count of the service module according to the data update credential and the current value of the unread message count of the service module includes: calculating the update value of the unread message number of the service module by the following formula: n is a radical ofUpdating=NAt present+NFirst of all(ii) a In the formula, NFirst of allRepresenting the number of said first data update credentials, NAt presentCurrent value, N, representing the number of unread messages of the service moduleUpdatingAn updated value representing the number of unread messages for the traffic module.
With reference to the first aspect, an embodiment of the present invention provides a fourth possible implementation manner of the first aspect, where the new message signal is a new message read signal; the new message reading signal is sent by the service module when the message state change of the new message is detected to be read.
With reference to the first aspect, an embodiment of the present invention provides a fifth possible implementation manner of the first aspect, where the step of generating a data update credential of the service module according to the new message signal includes: judging whether the number of the first data updating vouchers corresponding to the service module is zero, if so, generating a second data updating voucher according to the preset display position code of the service module; and each second data updating certificate is used for indicating that the unread message number of the service module is reduced by one.
With reference to the first aspect, an embodiment of the present invention provides a sixth possible implementation manner of the first aspect, where the step of determining an updated value of the unread message count of the service module according to the data update credential and the current value of the unread message count of the service module includes: calculating the update value of the unread message number of the service module by the following formula: n is a radical ofUpdating=NAt present-NSecond one(ii) a In the formula, NSecond oneRepresenting the number of said second data update credentials, NAt presentCurrent value, N, representing the number of unread messages of the service moduleUpdatingAn updated value representing the number of unread messages for the traffic module.
In a second aspect, the present embodiment provides a message processing apparatus, applied to a server, the apparatus including: the message acquisition module is used for receiving a new message signal sent by a service module in the target application; the new message signal comprises a new message generation signal or a new message reading signal; the message processing module is used for generating a data updating certificate of the business module according to the new message signal; the data updating certificate is used for adjusting the number of unread messages of the service module; the message updating module is used for determining an updating value of the unread message number of the service module according to the data updating certificate and the current value of the unread message number of the service module; and the message display module is used for sending the updated value of the unread message number to the client of the target application so as to display the updated value of the unread message number at the preset position of the client.
In a third aspect, an embodiment of the present invention further provides an electronic device, where the electronic device includes a processor and a memory, where the memory stores computer-executable instructions that can be executed by the processor, and the processor executes the computer-executable instructions to implement the message processing method according to any one of the first to sixth possible implementation manners of the first aspect.
In a fourth aspect, the present invention further provides a computer-readable storage medium, in which a computer program is stored, where the computer program, when executed by a processor, implements the steps of the message processing method according to any one of the first to sixth possible implementation manners of the first aspect.
The embodiment of the invention has the following beneficial effects:
the invention provides a message processing method, a message processing device, electronic equipment and a storage medium, which are applied to a server side, wherein the method comprises the following steps: receiving a new message signal sent by a service module in a target application; generating a data updating certificate of the business module according to the new message signal; determining an update value of the unread message number of the service module according to the data update certificate and the current value of the unread message number of the service module; and sending the updated value of the number of the unread messages to the client of the target application so as to display the updated value of the number of the unread messages at a preset position of the client. The embodiment of the application aims to provide a message processing method, a message processing device and electronic equipment, so as to reduce the complexity of an application program in processing unread messages and improve the accuracy of unread message statistics of the application program.
Additional features and advantages of the present disclosure will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by practice of the above-described techniques of the present disclosure.
In order to make the aforementioned objects, features and advantages of the present disclosure more comprehensible, preferred embodiments accompanied with figures are described in detail below.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and other drawings can be obtained by those skilled in the art without creative efforts.
Fig. 1 is a schematic flowchart of a message processing method according to an embodiment of the present invention;
FIG. 2 is a diagram illustrating an unread message according to an embodiment of the present invention;
FIG. 3 is a flow chart illustrating another message processing method according to an embodiment of the present invention;
FIG. 4 is a schematic diagram illustrating a first data update credential generation method according to an embodiment of the present invention;
FIG. 5 is a diagram illustrating a second data update credential generation method according to an embodiment of the present invention;
fig. 6 is a schematic diagram of a location encoding processing method of a client according to the embodiment of the present invention;
FIG. 7 is a schematic diagram of a message program according to an embodiment of the present invention;
FIG. 8 is a diagram of a message processing apparatus according to an embodiment of the present invention;
fig. 9 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Icon: 801-a message acquisition module; 802-a message processing module; 803-a message update module; 804-a message display module; 90-an electronic device; 91-a memory; 92-a processor; 93-a bus; 94-communication interface.
Detailed Description
To make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is apparent that the described embodiments are some, but not all embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
In the existing message processing technology, first, each service module of an application program calculates the number of unread messages, and on this basis, the application program needs to add the number of unread messages of each service module to obtain a final total number of unread messages, and display the total number of unread messages to a preset position of a display interface of the application program. On one hand, for the application program, the number of unread messages of the service module needs to be acquired for many times, and the operation is complicated; on the other hand, if the message counts of the same service module are statistically displayed at different positions of the page, the unread messages may be repeatedly calculated, and the total number of the unread messages of the application program obtained finally is inaccurate.
Based on this, embodiments of the present invention provide a message processing method, an apparatus, and an electronic device, which may alleviate the above technical problems, and may reduce complexity of an application program in processing an unread message and improve accuracy of unread message statistics on the application program. For facilitating understanding of the embodiment of the present invention, a detailed description will be first given of a message processing method disclosed in the embodiment of the present invention.
Example 1
Fig. 1 is a schematic flow chart of a message processing method according to an embodiment of the present invention, where the method is applied to a server.
As seen in fig. 1, the method comprises the steps of:
step S101, receiving a new message signal sent by a service module in a target application; the new message signal includes a new message generation signal or a new message reading signal.
In this embodiment, a digital service program is installed in advance on the server, so that when the server runs a service program of a target application, the server also runs the digital service program; the number of the target applications may be plural. The method is applied to a server, wherein a digital service program and a service program of a target application are operated on the server, and the target application comprises at least one business module. The target application at least comprises one business module, and usually, the target application comprises a plurality of business modules, wherein the business module is a module for realizing business functions in the target application, and preferably comprises an instant chat business module, a mail transceiving business module, an approval business module, a report business module and the like.
Typically, when the new message signals a new message, the service module will automatically signal the digital service program with information, and at the same time, the number of new message signals will be displayed on the service interface of the service module.
Step S102: generating a data updating certificate of the business module according to the new message signal; the data updating certificate is used for adjusting the number of unread messages of the service module.
In this embodiment, first, in the process of generating the data update voucher of the service module according to the new message signal, because the new message signal includes a new message generation signal or a new message reading signal, in general, when the new message signal is a message generation signal, the data update voucher of the service module is generated as a data accumulation voucher, and when there are different service modules and messages corresponding to message generation information sent by the different service modules are the same, the number of the data accumulation voucher is 1; and when the new message signal is a message reading signal, generating a data updating certificate of the service module as a data subtraction certificate. Secondly, the data accumulation certificate and the data accumulation certificate are both used for adjusting the unread message number of the service module. Finally, the service module may display the adjusted unread message number on a service interface corresponding to the service module.
Step S103: and determining an updating value of the unread message number of the service module according to the data updating certificate and the current value of the unread message number of the service module.
For easy understanding, fig. 2 provides a schematic diagram of displaying an unread message by the existing message processing method according to the present embodiment of the present invention, as shown in fig. 2, the target application corresponds to the service module a and the service module B, when the service module a and the service module B receive the same unread message, the service module a and the service module B need to calculate the number of the unread messages respectively, then send the number of the unread messages to the target application, and perform calculation again in the target application, and calculate the total number of the unread messages to be 2, and the service module a and the service module B receive the same unread message, it is obvious that the existing message processing method has a phenomenon of repeated calculation when displaying the unread message, and a preset position of a display interface of the target application should display 1 instead of 2.
In this application, the digital service program generates the data update certificate of the service module and the current value of the unread message number of the service module through the step S102, and the update value of the unread message of the service module can be obtained through calculation. For example: the data updating voucher is a data accumulation voucher, the number of the data accumulation vouchers is 1, the current value of the unread message number is 1, and the update value of the unread message number of the service module is determined to be 2. When the target application includes a plurality of business modules, the digital service program generates a data update certificate of each business module and a current value of the number of unread messages of each business module through the above step S102, and an update value of the unread messages of the target application can be determined through calculation. For example: when the target application comprises 2 service modules (a service module 1 and a service module 2), each data updating certificate is an accumulated certificate, the number of the data accumulated certificates is 1, the current value of the number of the unread messages is 1, the update value of the number of the unread messages of the service module 1 can be determined to be 2, the update value of the number of the unread messages of the service module 2 is 2, and then the update value of the final number of the unread messages of the target application can be determined to be 4. It is understood that the updated value of the final unread message number of the target application may be determined by the summation of the digital service program, or may be determined by the summation of the updated values of the unread messages of the service modules sent by the digital service program, and is not limited herein.
According to the method and the device, the data updating certificate of the corresponding service module is generated according to the new message signal, the new message exists only, and then the updating value of the unread message number of the service module is determined according to the data updating certificate and the current value of the unread message number of the service module, so that the repeated calculation of the unread message by the target application is avoided. Moreover, in the present application, the process of determining the update value of the number of unread messages of the service module is performed in the digital service program, and each service module is not required to perform respective calculation on the respective unread messages, so that the complexity of processing the unread messages by the application program is reduced, and the accuracy of the unread message statistics of the application program is improved.
Furthermore, for the development of the business module, the business module does not need to design a corresponding unread message number calculation program, so the time to be developed and the labor cost of the business module are reduced.
Step S104: and sending the updated value of the number of the unread messages to the client of the target application so as to display the updated value of the number of the unread messages at the preset position of the client.
Here, the server is connected with a client, and the updated value of the number of unread messages is sent to the client of the target application through the digital service program, so that the updated value of the number of unread messages is displayed at a preset position of the client. Wherein, the client includes but not limited to: computer PC end, cell phone and other electronic equipment with communication function.
The message processing method provided by the embodiment of the invention is applied to a server side, and comprises the following steps: receiving a new message signal sent by a business module in a target application through the digital service program; generating a data updating certificate of the business module according to the new message signal; determining an update value of the unread message number of the service module according to the data update certificate and the current value of the unread message number of the service module; and sending the updated value of the number of the unread messages to the client of the target application so as to display the updated value of the number of the unread messages at a preset position of the client. The method reduces the complexity of the application program for processing the unread messages and improves the accuracy of the unread message statistics of the application program.
Example 2
On the basis of the method shown in fig. 1, the invention also provides another message processing method, which is applied to the server. Fig. 3 is a schematic flow chart of another message processing method according to an embodiment of the present invention, and as shown in fig. 3, the method includes the following steps:
step S301: the new message generation signal is sent by the service module by means of a message queue or hypertext transfer.
In this embodiment, the new message signal is a new message generation signal. When the service module receives a new message, the message generation signal is sent to the digital service program by means of message queue or hypertext transmission.
In another embodiment, when the service module receives a new message, the message generation signal may also be sent directly to the digital service program.
Step S302: receiving a new message signal sent by the service module in the target application; the new message signal includes a new message generation signal or a new message reading signal.
Step S303: generating a data updating certificate of the business module according to the new message signal; the data updating certificate is used for adjusting the number of unread messages of the service module.
In one embodiment, the data update voucher for the service module is generated from the new message signal by the following steps a1-a 2.
Step a 1: acquiring the message state of the new message corresponding to the new message generation signal; the message status is read or unread.
Here, the same message is edited in the middle of the time, so that the message versions corresponding to different time nodes may be different, and when the new message version corresponding to the new message reading signal is the message of the latest version received by the service module, the message state is read; the new message signal is a new message reading signal; the new message reading signal is sent by the service module when the message state change of the new message is detected to be read.
When the new message version corresponding to the new message reading signal is the message of the early version received by the service module, the message state is unread; the new message signal is a new message generation signal; the new message generation signal is sent by the service module when the message state change of the new message is detected as unread.
Step a 2: if the message state is unread, generating a first data updating certificate according to a preset display position code of the service module; each first data updating certificate is used for indicating that an operation is added to the number of the unread messages of the service module.
In actual operation, in order to clarify the position of the service module, the display position of the service module is encoded in advance. For example: a mailing plate block which is encoded according to a preset display position of the mailing plate block to generate preset display position codes 1004, 1004_001, and 1004_001_ 001; then, a first data update voucher corresponding to the preset display position codes 1004, 1004_001 and 1004_001_001 is generated based on the preset display position codes.
The private position and the public position are divided by the target application. The private position is a service interface corresponding to different levels of service modules in the application program; the public position is a preset position of a display interface of the application program. Therefore, when the business module corresponding to the private location generates the first data update certificate, the preset location of the display interface of the target application also generates the first data update certificate. For convenience of understanding, fig. 4 provides a schematic diagram of a generation manner of a first data update certificate according to an embodiment of the present invention, and as shown in fig. 4, when a business module corresponding to the private location P003 generates the first data update certificate, the public location F001 of the target application also generates the first data update certificate.
In one implementation manner, whether the number of first data update certificates corresponding to the service module is zero is judged, and if yes, a second data update certificate is generated according to a preset display position code of the service module; and each second data updating certificate is used for indicating that the unread message number of the service module is reduced by one. For convenience of understanding, fig. 5 provides a schematic diagram of a generation manner of a second data update certificate according to an embodiment of the present invention, and as shown in fig. 5, when a business module corresponding to the private location P003 generates the second data update certificate, the public location F001 of the target application also generates the second data update certificate.
Step S304: and determining an updating value of the unread message number of the service module according to the data updating certificate and the current value of the unread message number of the service module.
In one embodiment, when the new message signal is a new message generation signal, the step of determining an updated value of the number of unread messages of the service module according to the data update certificate and the current value of the number of unread messages of the service module includes:
calculating the update value of the unread message number of the service module by the following formula:
Nupdating=NAt present+NFirst of all
In the formula, NFirst of allRepresenting the number of the first data update voucher, NAt presentCurrent value, N, representing the number of unread messages of the service moduleUpdatingAn updated value representing the number of unread messages for the service module.
In another embodiment, whether the number of the first data updating certificates corresponding to the service module is zero is judged, and if yes, a second data updating certificate is generated according to a preset display position code of the service module; each second data updating certificate is used for indicating that the unread message number of the service module is reduced by one; then, the updated value of the number of unread messages of the service module is calculated by the following formula:
Nupdating=NAt present-NSecond one
In the formula, NSecond oneIndicating the number of the second data update voucher, NAt presentCurrent value, N, representing the number of unread messages of the service moduleUpdatingAn updated value representing the number of unread messages for the service module.
Step S305: and sending the updated value of the number of the unread messages to the client of the target application so as to display the updated value of the number of the unread messages at a preset position of the client.
In this embodiment, in order to clarify the preset position of the client, the preset position of the client is encoded in advance to generate the preset position code of the client. And then displaying the updated value of the number of the unread messages based on the preset position code of the client. Further, the preset position code of the client can be added or deleted. For convenience of understanding, fig. 6 is a schematic diagram of a location encoding processing method of the client according to the embodiment of the present invention. As seen in FIG. 6, the message Pcode001 is displayed according to the position codes of positions S1, S2, and S3, and may also add position code S4 or delete position code S2, or add position code S4 and delete position code S2.
Further, fig. 7 provides a schematic diagram of a message program according to an embodiment of the present invention. As shown in fig. 7, the service module 01, the service module 02, and the service module 03 respectively send new message signals to the digital service program in a message queue manner or respectively send new message signals to the digital service program, and the digital service program pushes update value information of the unread message number to the client of the target application, so as to display the update value of the unread message number in a form of a digital corner mark at a preset position of the client.
The message processing method provided by the embodiment of the invention is applied to a server side, and comprises the following steps: the new message generating signal is sent by the service module through a message queue or a hypertext transmission mode; receiving a new message signal sent by a service module in a target application; generating a data updating certificate of the business module according to the new message signal; determining an update value of the unread message number of the service module according to the data update certificate and the current value of the unread message number of the service module; and sending the updated value of the number of the unread messages to the client of the target application so as to display the updated value of the number of the unread messages at a preset position of the client. The method sends the new message generating signal to the digital service program by the service module in a message queue or hypertext transmission mode, and further improves the speed of processing the unread message by the application program.
Example 3
An embodiment of the present invention further provides a message processing apparatus connected to a server, as shown in fig. 8, and a schematic diagram of the message processing apparatus is provided for the embodiment of the present invention, where the schematic diagram includes:
a message acquiring module 801, configured to receive a new message signal sent by a service module in a target application; the new message signal comprises a new message generation signal or a new message reading signal;
a message processing module 802, configured to generate a data update credential of the service module according to the new message signal; the data updating certificate is used for adjusting the number of unread messages of the service module;
a message updating module 803, configured to determine an updated value of the unread message number of the service module according to the data update certificate and the current value of the unread message number of the service module;
a message display module 804, configured to send the updated value of the number of unread messages to the client of the target application, so as to display the updated value of the number of unread messages at a preset location of the client.
The message acquiring module 801, the message processing module 802, the message updating module 803, and the message displaying module 804 are connected in sequence.
In one possible embodiment, the new message signal generates a signal for a new message; the message acquiring module 801 is further configured to send the new message generation signal by the service module through a message queue or a hypertext transfer mode.
In one possible implementation manner, the message processing module 802 is further configured to obtain a message status of a new message corresponding to the new message generation signal; the message status is read or unread; if the message state is unread, generating a first data updating certificate according to a preset display position code of the service module; each first data updating certificate is used for indicating that an operation is added to the number of the unread messages of the service module.
In one possible implementation, the message update module 803 is further configured to calculate an update value of the number of unread messages of the service module by using the following formula: n is a radical ofUpdating=NAt present+NFirst of all(ii) a In the formula, NFirst of allRepresenting the number of the first data update voucher, NAt presentCurrent value, N, representing the number of unread messages of the service moduleUpdatingAn updated value representing the number of unread messages for the service module.
In one possible embodiment, the new message signal is a new message read signal; the message acquiring module 801 is further configured to send the new message reading signal when the service module detects that the message status of the new message is changed to read.
In one possible implementation manner, the message processing module 802 is further configured to determine whether the number of the first data update credentials corresponding to the service module is zero, and if so, generate a second data update credential according to a preset display position code of the service module; and each second data updating certificate is used for indicating that the unread message number of the service module is reduced by one.
In one possible implementation, the message update module 803 is further configured to calculate an update value of the number of unread messages of the service module by using the following formula: n is a radical ofUpdating=NAt present-NSecond one(ii) a In the formula, NSecond oneIndicating the number of the second data update voucher, NAt presentCurrent value, N, representing the number of unread messages of the service moduleUpdatingAn updated value representing the number of unread messages for the service module.
The message processing device provided by the embodiment of the invention has the same technical characteristics as the message processing method provided by the embodiment, so that the same technical problems can be solved, and the same technical effects can be achieved. It is clear to those skilled in the art that, for convenience and brevity of description, the specific working process of the apparatus described above may refer to the corresponding process in the foregoing method embodiment, and is not described herein again.
Example 4
The present embodiments provide an electronic device comprising a processor and a memory, the memory storing computer-executable instructions capable of being executed by the processor, the processor executing the computer-executable instructions to implement the steps of the message processing method.
The present embodiment provides a computer-readable storage medium in which a computer program is stored which, when being executed by a processor, implements the steps of the message processing method.
Referring to a schematic structural diagram of an electronic device shown in fig. 9, the electronic device 90 includes: the message processing method comprises a memory 91 and a processor 92, wherein a computer program capable of running on the processor 92 is stored in the memory 91, and the steps provided by the message processing method are realized when the processor executes the computer program.
As shown in fig. 9, the electronic apparatus further includes: a bus 93 and a communication interface 94, the processor 92, the communication interface 94 and the memory 91 being connected by the bus 93; the processor 92 is adapted to execute executable modules, such as computer programs, stored in the memory 91.
The Memory 91 may include a high-speed Random Access Memory (RAM) and may further include a non-volatile Memory (non-volatile Memory), such as at least one disk Memory. The communication connection between the network element of the system and at least one other network element is realized through at least one communication interface 94 (which may be wired or wireless), and the internet, a wide area network, a local network, a metropolitan area network, and the like can be used.
The bus 93 may be an ISA bus, PCI bus, EISA bus, or the like. The bus may be divided into an address bus, a data bus, a control bus, etc. For ease of illustration, only one double-headed arrow is shown in FIG. 9, but this does not indicate only one bus or one type of bus.
The memory 91 is used for storing a program, and the processor 92 executes the program after receiving an execution instruction, and the method executed by the message processing apparatus according to any of the embodiments of the present invention may be applied to the processor 92, or implemented by the processor 92. The processor 92 may be an integrated circuit chip having signal processing capabilities. In implementation, the steps of the above method may be performed by instructions in the form of hardware, integrated logic circuits, or software in the processor 92. The Processor 92 may be a general-purpose Processor, and includes a Central Processing Unit (CPU), a Network Processor (NP), and the like; the device can also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA), or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components. The various methods, steps and logic blocks disclosed in the embodiments of the present invention may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of the method disclosed in connection with the embodiments of the present invention may be directly implemented by a hardware decoding processor, or implemented by a combination of hardware and software modules in the decoding processor. The software module may be located in ram, flash memory, rom, prom, or eprom, registers, etc. storage media as is well known in the art. The storage medium is located in the memory 91, and the processor 92 reads the information in the memory 91 and performs the steps of the above method in combination with the hardware thereof.
Further, embodiments of the present invention also provide a machine-readable storage medium storing machine-executable instructions that, when invoked and executed by the processor 92, cause the processor 92 to implement the message processing method described above.
The electronic device and the computer-readable storage medium provided by the embodiment of the invention have the same technical characteristics, so the same technical problems can be solved, and the same technical effects can be achieved.
In addition, in the description of the embodiments of the present invention, unless otherwise explicitly specified or limited, the terms "mounted," "connected," and "connected" are to be construed broadly, e.g., as meaning either a fixed connection, a removable connection, or an integral connection; can be mechanically or electrically connected; they may be connected directly or indirectly through intervening media, or they may be interconnected between two elements. The specific meanings of the above terms in the present invention can be understood in specific cases to those skilled in the art.
In the description of the present invention, it should be noted that the terms "center", "upper", "lower", "left", "right", "vertical", "horizontal", "inner", "outer", etc., indicate orientations or positional relationships based on the orientations or positional relationships shown in the drawings, and are only for convenience of description and simplicity of description, but do not indicate or imply that the device or element being referred to must have a particular orientation, be constructed and operated in a particular orientation, and thus, should not be construed as limiting the present invention. Furthermore, the terms "first," "second," and "third" are used for descriptive purposes only and are not to be construed as indicating or implying relative importance.

Claims (10)

1. A message processing method is applied to a server side, and is characterized in that the method comprises the following steps:
receiving a new message signal sent by a service module in a target application; the new message signal comprises a new message generation signal or a new message reading signal;
generating a data updating certificate of the business module according to the new message signal; the data updating voucher is used for adjusting the number of unread messages of the service module;
determining an update value of the unread message number of the service module according to the data update certificate and the current value of the unread message number of the service module;
and sending the updated value of the number of the unread messages to a client of the target application so as to display the updated value of the number of the unread messages at a preset position of the client.
2. The message processing method of claim 1, wherein the new message signal is a new message generation signal;
the new message generating signal is sent by the service module by means of a message queue or hypertext transfer.
3. The message processing method according to claim 2, wherein the step of generating the data update certificate of the service module according to the new message signal comprises:
acquiring the message state of the new message corresponding to the new message generation signal; the message state is read or unread;
if the message state is unread, generating a first data updating certificate according to a preset display position code of the service module; and each first data updating certificate is used for indicating that the unread message number of the service module is added by one.
4. The message processing method according to claim 3, wherein the step of determining the updated value of the unread messages of the service module according to the data update voucher and the current value of the unread messages of the service module comprises:
calculating an updated value of the number of unread messages of the service module by the following formula:
Nupdating=NAt present+NFirst of all
In the formula, NFirst of allRepresenting the number of said first data update credentials, NAt presentCurrent value, N, representing the number of unread messages of the service moduleUpdatingAn updated value representing the number of unread messages for the traffic module.
5. The message processing method according to claim 1, wherein the new message signal is a new message read signal;
the new message reading signal is sent by the service module when the message state change of the new message is detected to be read.
6. The message processing method according to claim 5, wherein the step of generating the data update certificate of the service module according to the new message signal comprises:
judging whether the number of first data updating vouchers corresponding to the business module is zero, if so, generating second data updating vouchers according to preset display position codes of the business module; and each second data updating certificate is used for indicating that the unread message number of the service module is reduced by one.
7. The message processing method according to claim 6, wherein the step of determining the updated value of the unread messages of the service module according to the data update voucher and the current value of the unread messages of the service module comprises:
calculating an updated value of the number of unread messages of the service module by the following formula:
Nupdating=NAt present-NSecond one
In the formula, NSecond oneRepresenting the number of said second data update credentials, NAt presentCurrent value, N, representing the number of unread messages of the service moduleUpdatingAn updated value representing the number of unread messages for the traffic module.
8. A message processing apparatus connected to a server, the apparatus comprising:
the message acquisition module is used for receiving a new message signal sent by a service module in the target application; the new message signal comprises a new message generation signal or a new message reading signal;
the message processing module is used for generating a data updating certificate of the business module according to the new message signal; the data updating voucher is used for adjusting the number of unread messages of the service module;
the message updating module is used for determining an updating value of the unread message number of the service module according to the data updating certificate and the current value of the unread message number of the service module;
and the message display module is used for sending the updated value of the unread message number to the client of the target application so as to display the updated value of the unread message number at the preset position of the client.
9. An electronic device, comprising a processor and a memory, the memory storing computer-executable instructions executable by the processor, the processor executing the computer-executable instructions to implement the message processing method of any of claims 1 to 7.
10. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, carries out the steps of the message processing method according to any one of claims 1 to 7.
CN202111041338.8A 2021-09-07 2021-09-07 Message processing method and device, electronic equipment and storage medium Active CN113485857B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111041338.8A CN113485857B (en) 2021-09-07 2021-09-07 Message processing method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111041338.8A CN113485857B (en) 2021-09-07 2021-09-07 Message processing method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN113485857A true CN113485857A (en) 2021-10-08
CN113485857B CN113485857B (en) 2021-12-21

Family

ID=77947231

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111041338.8A Active CN113485857B (en) 2021-09-07 2021-09-07 Message processing method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113485857B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115022274A (en) * 2022-08-04 2022-09-06 广州此声网络科技有限公司 Unread message quantity statistical method and device, computer equipment and storage medium

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1220130A2 (en) * 2000-12-14 2002-07-03 Readingvillage. Com, Inc. Method for enabling non-readers to communicate with electronic messages
CN102857638A (en) * 2012-09-14 2013-01-02 东莞宇龙通信科技有限公司 Mobile terminal message prompting method and system for implementing same
CN103870464A (en) * 2012-12-10 2014-06-18 腾讯科技(北京)有限公司 Unread message processing method, display method and device
CN106844404A (en) * 2015-12-07 2017-06-13 腾讯科技(深圳)有限公司 Message display method and terminal device
CN107294908A (en) * 2016-03-30 2017-10-24 阿里巴巴集团控股有限公司 Account information processing method, apparatus and system in instant messaging application
CN109766036A (en) * 2018-12-24 2019-05-17 华为终端有限公司 Message treatment method and electronic equipment
CN110324233A (en) * 2019-05-23 2019-10-11 平安科技(深圳)有限公司 Unread message footmark reminding method, device, equipment and storage medium
CN111432067A (en) * 2020-03-03 2020-07-17 上海掌门科技有限公司 Unread message number processing method, unread message number processing device, unread message number processing equipment and unread message number processing medium

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1220130A2 (en) * 2000-12-14 2002-07-03 Readingvillage. Com, Inc. Method for enabling non-readers to communicate with electronic messages
CN102857638A (en) * 2012-09-14 2013-01-02 东莞宇龙通信科技有限公司 Mobile terminal message prompting method and system for implementing same
CN103870464A (en) * 2012-12-10 2014-06-18 腾讯科技(北京)有限公司 Unread message processing method, display method and device
CN106844404A (en) * 2015-12-07 2017-06-13 腾讯科技(深圳)有限公司 Message display method and terminal device
CN107294908A (en) * 2016-03-30 2017-10-24 阿里巴巴集团控股有限公司 Account information processing method, apparatus and system in instant messaging application
CN109766036A (en) * 2018-12-24 2019-05-17 华为终端有限公司 Message treatment method and electronic equipment
CN110324233A (en) * 2019-05-23 2019-10-11 平安科技(深圳)有限公司 Unread message footmark reminding method, device, equipment and storage medium
CN111432067A (en) * 2020-03-03 2020-07-17 上海掌门科技有限公司 Unread message number processing method, unread message number processing device, unread message number processing equipment and unread message number processing medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115022274A (en) * 2022-08-04 2022-09-06 广州此声网络科技有限公司 Unread message quantity statistical method and device, computer equipment and storage medium

Also Published As

Publication number Publication date
CN113485857B (en) 2021-12-21

Similar Documents

Publication Publication Date Title
CN113485857B (en) Message processing method and device, electronic equipment and storage medium
CN108833126B (en) Electronic device, data link risk early warning method and storage medium
CN109002424B (en) File format conversion method and device, computer equipment and storage medium
CN110634054B (en) Fixed-point vehicle returning method and device and electronic equipment
WO2016041171A1 (en) Method and apparatus for determining terminal roaming status, terminal and server
CN114629856A (en) Congestion control method and device, electronic equipment and readable storage medium
CN111669720B (en) Method and device for processing charging message
CN105210349B (en) Radio communication quality information processing meanss and communication system
CN110445658B (en) Message processing method and system
CN104780117A (en) Network congestion information obtaining method and device
CN102333291A (en) SMS (short message service) processing method and device
CN108400901B (en) Application testing method, terminal device and computer readable storage medium
CN117014379A (en) Code rate control method, device, electronic equipment and storage medium
CN108306865B (en) Modbus packet-sticking processing method and device based on Netty framework
CN115965296A (en) Assessment data processing method, device, equipment, product and readable storage medium
JP6925889B2 (en) Relay device, transmission processing program
WO2021073413A1 (en) Method and apparatus for sending system performance parameters, management device, and storage medium
CN114661587A (en) System testing method and device and electronic equipment
CN106878155B (en) Method, system and mobile terminal for short message delay notification
CN109194734B (en) Message pushing method and device, server and readable storage medium
CN111641959A (en) Method and device for detecting network environment information
CN114650511B (en) Short message service processing method, device and system
CN113676894A (en) Service processing method and device
CN108243446B (en) Network communication problem judgment processing method and device
CN110430118B (en) Bill mail managing method, apparatus, computer device and computer readable storage medium

Legal Events

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