WO2012167473A1 - Method for setting message status and converged internet protocol message (cpm) traffic server - Google Patents

Method for setting message status and converged internet protocol message (cpm) traffic server Download PDF

Info

Publication number
WO2012167473A1
WO2012167473A1 PCT/CN2011/077068 CN2011077068W WO2012167473A1 WO 2012167473 A1 WO2012167473 A1 WO 2012167473A1 CN 2011077068 W CN2011077068 W CN 2011077068W WO 2012167473 A1 WO2012167473 A1 WO 2012167473A1
Authority
WO
WIPO (PCT)
Prior art keywords
message
cpm
user terminal
storage server
read
Prior art date
Application number
PCT/CN2011/077068
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 华为技术有限公司
Priority to CN201180001340.0A priority Critical patent/CN102986173B/en
Priority to PCT/CN2011/077068 priority patent/WO2012167473A1/en
Publication of WO2012167473A1 publication Critical patent/WO2012167473A1/en

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L51/00User-to-user messaging in packet-switching networks, transmitted according to store-and-forward or real-time protocols, e.g. e-mail
    • H04L51/56Unified messaging, e.g. interactions between e-mail, instant messaging or converged IP messaging [CPM]

Definitions

  • the embodiments of the present invention relate to communication technologies, and in particular, to a message state setting method and a CPM service server. Background technique
  • OMA Open Mobile Alliance
  • IM Instant Message
  • IP Internet Protocol
  • Mobile data service specifications such as Converged Internet Protocol Message (CPM).
  • CPM Converged Internet Protocol Message
  • the OMA CPM specification provides users with a variety of media types (text, picture, voice, video) for message delivery, session establishment, and network storage.
  • the CPM standard defines two servers: CPM service server and CPM storage server. Users also have two clients: Session Initiated Protocol (SIP)-based CPM client and Internet Message Access Protocol (Internet Message Access Protocol). , referred to as IMAP) client, the two are not necessarily online at the same time.
  • SIP Session Initiated Protocol
  • IMAP Internet Message Access Protocol
  • the CPM service server sends a message to the terminal and/or the CPM message storage server according to user settings and the like.
  • IMAP clients are only online when the terminal synchronizes with the CPM message store server and stores messages to the CPM message store server.
  • the CPM service server when a message arrives at the CPM service server, the CPM service server sends a message to the terminal and/or the CPM message storage server according to user settings and the like. Due to the difference in user terminal performance and user settings, the CPM service server does not send all messages to the user terminal, nor does it store all messages to the CPM storage server. In the case that the CPM service server simultaneously sends the received message to the CPM storage server and the user terminal, if the read status of the message is stored in the CPM storage server, The read status of the message stored in the CPM storage server may be inconsistent with the status of the user terminal regarding the message. Summary of the invention
  • the embodiment of the invention provides a message state setting method and a CPM service server, which are used to solve
  • the reading status of the message stored in the CPM storage server is inconsistent with the user terminal's read status of the message.
  • An aspect of the present invention provides a method for setting a message state, including:
  • Receiving a message determining that the message needs to be submitted to a storage server, sending a message storage request including the message to the storage server; determining that the message needs to be sent to a user terminal, and sending the message to the user terminal;
  • An aspect of the present invention provides a CPM service server, including:
  • a receiving module configured to receive a message
  • a message storage requesting module configured to determine that the message needs to be submitted to a CPM storage server storage, and send a message storage request including the message to the CPM storage server
  • a sending module configured to determine that the message needs to be sent to a user terminal, and send the message to the user terminal;
  • the receiving module is further configured to receive a receiving response returned by the user terminal, and the state modifying requesting module is configured to receive a receiving response returned by the user terminal, and determine that the CPM storage server stores a response corresponding to the receiving response. And determining, according to the receiving response, that a read status of the message corresponding to the received response is read, and storing the service to the CPM
  • the device sends a message state modification request, and the read state of the message in the message state modification request is read.
  • One aspect of the present invention provides a message state setting method and a CPM service server.
  • the CPM service server determines that a new message needs to be submitted to the CPM storage server, the message is sent to the CPM storage server. After the CPM storage server receives the message that does not indicate the read status, the CPM storage server defaults that the read status of the message is unread. If the CPM service server needs to send the message to the user terminal, if the read status of the message determined according to the receiving response returned by the user terminal is read, the CPM service server sends a message status modification request to the CPM storage server. Modifying the read status of the message in the CPM storage server according to the receiving response request returned by the user terminal.
  • the read status of the message stored in the CPM storage server is consistent with the receiving status of the message by the user terminal.
  • the CPM storage server can be prevented from transmitting a message that the user terminal has successfully received to the user terminal, which saves resources. It also avoids the user terminal repeatedly receiving the read message and improving the user experience.
  • Another aspect of the present invention provides another method for setting a message state, including:
  • Receiving a message determining that the message needs to be submitted to the CPM storage server and transmitting the message to the user terminal, identifying a read status of the message as read; sending a message storage request to the CPM storage server, and reporting to The user terminal sends the message; the message storage request includes the message and the read status of the message; receiving the received response returned by the user terminal, and determining the message according to the received response returned by the user terminal
  • the read status is unread, and a message status modification request is sent to the CPM storage server, and the read status of the message in the message status modification request is unread.
  • Another aspect of the present invention provides another CPM service server, including:
  • a receiving module configured to receive a message
  • a determining module configured to determine that the message needs to be submitted to the CPM storage server, and needs to send the message to the user terminal, and identify a read status of the message as a read message storage request module, Sending a message storage request to the CPM storage server, where the message storage request includes the message and a read status of the message
  • a module configured to send the message to the user terminal
  • the receiving module is further configured to receive a receiving response returned by the user terminal, and a state modification requesting module, configured to determine, according to the receiving response returned by the user terminal, The read status of the message corresponding to the received response is unread, and the message status modification request is sent to the CPM storage server, where the read status of the message is unread.
  • Another message state setting method and a CPM service server provided by another aspect of the present invention, when the CPM service server needs to submit the message to the CPM storage server and needs to send the message to the user terminal, the CPM service server will The read status is identified as read, and the read status of the message carried when the server message storage request is stored to the CPM is read, causing the CPM storage server to store the read status of the message. And the CPM service server sends a message state modification request to the CPM storage server according to the read state of the message determined by the receiving response returned by the user terminal, according to the read state of the message in the message storage request, according to the user terminal The returned receive response request modifies the read status of the message in the CPM storage server. Thus, the read status of the message stored in the CPM storage server is consistent with the read status of the message by the user terminal.
  • Another aspect of the present invention provides a method for setting a message state, including:
  • Receiving a message determining that the message needs to be submitted to a CPM storage server for storage, buffering the message; determining that the message needs to be sent to a user terminal, transmitting the message to the user terminal, and receiving a receiving response returned by the user terminal Determining that a message corresponding to the received response is buffered, identifying a read status of the cached message corresponding to the received response according to the received response returned by the user terminal; and transmitting a message storage request to the CPM storage server,
  • the message storage request includes the cached messages and the read status of each message.
  • CPM service server including:
  • a receiving module configured to receive a message
  • a cache module configured to determine that the message needs to be submitted to a CPM storage server, and to cache the message
  • a sending module configured to determine that the message needs to be sent to the user terminal, to the user terminal Sending the message
  • receiving module for receiving a receiving response returned by the user terminal
  • a status identifying module configured to determine that a message corresponding to the received response is cached, and to identify a read status of the cached message corresponding to the received response according to the received response returned by the user terminal
  • a message storage requesting module configured to send a message storage request to the CPM storage server, where the message storage request includes the cached message and a corresponding read state of each message.
  • a message state setting method and a CPM service server After receiving a message, the CPM service server first caches a message that needs to be submitted to the CPM storage server, and the message that needs to be sent to the user terminal for the cache, CPM The service server identifies the read status of each cached message according to the received response returned by the user terminal. The CPM service server sends the cached messages and their read status to the CPM storage server for storage. Therefore, for messages that need to be submitted to the CPM storage server store and that need to be sent to the user terminal at the same time, the read status of the message stored in the CPM storage server is consistent with the read status of the message by the user terminal.
  • Embodiment 1 is a flowchart of Embodiment 1 of a message state setting method according to the present invention
  • Embodiment 2 is a flowchart of Embodiment 2 of a method for setting a message state according to the present invention
  • FIG. 3 is a flowchart of another embodiment of a message state setting method according to the present invention
  • FIG. 4 is a flowchart of another embodiment of a message state setting method according to the present invention
  • FIG. FIG. 6 is a flowchart of Embodiment 2 of a message state setting method according to another embodiment of the present invention
  • FIG. 7A is a schematic structural diagram of Embodiment 1 of a CPM service server according to the present invention
  • 8 is a schematic structural diagram of another embodiment of a CPM service server according to the present invention
  • FIG. 9A is a schematic structural diagram of another embodiment of a CPM service server according to the present invention
  • FIG. 9B is still another CPM service server provided by the present invention.
  • the CPM service server may be a user subscription message service server, such as a CPM PF (Participation Function) Server
  • the CPM storage server may be a CPM Message Storage Server
  • the user terminal may be a user message client.
  • CPM Client CPM Client
  • the CPM service server and the CPM storage server may be devices such as computers, and the user terminals may be mobile phones, notebook computers, digital set top boxes, personal digital assistants, and the like.
  • the steps performed by the CPM service server and the functions performed by each module of the CPM service server may be executed by a processor of a device such as a computer.
  • the steps performed by the CPM storage server and the functions performed by each module of the CPM storage server can also be performed by a processor of a device such as a computer.
  • FIG. 1 is a flowchart of Embodiment 1 of a message state setting method according to the present invention. As shown in Figure 1, this embodiment includes:
  • Step 11 The CPM service server receives the message.
  • Step 12 Determine that the message needs to be submitted to the CPM storage server store, and the CPM service server sends a message storage request including the message to the CPM storage server.
  • the CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the user's willingness to select whether the message received by the CPM service server is submitted to the CPM storage server, whether the message needs to be submitted to the CPM. Storage server storage. Normally, the user selects in the subscription information that "the user submits the received message to the CPM storage server when the user is online, and does not submit the received message to the CPM storage server when the user goes offline". Further, the user selects "the user does not submit the received message to the CPM storage server when the content of the message exceeds the preset value" in the subscription information.
  • the CPM service server determines that the message needs to be submitted to the CPM storage server storage, it sends the message to the CPM storage server. After the CPM storage server receives the message storage request, if the message storage request does not indicate the read status of the message, the CPM storage server defaults the read status of the message to unread. After the CPM storage server stores the message and the read status of the message, it returns a storage response to the CPM business server.
  • Step 13 It is determined that the message needs to be sent to the user terminal, and the CPM service server sends the message to the user terminal.
  • the CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the willingness of the user in the subscription information to select whether the message received by the CPM service server is sent to the user terminal, whether the message needs to be sent to and received.
  • the user terminal of the party user Normally, the user selects in the subscription information that "the user sends the received message to the user terminal when the user is online, and does not send the received message to the user terminal when the user goes offline". Further, the user selects "the user does not send the received message to the user terminal when the user is online but the user status is busy or do not disturb" in the subscription information.
  • Step 14 The CPM service server receives the receiving response returned by the user terminal, determines that the CPM storage server stores a message corresponding to the received response, and determines, according to the received response returned by the user terminal, that the read status of the message corresponding to the received response is Read, send a message status modification request to the CPM storage server, and the read status of the message in the message status modification request is read.
  • the CPM service server After the CPM service server sends the message to the user terminal, it receives the connection returned by the user terminal. Receive response.
  • the CPM service server may determine, by the storage response returned by the cached CPM storage server, whether the message returned by the user terminal corresponding to the received response is stored in the CPM storage server. When it is determined that the message corresponding to the received response has been stored in the storage server, the CPM service server determines the read status of the response response corresponding message. When the receiving response indicates that the user terminal fails to receive, the CPM service server determines that the reading status of the receiving response corresponding message is unread; and the receiving response indicates that the user receives the success. The CPM service server determines that the read status of the response response corresponding message is read.
  • the CPM service server When the read status of the response response corresponding message is read, the CPM service server sends a message status modification request to the CPM storage server, requesting to modify the read status of the message in the CPM storage server to read, so that the message is stored in the CPM storage server.
  • the reading state is consistent with the reading status of the user terminal regarding the message.
  • the CPM service server can determine whether the message corresponding to the received response returned by the user terminal is stored in the CPM storage server.
  • the following examples are as follows:
  • One method is to judge the message by assigning a unique identifier (MID) to the message through the CPM service server.
  • MID unique identifier
  • the message may be assigned a unique identifier (MID), and the message including the MID is carried in the message storage request and sent to the CPM storage server, and when the CPM storage server returns the storage response, The MID of the message is carried in the storage response.
  • the CPM service server sends the message including the MID to the user terminal. After the CPM service server sends the message to the user terminal, it receives the receiving response of the MID returned by the user terminal.
  • the CPM service server searches for the cached storage response according to the MID in the received response, and if it finds a storage response including the MID in the received response, determines that the message corresponding to the received response has been stored in the storage server.
  • Another method is to: Determine the message by assigning a unique identifier (UID) to the message through the CPM storage server.
  • UID unique identifier
  • the CPM storage server return storage response may also include a unique identifier (UID) assigned by the CPM storage server for the message.
  • UID unique identifier
  • the CPM service server Upon determining that the message needs to be sent to the user terminal, the CPM service server sends the message including the UID to the user terminal. CPM service server sends to the user terminal After the message is sent, the receiving response of the UID returned by the user terminal is received. The CPM service server searches for the cached storage response according to the UID in the received response. If the storage response including the UID in the received response is found, it is determined that the message corresponding to the received response is stored in the storage server.
  • UID unique identifier
  • the CPM service server determines that the received message does not need to be submitted to the CPM storage server, whether the message needs to be sent to the user terminal, the CPM service server no longer reads the message during the receiving message phase. Carry out maintenance.
  • the CPM service server determines that the message needs to be submitted to the CPM storage server without sending the message to the user terminal, after the CPM service server sends a message storage request to the CPM storage server, the CPM service server receives the message phase, and the CPM service server The read status of the message is no longer maintained.
  • the CPM service server determines that the received message needs to be submitted to the CPM storage server, the message is sent to the CPM storage server.
  • the CPM storage server receives the message storage request, if the message storage request does not indicate the read status of the message, the CPM storage server defaults to reading the message as unread. If the CPM service server needs to send the message to the user terminal, if the read status of the message determined according to the receiving response returned by the terminal is read, the CPM service server sends a message status modification request to the CPM storage server. Modifying the read status of the message in the CPM storage server according to the receiving response request returned by the terminal.
  • the reading state of the message stored in the CPM storage server is consistent with the receiving state of the message by the user terminal, and the CPM storage server can be prevented from transmitting the message that the user terminal has successfully received to the user terminal, thereby saving resources. It also avoids the user terminal repeatedly receiving the read message, which improves the user experience.
  • FIG. 2 is a flowchart of Embodiment 2 of a method for setting a message state according to the present invention.
  • This embodiment is a refinement flow of the corresponding embodiment of Fig. 1. As shown in FIG. 2, this embodiment includes:
  • Step la The CPM service server receives the message.
  • the CPM business server is a CPM PF Server, and the CPM PF Server receives a CPM.
  • the CPM Message can be a Page Mode message, for example: SIP MESSAGE;
  • the CPM Message can be a Large Mode message, for example: MSRP SEND MESSAGE.
  • MSRP SEND MESSAGE The full English name of MSRP is: Message Session Relay Protocol.
  • SIP MESSAGE is a single transmission, and the number of bytes sent each time is limited, only 13022 bytes can be sent at a time.
  • MSRP SEND MESSAGE is sent over a dedicated channel, and there is no limit to the number of bytes sent each time.
  • Step 2a The CPM service server determines whether the message needs to be submitted to the CPM storage server for storage.
  • the CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the willingness of the user in the subscription information to select whether the message received by the CPM service server is submitted to the CPM storage server, whether the message is Need to submit CPM storage server storage.
  • the user selects in the subscription information that "the user submits the received message to the CPM storage server when the user is online, and does not submit the received message to the CPM storage server when the user goes offline". Further, the user selects "the user does not submit the received message to the CPM storage server when the user is online but the content length of the message exceeds the user preset value" in the subscription information.
  • step 5a When the CPM service server determines that the message does not need to be submitted to the CPM storage server storage, directly execute step 5a, otherwise step 3a is performed.
  • Step 3a When the CPM service server determines that the message needs to be submitted to the CPM storage server storage, it sends a message storage request including the message to the CPM storage server.
  • Step 4a The CPM storage server stores the message according to the message storage request and returns a storage response to the CPM service server.
  • the CPM storage server After the CPM storage server receives the message without identifying the read status, the CPM storage server defaults that the read status of the message is unread.
  • the message storage request may be an IMAP APPEND message.
  • the IPM protocol-based CPM message storage server receives the message storage request. If the message carried in the message storage request does not identify the read status, the read status of the message is "/Recent" (indicating that the message is a message) or "/Unseen". (Indicating that the message was not read). Further, in step 4a, the storage response returned by the CPM storage server may further include a unique identifier assigned to the message when the CPM storage server stores the message.
  • Step 5a The CPM service server determines whether the message needs to be sent to the user terminal. When the CPM service server determines that the message does not need to be sent to the user terminal, the receiving process of the message ends, otherwise step 6a is performed.
  • Step 6a When the CPM service server determines that it needs to be sent to the user terminal, the message is sent to the user terminal.
  • the CPM Service Server When the CPM Service Server determines that it needs to be sent to the user terminal, it can assign an identifier (MID) to the message.
  • the CPM service server may also assign an identifier (MID) to the message when it is determined to submit the received message to the CPM storage server, and determine that the message carrying the MID is sent to the user terminal when it is sent to the user terminal.
  • the CPM service server sends the message to the user terminal.
  • the CPM PF Server sends a SIP MESSAGE to the CPM Client or sends an MSRP SEND message.
  • the CPM service server also carries the UID when transmitting the message to the user terminal.
  • the CPM storage server synchronizes the message to the user terminal, in addition to synchronizing the message whose read status is "unread” to the user terminal, it also checks whether the message whose read status is "read” in the storage server is saved with the user terminal. Whether the messages are consistent, that is, the message consistency check is performed. If not,
  • the CPM storage server synchronizes the message inconsistent with the user terminal to the user terminal. Since the CPM storage server may not be able to recognize the MID, or the MPM is not included in the message stored by the CPM storage server, other auxiliary information and methods are needed to check the consistency of the message through the MID, so that the implementation complexity is high.
  • the message stored in the user terminal includes the UID
  • the consistency of the UID of the message can be used to determine whether the message saved by the user terminal is consistent with the message saved by the CPM storage server. Therefore, checking the UID can reduce the complexity of checking message consistency when the CPM storage server synchronizes messages to the user terminal.
  • the CPM storage server can automatically synchronize messages when the preset time arrives. To the user terminal; the CPM storage server can also synchronize the message to the user terminal according to the active request of the user terminal when the user goes online; the CPM storage server can also synchronize the message to the user terminal according to other preset regulations.
  • Step 7a The user terminal returns a receiving response to the CPM service server.
  • the receiving response when the receiving response is ' ⁇ ', it indicates that the user terminal receives successfully; when the receiving response is "Error", it indicates that the user terminal receives the failure.
  • Step 8a The CPM service server determines whether the message is stored in the CPM storage server. When the CPM service server determines that the message is stored in the CPM storage server, step 9 a is performed, otherwise the process ends.
  • the CPM service server can determine whether the message corresponding to the received response returned by the user terminal is stored in the CPM storage server through the storage response returned by the cached CPM storage server. For example, the CPM service server can look up the cached storage response according to the identifier (MID) assigned by the CPM service server carried in the response to the message. If a storage response corresponding to the MID is found, it is determined that the message has been stored in the CPM storage server.
  • MID identifier
  • the CPM service server may also search for the cached storage response according to the UID carried in the received response, and if the storage response corresponding to the UID is found, Make sure the message is stored on the CPM storage server.
  • Step 9a When the message is stored in the CPM storage server, the CPM service server determines the read status of the message based on the received response.
  • the receiving response is ' ⁇ ', it indicates that the user terminal receives successfully, and the reading state of the message is read; if the receiving response is “Error”, it indicates that the user terminal fails to receive, and the reading state of the message is unread. .
  • Step 10a The CPM service server determines whether the read status of the message determined according to the received response is unread. When the CPM service server determines that the read status of the message is unread according to the received response, the read status of the message in the storage server does not need to be modified, and the process ends. When the CPM service server determines that the read status of the message is read according to the received response, step l la is performed.
  • Step 11a The CPM service server sends a message modification request to the CPM storage server according to the receiving response to determine that the read status of the message is read, and requests the CPM storage server to modify the read status of the message to read.
  • Step 12a The CPM storage server changes the read status of the message to read according to the message modification request, and returns a modification response to the CPM service server. Then the process ends.
  • the CPM PF Server sends an IMAP STORE to the IMAP protocol-based CPM message storage server, and the CPM message storage server modifies the read status of the message to Unseen (indicating that the message has been read) ).
  • the IMAP-based message field when the user goes online, the IMAP-based CPM message storage server needs to notify the user of the number of unread messages and unread messages.
  • the unread mail notified by the message storage server to the user is a message that the CPM PF Server does not send to the user terminal (or is not successfully sent to the user terminal).
  • the reading status of the mail in the CPM message storage server based on the IMAP protocol is consistent with the reading status of the mail on the user terminal.
  • the CPM message storage server based on the IMAP protocol receives the message forwarded by the service server, if the service server does not identify the read status, the read status of the message is unread by default. Therefore, if the message stored in the CPM message storage server based on the IMAP protocol has been successfully sent to the user terminal during the session, the read status of the message stored in the CPM message storage server based on the IMAP protocol is still unread.
  • the reading status of the mail in the CPM message storage server based on the IMAP protocol is inconsistent with the reading status of the mail on the user terminal, so that the CPM message storage server based on the IMAP protocol still needs to go to the user terminal when the user goes online again.
  • Sending a message or email that has been successfully received by the user terminal not only causes waste of resources, but also makes the user repeatedly receive and affect the user experience.
  • the unique identifier assigned to the message is further included in the message modification request sent by the CPM service server to the storage server in step 11a, and the unique identifier assigned by the CPM storage server to the message.
  • the CPM storage server can modify the read status of the message after finding the message according to the unique identifier of the message.
  • the CPM service server After transmitting the received message to the user terminal, the CPM service server requests the CPM storage server when determining that the read status of the message is unread according to the receiving response returned by the user terminal when determining that the message has been stored to the CPM storage server. Modify the reading status of the message. After the CPM service server sends the received message to the user terminal and determines that the message is not stored to the CPM storage server, the CPM service server does not have to maintain the read status of the message during the message receiving phase. Similarly, after the CPM service server submits the received message to the CPM storage server, if the message does not need to be sent to the user terminal, the CPM service server does not have to maintain the read status of the message during the message receiving phase.
  • FIG. 3 is a flowchart of Embodiment 1 of another method for setting a message state according to the present invention.
  • the difference between this embodiment and FIG. 1 or FIG. 2 is that, in FIG. 1 or FIG. 2, when the CPM service server sends a message to the CPM storage server, the message is sent directly to the user terminal regardless of whether the message needs to be sent to the user terminal. To the CPM storage server, the CPM storage server defaults to reading the message as unread. In this embodiment, before sending the message to the CPM storage server, the CPM service server also considers whether it needs to send to the user terminal to the user terminal, and identifies the read status of the message, and sends a message indicating the read status to the CPM. Storage server. As shown in FIG. 3, this embodiment includes:
  • Step 31 The CPM service server receives the message.
  • Step 32 determining that a message needs to be submitted to the CPM storage server and sending a message to the user terminal, the CPM service server identifies the read status of the message as read, sends a message storage request to the CPM storage server, and sends a message to the user terminal; message storage The request includes the read status of the message and the message.
  • the CPM service server may according to the subscription information of the recipient user corresponding to the message, for example, the root According to the willingness of the user in the subscription information to select whether the message received by the CPM service server is submitted to the CPM storage server, it is determined whether the message needs to be submitted to the CPM storage server for storage. Normally, the user selects in the subscription information that "the user submits the received message to the CPM storage server when the user is online, and does not submit the received message to the CPM storage server when the user goes offline". Further, the user selects "the user does not submit the received message to the CPM storage server when the user is online but the content length of the message exceeds the user preset value" in the subscription information.
  • the CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the willingness of the user in the subscription information to select whether the message received by the CPM service server is sent to the user terminal, whether the message needs to be sent to and received.
  • the user terminal of the party user Normally, the user selects in the subscription information that "the user sends the received message to the user terminal when the user is online, and does not send the received message to the user terminal when the user goes offline". Further, the user selects "the user does not send the received message to the user terminal when the user is online but the user status is busy or do not disturb" in the subscription information.
  • Step 33 The CPM service server receives the receiving response returned by the user terminal, and the read status of the message determined according to the receiving response returned by the terminal is unread, and sends a message state modification request to the CPM storage server, where the message is in the message state modification request. The reading status is unread.
  • the receiving response is ' ⁇ ', it indicates that the user terminal receives successfully, and determines that the reading state of the message is read; if the receiving response is “Error”, indicating that the user terminal fails to receive, determining that the reading state of the message is unread.
  • the CPM service server when the CPM service server needs to submit the message to the storage server and needs to send the message to the user terminal, the CPM service server identifies the read status of the message as read, in the CPM The storage server message storage request carries the read status of the message, so that the CPM storage server stores the read status of the message. And if the read status of the message determined according to the receiving response returned by the terminal is inconsistent with the read status of the message in the message storage request, the CPM service server sends a message status modification request to the CPM storage server, according to the receiving return by the terminal. Modify the read of the message in the CPM storage server in response to the request State.
  • the reading state of the message stored in the CPM storage server is consistent with the reading state of the message by the user terminal, which can prevent the CPM storage server from transmitting the message that the user terminal has successfully received to the user terminal, saving resources and improving the user experience. .
  • FIG. 4 is a flowchart of Embodiment 2 of another method for setting a message state according to the present invention.
  • This embodiment is a refinement flow of the corresponding embodiment of FIG. 3. As shown in FIG. 4, this embodiment includes:
  • Step lb The CPM Service Server receives the message.
  • Step 2b The CPM service server determines whether the message needs to be submitted to the CPM storage server for storage, and determines whether the message needs to be sent to the user terminal.
  • the CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the user's willingness to select whether the message received by the CPM service server is submitted to the CPM storage server, whether the message needs to be submitted to the CPM. Storage server storage.
  • the user selects in the subscription information that "the user submits the received message to the CPM storage server when the user is online, and does not submit the received message to the CPM storage server when the user goes offline". Further, the user does not submit the received message to the CPM storage server when the user is online but the content length of the message exceeds the user preset value in the subscription information.
  • the CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the willingness of the user in the subscription information to select whether the message received by the CPM service server is sent to the user terminal, whether the message needs to be sent to and received.
  • the user terminal of the party user Normally, the user selects in the subscription information that "the user sends the received message to the user terminal when the user is online, and does not send the received message to the user terminal when the user goes offline". Further, the user selects "the user does not send the received message to the user terminal when the user is online but the user status is busy or do not disturb" in the subscription information.
  • Step 3b When the CPM service server determines that the message needs to be submitted to the CPM storage server and needs to send the message to the user terminal, the CPM service server identifies the read status of the message as read.
  • Step 4b The CPM service server determines that the message needs to be submitted to the CPM storage server but not When the message needs to be sent to the user terminal, the CPM service server sends the message to the CPM storage server. The CPM service server receives the storage response of the CPM storage server, and the process ends.
  • the CPM storage server After receiving the message, the CPM storage server defaults to reading the message as unread, stores the message and the read status of the message, and returns a storage response to the CPM service server after storage.
  • step 6b is directly executed.
  • Step 5b The CPM service server sends a message storage request including the message and the read status of the message to the CPM storage server, and the CPM storage server stores the message and returns a storage response.
  • Step 6b The CPM service server sends the message to the user terminal, and receives the receiving response returned by the user terminal.
  • the CPM service server in step 6b also carries the UID of the message when transmitting the message to the user terminal.
  • UID unique identifier
  • the CPM storage server synchronizes the message to the user terminal, in addition to synchronizing the message whose read status is "unread” to the user terminal, it is also necessary to check whether the message in the storage server whose read status is "read” is related to the user terminal. Whether the saved messages are consistent, that is, the message consistency check is performed. If not, the CPM storage server synchronizes the message with the user terminal to the user terminal.
  • the CPM storage server may not be able to recognize the MID, or the MPM is not included in the message stored by the CPM storage server, when the MID is used to check the consistency of the message, other auxiliary information and methods are needed, so that the implementation complexity is high.
  • the consistency of the UID of the message may be used to determine whether the message saved by the user terminal is consistent with the message saved by the CPM storage server. Therefore, by checking the UID, the complexity of checking the message consistency when the CPM storage server synchronizes the message to the user terminal can be reduced.
  • the CPM storage server can automatically synchronize messages to the user terminal when the preset time arrives.
  • the CPM storage server can also be activated according to the user terminal when the user goes online. Request to synchronize the message to the user terminal; the CPM storage server can also synchronize the message to the user terminal according to other preset rules.
  • Step 7b The CPM service server determines whether the message is stored in the CPM storage server. If it is already stored on the CPM storage server, go to step 8b, otherwise it ends.
  • the CPM service server can determine whether the message corresponding to the received response returned by the user terminal is stored in the CPM storage server through the storage response returned by the cached CPM storage server. For example, the CPM service server may look up the cached storage response according to the identifier (MID) assigned by the CPM service server carried in the response to the message. If the storage response corresponding to the MID is found, it is determined that the message is stored in the CPM storage server. Further, if the storage response includes the CPM storage server as the unique identifier (UID) of the message, the CPM service server may also search for the cached storage response according to the UID carried in the received response, and if the storage response corresponding to the UID is found, determine The message is already stored on the CPM storage server. In addition, there are various ways to determine whether the message corresponding to the receiving response has been stored in the CPM storage server, and no longer.
  • MID identifier
  • UID unique identifier
  • Step 8b When the message is stored in the CPM storage server, the CPM service server determines the read status of the message based on the received response.
  • Step 9b The CPM service server determines whether the read status of the message determined according to the received response is unread. If it is unread, go to step 10b, otherwise the process ends.
  • the receiving response is ' ⁇ ', it indicates that the user terminal receives successfully, and the reading state of the message is read; if the receiving response is “Error”, it indicates that the user terminal fails to receive, and the reading state of the message is unread. .
  • the CPM service server determines that the read status of the message is read according to the received response, since the CPM storage server is requested to identify the read status of the message as read in step 3b, there is no need to modify the read status of the message in the CPM storage server. , the process ends.
  • Step 10b When the CPM service server determines that the read status of the message is unread according to the received response, the CPM service server sends a message modification request to the CPM storage server, requesting the CPM storage server to send the message. The reading status is changed to unread. After that, the CPM service server receives the CPM storage server and returns a modification response, and the process ends.
  • FIG. 5 is a flowchart of still another embodiment of a message state setting method according to the present invention. This embodiment is adapted to batch processing of received messages by the CPM service server. As shown in FIG. 5, this embodiment includes:
  • Step 51 The CPM service server receives the message.
  • Step 52 Determine that the message needs to be submitted to the CPM storage server store, and the CPM service server caches the message.
  • the CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the user's willingness to select whether the message received by the CPM service server is submitted to the CPM storage server, whether the message needs to be submitted to the CPM. Storage server storage.
  • the user selects in the subscription information that "the user submits the received message to the CPM storage server when the user is online, and does not submit the received message to the CPM storage server when the user goes offline". Further, the user does not submit the received message to the CPM storage server when the user is online but the content length of the message exceeds the user preset value in the subscription information.
  • Step 53 Determine that the message needs to be sent to the user terminal, and the CPM service server sends the message to the user terminal, and receives the receiving response returned by the user terminal.
  • the CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the willingness of the user in the subscription information to select whether the message received by the CPM service server is sent to the user terminal, whether the message needs to be sent to the User terminal of the recipient user. Normally, the user selects in the subscription information that "the user sends the received message to the user terminal when the user is online, and does not send the received message to the user terminal when the user goes offline". Further, the user selects "the user does not send the received message to the user terminal when the user is online but the user status is busy or do not disturb" in the subscription information.
  • Step 54 Determine that a message corresponding to the received response is buffered, and identify a read status of the cached message corresponding to the received response according to the received response returned by the user terminal.
  • Step 55 The CPM service server sends a message storage request to the CPM storage server, where the message storage request includes the cached messages and the read status of each message.
  • the CPM service server may send a message storage request to the CPM storage server when there are multiple messages or cached messages to be processed, such as when the cache space is full or the preset cache amount is reached.
  • the CPM service server After receiving the message, the CPM service server first caches the message that needs to be submitted to the CPM storage server. For the cached message that needs to be sent to the user terminal, the CPM service server identifies the read status of the cached message according to the received response returned by the user terminal. . The CPM service server sends the cached messages and their read status to the CPM storage server for storage. Therefore, for a message that needs to be submitted to the CPM storage server storage and needs to be sent to the user terminal at the same time, the reading state of the message stored in the CPM storage server is consistent with the reading state of the message by the user terminal, so that the CPM storage server can be avoided from being sent to the user. The terminal sends a message that the user terminal has successfully received, which saves resources and improves user resources.
  • FIG. 6 is a flowchart of still another embodiment 2 of a message state setting method according to the present invention. This embodiment is a detailed flow of the corresponding embodiment of Fig. 6. As shown in Figure 6. This embodiment includes:
  • Step lc The CPM service server receives the message.
  • Step 2c The CPM service server determines whether the message is submitted to the CPM storage server storage. If step 3c is performed, otherwise step 4c is performed.
  • Step 3c The CPM service server caches messages to be submitted to the CPM storage server. After that, go to step 5c.
  • Step 4c When it is determined that the message needs to be sent to the user terminal, the message is sent to the user terminal. After that, the process ends.
  • Step 5c The CPM service server determines whether the message is sent to the user terminal. If step 6c is performed, otherwise step 11c is performed: that is, the CPM service server identifies the read status of the cached message as unread, and executes step 12c.
  • Step 6c The CPM service server sends the message to the user terminal, and receives the user terminal. Receive response back.
  • Step 7c The CPM service server determines whether a message corresponding to the received response is cached. If it is step 8c, the process ends.
  • the CPM service server can determine whether to cache a message corresponding to the received response returned by the user terminal by using the cached message. For example, the CPM service server searches for the cached message according to the identifier (MID) assigned by the CPM service server carried in the response, and if the message cached corresponding to the MID is found, it is determined that the message is cached. In addition, there are various implementation methods for judging whether the message corresponding to the received response has been stored in the CPM storage server, and will not be listed one by one.
  • MID identifier
  • Step 8c The CPM service server determines whether the reception response indicates that the reception is successful. If it is, go to step 9c, otherwise go to step 10c.
  • the receiving response is ' ⁇ ', it indicates that the user terminal receives successfully, and the reading state of the message is read; if the receiving response is “Error”, it indicates that the user terminal fails to receive, and the reading state of the message is unread. .
  • Step 9c The CPM service server identifies the read status of the message in the cache corresponding to the received response as read.
  • Step 10c The CPM service server identifies the read status of the message in the cache corresponding to the received response as unread.
  • step 12c Repeat the above steps until the CPM service server's cache is full or has received a batch of batch processed messages, and then perform step 12c.
  • Step 12c After sending the cached messages and the read status of each message to the CPM storage server, the CPM service server receives the storage response returned by the CPM storage server. Then the process ends.
  • the message that needs to be sent only to the user terminal does not need to be cached in the CPM service server; for the message that only needs to be submitted to the CPM storage server, the CPM service server identifies the read status of the cached message as unread. For need to submit to both The CPM stores the server and the message sent to the user terminal. After the CPM service server caches the message, the CPM service server identifies the read status of the message according to the received response returned by the user terminal.
  • FIG. 7A is a schematic structural diagram of Embodiment 1 of a CPM service server according to the present invention.
  • the service device provided in this embodiment includes: a receiving module 71, a message storage requesting block 72, a sending module 73, and a state modifying requesting module 74.
  • the receiving module 71 is configured to receive a message.
  • the message storage request block 72 is configured to determine that the message needs to be submitted to the CPM storage server storage, and send a message storage request including the message to the CPM storage server.
  • the sending module 73 is configured to determine that the message needs to be sent to the user terminal, and send the message to the user terminal.
  • the receiving module 71 is further configured to receive a receiving response returned by the user terminal.
  • the status modification requesting module 74 determines that the CPM storage server stores a message corresponding to the received response, and determines, according to the received response returned by the user terminal, that the read status of the message corresponding to the received response is read.
  • the CPM storage server sends a message state modification request, and the read state of the message in the message state modification request is read.
  • the receiving module 71 is further configured to receive a storage response returned by the CPM storage server that includes the identifier allocated by the CPM storage server for the message.
  • the sending module 73 is specifically configured to send the message to the user terminal and the target that the CPM storage server allocates the message.
  • the state modification requesting module 74 includes: a storage determining unit 741, a state determining unit 742, and a state modifying requesting unit 743.
  • the storage determining unit 741 is configured to receive, by the receiving module 71, a receiving response returned by the user terminal, and determine that a message corresponding to the receiving response is stored in the CPM storage server.
  • the status determining unit 742 is configured to read the read status of the message according to the received response returned by the terminal.
  • a state modification requesting unit 743 configured to determine the read condition of the message by the state determining unit 742 After the state is read, a message state modification request is sent to the CPM storage server.
  • the state determining unit 742 is specifically configured to: after determining, by the CPM storage server, the identifier that is allocated by the CPM storage server for the message, determining that the CPM storage server stores a message corresponding to the received response, according to The identifier allocated by the CPM storage server in the receiving response for the message determines that the read status of the message corresponding to the received response is read.
  • the CPM service server When the CPM service server provided by the implementation of the present invention determines that the received message needs to be submitted to the CPM storage server, the message is sent to the CPM storage server. After the CPM storage server receives a message that does not identify the read status, the CPM storage server defaults to reading the message as unread. If the CPM service server needs to send the message to the user terminal, if it is determined according to the received response returned by the terminal, the read status of the message corresponding to the received response is read, that is, the read status of the message and the CPM storage server. The reading status of the message is inconsistent.
  • the CPM service server sends a message state modification request to the CPM storage server, and modifies the read state of the message in the CPM storage server according to the receiving response request returned by the terminal.
  • the read status of the message stored in the CPM storage server is consistent with the receiving status of the message by the user terminal.
  • FIG. 8 is a schematic structural diagram of another embodiment of a CPM service server according to the present invention.
  • the service provider provided in this embodiment includes: a receiving module 81, a message storage request block 82, a sending module 83 and a state modification requesting module 84, and a determining module 85.
  • the receiving module 81 is configured to receive a message.
  • the determining module 85 is configured to determine that the message needs to be submitted to the CPM storage server and needs to send the message to the user terminal, and the read status of the message is identified as read.
  • the message storage requesting module 82 is configured to send a message storage request to the CPM storage server; the message storage request includes the message and a read status of the message.
  • the sending module 83 is configured to send the message to the user terminal.
  • the receiving module 81 is further configured to receive a receiving response returned by the user terminal.
  • the state modification requesting module 84 is configured to determine, according to the receiving response returned by the user terminal, that the read state of the message corresponding to the received response is unread, and send a message state modification request to the CPM storage server, where the message state is modified. The read status of the message described in the request is unread.
  • the receiving module 81 is further configured to receive a storage response returned by the CPM storage server that includes the identifier allocated by the CPM storage server for the message.
  • the sending module 83 is specifically configured to send the message to the user terminal and an identifier that is allocated by the CPM storage server for the message.
  • the state modification requesting module 84 is specifically configured to determine, according to the identifier allocated by the CPM storage server for the message, in the receiving response, that includes the identifier allocated by the CPM storage server for the message. And the read status of the message corresponding to the received response is unread, and the message status modification request is sent to the CPM storage server.
  • the CPM service server When the CPM service server provided by the implementation of the present invention needs to submit the message to the CPM storage server and needs to send the message to the user terminal, the CPM service server identifies the read status of the message as read, and stores the message in the CPM storage server. The request carries the read status of the message, so that the CPM storage server stores the read status of the message as read.
  • the CPM service service crying determines the read status of the message according to the receiving response returned by the terminal, if the message is inconsistent with the read status of the message in the message storage request, that is, if the message is determined according to the received response returned by the terminal.
  • the read status is unread, and the CPM service server sends a message status modification request to the CPM storage server, and the read status of the message in the CPM storage server is modified according to the received response request returned by the terminal.
  • the read status of the message stored in the CPM storage server is consistent with the read status of the message by the user terminal.
  • FIG. 9 is a schematic structural diagram of another embodiment of a CPM service server according to the present invention.
  • the service device provided in this embodiment includes: a receiving module 91, a cache module 92, a sending module 93, a status identifying module 94, and a message storage requesting module 95.
  • the receiving module 91 is configured to receive a message.
  • the cache module 92 is configured to determine that the message needs to be submitted to the CPM storage server storage, and cache the message.
  • the sending module 93 is configured to determine that the message needs to be sent to the user terminal, and send the message to the user terminal.
  • the receiving module 91 is further configured to receive a receiving response returned by the user terminal.
  • the status identification module 94 is configured to determine that a message corresponding to the received response is buffered, and identify a read status of the cached message corresponding to the received response according to the received response returned by the user terminal.
  • the message storage requesting module 95 is configured to send a message storage request to the CPM storage server, where the message storage request includes each cached message and a read status corresponding to each message.
  • the status identification module 95 is further configured to: after the message is cached, determine that the message does not need to be sent to the user terminal, and identify a read status of the cached message corresponding to the received response as unread .
  • the status identification module 94 includes: a first identification unit 941, a second identification unit 942, and a third identification unit 943.
  • the first identifier unit 941 is configured to: when the receiving response returned by the user terminal indicates that the receiving is successful, the read status of the cached message corresponding to the received response is identified as read.
  • the second identifier unit 942 the receiving response for returning by the user terminal indicates that the read status of the message buffered by the cache module 92 corresponding to the received response is unread when the receiving fails.
  • the third identifying unit 943 is configured to: after the message is cached, determine that the read status of the cached message is unread when the message does not need to be sent to the user terminal.
  • the CPM service server of the present invention After receiving the message, the CPM service server of the present invention first caches a message that needs to be submitted to the CPM storage server. For the message that needs to be sent to the user terminal in the cache, the CPM service server identifies the message in the cache according to the received response returned by the user terminal. Reading status. The CPM service server batches the cached messages and their read status to the CPM storage server for storage. Therefore, for messages that need to be submitted to the CPM storage server store and that need to be sent to the user terminal at the same time, the read status of the message stored in the CPM storage server is consistent with the read status of the message by the user terminal.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Information Transfer Between Computers (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)
  • Telephonic Communication Services (AREA)

Abstract

A method for setting message status and a traffic server are provided by the invention. The method for setting message status includes: receiving a message; determining that the message is required to send to a storage server for storing, sending a message storage request including the message to the storage server; determining that the message is required to send to a user terminal, sending the message to the user terminal; when a reception response returned from the user terminal is received, determining that the message corresponding to the reception response is stored in a CPM storage server and determining that the read status of the message is read corresponding to the reception response according to the reception response returned from the user terminal, sending a message status modification request, in which the read status of the message is read, to the CPM storage server. Therefore, the read status of the message stored in the storage server is consistent with the reception status of the message in the user terminal.

Description

消息状态设置方法和 CPM业务服务器  Message status setting method and CPM business server
技术领域 Technical field
本发明实施例涉及通信技术,尤其涉及一种消息状态设置方法和 CPM业 务服务器。 背景技术  The embodiments of the present invention relate to communication technologies, and in particular, to a message state setting method and a CPM service server. Background technique
开放移动联盟(Open Mobile Alliance, 简称 OMA )致力于部署一键通 ( Push to talk Over Cellular, 简称 PoC ) 、 即时消息 ( Instant Message, 简称 IM )、以及融合互联网协议 (internet protocol, 简称 IP)消息( Converged Internet Protocol Message, 简称 CPM )等移动数据业务规范。 为了在异构环境下为用 户提供更好的业务体验, OMA CPM规范为用户提供各种媒体类型 (文本、 图片、 语音、 视频) 消息递送、 会话建立和网络存储等服务。  The Open Mobile Alliance (OMA) is dedicated to deploying Push to talk Over Cellular (PoC), Instant Message (IM), and Internet Protocol (IP) messages. Mobile data service specifications such as Converged Internet Protocol Message (CPM). To provide a better business experience for users in heterogeneous environments, the OMA CPM specification provides users with a variety of media types (text, picture, voice, video) for message delivery, session establishment, and network storage.
CPM标准定义有两个服务器: CPM业务服务器和 CPM存储服务器, 用 户同样有两个客户端:基于初始会话协议( Session Initiated Protocol,简称 SIP ) 的 CPM客户端和互联网消息访问协议 ( Internet Message Access Protocol, 简 称 IMAP )客户端,二者不一定同时在线。 当有消息到达业务服务器后, CPM 业务服务器会根据用户设置等, 将消息发送给终端和 /或 CPM消息存储服务 器。通常情况下 IMAP客户端只在终端和 CPM消息存储服务器同步和对 CPM 消息存储服务器存储消息情况下在线。根据 CPM的需求,当有消息到达 CPM 业务服务器后, CPM 业务服务器会根据用户设置等, 将消息发送给终端和 / 或 CPM消息存储服务器。 由于用户终端性能、 用户设置的不同, CPM业务 服务器不是将所有消息都会发送到用户终端, 也不是将所有的消息都存储到 CPM存储服务器。在 CPM业务服务器将接收到的消息同时发送给 CPM存储 服务器和用户终端情况下, 若 CPM存储服务器中存储有该消息的阅读状态, CPM存储服务器中存储的该消息的阅读状态有可能与用户终端关于该消息 的状态不一致。 发明内容 The CPM standard defines two servers: CPM service server and CPM storage server. Users also have two clients: Session Initiated Protocol (SIP)-based CPM client and Internet Message Access Protocol (Internet Message Access Protocol). , referred to as IMAP) client, the two are not necessarily online at the same time. When a message arrives at the service server, the CPM service server sends a message to the terminal and/or the CPM message storage server according to user settings and the like. Typically, IMAP clients are only online when the terminal synchronizes with the CPM message store server and stores messages to the CPM message store server. According to the requirements of the CPM, when a message arrives at the CPM service server, the CPM service server sends a message to the terminal and/or the CPM message storage server according to user settings and the like. Due to the difference in user terminal performance and user settings, the CPM service server does not send all messages to the user terminal, nor does it store all messages to the CPM storage server. In the case that the CPM service server simultaneously sends the received message to the CPM storage server and the user terminal, if the read status of the message is stored in the CPM storage server, The read status of the message stored in the CPM storage server may be inconsistent with the status of the user terminal regarding the message. Summary of the invention
本发明实施例提供一种消息状态设置方法和 CPM业务服务器,用以解决 The embodiment of the invention provides a message state setting method and a CPM service server, which are used to solve
CPM存储服务器中存储的消息的阅读状态, 与用户终端关于该消息的阅读状 态不一致的问题。 The reading status of the message stored in the CPM storage server is inconsistent with the user terminal's read status of the message.
本发明一方面提供一种消息状态设置方法, 包括:  An aspect of the present invention provides a method for setting a message state, including:
接收消息; 确定所述消息需要提交存储服务器存储, 向所述存储服务 器发送包括所述消息的消息存储请求; 确定所述消息需要发送到用户终 端, 向所述用户终端发送所述消息;  Receiving a message; determining that the message needs to be submitted to a storage server, sending a message storage request including the message to the storage server; determining that the message needs to be sent to a user terminal, and sending the message to the user terminal;
接收到所述用户终端返回的接收响应时, 确定 CPM存储服务器中存储 有与所述接收响应对应的消息且根据所述用户终端返回的接收响应确定与 所述接收响应对应的消息的阅读状态为已读, 向所述 CPM存储服务器发送 消息状态修改请求, 所述消息状态修改请求中所述消息的阅读状态为已 读。  Receiving a receiving response returned by the user terminal, determining that a message corresponding to the receiving response is stored in the CPM storage server, and determining, according to the receiving response returned by the user terminal, a reading state of a message corresponding to the received response is Read, sending a message state modification request to the CPM storage server, wherein the read state of the message in the message state modification request is read.
本发明一方面提供一种 CPM业务服务器, 包括:  An aspect of the present invention provides a CPM service server, including:
接收模块, 用于接收消息; 消息存储请求模块, 用于确定所述消息需 要提交 CPM存储服务器存储,向所述 CPM存储服务器发送包括所述消息 的消息存储请求;  a receiving module, configured to receive a message; a message storage requesting module, configured to determine that the message needs to be submitted to a CPM storage server storage, and send a message storage request including the message to the CPM storage server;
发送模块, 用于确定所述消息需要发送到用户终端, 向所述用户终端 发送所述消息;  a sending module, configured to determine that the message needs to be sent to a user terminal, and send the message to the user terminal;
所述接收模块, 还用于接收所述用户终端返回的接收响应; 状态修改请求模块, 用于接收到所述用户终端返回的接收响应, 确定 CPM存储服务器中存储有与所述接收响应对应的消息,且根据所述接收响应 确定与所述接收响应对应的消息的阅读状态为已读, 向所述 CPM存储服务 器发送消息状态修改请求, 所述消息状态修改请求中所述消息的阅读状态 为已读。 The receiving module is further configured to receive a receiving response returned by the user terminal, and the state modifying requesting module is configured to receive a receiving response returned by the user terminal, and determine that the CPM storage server stores a response corresponding to the receiving response. And determining, according to the receiving response, that a read status of the message corresponding to the received response is read, and storing the service to the CPM The device sends a message state modification request, and the read state of the message in the message state modification request is read.
本发明一方面提供的一种消息状态设置方法和 CPM业务服务器, CPM业 务服务器确定需要向 CPM存储服务器提交接收到的新的消息时, 将该消息发 送给 CPM存储服务器。 CPM存储服务器接收到没有标识阅读状态的消息后, CPM存储服务器默认该消息的阅读状态为未读。 如果 CPM业务服务器需要向 用户终端发送该消息, 后续如果根据所述用户终端返回的接收响应确定的所 述消息的阅读状态为已读时, CPM业务服务器向所述 CPM存储服务器发送消 息状态修改请求, 根据用户终端返回的接收响应请求修改 CPM存储服务器中 该消息的阅读状态。 从而, CPM存储服务器中保存的消息的阅读状态与用户 终端对该消息的接收状态保持一致。 可避免 CPM存储服务器向用户终端发送 用户终端已成功接收到的消息, 节省了资源。 同样还避免了用户终端重复接 收已阅读的消息, 提高了用户体验。  One aspect of the present invention provides a message state setting method and a CPM service server. When the CPM service server determines that a new message needs to be submitted to the CPM storage server, the message is sent to the CPM storage server. After the CPM storage server receives the message that does not indicate the read status, the CPM storage server defaults that the read status of the message is unread. If the CPM service server needs to send the message to the user terminal, if the read status of the message determined according to the receiving response returned by the user terminal is read, the CPM service server sends a message status modification request to the CPM storage server. Modifying the read status of the message in the CPM storage server according to the receiving response request returned by the user terminal. Thus, the read status of the message stored in the CPM storage server is consistent with the receiving status of the message by the user terminal. The CPM storage server can be prevented from transmitting a message that the user terminal has successfully received to the user terminal, which saves resources. It also avoids the user terminal repeatedly receiving the read message and improving the user experience.
本发明另一方面还提供另一种消息状态设置方法, 包括:  Another aspect of the present invention provides another method for setting a message state, including:
接收消息; 确定需要提交所述消息至 CPM存储服务器且需要发送所 述消息至用户终端, 将所述消息的阅读状态标识为已读; 向所述 CPM存 储服务器发送消息存储请求, 并向所述用户终端发送所述消息; 所述消息 存储请求中包括所述消息和所述消息的阅读状态; 接收所述用户终端返回 的接收响应, 根据所述用户终端返回的接收响应确定的所述消息的阅读状 态为未读, 向所述 CPM存储服务器发送消息状态修改请求, 所述消息状 态修改请求中所述消息的阅读状态为未读。  Receiving a message; determining that the message needs to be submitted to the CPM storage server and transmitting the message to the user terminal, identifying a read status of the message as read; sending a message storage request to the CPM storage server, and reporting to The user terminal sends the message; the message storage request includes the message and the read status of the message; receiving the received response returned by the user terminal, and determining the message according to the received response returned by the user terminal The read status is unread, and a message status modification request is sent to the CPM storage server, and the read status of the message in the message status modification request is unread.
本发明另一方面还提供另一种 CPM业务服务器, 包括:  Another aspect of the present invention provides another CPM service server, including:
接收模块, 用于接收消息; 确定模块, 用于确定需要提交所述消息至 CPM存储服务器且需要发送所述消息至用户终端,将所述消息的阅读状态 标识为已读消息存储请求模块, 用于向所述 CPM存储服务器发送消息存 储请求, 所述消息存储请求中包括所述消息和所述消息的阅读状态; 发送 模块, 用于向所述用户终端发送所述消息; 所述接收模块进一步用于接收 所述用户终端返回的接收响应; 状态修改请求模块, 用于根据所述用户终 端返回的接收响应确定与所述接收响应对应的消息的阅读状态为未读, 向 所述 CPM存储服务器发送消息状态修改请求, 所述消息状态修改请求中 所述消息的阅读状态为未读。 a receiving module, configured to receive a message, a determining module, configured to determine that the message needs to be submitted to the CPM storage server, and needs to send the message to the user terminal, and identify a read status of the message as a read message storage request module, Sending a message storage request to the CPM storage server, where the message storage request includes the message and a read status of the message; a module, configured to send the message to the user terminal, the receiving module is further configured to receive a receiving response returned by the user terminal, and a state modification requesting module, configured to determine, according to the receiving response returned by the user terminal, The read status of the message corresponding to the received response is unread, and the message status modification request is sent to the CPM storage server, where the read status of the message is unread.
本发明另一方面提供的另一种消息状态设置方法和 CPM业务服务器, CPM业务服务器需要提交所述消息至 CPM存储服务器且需要发送所述消息 至用户终端时, CPM业务服务器将所述消息的阅读状态标识为已读, 在向 CPM存储服务器消息存储请求时携带该消息的阅读状态即已读, 使 CPM存储 服务器存储该消息的阅读状态。 根据所述用户终端返回的接收响应确定的所 述消息的阅读状态,如果与消息存储请求中所述消息的阅读状态不一致, CPM 业务服务器向所述 CPM存储服务器发送消息状态修改请求, 根据用户终端返 回的接收响应请求修改 CPM存储服务器中该消息的阅读状态。 从而, CPM存 储服务器中保存的消息的阅读状态与用户终端对该消息的阅读状态保持一 致。  Another message state setting method and a CPM service server provided by another aspect of the present invention, when the CPM service server needs to submit the message to the CPM storage server and needs to send the message to the user terminal, the CPM service server will The read status is identified as read, and the read status of the message carried when the server message storage request is stored to the CPM is read, causing the CPM storage server to store the read status of the message. And the CPM service server sends a message state modification request to the CPM storage server according to the read state of the message determined by the receiving response returned by the user terminal, according to the read state of the message in the message storage request, according to the user terminal The returned receive response request modifies the read status of the message in the CPM storage server. Thus, the read status of the message stored in the CPM storage server is consistent with the read status of the message by the user terminal.
本发明又一方面还提供又一种消息状态设置方法, 包括:  Another aspect of the present invention provides a method for setting a message state, including:
接收消息; 确定所述消息需要提交 CPM存储服务器存储, 緩存所述 消息;确定所述消息需要发送到用户终端,向所述用户终端发送所述消息, 并接收到所述用户终端返回的接收响应; 确定已緩存有与所述接收响应对应 的消息, 根据用户终端返回的接收响应, 标识緩存的与所述接收响应对应的 消息的阅读状态; 向所述 CPM存储服务器发送消息存储请求, 所述消息存储 请求包括緩存的各消息和各消息的阅读状态。  Receiving a message; determining that the message needs to be submitted to a CPM storage server for storage, buffering the message; determining that the message needs to be sent to a user terminal, transmitting the message to the user terminal, and receiving a receiving response returned by the user terminal Determining that a message corresponding to the received response is buffered, identifying a read status of the cached message corresponding to the received response according to the received response returned by the user terminal; and transmitting a message storage request to the CPM storage server, The message storage request includes the cached messages and the read status of each message.
本发明又一方面还提供又一种 CPM业务服务器, 包括:  Yet another aspect of the present invention provides a CPM service server, including:
接收模块, 用于接收消息; 緩存模块, 用于确定所述消息需要提交 CPM存储服务器存储, 并緩存所述消息; 发送模块, 用于确定所述消息需 要发送到用户终端, 向所述用户终端发送所述消息; 接收模块, 用于接收 所述用户终端返回的接收响应; 状态标识模块, 用于确定已緩存有与所述 接收响应对应的消息, 根据用户终端返回的接收响应, 标识緩存的与所述接 收响应对应的消息的阅读状态; 消息存储请求模块,用于向所述 CPM存储服 务器发送消息存储请求, 所述消息存储请求包括緩存的各消息和各消息的对 应的阅读状态。 a receiving module, configured to receive a message, a cache module, configured to determine that the message needs to be submitted to a CPM storage server, and to cache the message, and a sending module, configured to determine that the message needs to be sent to the user terminal, to the user terminal Sending the message; receiving module, for receiving a receiving response returned by the user terminal; a status identifying module, configured to determine that a message corresponding to the received response is cached, and to identify a read status of the cached message corresponding to the received response according to the received response returned by the user terminal And a message storage requesting module, configured to send a message storage request to the CPM storage server, where the message storage request includes the cached message and a corresponding read state of each message.
本发明又一方面提供的又一种消息状态设置方法和 CPM业务服务器, CPM业务服务器接收到消息后,先緩存需要提交至 CPM存储服务器的消息, 对于緩存的需要发送至用户终端的消息, CPM业务服务器根据用户终端返回 的接收响应标识緩存的各消息的阅读状态。 CPM业务服务器将緩存的消息及 其阅读状态批量发送给 CPM存储服务器进行存储。 因此, 对于需要提交至 CPM存储服务器存储且同时需要发送至用户终端的消息, CPM存储服务器 中保存的该消息的阅读状态与用户终端关于该消息的阅读状态保持一致。 附图说明  According to still another aspect of the present invention, a message state setting method and a CPM service server are provided. After receiving a message, the CPM service server first caches a message that needs to be submitted to the CPM storage server, and the message that needs to be sent to the user terminal for the cache, CPM The service server identifies the read status of each cached message according to the received response returned by the user terminal. The CPM service server sends the cached messages and their read status to the CPM storage server for storage. Therefore, for messages that need to be submitted to the CPM storage server store and that need to be sent to the user terminal at the same time, the read status of the message stored in the CPM storage server is consistent with the read status of the message by the user terminal. DRAWINGS
为了更清楚地说明本发明实施例或现有技术中的技术方案, 下面将对实 施例或现有技术描述中所需要使用的附图作一简单地介绍, 显而易见地, 下 面描述中的附图是本发明的一些实施例, 对于本领域普通技术人员来讲, 在 不付出创造性劳动性的前提下, 还可以根据这些附图获得其他的附图。  In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, a brief description of the drawings used in the embodiments or the prior art description will be briefly described below. Obviously, the drawings in the following description It is a certain embodiment of the present invention, and other drawings can be obtained from those skilled in the art without any inventive labor.
图 1为本发明提供的一种消息状态设置方法实施例一流程图;  1 is a flowchart of Embodiment 1 of a message state setting method according to the present invention;
图 2为本发明提供的一种消息状态设置方法实施例二流程图;  2 is a flowchart of Embodiment 2 of a method for setting a message state according to the present invention;
图 3为本发明提供的另一种消息状态设置方法实施例一流程图; 图 4为本发明提供的另一种消息状态设置方法实施例二流程图; 图 5为本发明提供的又一种消息状态设置方法实施例一流程图; 图 6为本发明提供的又一种消息状态设置方法实施例二流程图; 图 7A为本发明提供的一种 CPM业务服务器实施例一结构示意图; 图 7B为本发明提供的一种 CPM业务服务器实施例二结构示意图; 图 8为本发明提供的另一种 CPM业务服务器实施例结构示意图; 图 9A为本发明提供的又一种 CPM业务服务器实施例一结构示意图; 图 9B为本发明提供的又一种 CPM业务服务器实施例二结构示意图。 具体实施方式 FIG. 3 is a flowchart of another embodiment of a message state setting method according to the present invention; FIG. 4 is a flowchart of another embodiment of a message state setting method according to the present invention; FIG. FIG. 6 is a flowchart of Embodiment 2 of a message state setting method according to another embodiment of the present invention; FIG. 7A is a schematic structural diagram of Embodiment 1 of a CPM service server according to the present invention; A schematic structural diagram of a second embodiment of a CPM service server provided by the present invention; 8 is a schematic structural diagram of another embodiment of a CPM service server according to the present invention; FIG. 9A is a schematic structural diagram of another embodiment of a CPM service server according to the present invention; FIG. 9B is still another CPM service server provided by the present invention. A schematic diagram of the structure of the second embodiment. detailed description
为使本发明实施例的目的、 技术方案和优点更加清楚, 下面将结合本发 明实施例中的附图, 对本发明实施例中的技术方案进行清楚、 完整地描述, 显然, 所描述的实施例是本发明一部分实施例, 而不是全部的实施例。 基于 本发明中的实施例, 本领域普通技术人员在没有付出创造性劳动前提下所获 得的所有其他实施例, 都属于本发明保护的范围。  The technical solutions in the embodiments of the present invention are clearly and completely described in the following with reference to the accompanying drawings in the embodiments of the present invention. It is a partial embodiment of the invention, and not all of the embodiments. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments of the present invention without any inventive effort are within the scope of the present invention.
本发明实施例中 CPM 业务服务器可为用户签约消息业务服务器, 例如 CPM PF ( Participating Function ) Server, CPM存储服务器可为 CPM消息存 储服务器( CPM Message Storage Server ) , 用户终端可为用户消息客户端, 例如 CPM客户端(CPM Client ) 。 CPM业务服务器和 CPM存储服务器可为 计算机等设备, 用户终端可以是手机, 笔记本电脑, 数字机顶盒、 个人数字 助理等。 如下实施例的各方法中, CPM业务服务器执行的各步骤以及 CPM 业务服务器各模块执行的功能均可由计算机等设备的处理器执行。与此相似, CPM存储服务器执行的各步骤以及 CPM存储服务器各模块执行的功能也均 可由计算机等设备的处理器执行。  In the embodiment of the present invention, the CPM service server may be a user subscription message service server, such as a CPM PF (Participation Function) Server, the CPM storage server may be a CPM Message Storage Server, and the user terminal may be a user message client. For example, CPM Client (CPM Client). The CPM service server and the CPM storage server may be devices such as computers, and the user terminals may be mobile phones, notebook computers, digital set top boxes, personal digital assistants, and the like. In the methods of the following embodiments, the steps performed by the CPM service server and the functions performed by each module of the CPM service server may be executed by a processor of a device such as a computer. Similarly, the steps performed by the CPM storage server and the functions performed by each module of the CPM storage server can also be performed by a processor of a device such as a computer.
图 1为本发明提供的一种消息状态设置方法实施例一流程图。 如图 1所 示, 本实施例包括:  FIG. 1 is a flowchart of Embodiment 1 of a message state setting method according to the present invention. As shown in Figure 1, this embodiment includes:
步骤 11; CPM业务服务器接收消息。  Step 11: The CPM service server receives the message.
一个用户向另一个用户发送新的消息时,作为发送方的用户通过 CPM业 务服务器向接收方用户发送新的消息。  When a user sends a new message to another user, the user acting as the sender sends a new message to the recipient user through the CPM service server.
步骤 12: 确定该消息需要提交 CPM存储服务器存储, CPM业务服务器 向所述 CPM存储服务器发送包括该消息的消息存储请求。 CPM业务服务器可根据该消息对应的接收方用户的签约信息, 例如, 根 据签约信息中用户针对 "CPM业务服务器接收到的消息是否提交至 CPM存 储服务器"选择的意愿, 判断该消息是否需要提交 CPM存储服务器存储。 通 常情况下,用户在签约信息中选择 "用户在线时向 CPM存储服务器提交接收 到的消息, 用户离线时不向 CPM存储服务器提交接收到的消息" 。 进一步, 用户在签约信息中选择 "用户在线但消息的内容长度超过预设值时, 不向 CPM存储服务器提交接收到的消息" 。 Step 12: Determine that the message needs to be submitted to the CPM storage server store, and the CPM service server sends a message storage request including the message to the CPM storage server. The CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the user's willingness to select whether the message received by the CPM service server is submitted to the CPM storage server, whether the message needs to be submitted to the CPM. Storage server storage. Normally, the user selects in the subscription information that "the user submits the received message to the CPM storage server when the user is online, and does not submit the received message to the CPM storage server when the user goes offline". Further, the user selects "the user does not submit the received message to the CPM storage server when the content of the message exceeds the preset value" in the subscription information.
CPM业务服务器确定该消息需要提交 CPM存储服务器存储时, 将该消 息发送给 CPM存储服务器。 CPM存储服务器接收到消息存储请求后, 如果 消息存储请求中没有标识消息的阅读状态, CPM存储服务器默认该消息的阅 读状态为未读。 CPM存储服务器存储该消息和该消息的阅读状态后,向 CPM 业务服务器返回存储响应。  When the CPM service server determines that the message needs to be submitted to the CPM storage server storage, it sends the message to the CPM storage server. After the CPM storage server receives the message storage request, if the message storage request does not indicate the read status of the message, the CPM storage server defaults the read status of the message to unread. After the CPM storage server stores the message and the read status of the message, it returns a storage response to the CPM business server.
步骤 13: 确定所述消息需要发送到用户终端, CPM业务服务器向所述用 户终端发送该消息。  Step 13: It is determined that the message needs to be sent to the user terminal, and the CPM service server sends the message to the user terminal.
CPM业务服务器可根据该消息对应的接收方用户的签约信息, 例如, 根 据签约信息中用户针对 "CPM 业务服务器接收到的消息是否发送至用户终 端" 选择的意愿, 判断该消息是否需要发送到接收方用户的用户终端。 通常 情况下, 用户在签约信息中选择 "用户在线时向用户终端发送接收到的消息, 用户离线时不向用户终端发送接收到的消息" 。 进一步, 用户在签约信息中 选择 "用户在线但用户状态为忙碌或免打扰时, 不向用户终端发送接收到的 消息" 。  The CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the willingness of the user in the subscription information to select whether the message received by the CPM service server is sent to the user terminal, whether the message needs to be sent to and received. The user terminal of the party user. Normally, the user selects in the subscription information that "the user sends the received message to the user terminal when the user is online, and does not send the received message to the user terminal when the user goes offline". Further, the user selects "the user does not send the received message to the user terminal when the user is online but the user status is busy or do not disturb" in the subscription information.
步骤 14: CPM业务服务器接收到用户终端返回的接收响应, 确定 CPM 存储服务器中存储有与接收响应对应的消息, 且根据用户终端返回的接收响 应确定与所述接收响应对应的消息的阅读状态为已读,向 CPM存储服务器发 送消息状态修改请求, 消息状态修改请求中消息的阅读状态为已读。  Step 14: The CPM service server receives the receiving response returned by the user terminal, determines that the CPM storage server stores a message corresponding to the received response, and determines, according to the received response returned by the user terminal, that the read status of the message corresponding to the received response is Read, send a message status modification request to the CPM storage server, and the read status of the message in the message status modification request is read.
CPM业务服务器向用户终端发送该消息后, 会接收到用户终端返回的接 收响应。 CPM业务服务器可通过自身緩存的 CPM存储服务器返回的存储响 应,判断用户终端返回的与接收响应对应的该消息是否已存储在 CPM存储服 务器。 确定与接收响应对应的消息已存储在存储服务器时, CPM业务服务器 确定接收响应对应消息的阅读状态。接收响应表示用户终端接收失败时, CPM 业务服务器确定接收响应对应消息的阅读状态为未读; 接收响应表示用户接 收成功时。 CPM业务服务器确定接收响应对应消息的阅读状态为已读。 接收 响应对应消息的阅读状态为已读时, CPM业务服务器向所述 CPM存储服务 器发送消息状态修改请求,请求将 CPM存储服务器中该消息的阅读状态修改 为已读,使 CPM存储服务器中该消息的阅读状态与用户终端关于该消息的阅 读状态保持一致。 After the CPM service server sends the message to the user terminal, it receives the connection returned by the user terminal. Receive response. The CPM service server may determine, by the storage response returned by the cached CPM storage server, whether the message returned by the user terminal corresponding to the received response is stored in the CPM storage server. When it is determined that the message corresponding to the received response has been stored in the storage server, the CPM service server determines the read status of the response response corresponding message. When the receiving response indicates that the user terminal fails to receive, the CPM service server determines that the reading status of the receiving response corresponding message is unread; and the receiving response indicates that the user receives the success. The CPM service server determines that the read status of the response response corresponding message is read. When the read status of the response response corresponding message is read, the CPM service server sends a message status modification request to the CPM storage server, requesting to modify the read status of the message in the CPM storage server to read, so that the message is stored in the CPM storage server. The reading state is consistent with the reading status of the user terminal regarding the message.
CPM 业务服务器可有多种方法判断与用户终端返回的接收响应对应的 该消息是否已存储在 CPM存储服务器, 以下举例说明:  The CPM service server can determine whether the message corresponding to the received response returned by the user terminal is stored in the CPM storage server. The following examples are as follows:
一种方法是:通过 CPM业务服务器为消息分配唯一标识( MID )来判断。 One method is to judge the message by assigning a unique identifier (MID) to the message through the CPM service server.
CPM业务服务器确定消息需要提交至 CPM存储服务器时, 可为该消息 分配唯一标识(MID ) , 将包括 MID的该消息携带在消息存储请求中发送给 CPM存储服务器, CPM存储服务器返回存储响应时, 将该消息的 MID携带 在存储响应中, 在确定需要向用户终端发送该消息时, CPM业务服务器将包 括有 MID的该消息发送给用户终端。 CPM业务服务器向用户终端发送该消 息后, 会接收到用户终端返回的携带 MID的接收响应。 CPM业务服务器根 据接收响应中的 MID, 查找緩存的存储响应, 如果查找到与包括接收响应中 MID的存储响应, 确定与接收响应对应的消息已存储在存储服务器。 When the CPM service server determines that the message needs to be submitted to the CPM storage server, the message may be assigned a unique identifier (MID), and the message including the MID is carried in the message storage request and sent to the CPM storage server, and when the CPM storage server returns the storage response, The MID of the message is carried in the storage response. When it is determined that the message needs to be sent to the user terminal, the CPM service server sends the message including the MID to the user terminal. After the CPM service server sends the message to the user terminal, it receives the receiving response of the MID returned by the user terminal. The CPM service server searches for the cached storage response according to the MID in the received response, and if it finds a storage response including the MID in the received response, determines that the message corresponding to the received response has been stored in the storage server.
另一种方法是: 通过 CPM存储服务器为消息分配唯一标识(UID )来判 断。  Another method is to: Determine the message by assigning a unique identifier (UID) to the message through the CPM storage server.
CPM存储服务器返回存储响应中还可包括 CPM存储服务器为该消息分 配的唯一标识(UID ) 。 在确定需要向用户终端发送该消息时, CPM业务服 务器将包括有 UID的该消息发送给用户终端。 CPM业务服务器向用户终端发 送该消息后,会接收到用户终端返回的携带 UID的接收响应。 CPM业务服务 器根据接收响应中的 UID, 查找緩存的存储响应, 如果查找到与包括接收响 应中 UID的存储响应, 确定与接收响应对应的消息已存储在存储服务器。 The CPM storage server return storage response may also include a unique identifier (UID) assigned by the CPM storage server for the message. Upon determining that the message needs to be sent to the user terminal, the CPM service server sends the message including the UID to the user terminal. CPM service server sends to the user terminal After the message is sent, the receiving response of the UID returned by the user terminal is received. The CPM service server searches for the cached storage response according to the UID in the received response. If the storage response including the UID in the received response is found, it is determined that the message corresponding to the received response is stored in the storage server.
在本发明实施例中, 如果 CPM业务服务器确定不需要向 CPM存储服务 器提交接收到的消息, 无论该消息是否需要发送至用户终端, 在接收消息阶 段, CPM 业务服务器不再对该消息的阅读状态进行维护。 另外, 如果 CPM 业务服务器确定需要向 CPM存储服务器提交该消息而不需要向用户终端发 送该消息, 在 CPM业务服务器向 CPM存储服务器发送消息存储请求后, 在 CPM业务服务器接收消息阶段, CPM 业务服务器不再对该消息的阅读状态 进行维护。  In the embodiment of the present invention, if the CPM service server determines that the received message does not need to be submitted to the CPM storage server, whether the message needs to be sent to the user terminal, the CPM service server no longer reads the message during the receiving message phase. Carry out maintenance. In addition, if the CPM service server determines that the message needs to be submitted to the CPM storage server without sending the message to the user terminal, after the CPM service server sends a message storage request to the CPM storage server, the CPM service server receives the message phase, and the CPM service server The read status of the message is no longer maintained.
本发明实施例的消息状态设置方法, CPM业务服务器确定需要向 CPM 存储服务器提交接收到的消息时, 将该消息发送给 CPM存储服务器。 CPM 存储服务器接收到消息存储请求后, 如果消息存储请求中没有标识消息的阅 读状态, CPM存储服务器默认该消息的阅读状态为未读。 如果 CPM业务服 务器需要向用户终端发送该消息, 后续如果根据所述终端返回的接收响应确 定的所述消息的阅读状态为已读时, CPM业务服务器向所述 CPM存储服务 器发送消息状态修改请求,根据终端返回的接收响应请求修改 CPM存储服务 器中该消息的阅读状态。 从而, CPM存储服务器中保存的消息的阅读状态与 用户终端对该消息的接收状态保持一致,可避免 CPM存储服务器向用户终端 发送用户终端已成功接收到的消息, 节省了资源。 同样还避免了用户终端重 复接收已阅读的消息, 提高了用户体验。  In the message state setting method of the embodiment of the present invention, when the CPM service server determines that the received message needs to be submitted to the CPM storage server, the message is sent to the CPM storage server. After the CPM storage server receives the message storage request, if the message storage request does not indicate the read status of the message, the CPM storage server defaults to reading the message as unread. If the CPM service server needs to send the message to the user terminal, if the read status of the message determined according to the receiving response returned by the terminal is read, the CPM service server sends a message status modification request to the CPM storage server. Modifying the read status of the message in the CPM storage server according to the receiving response request returned by the terminal. Therefore, the reading state of the message stored in the CPM storage server is consistent with the receiving state of the message by the user terminal, and the CPM storage server can be prevented from transmitting the message that the user terminal has successfully received to the user terminal, thereby saving resources. It also avoids the user terminal repeatedly receiving the read message, which improves the user experience.
图 2为本发明提供的一种消息状态设置方法实施例二流程图。 本实施例 为图 1对应实施例的细化流程。 如图 2所示, 本实施例包括:  FIG. 2 is a flowchart of Embodiment 2 of a method for setting a message state according to the present invention. This embodiment is a refinement flow of the corresponding embodiment of Fig. 1. As shown in FIG. 2, this embodiment includes:
步骤 la: CPM业务服务器接收消息。  Step la: The CPM service server receives the message.
例如, CPM业务服务器为 CPM PF Server, CPM PF Server接收 CPM For example, the CPM business server is a CPM PF Server, and the CPM PF Server receives a CPM.
Message, 该 CPM Message可以是 Page Mode消息, 例如: SIP MESSAGE; 或者, 该 CPM Message 可以是 Large Mode 消息, 例如: MSRP SEND MESSAGE。 MSRP的英文全称为: Message Session Relay Protocol。其中, SIP MESSAGE 为单次发送, 且每次发送的字节数有限制, 每次只能发送 13022 个字节。 而 MSRP SEND MESSAGE通过专用信道进行发送, 且每次发送的 字节数没有限制。 Message, the CPM Message can be a Page Mode message, for example: SIP MESSAGE; Alternatively, the CPM Message can be a Large Mode message, for example: MSRP SEND MESSAGE. The full English name of MSRP is: Message Session Relay Protocol. Among them, SIP MESSAGE is a single transmission, and the number of bytes sent each time is limited, only 13022 bytes can be sent at a time. MSRP SEND MESSAGE is sent over a dedicated channel, and there is no limit to the number of bytes sent each time.
步骤 2a: CPM业务服务器判断该消息是否需要提交 CPM存储服务器存 储。  Step 2a: The CPM service server determines whether the message needs to be submitted to the CPM storage server for storage.
CPM业务服务器可根据与该消息对应的接收方用户的签约信息, 例如, 例如, 根据签约信息中用户针对 "CPM业务服务器接收到的消息是否提交至 CPM存储服务器" 选择的意愿, 判断该消息是否需要提交 CPM存储服务器 存储。 通常情况下, 用户在签约信息中选择 "用户在线时向 CPM存储服务器 提交接收到的消息, 用户离线时不向 CPM存储服务器提交接收到的消息" 。 进一步, 用户在签约信息中选择 "用户在线但消息的内容长度超过用户预设 值时, 不向 CPM存储服务器提交接收到的消息" 。  The CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the willingness of the user in the subscription information to select whether the message received by the CPM service server is submitted to the CPM storage server, whether the message is Need to submit CPM storage server storage. Normally, the user selects in the subscription information that "the user submits the received message to the CPM storage server when the user is online, and does not submit the received message to the CPM storage server when the user goes offline". Further, the user selects "the user does not submit the received message to the CPM storage server when the user is online but the content length of the message exceeds the user preset value" in the subscription information.
CPM业务服务器确定该消息不需要提交 CPM存储服务器存储时, 直接 执行步骤 5a, 否则执行步骤 3a。  When the CPM service server determines that the message does not need to be submitted to the CPM storage server storage, directly execute step 5a, otherwise step 3a is performed.
步骤 3a: CPM业务服务器确定该消息需要提交 CPM存储服务器存储时, 向 CPM存储服务器发送包括该消息的消息存储请求。  Step 3a: When the CPM service server determines that the message needs to be submitted to the CPM storage server storage, it sends a message storage request including the message to the CPM storage server.
步骤 4a: CPM存储服务器根据消息存储请求存储该消息, 并向 CPM业 务服务器返回存储响应。  Step 4a: The CPM storage server stores the message according to the message storage request and returns a storage response to the CPM service server.
CPM存储服务器接收没有标识阅读状态的消息后, CPM存储服务器默 认该消息的阅读状态为未读。以基于 IMAP协议的 CPM消息存储服务器为例, 消息存储请求可为 IMAP APPEND消息。 基于 IMAP协议的 CPM消息存储 服务器接收到消息存储请求, 如果消息存储请求中携带的消息没有标识阅读 状态, 默认该消息的阅读状态为" /Recent" (表示该消息为消息)或"/ Unseen" (表示该消息未读) 。 进一步, 在步骤 4a中, CPM存储服务器返回的存储响应还可包括 CPM 存储服务器存储该消息时为该消息分配的唯一标识。 After the CPM storage server receives the message without identifying the read status, the CPM storage server defaults that the read status of the message is unread. Taking the CPM message storage server based on the IMAP protocol as an example, the message storage request may be an IMAP APPEND message. The IPM protocol-based CPM message storage server receives the message storage request. If the message carried in the message storage request does not identify the read status, the read status of the message is "/Recent" (indicating that the message is a message) or "/Unseen". (Indicating that the message was not read). Further, in step 4a, the storage response returned by the CPM storage server may further include a unique identifier assigned to the message when the CPM storage server stores the message.
步骤 5a: CPM 业务服务器判断该消息是否需要发送至用户终端。 CPM 业务服务器确定该消息不需要发送至用户终端时, 该消息的接收流程结束, 否则执行步骤 6a。  Step 5a: The CPM service server determines whether the message needs to be sent to the user terminal. When the CPM service server determines that the message does not need to be sent to the user terminal, the receiving process of the message ends, otherwise step 6a is performed.
步骤 6a: CPM业务服务器确定需要发送至用户终端时, 向用户终端发送 该消息。  Step 6a: When the CPM service server determines that it needs to be sent to the user terminal, the message is sent to the user terminal.
CPM 业务服务器确定需要发送至用户终端时, 可为该消息分配标识 ( MID ) 。 CPM业务服务器也可以在确定向 CPM存储服务器提交接收到的 消息时, 就为该消息分配标识(MID ) , 确定需要发送至用户终端时将携带 有 MID的该消息发送给用户终端。 CPM业务服务器向用户终端发送该消息 可以是, CPM PF Server向 CPM Client发送 SIP MESSAGE或者发送 MSRP SEND消息。  When the CPM Service Server determines that it needs to be sent to the user terminal, it can assign an identifier (MID) to the message. The CPM service server may also assign an identifier (MID) to the message when it is determined to submit the received message to the CPM storage server, and determine that the message carrying the MID is sent to the user terminal when it is sent to the user terminal. The CPM service server sends the message to the user terminal. The CPM PF Server sends a SIP MESSAGE to the CPM Client or sends an MSRP SEND message.
进一步, 如果在步骤 4a中包括 CPM存储服务器为该消息分配的唯一标 识(UID ) 时, CPM业务服务器向用户终端发送该消息时还携带有 UID。 在 CPM存储服务器将消息同步到用户终端时, 除了将阅读状态为 "未读" 的消 息同步到用户终端外, 同时还检查存储服务器中阅读状态为 "已读" 的消息 是否与用户终端保存的消息是否一致, 即进行消息一致性检查。 如果不一致, Further, if the unique identifier (UID) assigned by the CPM storage server to the message is included in step 4a, the CPM service server also carries the UID when transmitting the message to the user terminal. When the CPM storage server synchronizes the message to the user terminal, in addition to synchronizing the message whose read status is "unread" to the user terminal, it also checks whether the message whose read status is "read" in the storage server is saved with the user terminal. Whether the messages are consistent, that is, the message consistency check is performed. If not,
CPM存储月良务器将与用户终端不一致的消息同步到用户终端。 由于 CPM存 储服务器有可能不能识别 MID, 或 CPM存储服务器保存的消息中不包括 MID, 因此通过 MID检查消息的一致性时, 还需要采用其它的辅助信息和方 法, 从而实现时复杂度较高。 而用户终端中保存的消息包括有 UID时, 可通 过消息的 UID的一致性判断用户终端保存的消息是否与 CPM存储服务器保 存的消息一致。 因此, 通过检查 UID可降低 CPM存储服务器将消息同步到 用户终端时, 检查消息一致性时的复杂度。 The CPM storage server synchronizes the message inconsistent with the user terminal to the user terminal. Since the CPM storage server may not be able to recognize the MID, or the MPM is not included in the message stored by the CPM storage server, other auxiliary information and methods are needed to check the consistency of the message through the MID, so that the implementation complexity is high. When the message stored in the user terminal includes the UID, the consistency of the UID of the message can be used to determine whether the message saved by the user terminal is consistent with the message saved by the CPM storage server. Therefore, checking the UID can reduce the complexity of checking message consistency when the CPM storage server synchronizes messages to the user terminal.
通常情况下, CPM存储服务器可在预设时间到达时自动进将消息同步 到用户终端; CPM存储服务器也可以在用户上线时, 根据用户终端的主动 请求将消息同步到用户终端; CPM存储服务器也可以按照其它预设规定将消 息同步到用户终端。 Normally, the CPM storage server can automatically synchronize messages when the preset time arrives. To the user terminal; the CPM storage server can also synchronize the message to the user terminal according to the active request of the user terminal when the user goes online; the CPM storage server can also synchronize the message to the user terminal according to other preset regulations.
步骤 7a: 用户终端向 CPM业务服务器返回接收响应。  Step 7a: The user terminal returns a receiving response to the CPM service server.
例如,接收响应为' ΌΚ"时,表示用户终端接收成功;接收响应为 "Error" 时, 表示用户终端接收失败。  For example, when the receiving response is 'ΌΚ', it indicates that the user terminal receives successfully; when the receiving response is "Error", it indicates that the user terminal receives the failure.
步骤 8a: CPM业务服务器判断该消息是否已存储在 CPM存储服务器。 CPM业务服务器确定该消息已存储在 CPM存储服务器时, 执行步骤 9 a, 否 则本流程结束。  Step 8a: The CPM service server determines whether the message is stored in the CPM storage server. When the CPM service server determines that the message is stored in the CPM storage server, step 9 a is performed, otherwise the process ends.
CPM业务服务器可通过自身緩存的 CPM存储服务器返回的存储响应, 判断与用户终端返回的接收响应对应的消息是否已存储在 CPM存储服务器。 例如, CPM业务服务器可根据接收响应中携带的 CPM业务服务器为该消息 分配的标识(MID ) , 查找緩存的存储响应。 如果查找到与该 MID对应的存 储响应, 则确定该消息已存储在 CPM存储服务器。 进一步, 如果存储响应中 包括 CPM存储服务器为该消息的唯一标识(UID ) , CPM业务服务器也可 根据接收响应中携带的 UID查找緩存的存储响应,如果查找到与该 UID对应 的存储响应, 则确定该消息已存储在 CPM存储服务器。 另外, 判断接收响应 对应的该消息是否已存储在 CPM存储服务器的方法有多种实现方式,不再一 一列举。  The CPM service server can determine whether the message corresponding to the received response returned by the user terminal is stored in the CPM storage server through the storage response returned by the cached CPM storage server. For example, the CPM service server can look up the cached storage response according to the identifier (MID) assigned by the CPM service server carried in the response to the message. If a storage response corresponding to the MID is found, it is determined that the message has been stored in the CPM storage server. Further, if the storage response includes the CPM storage server as the unique identifier (UID) of the message, the CPM service server may also search for the cached storage response according to the UID carried in the received response, and if the storage response corresponding to the UID is found, Make sure the message is stored on the CPM storage server. In addition, there are various implementation methods for determining whether the message corresponding to the received response has been stored in the CPM storage server, and will not be enumerated.
步骤 9a: 在该消息已存储在 CPM存储服务器时, CPM业务服务器根据 接收响应确定该消息的阅读状态。  Step 9a: When the message is stored in the CPM storage server, the CPM service server determines the read status of the message based on the received response.
具体的, 如果接收响应为' ΌΚ"时, 表示用户终端接收成功, 该消息的阅 读状态为已读; 如果接收响应为 "Error"时, 表示用户终端接收失败, 该消息 的阅读状态为未读。  Specifically, if the receiving response is 'ΌΚ', it indicates that the user terminal receives successfully, and the reading state of the message is read; if the receiving response is “Error”, it indicates that the user terminal fails to receive, and the reading state of the message is unread. .
步骤 10a: CPM业务服务器判断根据接收响应确定的该消息的阅读状态 是否为未读。 CPM业务服务器根据接收响应确定该消息的阅读状态为未读时, 不需要 修改存储服务器中该消息的阅读状态, 本流程结束。 CPM业务服务器根据接 收响应确定该消息的阅读状态为已读时, 执行步骤 l la。 Step 10a: The CPM service server determines whether the read status of the message determined according to the received response is unread. When the CPM service server determines that the read status of the message is unread according to the received response, the read status of the message in the storage server does not need to be modified, and the process ends. When the CPM service server determines that the read status of the message is read according to the received response, step l la is performed.
步骤 11a: CPM业务服务器根据接收响应确定该消息的阅读状态为已读 时, 向 CPM存储服务器发送消息修改请求, 请求 CPM存储服务器将该消息 的阅读状态修改为已读。  Step 11a: The CPM service server sends a message modification request to the CPM storage server according to the receiving response to determine that the read status of the message is read, and requests the CPM storage server to modify the read status of the message to read.
步骤 12a: CPM存储服务器根据消息修改请求, 将该消息的阅读状态修 改为已读, 向 CPM业务服务器返回修改响应。 之后本流程结束。  Step 12a: The CPM storage server changes the read status of the message to read according to the message modification request, and returns a modification response to the CPM service server. Then the process ends.
以 CPM PF Server和基于 IMAP协议的 CPM消息存储服务器为例 , CPM PF Server向基于 IMAP协议的 CPM消息存储服务器发送 IMAP STORE , CPM 消息存储服务器将该消息的阅读状态修改 Unseen (表示该消息已读) 。 在基 于 IMAP协议的消息领域中, 用户上线时,基于 IMAP协议的 CPM消息存储 服务器需通知用户未读邮件和未读邮件的数量。 通过本实施例提供的方法, 消息存储服务器向用户通知的未读邮件, 均是 CPM PF Server没有发送给用 户终端(或没有成功发送给用户终端)的消息。 因此基于 IMAP协议的 CPM 消息存储服务器中邮件的阅读状态与用户终端上关于该邮件的阅读状态保持 一致。 而现有技术中, 由于基于 IMAP协议的 CPM消息存储服务器接收到业 务服务器转发的消息后, 如果业务服务器没有标识阅读状态, 则默认该消息 的阅读状态为未读。 因此,如果基于 IMAP协议的 CPM消息存储服务器中存 储的该消息在会话过程中已成功发送给了用户终端, 而基于 IMAP 协议的 CPM 消息存储服务器中存储的该消息的阅读状态仍为未读, 从而导致基于 IMAP协议的 CPM消息存储月良务器中邮件的阅读状态与用户终端上关于该邮 件的阅读状态不一致, 从而导致用户再次上线时, 基于 IMAP协议的 CPM 消息存储服务器仍要向用户终端发送述用户终端已成功接收到的消息或 邮件, 不但会导致的资源的浪费, 更加使得用户重复接收, 影响用户体验。  Taking the CPM PF Server and the IMAP protocol-based CPM message storage server as an example, the CPM PF Server sends an IMAP STORE to the IMAP protocol-based CPM message storage server, and the CPM message storage server modifies the read status of the message to Unseen (indicating that the message has been read) ). In the IMAP-based message field, when the user goes online, the IMAP-based CPM message storage server needs to notify the user of the number of unread messages and unread messages. Through the method provided in this embodiment, the unread mail notified by the message storage server to the user is a message that the CPM PF Server does not send to the user terminal (or is not successfully sent to the user terminal). Therefore, the reading status of the mail in the CPM message storage server based on the IMAP protocol is consistent with the reading status of the mail on the user terminal. In the prior art, after the CPM message storage server based on the IMAP protocol receives the message forwarded by the service server, if the service server does not identify the read status, the read status of the message is unread by default. Therefore, if the message stored in the CPM message storage server based on the IMAP protocol has been successfully sent to the user terminal during the session, the read status of the message stored in the CPM message storage server based on the IMAP protocol is still unread. Therefore, the reading status of the mail in the CPM message storage server based on the IMAP protocol is inconsistent with the reading status of the mail on the user terminal, so that the CPM message storage server based on the IMAP protocol still needs to go to the user terminal when the user goes online again. Sending a message or email that has been successfully received by the user terminal not only causes waste of resources, but also makes the user repeatedly receive and affect the user experience.
进一步, 如果步骤 4a中, CPM存储服务器的存储响应中包括存储服务 器为该消息分配的唯一标识,则在步骤 11a中 CPM业务服务器向存储服务器 发送的消息修改请求中还包括 CPM存储服务器为该消息分配的唯一标识。 CPM存储服务器可根据该消息的唯一标识查找到该消息后, 修改该消息的阅 读状态。 Further, if the storage response of the CPM storage server is included in the storage service in step 4a The unique identifier assigned to the message is further included in the message modification request sent by the CPM service server to the storage server in step 11a, and the unique identifier assigned by the CPM storage server to the message. The CPM storage server can modify the read status of the message after finding the message according to the unique identifier of the message.
本实施例 CPM业务服务器向用户终端发送接收到的消息后,在确定该消 息已存储至 CPM存储服务器时,根据用户终端返回的接收响应确定该消息的 阅读状态为未读时, 请求 CPM存储服务器修改该消息的阅读状态。 CPM业 务服务器向用户终端发送接收到的消息后,确定该消息没有存储至 CPM存储 服务器时, 在消息接收阶段, CPM业务服务器不必对该消息的阅读状态进行 维护。 同样, 在 CPM业务服务器向 CPM存储服务器提交接收到的消息后, 若不需要向用户终端发送该消息, 在消息接收阶段, CPM业务服务器不必对 该消息的阅读状态进行维护。  After transmitting the received message to the user terminal, the CPM service server requests the CPM storage server when determining that the read status of the message is unread according to the receiving response returned by the user terminal when determining that the message has been stored to the CPM storage server. Modify the reading status of the message. After the CPM service server sends the received message to the user terminal and determines that the message is not stored to the CPM storage server, the CPM service server does not have to maintain the read status of the message during the message receiving phase. Similarly, after the CPM service server submits the received message to the CPM storage server, if the message does not need to be sent to the user terminal, the CPM service server does not have to maintain the read status of the message during the message receiving phase.
图 3为本发明提供的另一种消息状态设置方法实施例一流程图。 本实施 例与图 1或图 2的区别在于, 在图 1或图 2中, CPM业务服务器在向 CPM 存储服务器发送消息时, 不考虑是否需要将该消息发送至用户终端, 直接将 该消息发送至 CPM存储服务器, CPM存储服务器默认该消息的阅读状态为 未读。 而本实施例中, CPM业务服务器在向 CPM存储服务器发送消息之前, 还考虑到是否需要向用户终端发送至用户终端, 并标识该消息的阅读状态, 并将标识有阅读状态的消息发送给 CPM存储服务器。如图 3所示, 本实施例 包括:  FIG. 3 is a flowchart of Embodiment 1 of another method for setting a message state according to the present invention. The difference between this embodiment and FIG. 1 or FIG. 2 is that, in FIG. 1 or FIG. 2, when the CPM service server sends a message to the CPM storage server, the message is sent directly to the user terminal regardless of whether the message needs to be sent to the user terminal. To the CPM storage server, the CPM storage server defaults to reading the message as unread. In this embodiment, before sending the message to the CPM storage server, the CPM service server also considers whether it needs to send to the user terminal to the user terminal, and identifies the read status of the message, and sends a message indicating the read status to the CPM. Storage server. As shown in FIG. 3, this embodiment includes:
步骤 31; CPM业务服务器接收消息。  Step 31: The CPM service server receives the message.
步骤 32; 确定需要提交消息至 CPM存储服务器且需要发送消息至用户 终端, CPM业务服务器将消息的阅读状态标识为已读, 向 CPM存储服务器 发送消息存储请求, 并向用户终端发送消息; 消息存储请求中包括消息和消 息的阅读状态。  Step 32: determining that a message needs to be submitted to the CPM storage server and sending a message to the user terminal, the CPM service server identifies the read status of the message as read, sends a message storage request to the CPM storage server, and sends a message to the user terminal; message storage The request includes the read status of the message and the message.
CPM业务服务器可根据该消息对应的接收方用户的签约信息, 例如, 根 据签约信息中用户针对 "CPM业务服务器接收到的消息是否提交至 CPM存 储服务器"选择的意愿, 判断该消息是否需要提交 CPM存储服务器存储。 通 常情况下,用户在签约信息中选择 "用户在线时向 CPM存储服务器提交接收 到的消息, 用户离线时不向 CPM存储服务器提交接收到的消息" 。 进一步, 用户在签约信息中选择 "用户在线但消息的内容长度超过用户预设值时, 不 向 CPM存储服务器提交接收到的消息" 。 The CPM service server may according to the subscription information of the recipient user corresponding to the message, for example, the root According to the willingness of the user in the subscription information to select whether the message received by the CPM service server is submitted to the CPM storage server, it is determined whether the message needs to be submitted to the CPM storage server for storage. Normally, the user selects in the subscription information that "the user submits the received message to the CPM storage server when the user is online, and does not submit the received message to the CPM storage server when the user goes offline". Further, the user selects "the user does not submit the received message to the CPM storage server when the user is online but the content length of the message exceeds the user preset value" in the subscription information.
CPM业务服务器可根据该消息对应的接收方用户的签约信息, 例如, 根 据签约信息中用户针对 "CPM 业务服务器接收到的消息是否发送至用户终 端" 选择的意愿, 判断该消息是否需要发送到接收方用户的用户终端。 通常 情况下, 用户在签约信息中选择 "用户在线时向用户终端发送接收到的消息, 用户离线时不向用户终端发送接收到的消息" 。 进一步, 用户在签约信息中 选择 "用户在线但用户状态为忙碌或免打扰时, 不向用户终端发送接收到的 消息" 。  The CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the willingness of the user in the subscription information to select whether the message received by the CPM service server is sent to the user terminal, whether the message needs to be sent to and received. The user terminal of the party user. Normally, the user selects in the subscription information that "the user sends the received message to the user terminal when the user is online, and does not send the received message to the user terminal when the user goes offline". Further, the user selects "the user does not send the received message to the user terminal when the user is online but the user status is busy or do not disturb" in the subscription information.
步骤 33; CPM业务服务器接收用户终端返回的接收响应,根据终端返回 的接收响应确定的消息的阅读状态为未读,向 CPM存储服务器发送消息状态 修改请求, 所述消息状态修改请求中所述消息的阅读状态为未读。  Step 33: The CPM service server receives the receiving response returned by the user terminal, and the read status of the message determined according to the receiving response returned by the terminal is unread, and sends a message state modification request to the CPM storage server, where the message is in the message state modification request. The reading status is unread.
具体的, 如果接收响应为' ΌΚ"时, 表示用户终端接收成功, 确定该消息 的阅读状态为已读; 如果接收响应为 "Error"时, 表示用户终端接收失败, 确 定该消息的阅读状态为未读。  Specifically, if the receiving response is 'ΌΚ', it indicates that the user terminal receives successfully, and determines that the reading state of the message is read; if the receiving response is “Error”, indicating that the user terminal fails to receive, determining that the reading state of the message is unread.
本发明实施例的消息状态设置方法, CPM业务服务器需要提交所述消息 至存储服务器且需要发送所述消息至用户终端时, CPM业务服务器将所述消 息的阅读状态标识为已读,在向 CPM存储服务器消息存储请求时携带该消息 的阅读状态,使 CPM存储服务器存储该消息的阅读状态。根据所述终端返回 的接收响应确定的所述消息的阅读状态如果与消息存储请求中所述消息的阅 读状态不一致, CPM业务服务器向所述 CPM存储服务器发送消息状态修改 请求,根据终端返回的接收响应请求修改 CPM存储服务器中该消息的阅读状 态。 从而, CPM存储服务器中保存的消息的阅读状态与用户终端对该消息的 阅读状态保持一致,可避免 CPM存储服务器向用户终端发送用户终端已成功 接收到的消息, 节省了资源, 提高了用户体验。 In the message state setting method of the embodiment of the present invention, when the CPM service server needs to submit the message to the storage server and needs to send the message to the user terminal, the CPM service server identifies the read status of the message as read, in the CPM The storage server message storage request carries the read status of the message, so that the CPM storage server stores the read status of the message. And if the read status of the message determined according to the receiving response returned by the terminal is inconsistent with the read status of the message in the message storage request, the CPM service server sends a message status modification request to the CPM storage server, according to the receiving return by the terminal. Modify the read of the message in the CPM storage server in response to the request State. Therefore, the reading state of the message stored in the CPM storage server is consistent with the reading state of the message by the user terminal, which can prevent the CPM storage server from transmitting the message that the user terminal has successfully received to the user terminal, saving resources and improving the user experience. .
图 4为本发明提供的另一种消息状态设置方法实施例二流程图。 本实施 例为图 3对应实施例的细化流程。 如图 4所示, 本实施例包括:  FIG. 4 is a flowchart of Embodiment 2 of another method for setting a message state according to the present invention. This embodiment is a refinement flow of the corresponding embodiment of FIG. 3. As shown in FIG. 4, this embodiment includes:
步骤 lb: CPM业务服务器接收消息。  Step lb: The CPM Service Server receives the message.
步骤 2b: CPM业务服务器判断该消息是否需要提交 CPM存储服务器存 储, 并判断该消息是否需要发送至用户终端。  Step 2b: The CPM service server determines whether the message needs to be submitted to the CPM storage server for storage, and determines whether the message needs to be sent to the user terminal.
CPM业务服务器可根据该消息对应的接收方用户的签约信息, 例如, 根 据签约信息中用户针对 "CPM业务服务器接收到的消息是否提交至 CPM存 储服务器"选择的意愿, 判断该消息是否需要提交 CPM存储服务器存储。 通 常情况下,用户在签约信息中选择 "用户在线时向 CPM存储服务器提交接收 到的消息, 用户离线时不向 CPM存储服务器提交接收到的消息" 。 进一步, 用户在签约信息中选择 "用户在线但消息的内容长度超过用户预设值时, 不 向 CPM存储服务器提交接收到的消息" 。  The CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the user's willingness to select whether the message received by the CPM service server is submitted to the CPM storage server, whether the message needs to be submitted to the CPM. Storage server storage. In general, the user selects in the subscription information that "the user submits the received message to the CPM storage server when the user is online, and does not submit the received message to the CPM storage server when the user goes offline". Further, the user does not submit the received message to the CPM storage server when the user is online but the content length of the message exceeds the user preset value in the subscription information.
CPM业务服务器可根据该消息对应的接收方用户的签约信息, 例如, 根 据签约信息中用户针对 "CPM 业务服务器接收到的消息是否发送至用户终 端" 选择的意愿, 判断该消息是否需要发送到接收方用户的用户终端。 通常 情况下, 用户在签约信息中选择 "用户在线时向用户终端发送接收到的消息, 用户离线时不向用户终端发送接收到的消息" 。 进一步, 用户在签约信息中 选择 "用户在线但用户状态为忙碌或免打扰时, 不向用户终端发送接收到的 消息" 。  The CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the willingness of the user in the subscription information to select whether the message received by the CPM service server is sent to the user terminal, whether the message needs to be sent to and received. The user terminal of the party user. Normally, the user selects in the subscription information that "the user sends the received message to the user terminal when the user is online, and does not send the received message to the user terminal when the user goes offline". Further, the user selects "the user does not send the received message to the user terminal when the user is online but the user status is busy or do not disturb" in the subscription information.
步骤 3b: CPM业务服务器确定需要提交该消息至 CPM存储服务器且需 要发送该消息至用户终端时, CPM业务服务器将该消息的阅读状态标识为已 读。  Step 3b: When the CPM service server determines that the message needs to be submitted to the CPM storage server and needs to send the message to the user terminal, the CPM service server identifies the read status of the message as read.
步骤 4b: CPM业务服务器确定需要提交该消息至 CPM存储服务器但不 需要发送该消息至用户终端时, CPM业务服务器向 CPM存储服务器发送该 消息。 CPM业务服务器接收 CPM存储服务器的存储响应, 之后本流程结束。 Step 4b: The CPM service server determines that the message needs to be submitted to the CPM storage server but not When the message needs to be sent to the user terminal, the CPM service server sends the message to the CPM storage server. The CPM service server receives the storage response of the CPM storage server, and the process ends.
CPM存储服务器接收到该消息后, 默认该消息的阅读状态为未读, 对该 消息和该消息的阅读状态进行存储,存储之后向 CPM业务服务器返回存储响 应。  After receiving the message, the CPM storage server defaults to reading the message as unread, stores the message and the read status of the message, and returns a storage response to the CPM service server after storage.
CPM业务服务器确定不需要提交该消息至 CPM存储服务器但需要发送 该消息至用户终端时, 直接执行步骤 6b。  When the CPM service server determines that the message does not need to be submitted to the CPM storage server but needs to send the message to the user terminal, step 6b is directly executed.
步骤 5b: CPM业务服务器向所述 CPM存储服务器发送包括该消息和该 消息的阅读状态的消息存储请求, CPM存储服务器存储该消息后返回存储响 应。  Step 5b: The CPM service server sends a message storage request including the message and the read status of the message to the CPM storage server, and the CPM storage server stores the message and returns a storage response.
步骤 6b: CPM业务服务器向用户终端发送该消息,接收用户终端返回的 接收响应。  Step 6b: The CPM service server sends the message to the user terminal, and receives the receiving response returned by the user terminal.
进一步, 如果在步骤 5b中存储响应包括 CPM存储服务器为该消息分配 的唯一标识(UID ) , 步骤 6b中 CPM业务服务器向用户终端发送该消息时 还携带有该消息的 UID。在 CPM存储服务器将消息同步到用户终端时, 除了 需要将阅读状态为 "未读" 的消息同步到用户终端外, 同时还需要检查存储 服务器中阅读状态为 "已读" 的消息是否与用户终端保存的消息是否一致, 即进行消息一致性检查。 如果不一致, CPM存储服务器将与用户终端不一致 的消息同步到用户终端。由于 CPM存储服务器有可能不能识别 MID,或 CPM 存储服务器保存的消息中不包括 MID , 因此通过 MID检查消息的一致性时, 还需要采用其它的辅助信息和方法, 从而实现时复杂度较高。 而用户终端中 保存的消息包括有 UID时,可通过消息的 UID的一致性判断用户终端保存的 消息是否与 CPM存储服务器保存的消息一致。 因此, 通过检查 UID可降低 CPM存储服务器将消息同步到用户终端时, 检查消息一致性时的复杂度。  Further, if the stored response in step 5b includes a unique identifier (UID) assigned by the CPM storage server for the message, the CPM service server in step 6b also carries the UID of the message when transmitting the message to the user terminal. When the CPM storage server synchronizes the message to the user terminal, in addition to synchronizing the message whose read status is "unread" to the user terminal, it is also necessary to check whether the message in the storage server whose read status is "read" is related to the user terminal. Whether the saved messages are consistent, that is, the message consistency check is performed. If not, the CPM storage server synchronizes the message with the user terminal to the user terminal. Since the CPM storage server may not be able to recognize the MID, or the MPM is not included in the message stored by the CPM storage server, when the MID is used to check the consistency of the message, other auxiliary information and methods are needed, so that the implementation complexity is high. When the message stored in the user terminal includes the UID, the consistency of the UID of the message may be used to determine whether the message saved by the user terminal is consistent with the message saved by the CPM storage server. Therefore, by checking the UID, the complexity of checking the message consistency when the CPM storage server synchronizes the message to the user terminal can be reduced.
通常情况下, CPM存储服务器可在预设时间到达时自动进将消息同步 到用户终端; CPM存储服务器也可以在用户上线时, 根据用户终端的主动 请求将消息同步到用户终端; CPM存储服务器也可以按照其它预设规定将消 息同步到用户终端。 Normally, the CPM storage server can automatically synchronize messages to the user terminal when the preset time arrives. The CPM storage server can also be activated according to the user terminal when the user goes online. Request to synchronize the message to the user terminal; the CPM storage server can also synchronize the message to the user terminal according to other preset rules.
步骤 7b: CPM业务服务器判断该消息是否已存储在 CPM存储服务器。 如果已存储在 CPM存储服务器, 执行步骤 8b, 否则结束。  Step 7b: The CPM service server determines whether the message is stored in the CPM storage server. If it is already stored on the CPM storage server, go to step 8b, otherwise it ends.
CPM业务服务器可通过自身緩存的 CPM存储服务器返回的存储响应, 判断与用户终端返回的接收响应对应的该消息是否已存储在 CPM存储服务 器。 例如, CPM业务服务器可根据接收响应中携带的 CPM业务服务器为该 消息分配的标识(MID ) , 查找緩存的存储响应。 如果查找到该 MID对应的 存储响应, 则确定该消息已存储在 CPM存储服务器。 进一步, 如果存储响应 中包括 CPM存储服务器为该消息的唯一标识(UID ) , CPM业务服务器也 可根据接收响应中携带的 UID查找緩存的存储响应,如果查找到该 UID对应 的存储响应, 则确定该消息已存储在 CPM存储服务器。 另外, 判断与接收响 应对应的该消息是否已存储在 CPM存储服务器的方法有多种实现方式,不再 歹'】举。  The CPM service server can determine whether the message corresponding to the received response returned by the user terminal is stored in the CPM storage server through the storage response returned by the cached CPM storage server. For example, the CPM service server may look up the cached storage response according to the identifier (MID) assigned by the CPM service server carried in the response to the message. If the storage response corresponding to the MID is found, it is determined that the message is stored in the CPM storage server. Further, if the storage response includes the CPM storage server as the unique identifier (UID) of the message, the CPM service server may also search for the cached storage response according to the UID carried in the received response, and if the storage response corresponding to the UID is found, determine The message is already stored on the CPM storage server. In addition, there are various ways to determine whether the message corresponding to the receiving response has been stored in the CPM storage server, and no longer.
步骤 8b: 在该消息已存储在 CPM存储服务器时, CPM业务服务器根据 接收响应确定该消息的阅读状态。  Step 8b: When the message is stored in the CPM storage server, the CPM service server determines the read status of the message based on the received response.
步骤 9b: CPM业务服务器判断根据接收响应确定的该消息的阅读状态是 否为未读。 如果是未读, 执行步骤 10b, 否则本流程结束。  Step 9b: The CPM service server determines whether the read status of the message determined according to the received response is unread. If it is unread, go to step 10b, otherwise the process ends.
具体的, 如果接收响应为' ΌΚ"时, 表示用户终端接收成功, 该消息的阅 读状态为已读; 如果接收响应为 "Error"时, 表示用户终端接收失败, 该消息 的阅读状态为未读。  Specifically, if the receiving response is 'ΌΚ', it indicates that the user terminal receives successfully, and the reading state of the message is read; if the receiving response is “Error”, it indicates that the user terminal fails to receive, and the reading state of the message is unread. .
CPM业务服务器根据接收响应确定该消息的阅读状态为已读时, 由于在 步骤 3b已请求 CPM存储服务器将该消息的阅读状态标识为已读, 因此不需 要修改 CPM存储服务器中该消息的阅读状态, 本流程结束。  When the CPM service server determines that the read status of the message is read according to the received response, since the CPM storage server is requested to identify the read status of the message as read in step 3b, there is no need to modify the read status of the message in the CPM storage server. , the process ends.
步骤 10b: CPM业务服务器根据接收响应确定该消息的阅读状态为未读 时, 向 CPM存储服务器发送消息修改请求, 请求 CPM存储服务器将该消息 的阅读状态修改为未读。 之后, CPM业务服务器接收 CPM存储服务器返回 修改响应, 本流程结束。 Step 10b: When the CPM service server determines that the read status of the message is unread according to the received response, the CPM service server sends a message modification request to the CPM storage server, requesting the CPM storage server to send the message. The reading status is changed to unread. After that, the CPM service server receives the CPM storage server and returns a modification response, and the process ends.
图 5为本发明提供的又一种消息状态设置方法实施例一流程图。 本实施 例适应于 CPM业务服务器批量处理接收到的消息。如图 5所示, 本实施例包 括:  FIG. 5 is a flowchart of still another embodiment of a message state setting method according to the present invention. This embodiment is adapted to batch processing of received messages by the CPM service server. As shown in FIG. 5, this embodiment includes:
步骤 51: CPM业务服务器接收消息。  Step 51: The CPM service server receives the message.
步骤 52: 确定消息需要提交 CPM存储服务器存储, CPM业务服务器緩 存该消息。  Step 52: Determine that the message needs to be submitted to the CPM storage server store, and the CPM service server caches the message.
CPM业务服务器可根据该消息对应的接收方用户的签约信息, 例如, 根 据签约信息中用户针对 "CPM业务服务器接收到的消息是否提交至 CPM存 储服务器"选择的意愿, 判断该消息是否需要提交 CPM存储服务器存储。 通 常情况下,用户在签约信息中选择 "用户在线时向 CPM存储服务器提交接收 到的消息, 用户离线时不向 CPM存储服务器提交接收到的消息" 。 进一步, 用户在签约信息中选择 "用户在线但消息的内容长度超过用户预设值时, 不 向 CPM存储服务器提交接收到的消息" 。  The CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the user's willingness to select whether the message received by the CPM service server is submitted to the CPM storage server, whether the message needs to be submitted to the CPM. Storage server storage. In general, the user selects in the subscription information that "the user submits the received message to the CPM storage server when the user is online, and does not submit the received message to the CPM storage server when the user goes offline". Further, the user does not submit the received message to the CPM storage server when the user is online but the content length of the message exceeds the user preset value in the subscription information.
步骤 53: 确定消息需要发送到用户终端, CPM业务服务器向用户终端发 送该消息, 并接收到用户终端返回的接收响应。  Step 53: Determine that the message needs to be sent to the user terminal, and the CPM service server sends the message to the user terminal, and receives the receiving response returned by the user terminal.
CPM业务服务器可根据该消息对应的接收方用户的签约信息, 例如, , 根据签约信息中用户针对 "CPM业务服务器接收到的消息是否发送至用户终 端" 选择的意愿, 判断该消息是否需要发送到接收方用户的用户终端。 通常 情况下, 用户在签约信息中选择 "用户在线时向用户终端发送接收到的消息, 用户离线时不向用户终端发送接收到的消息" 。 进一步, 用户在签约信息中 选择 "用户在线但用户状态为忙碌或免打扰时, 不向用户终端发送接收到的 消息" 。  The CPM service server may determine, according to the subscription information of the recipient user corresponding to the message, for example, according to the willingness of the user in the subscription information to select whether the message received by the CPM service server is sent to the user terminal, whether the message needs to be sent to the User terminal of the recipient user. Normally, the user selects in the subscription information that "the user sends the received message to the user terminal when the user is online, and does not send the received message to the user terminal when the user goes offline". Further, the user selects "the user does not send the received message to the user terminal when the user is online but the user status is busy or do not disturb" in the subscription information.
步骤 54: 确定已緩存有与所述接收响应对应的消息, 根据用户终端返回 的接收响应, 标识緩存的与接收响应对应的消息的阅读状态。 步骤 55: CPM业务服务器向 CPM存储服务器发送消息存储请求, 消息 存储请求包括緩存的各消息和各消息的阅读状态。 Step 54: Determine that a message corresponding to the received response is buffered, and identify a read status of the cached message corresponding to the received response according to the received response returned by the user terminal. Step 55: The CPM service server sends a message storage request to the CPM storage server, where the message storage request includes the cached messages and the read status of each message.
可在接收到需处理的多个消息或緩存的消息有多个时, 如緩存空间已满 或达到预设的緩存量时, CPM业务服务器向 CPM存储服务器发送消息存储 请求。  The CPM service server may send a message storage request to the CPM storage server when there are multiple messages or cached messages to be processed, such as when the cache space is full or the preset cache amount is reached.
本实施例 CPM业务服务器接收到消息后, 先緩存需要提交至 CPM存储 服务器的消息, 对于緩存的需要发送至用户终端的消息, CPM业务服务器根 据用户终端返回的接收响应标识緩存的消息的阅读状态。 CPM业务服务器将 緩存的消息及其阅读状态批量发送给 CPM存储服务器进行存储。 因此,对于 需要提交至 CPM存储服务器存储且同时需要发送至用户终端的消息, CPM 存储服务器中保存的该消息的阅读状态与用户终端关于该消息的阅读状态保 持一致,可避免 CPM存储服务器向用户终端发送用户终端已成功接收到的消 息, 节省了资源, 提高了用户资源。  After receiving the message, the CPM service server first caches the message that needs to be submitted to the CPM storage server. For the cached message that needs to be sent to the user terminal, the CPM service server identifies the read status of the cached message according to the received response returned by the user terminal. . The CPM service server sends the cached messages and their read status to the CPM storage server for storage. Therefore, for a message that needs to be submitted to the CPM storage server storage and needs to be sent to the user terminal at the same time, the reading state of the message stored in the CPM storage server is consistent with the reading state of the message by the user terminal, so that the CPM storage server can be avoided from being sent to the user. The terminal sends a message that the user terminal has successfully received, which saves resources and improves user resources.
图 6为本发明提供的又一种消息状态设置方法实施例二流程图。 本实施 例为图 6对应实施例的详细流程。 如图 6所示。 本实施例包括:  FIG. 6 is a flowchart of still another embodiment 2 of a message state setting method according to the present invention. This embodiment is a detailed flow of the corresponding embodiment of Fig. 6. As shown in Figure 6. This embodiment includes:
步骤 lc: CPM业务服务器接收消息。  Step lc: The CPM service server receives the message.
步骤 2c: CPM业务服务器判断该消息是否提交至 CPM存储服务器存储。 如果是执行步骤 3c, 否则执行步骤 4c。  Step 2c: The CPM service server determines whether the message is submitted to the CPM storage server storage. If step 3c is performed, otherwise step 4c is performed.
步骤 3c: CPM业务服务器緩存待提交至 CPM存储服务器的消息。之后, 执行步骤 5c。  Step 3c: The CPM service server caches messages to be submitted to the CPM storage server. After that, go to step 5c.
步骤 4c: 在确定该消息需要发送至用户终端时, 将该消息发送至用户终 端。 之后, 本流程结束。  Step 4c: When it is determined that the message needs to be sent to the user terminal, the message is sent to the user terminal. After that, the process ends.
步骤 5c: CPM业务服务器判断该消息是否发送至用户终端。如果是执行 步骤 6c, 否则执行步骤 11c: 即 CPM业务服务器将緩存的该消息的阅读状态 标识为未读, 并执行步骤 12c。  Step 5c: The CPM service server determines whether the message is sent to the user terminal. If step 6c is performed, otherwise step 11c is performed: that is, the CPM service server identifies the read status of the cached message as unread, and executes step 12c.
步骤 6c: CPM业务服务器将该消息发送至用户终端, 并接收用户终端返 回的接收响应。 Step 6c: The CPM service server sends the message to the user terminal, and receives the user terminal. Receive response back.
步骤 7c: CPM业务服务器判断是否緩存有与该接收响应对应的消息。如 果是步骤 8c, 否则本流程结束。  Step 7c: The CPM service server determines whether a message corresponding to the received response is cached. If it is step 8c, the process ends.
CPM业务服务器可通过自身緩存的消息, 判断是否緩存有与用户终端返 回的接收响应对应的消息。 例如, CPM 业务服务器根据接收响应中携带的 CPM业务服务器为消息分配的标识(MID ) , 查找緩存的消息, 如果查找到 与 MID对应緩存的该消息, 则确定该消息已緩存。 另外, 判断接收响应对应 的消息是否已存储在 CPM存储服务器的方法有多种实现方式, 不再一一列 举。  The CPM service server can determine whether to cache a message corresponding to the received response returned by the user terminal by using the cached message. For example, the CPM service server searches for the cached message according to the identifier (MID) assigned by the CPM service server carried in the response, and if the message cached corresponding to the MID is found, it is determined that the message is cached. In addition, there are various implementation methods for judging whether the message corresponding to the received response has been stored in the CPM storage server, and will not be listed one by one.
步骤 8c: CPM业务服务器判断接收响应是否表示接收成功。如果是执行 步骤 9c, 否则执行步骤 10c。  Step 8c: The CPM service server determines whether the reception response indicates that the reception is successful. If it is, go to step 9c, otherwise go to step 10c.
具体的, 如果接收响应为' ΌΚ"时, 表示用户终端接收成功, 该消息的阅 读状态为已读; 如果接收响应为 "Error"时, 表示用户终端接收失败, 该消息 的阅读状态为未读。  Specifically, if the receiving response is 'ΌΚ', it indicates that the user terminal receives successfully, and the reading state of the message is read; if the receiving response is “Error”, it indicates that the user terminal fails to receive, and the reading state of the message is unread. .
步骤 9c: CPM业务服务器将緩存中与接收响应对应的消息的阅读状态标 识为已读。  Step 9c: The CPM service server identifies the read status of the message in the cache corresponding to the received response as read.
步骤 10c: CPM业务服务器将緩存中与接收响应对应的消息的阅读状态 标识为未读。  Step 10c: The CPM service server identifies the read status of the message in the cache corresponding to the received response as unread.
重复以上步骤,直至 CPM业务服务器的緩存已满或已接收到批量处理的 一批消息后, 执行步骤 12c。  Repeat the above steps until the CPM service server's cache is full or has received a batch of batch processed messages, and then perform step 12c.
步骤 12c: CPM业务服务器将緩存的各消息和各消息的阅读状态发送至 CPM存储服务器后, 接收 CPM存储服务器返回的存储响应。 之后本流程结 束。  Step 12c: After sending the cached messages and the read status of each message to the CPM storage server, the CPM service server receives the storage response returned by the CPM storage server. Then the process ends.
通过本实施例提供的方法, 对于只需要发送至用户终端的消息, 不需要 在 CPM业务服务器中緩存;对于只需要提交至 CPM存储服务器的消息 , CPM 业务服务器将緩存这些消息的阅读状态标识为未读。 对于需要同时提交至 CPM存储服务器和发送至用户终端的消息, CPM业务服务器緩存该消息后 , 根据用户终端返回的接收响应标识该消息的阅读状态。 With the method provided in this embodiment, the message that needs to be sent only to the user terminal does not need to be cached in the CPM service server; for the message that only needs to be submitted to the CPM storage server, the CPM service server identifies the read status of the cached message as unread. For need to submit to both The CPM stores the server and the message sent to the user terminal. After the CPM service server caches the message, the CPM service server identifies the read status of the message according to the received response returned by the user terminal.
图 7A为本发明提供的一种 CPM业务服务器实施例一结构示意图。 如图 7A所示, 本实施例提供的业务器包括: 接收模块 71、 消息存储请求块 72、 发送模块 73和状态修改请求模块 74。  FIG. 7A is a schematic structural diagram of Embodiment 1 of a CPM service server according to the present invention. As shown in FIG. 7A, the service device provided in this embodiment includes: a receiving module 71, a message storage requesting block 72, a sending module 73, and a state modifying requesting module 74.
接收模块 71 , 用于接收消息。  The receiving module 71 is configured to receive a message.
消息存储请求块 72, 用于确定所述消息需要提交 CPM存储服务器存储, 向所述 CPM存储服务器发送包括所述消息的消息存储请求。  The message storage request block 72 is configured to determine that the message needs to be submitted to the CPM storage server storage, and send a message storage request including the message to the CPM storage server.
发送模块 73 , 用于确定所述消息需要发送到用户终端, 向所述用户终端 发送所述消息。  The sending module 73 is configured to determine that the message needs to be sent to the user terminal, and send the message to the user terminal.
接收模块 71 , 还用于接收所述用户终端返回的接收响应。  The receiving module 71 is further configured to receive a receiving response returned by the user terminal.
状态修改请求模块 74, 确定 CPM存储服务器中存储有与所述接收响应 对应的消息, 且根据所述用户终端返回的接收响应确定与所述接收响应对 应的消息的阅读状态为已读, 向所述 CPM存储服务器发送消息状态修改 请求, 所述消息状态修改请求中所述消息的阅读状态为已读。  The status modification requesting module 74 determines that the CPM storage server stores a message corresponding to the received response, and determines, according to the received response returned by the user terminal, that the read status of the message corresponding to the received response is read. The CPM storage server sends a message state modification request, and the read state of the message in the message state modification request is read.
进一步, 接收模块 71 , 还用于接收所述 CPM存储服务器返回的包括有 所述 CPM存储服务器为所述消息分配的标识的存储响应。 发送模块 73 , 具 体用于向所述用户终端发送所述消息和所述 CPM存储服务器为所述消息分 配的标 i只。  Further, the receiving module 71 is further configured to receive a storage response returned by the CPM storage server that includes the identifier allocated by the CPM storage server for the message. The sending module 73 is specifically configured to send the message to the user terminal and the target that the CPM storage server allocates the message.
进一步, 如图 7B所示, 状态修改请求模块 74包括: 存储确定单元 741、 状态确定单元 742和状态修改请求单元 743。  Further, as shown in FIG. 7B, the state modification requesting module 74 includes: a storage determining unit 741, a state determining unit 742, and a state modifying requesting unit 743.
存储确定单元 741 , 用于接收模块 71接收到所述用户终端返回的接收响 应, 确定 CPM存储服务器中存储有与所述接收响应对应的消息。  The storage determining unit 741 is configured to receive, by the receiving module 71, a receiving response returned by the user terminal, and determine that a message corresponding to the receiving response is stored in the CPM storage server.
状态确定单元 742, 用于根据所述终端返回的接收响应确定的所述消 息的阅读状态为已读。  The status determining unit 742 is configured to read the read status of the message according to the received response returned by the terminal.
状态修改请求单元 743 , 用于状态确定单元 742确定所述消息的阅读状 态为已读后, 向所述 CPM存储服务器发送消息状态修改请求。 a state modification requesting unit 743, configured to determine the read condition of the message by the state determining unit 742 After the state is read, a message state modification request is sent to the CPM storage server.
进一步, 所述状态确定单元 742, 具体用于所述接收响应中包括所述 CPM存储服务器为所述消息分配的标识时, 确定 CPM存储服务器中存储 有与所述接收响应对应的消息后, 根据所述接收响应中的所述 CPM存储服 务器为所述消息分配的标识确定与所述接收响应对应的消息的阅读状态 为已读。  Further, the state determining unit 742 is specifically configured to: after determining, by the CPM storage server, the identifier that is allocated by the CPM storage server for the message, determining that the CPM storage server stores a message corresponding to the received response, according to The identifier allocated by the CPM storage server in the receiving response for the message determines that the read status of the message corresponding to the received response is read.
以上各模块实现的功能可参见图 1和图 2对应实施例中描述, 在此不再 赘述。  The functions implemented in the above modules can be described in the corresponding embodiments in FIG. 1 and FIG. 2, and details are not described herein again.
本发明实施提供的 CPM业务服务器确定需要向 CPM存储服务器提交接 收到的消息时, 将该消息发送给 CPM存储服务器。 CPM存储服务器接收到 没有标识阅读状态的消息后, CPM存储服务器默认该消息的阅读状态为未 读。如果 CPM业务服务器需要向用户终端发送该消息,后续如果根据所述终 端返回的接收响应确定与所述接收响应对应的消息的阅读状态为已读, 即所 述消息的阅读状态与 CPM存储服务器中所述消息的阅读状态不一致。 CPM 业务服务器向所述 CPM存储服务器发送消息状态修改请求,根据终端返回的 接收响应请求修改 CPM存储服务器中该消息的阅读状态。 从而, CPM存储 服务器中保存的消息的阅读状态与用户终端对该消息的接收状态保持一致。  When the CPM service server provided by the implementation of the present invention determines that the received message needs to be submitted to the CPM storage server, the message is sent to the CPM storage server. After the CPM storage server receives a message that does not identify the read status, the CPM storage server defaults to reading the message as unread. If the CPM service server needs to send the message to the user terminal, if it is determined according to the received response returned by the terminal, the read status of the message corresponding to the received response is read, that is, the read status of the message and the CPM storage server. The reading status of the message is inconsistent. The CPM service server sends a message state modification request to the CPM storage server, and modifies the read state of the message in the CPM storage server according to the receiving response request returned by the terminal. Thus, the read status of the message stored in the CPM storage server is consistent with the receiving status of the message by the user terminal.
图 8为本发明提供的另一种 CPM业务服务器实施例结构示意图。 如图 8 所示, 本实施例提供的业务器包括: 接收模块 81、 消息存储请求块 82、 发送 模块 83和状态修改请求模块 84以及确定模块 85。  FIG. 8 is a schematic structural diagram of another embodiment of a CPM service server according to the present invention. As shown in FIG. 8, the service provider provided in this embodiment includes: a receiving module 81, a message storage request block 82, a sending module 83 and a state modification requesting module 84, and a determining module 85.
接收模块 81 , 用于接收消息。  The receiving module 81 is configured to receive a message.
确定模块 85, 用于确定需要提交所述消息至 CPM存储服务器且需要 发送所述消息至用户终端, 将所述消息的阅读状态标识为已读。  The determining module 85 is configured to determine that the message needs to be submitted to the CPM storage server and needs to send the message to the user terminal, and the read status of the message is identified as read.
消息存储请求模块 82, 用于向所述 CPM存储服务器发送消息存储请 求; 所述消息存储请求中包括所述消息和所述消息的阅读状态。  The message storage requesting module 82 is configured to send a message storage request to the CPM storage server; the message storage request includes the message and a read status of the message.
发送模块 83 , 用于向所述用户终端发送所述消息。 接收模块 81 , 进一步用于接收所述用户终端返回的接收响应。 The sending module 83 is configured to send the message to the user terminal. The receiving module 81 is further configured to receive a receiving response returned by the user terminal.
状态修改请求模块 84,用于根据所述用户终端返回的接收响应确定与所 述接收响应对应的消息的阅读状态为未读, 向所述 CPM存储服务器发送 消息状态修改请求, 所述消息状态修改请求中所述消息的阅读状态为未 读。  The state modification requesting module 84 is configured to determine, according to the receiving response returned by the user terminal, that the read state of the message corresponding to the received response is unread, and send a message state modification request to the CPM storage server, where the message state is modified. The read status of the message described in the request is unread.
进一步, 接收模块 81进一步用于接收所述 CPM存储服务器返回的包括 有所述 CPM存储服务器为所述消息分配的标识的存储响应。 发送模块 83 , 具体用于向所述用户终端发送所述消息和所述 CPM存储服务器为所述消息 分配的标识。  Further, the receiving module 81 is further configured to receive a storage response returned by the CPM storage server that includes the identifier allocated by the CPM storage server for the message. The sending module 83 is specifically configured to send the message to the user terminal and an identifier that is allocated by the CPM storage server for the message.
状态修改请求模块 84, 具体用于所述接收响应中包括所述 CPM存储 服务器为所述消息分配的标识时, 根据所述接收响应中的所述 CPM存储 服务器为所述消息分配的标识确定与所述接收响应对应的消息的阅读状 态为未读, 向所述 CPM存储服务器发送消息状态修改请求。  The state modification requesting module 84 is specifically configured to determine, according to the identifier allocated by the CPM storage server for the message, in the receiving response, that includes the identifier allocated by the CPM storage server for the message. And the read status of the message corresponding to the received response is unread, and the message status modification request is sent to the CPM storage server.
以上各模块实现的功能可参见图 3和图 4对应实施例中描述, 在此不再 赘述。  The functions implemented in the above modules can be described in the corresponding embodiments in FIG. 3 and FIG. 4, and details are not described herein again.
本发明实施提供的 CPM业务服务器需要提交所述消息至 CPM存储服务 器且需要发送所述消息至用户终端时, CPM业务服务器将所述消息的阅读状 态标识为已读, 在向 CPM存储服务器消息存储请求时携带该消息的阅读状 态, 使 CPM存储服务器存储该消息的阅读状态为已读。 后所述 CPM业务服 务哭根据所述终端返回的接收响应确定所述消息的阅读状态, 如果与消息存 储请求中所述消息的阅读状态不一致即如果根据所述终端返回的接收响应确 定所述消息的阅读状态为未读, CPM业务服务器向所述 CPM存储服务器发 送消息状态修改请求,根据终端返回的接收响应请求修改 CPM存储服务器中 该消息的阅读状态。 从而, CPM存储服务器中保存的消息的阅读状态与用户 终端对该消息的阅读状态保持一致。  When the CPM service server provided by the implementation of the present invention needs to submit the message to the CPM storage server and needs to send the message to the user terminal, the CPM service server identifies the read status of the message as read, and stores the message in the CPM storage server. The request carries the read status of the message, so that the CPM storage server stores the read status of the message as read. The CPM service service crying determines the read status of the message according to the receiving response returned by the terminal, if the message is inconsistent with the read status of the message in the message storage request, that is, if the message is determined according to the received response returned by the terminal The read status is unread, and the CPM service server sends a message status modification request to the CPM storage server, and the read status of the message in the CPM storage server is modified according to the received response request returned by the terminal. Thus, the read status of the message stored in the CPM storage server is consistent with the read status of the message by the user terminal.
图 9Α为本发明提供的又一种 CPM业务服务器实施例一结构示意图。 如 图 9A所示, 本实施例提供的业务器包括: 接收模块 91、 緩存模块 92、 发送 模块 93、 状态标识模块 94和消息存储请求模块 95。 FIG. 9 is a schematic structural diagram of another embodiment of a CPM service server according to the present invention. Such as As shown in FIG. 9A, the service device provided in this embodiment includes: a receiving module 91, a cache module 92, a sending module 93, a status identifying module 94, and a message storage requesting module 95.
接收模块 91 , 用于接收消息。  The receiving module 91 is configured to receive a message.
緩存模块 92, 用于确定所述消息需要提交 CPM存储服务器存储, 并緩 存所述消息。  The cache module 92 is configured to determine that the message needs to be submitted to the CPM storage server storage, and cache the message.
发送模块 93 , 用于确定所述消息需要发送到用户终端, 向所述用户终端 发送所述消息。  The sending module 93 is configured to determine that the message needs to be sent to the user terminal, and send the message to the user terminal.
接收模块 91进一步用于接收所述用户终端返回的接收响应。  The receiving module 91 is further configured to receive a receiving response returned by the user terminal.
状态标识模块 94, 用于确定已緩存有与所述接收响应对应的消息, 根据 用户终端返回的接收响应, 标识緩存的与所述接收响应对应的消息的阅读状 态。  The status identification module 94 is configured to determine that a message corresponding to the received response is buffered, and identify a read status of the cached message corresponding to the received response according to the received response returned by the user terminal.
消息存储请求模块 95 , 用于向所述 CPM存储服务器发送消息存储请求 , 所述消息存储请求包括緩存的各消息和各消息对应的阅读状态。  The message storage requesting module 95 is configured to send a message storage request to the CPM storage server, where the message storage request includes each cached message and a read status corresponding to each message.
进一步, 状态标识模块 95 , 还用于在緩存所述消息之后, 确定所述消息 不需要发送到所述用户终端, 将所述緩存的与所述接收响应对应的消息的阅 读状态标识为未读。  Further, the status identification module 95 is further configured to: after the message is cached, determine that the message does not need to be sent to the user terminal, and identify a read status of the cached message corresponding to the received response as unread .
进一步, 如图 9B所示, 状态标识模块 94包括: 第一标识单元 941、 第 二标识单元 942和第三标识单元 943。  Further, as shown in FIG. 9B, the status identification module 94 includes: a first identification unit 941, a second identification unit 942, and a third identification unit 943.
第一标识单元 941 , 用于所述用户终端返回的接收响应表示接收成功时, 将緩存的与所述接收响应对应的消息的阅读状态标识为已读。  The first identifier unit 941 is configured to: when the receiving response returned by the user terminal indicates that the receiving is successful, the read status of the cached message corresponding to the received response is identified as read.
第二标识单元 942, 用于所述用户终端返回的接收响应表示接收失败时, 将緩存模块 92緩存的与所述接收响应对应的消息的阅读状态标识为未读。  The second identifier unit 942, the receiving response for returning by the user terminal indicates that the read status of the message buffered by the cache module 92 corresponding to the received response is unread when the receiving fails.
第三标识单元 943 , 用于在緩存所述消息之后, 确定所述消息不需要发 送到用户终端时, 将所述緩存的所述消息的阅读状态标识为未读。  The third identifying unit 943 is configured to: after the message is cached, determine that the read status of the cached message is unread when the message does not need to be sent to the user terminal.
以上各模块实现的功能可参见图 5和图 6对应实施例中描述, 在此不再 赘述。 本发明实施提供的 CPM 业务服务器接收到消息后, 先緩存需要提交至 CPM存储服务器的消息, 对于緩存中需要发送至用户终端的消息, CPM 业 务服务器根据用户终端返回的接收响应标识緩存中消息的阅读状态。 CPM业 务服务器将緩存的消息及其阅读状态批量发送给 CPM存储服务器进行存储。 因此,对于需要提交至 CPM存储服务器存储且同时需要发送至用户终端的消 息, CPM存储服务器中保存的该消息的阅读状态与用户终端关于该消息的阅 读状态保持一致。 The functions implemented in the above modules are described in the corresponding embodiments in FIG. 5 and FIG. 6, and details are not described herein again. After receiving the message, the CPM service server of the present invention first caches a message that needs to be submitted to the CPM storage server. For the message that needs to be sent to the user terminal in the cache, the CPM service server identifies the message in the cache according to the received response returned by the user terminal. Reading status. The CPM service server batches the cached messages and their read status to the CPM storage server for storage. Therefore, for messages that need to be submitted to the CPM storage server store and that need to be sent to the user terminal at the same time, the read status of the message stored in the CPM storage server is consistent with the read status of the message by the user terminal.
本领域普通技术人员可以理解: 实现上述方法实施例的全部或部分步骤 可以通过程序指令相关的硬件来完成, 前述的程序可以存储于一计算机可读 取存储介质中, 该程序在执行时, 执行包括上述方法实施例的步骤; 而前述 的存储介质包括: ROM、 RAM, 磁碟或者光盘等各种可以存储程序代码的介 质。  A person skilled in the art can understand that all or part of the steps of implementing the above method embodiments may be completed by using hardware related to program instructions, and the foregoing program may be stored in a computer readable storage medium, and the program is executed when executed. The foregoing steps include the steps of the foregoing method embodiments; and the foregoing storage medium includes: a medium that can store program codes, such as a ROM, a RAM, a magnetic disk, or an optical disk.
最后应说明的是: 以上实施例仅用以说明本发明的技术方案, 而非对其 限制; 尽管参照前述实施例对本发明进行了详细的说明, 本领域的普通技术 人员应当理解: 其依然可以对前述各实施例所记载的技术方案进行修改, 或 者对其中部分技术特征进行等同替换; 而这些修改或者替换, 并不使相应技 术方案的本质脱离本发明各实施例技术方案的精神和范围。  It should be noted that the above embodiments are only for explaining the technical solutions of the present invention, and are not intended to be limiting; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those skilled in the art that: The technical solutions described in the foregoing embodiments are modified, or some of the technical features are equivalently replaced. The modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

权 利 要求 书 Claim
1、 一种消息状态设置方法, 其特征在于, 包括:  A message state setting method, which is characterized by comprising:
接收消息;  Receiving a message;
确定所述消息需要提交存储服务器存储, 向所述存储服务器发送包括 所述消息的消息存储请求;  Determining that the message needs to be submitted to the storage server storage, and sending a message storage request including the message to the storage server;
确定所述消息需要发送到用户终端, 向所述用户终端发送所述消息; 接收到所述用户终端返回的接收响应时,确定 CPM存储服务器中存储 有与所述接收响应对应的消息且根据所述用户终端返回的接收响应确定与 所述接收响应对应的消息的阅读状态为已读, 向所述 CPM存储服务器发 送消息状态修改请求, 所述消息状态修改请求中所述消息的阅读状态为已 读。  Determining that the message needs to be sent to the user terminal, and sending the message to the user terminal; when receiving the receiving response returned by the user terminal, determining that the CPM storage server stores a message corresponding to the receiving response and according to the The receiving response returned by the user terminal determines that the read status of the message corresponding to the received response is read, and sends a message status modification request to the CPM storage server, where the read status of the message in the message status modification request is read.
2、 根据权利要求 1 所述方法, 其特征在于, 根据所述用户终端返回 的接收响应确定与所述接收响应对应的消息的阅读状态为已读包括:  2. The method according to claim 1, wherein determining, according to the received response returned by the user terminal, that the read status of the message corresponding to the received response is read includes:
确定所述用户终端返回的接收响应表示接收成功, 确定所述消息的阅 读^犬态为已读。  Determining that the receiving response returned by the user terminal indicates that the receiving is successful, determining that the read status of the message is read.
3、 根据权利要求 1或 2所述方法, 其特征在于, 在向所述 CPM存储 服务器发送消息存储请求之后, 还包括: 接收所述 CPM存储服务器返回 的包括有所述 CPM存储服务器为所述消息分配的标识的存储响应;  The method according to claim 1 or 2, after the sending of the message storage request to the CPM storage server, the method further comprising: receiving the CPM storage server and returning the CPM storage server The storage response of the identity of the message assignment;
向所述用户终端发送所述消息具体为: 向所述用户终端发送所述消息 和所述 CPM存储服务器为所述消息分配的标识。  Sending the message to the user terminal is specifically: sending the message to the user terminal and an identifier allocated by the CPM storage server for the message.
4、 根据权利要求 3 所述方法, 其特征在于, 所述接收响应中包括所 述 CPM存储服务器为所述消息分配的标识;  The method according to claim 3, wherein the receiving response includes an identifier allocated by the CPM storage server for the message;
根据所述用户终端返回的接收响应确定与所述接收响应对应的消息 的阅读状态为已读, 具体为: 根据所述接收响应中的所述 CPM存储服务 器为所述消息分配的标识确定与所述接收响应对应的消息的阅读状态为 已读。 Determining, according to the receiving response returned by the user terminal, that the read status of the message corresponding to the received response is read, specifically: determining, according to the identifier allocated by the CPM storage server for the message in the receiving response The read status of the message corresponding to the received response is read.
5、 一种消息状态设置方法, 其特征在于, 包括: A method for setting a message state, which is characterized by comprising:
接收消息;  Receiving a message;
确定需要提交所述消息至 CPM存储服务器且需要发送所述消息至用 户终端, 将所述消息的阅读状态标识为已读;  Determining that the message needs to be submitted to the CPM storage server and the message needs to be sent to the user terminal, and the read status of the message is identified as read;
向所述 CPM存储服务器发送消息存储请求, 并向所述用户终端发送 所述消息; 所述消息存储请求中包括所述消息和所述消息的阅读状态; 接收所述用户终端返回的接收响应, 并根据所述用户终端返回的接收 响应确定与所述接收响应对应的消息的阅读状态为未读;  Sending a message storage request to the CPM storage server, and sending the message to the user terminal; the message storage request includes the message and a read status of the message; receiving a receiving response returned by the user terminal, And determining, according to the receiving response returned by the user terminal, that the read status of the message corresponding to the received response is unread;
向所述 CPM存储服务器发送消息状态修改请求, 所述消息状态修改 请求中所述消息的阅读状态为未读。  Sending a message state modification request to the CPM storage server, where the read state of the message in the message state modification request is unread.
6、 根据权利要求 5所述方法, 其特征在于, 在向所述 CPM存储服 务器发送消息存储请求之后, 还包括: 接收所述 CPM存储服务器返回的 包括有所述 CPM存储服务器为所述消息分配的标识的存储响应;  The method of claim 5, after the sending the message storage request to the CPM storage server, the method further comprising: receiving the CPM storage server and including the CPM storage server to allocate the message Storage response of the identity;
向所述用户终端发送所述消息具体为: 向所述用户终端发送所述消息 和所述 CPM存储服务器为所述消息分配的标识。  Sending the message to the user terminal is specifically: sending the message to the user terminal and an identifier allocated by the CPM storage server for the message.
7. 根据权利要求 6所述方法, 其特征在于, 所述接收响应中包括所 述 CPM存储服务器为所述消息分配的标识;  The method according to claim 6, wherein the receiving response includes an identifier allocated by the CPM storage server for the message;
所述根据所述用户终端返回的接收响应确定与所述接收响应对应的 消息的阅读状态为未读具体为: 根据所述接收响应中的所述 CPM存储服 务器为所述消息分配的标识确定与所述接收响应对应的消息的阅读状态 为未读。  Determining, according to the receiving response returned by the user terminal, that the read status of the message corresponding to the received response is unread, specifically: determining, according to the identifier allocated by the CPM storage server for the message in the receiving response The read status of the message corresponding to the received response is unread.
8、 一种消息状态设置方法, 其特征在于, 包括:  8. A message state setting method, which is characterized by comprising:
接收消息;  Receiving a message;
确定所述消息需要提交 CPM存储服务器存储, 緩存所述消息; 确定所述消息需要发送到用户终端, 向所述用户终端发送所述消息并 接收到所述用户终端返回的接收响应; 确定已緩存有与所述接收响应对应的消息, 根据用户终端返回的接收响 应, 标识緩存的与所述接收响应对应的消息的阅读状态; Determining that the message needs to be submitted to the CPM storage server for storing the message; determining that the message needs to be sent to the user terminal, sending the message to the user terminal, and receiving the receiving response returned by the user terminal; Determining that a message corresponding to the received response is buffered, and identifying a read state of the cached message corresponding to the received response according to the received response returned by the user terminal;
向所述 CPM存储服务器发送消息存储请求, 所述消息存储请求包括 緩存中的各消息和各消息的阅读状态。  A message storage request is sent to the CPM storage server, the message storage request including each message in the cache and a read status of each message.
9、 根据权利要求 8 所述方法, 其特征在于, 所述根据所述用户终端 返回的接收响应,标识緩存的与所述接收响应对应的消息的阅读状态,包括: 所述用户终端返回的接收响应表示接收成功, 将緩存的所述消息的阅 读 ^犬态标识为已读;  The method according to claim 8, wherein the determining, according to the receiving response returned by the user terminal, the read status of the cached message corresponding to the received response, comprising: receiving the return by the user terminal The response indicates that the receiving is successful, and the read status of the cached message is marked as read;
所述用户终端返回的接收响应表示接收失败, 将緩存的所述消息的阅 读^犬态标 i只为未读。  The receiving response returned by the user terminal indicates that the receiving failure has occurred, and the read status of the cached message is only unread.
10、 根据权利要求 8或 9所述方法, 其特征在于, 在确定所述消息需 要提交 CPM存储服务器存储, 緩存所述消息之后, 还包括:  The method according to claim 8 or 9, wherein after determining that the message needs to be submitted to the CPM storage server storage, after the message is cached, the method further includes:
确定所述消息不需要发送到用户终端, 将所述緩存的与所述消息的阅 读状态标识为未读。  Determining that the message does not need to be sent to the user terminal, identifying the cached read status with the message as unread.
11、 一种 CPM业务服务器, 其特征在于, 包括:  11. A CPM service server, comprising:
接收模块, 用于接收消息;  a receiving module, configured to receive a message;
消息存储请求模块, 用于确定所述消息需要提交 CPM存储服务器存 储, 向所述 CPM存储服务器发送包括所述消息的消息存储请求;  a message storage requesting module, configured to determine that the message needs to be submitted to a CPM storage server, and send a message storage request including the message to the CPM storage server;
发送模块, 用于确定所述消息需要发送到用户终端, 向所述用户终端 发送所述消息;  a sending module, configured to determine that the message needs to be sent to a user terminal, and send the message to the user terminal;
所述接收模块还用于接收所述用户终端返回的接收响应;  The receiving module is further configured to receive a receiving response returned by the user terminal;
状态修改请求模块, 用于确定 CPM存储服务器中存储有与所述接收响 应对应的消息, 且根据所述用户终端返回的接收响应确定与所述接收响应 对应的消息的阅读状态为已读, 向所述 CPM存储服务器发送消息状态修 改请求, 所述消息状态修改请求中所述消息的阅读状态为已读。  a state modification requesting module, configured to determine that a message corresponding to the received response is stored in the CPM storage server, and determining, according to the received response returned by the user terminal, that a read status of the message corresponding to the received response is read, The CPM storage server sends a message state modification request, and the read state of the message in the message state modification request is read.
12、 根据权利要求 11所述的 CPM业务服务器, 其特征在于, 所述状 态修改请求模块包括: 12. The CPM service server according to claim 11, wherein: The state modification request module includes:
存储确定单元, 用于确定 CPM存储服务器中存储有与所述接收响应对 应的消息;  a storage determining unit, configured to determine that a message corresponding to the receiving response is stored in the CPM storage server;
状态确定单元, 用于根据所述用户终端返回的接收响应确定的所述消 息的阅读状态为已读;  a status determining unit, configured to read, according to the received response returned by the user terminal, the read status of the message as read;
状态修改请求单元, 用于向所述 CPM存储服务器发送消息状态修改 请求。  a status modification request unit, configured to send a message status modification request to the CPM storage server.
13、 根据权利要求 11或 12所述的 CPM业务服务器, 其特征在于: 所述接收模块进一步用于接收所述 CPM存储服务器返回的包括有所 述 CPM存储服务器为所述消息分配的标识的存储响应;  The CPM service server according to claim 11 or 12, wherein: the receiving module is further configured to receive, by the CPM storage server, a storage that includes an identifier that is allocated by the CPM storage server for the message. Respond
所述发送模块, 具体用于向所述用户终端发送所述消息和所述 CPM 存储服务器为所述消息分配的标识。  The sending module is specifically configured to send the message to the user terminal and an identifier that is allocated by the CPM storage server for the message.
14、 根据权利要求 12所述的 CPM业务服务器, 其特征在于, 所述状 态确定单元, 具体用于所述接收响应中包括所述 CPM存储服务器为所述 消息分配的标识时, 根据所述接收响应中的所述 CPM存储服务器为所述 消息分配的标识确定与所述接收响应对应的消息的阅读状态为已读。  The CPM service server according to claim 12, wherein the status determining unit is configured to: when the receiving response includes the identifier allocated by the CPM storage server for the message, according to the receiving The CPM storage server in response determines that the read status of the message corresponding to the received response is read.
15、 一种 CPM业务服务器, 其特征在于, 包括:  15. A CPM service server, comprising:
接收模块, 用于接收消息;  a receiving module, configured to receive a message;
确定模块, 用于确定需要提交所述消息至 CPM存储服务器且需要发 送所述消息至用户终端, 将所述消息的阅读状态标识为已读;  a determining module, configured to determine that the message needs to be submitted to the CPM storage server and needs to send the message to the user terminal, and identify the read status of the message as read;
消息存储请求模块, 用于向所述 CPM存储服务器发送消息存储请求, 所述消息存储请求中包括所述消息和所述消息的阅读状态;  a message storage requesting module, configured to send a message storage request to the CPM storage server, where the message storage request includes the message and a read status of the message;
发送模块, 用于向所述用户终端发送所述消息;  a sending module, configured to send the message to the user terminal;
所述接收模块进一步用于接收所述用户终端返回的接收响应; 状态修改请求模块, 用于根据所述用户终端返回的接收响应确定与所 述接收响应对应的消息的阅读状态为未读, 向所述 CPM存储服务器发送 消息状态修改请求, 所述消息状态修改请求中所述消息的阅读状态为未 读。 The receiving module is further configured to receive a receiving response returned by the user terminal, and the state modifying requesting module is configured to determine, according to the receiving response returned by the user terminal, that the read status of the message corresponding to the received response is unread, The CPM storage server sends a message status modification request, wherein the read status of the message in the message status modification request is unread.
16、 根据权利要求 15所述的 CPM业务服务器, 其特征在于: 所述接收模块进一步用于接收所述 CPM存储服务器返回的包括有所 述 CPM存储服务器为所述消息分配的标识的存储响应;  The CPM service server according to claim 15, wherein: the receiving module is further configured to receive a storage response returned by the CPM storage server that includes an identifier allocated by the CPM storage server for the message;
所述发送模块, 具体用于向所述用户终端发送所述消息和所述 CPM 存储服务器为所述消息分配的标识。  The sending module is specifically configured to send the message to the user terminal and an identifier that is allocated by the CPM storage server for the message.
17、 根据权利要求 16所述的 CPM业务服务器, 其特征在于: 所述状 态修改请求模块, 具体用于所述接收响应中包括所述 CPM存储服务器为 所述消息分配的标识时, 根据所述接收响应中的所述 CPM存储服务器为 所述消息分配的标识确定与所述接收响应对应的消息的阅读状态为未读, 向所述 CPM存储服务器发送消息状态修改请求。  The CPM service server according to claim 16, wherein: the status modification request module is configured to: when the receiving response includes the identifier allocated by the CPM storage server for the message, according to the And determining, by the CPM storage server in the response, the identifier assigned to the message that the read status of the message corresponding to the received response is unread, and sending a message status modification request to the CPM storage server.
18、 一种 CPM业务服务器, 其特征在于, 包括:  18. A CPM service server, comprising:
接收模块, 用于接收消息;  a receiving module, configured to receive a message;
緩存模块, 用于确定所述消息需要提交 CPM存储服务器存储, 并緩 存所述消息;  a cache module, configured to determine that the message needs to be submitted to the CPM storage server for storage, and to cache the message;
发送模块, 用于确定所述消息需要发送到用户终端, 向所述用户终端 发送所述消息;  a sending module, configured to determine that the message needs to be sent to a user terminal, and send the message to the user terminal;
所述接收模块进一步用于接收所述用户终端返回的接收响应; 状态标识模块, 用于确定已緩存有与所述接收响应对应的消息, 根据用 户终端返回的接收响应,标识緩存的与所述接收响应对应的消息的阅读状态; 消息存储请求模块, 用于向所述 CPM存储服务器发送消息存储请求, 所述消息存储请求包括緩存中各消息和各消息对应的阅读状态。  The receiving module is further configured to receive a receiving response returned by the user terminal, and the status identifying module is configured to determine that a message corresponding to the received response is cached, and identify the cached and the received according to the received response returned by the user terminal. Receiving a read status of the message corresponding to the response; the message storage requesting module is configured to send a message storage request to the CPM storage server, where the message storage request includes a message in the cache and a read status corresponding to each message.
19、 根据权利要求 18所述的 CPM业务服务器, 其特征在于, 所述状 态标识模块, 还用于在緩存所述消息之后, 确定所述消息不需要发送到所 述用户终端, 将所述緩存的与所述接收响应对应的消息的阅读状态标识为 未读。 The CPM service server according to claim 18, wherein the status identification module is further configured to: after the message is cached, determine that the message does not need to be sent to the user terminal, and the cache is The read status identifier of the message corresponding to the received response is unread.
20、 根据权利要求 19所述的 CPM业务服务器, 其特征在于, 所述状 态标识模块包括:  The CPM service server according to claim 19, wherein the status identification module comprises:
第一标识单元, 用于所述用户终端返回的接收响应表示接收成功时, 将緩存的与所述接收响应对应的消息的阅读状态标识为已读; 或  a first identifying unit, configured to receive, by the user terminal, a receiving response, indicating that the read status of the cached message corresponding to the received response is read as being received; or
第二标识单元, 用于所述用户终端返回的接收响应表示接收失败时, 将緩存的与所述接收响应对应的消息的阅读状态标识为未读; 或  a second identifier unit, configured to receive, by the user terminal, a receiving response, indicating that the read status of the cached message corresponding to the received response is unread when the receiving fails; or
第三标识单元, 用于在緩存所述消息之后, 确定所述消息不需要发送 到用户终端时, 将所述緩存的所述消息的阅读状态标识为未读。  And a third identifying unit, configured to: after the message is cached, determine that the read status of the cached message is unread when the message does not need to be sent to the user terminal.
PCT/CN2011/077068 2011-07-12 2011-07-12 Method for setting message status and converged internet protocol message (cpm) traffic server WO2012167473A1 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201180001340.0A CN102986173B (en) 2011-07-12 2011-07-12 Method for setting message status and converged internet protocol message (CPM) traffic server
PCT/CN2011/077068 WO2012167473A1 (en) 2011-07-12 2011-07-12 Method for setting message status and converged internet protocol message (cpm) traffic server

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2011/077068 WO2012167473A1 (en) 2011-07-12 2011-07-12 Method for setting message status and converged internet protocol message (cpm) traffic server

Publications (1)

Publication Number Publication Date
WO2012167473A1 true WO2012167473A1 (en) 2012-12-13

Family

ID=47295363

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2011/077068 WO2012167473A1 (en) 2011-07-12 2011-07-12 Method for setting message status and converged internet protocol message (cpm) traffic server

Country Status (2)

Country Link
CN (1) CN102986173B (en)
WO (1) WO2012167473A1 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101437565B1 (en) * 2013-06-07 2014-09-04 (주)오픈벡스 Messaging system for reliability of push message
CN109617787A (en) * 2018-12-17 2019-04-12 上海点融信息科技有限责任公司 For the message method of sending and receiving of block chain network, storage medium, calculate equipment
CN111431952B (en) * 2019-01-09 2022-06-03 阿里巴巴集团控股有限公司 Message pushing method, device and system, computer storage medium and electronic equipment

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070143417A1 (en) * 2005-12-15 2007-06-21 Daigle Brian K Instant messaging confirmation and receipt
CN101072386A (en) * 2007-06-22 2007-11-14 腾讯科技(深圳)有限公司 Business server, system message server and message broadcasting method
CN101374248A (en) * 2007-08-24 2009-02-25 上海华为技术有限公司 Method and apparatus for processing instant information
CN102007783A (en) * 2008-02-13 2011-04-06 三星电子株式会社 Method and system for interworking converged messaging service

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101374254A (en) * 2007-08-24 2009-02-25 华为技术有限公司 Method and apparatus for conveying report of communication system
EP2107755A1 (en) * 2008-04-04 2009-10-07 Nokia Corporation Method and apparatus for CPM session management

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20070143417A1 (en) * 2005-12-15 2007-06-21 Daigle Brian K Instant messaging confirmation and receipt
CN101072386A (en) * 2007-06-22 2007-11-14 腾讯科技(深圳)有限公司 Business server, system message server and message broadcasting method
CN101374248A (en) * 2007-08-24 2009-02-25 上海华为技术有限公司 Method and apparatus for processing instant information
CN102007783A (en) * 2008-02-13 2011-04-06 三星电子株式会社 Method and system for interworking converged messaging service

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
"Open Mobile Alliance", CPM CONVERSATION FUNCTIONS DRAFT VERSION 1.0, 25 October 2010 (2010-10-25), pages 31 - 32 *

Also Published As

Publication number Publication date
CN102986173A (en) 2013-03-20
CN102986173B (en) 2015-06-03

Similar Documents

Publication Publication Date Title
US8503300B2 (en) Efficient messaging over internet protocol
US8924593B2 (en) Apparatus and method for communication services network
US9609088B2 (en) Method for delivery of messages in a communication system
US20090241180A1 (en) System and Method for Data Transport
US8943572B2 (en) Method for accessing a storage server of an IM service system, and an IM service system
WO2018214865A1 (en) Processing method for message acknowledgement, related apparatus, storage medium and processor
KR102208935B1 (en) Messaging api over http protocol to establish context for data exchange
US9065788B2 (en) Method, device and system for voice communication
WO2013131472A1 (en) Message processing method, device and system
US20130266129A1 (en) Method and system for recalling a voice mail
WO2008040248A1 (en) A method and system for transmitting email and a push mail server
US20130151638A1 (en) Method, apparatus, and system for transferring file to user of instant message system
WO2012159389A1 (en) Method and device for obtaining contact information
EP2974159B1 (en) Method, device and system for voice communication
US9900353B2 (en) Method and apparatus for enabling communications between users
WO2012167473A1 (en) Method for setting message status and converged internet protocol message (cpm) traffic server
WO2017185934A1 (en) Management device and method for managing device
WO2012155652A1 (en) Communication method, net element and system of cross-social network
US9596577B1 (en) Relaying mobile communications
CN101860821A (en) Method and system for acquiring instant messages
EP2301225B1 (en) Methods, telecommunications node, and user equipment for transmission of user identifier
US8473625B1 (en) Preservation of network address translation (NAT) state across wireless sessions
US9641646B1 (en) Distributed multimedia system for IP networks
WO2016150334A1 (en) Method for realizing voice mailbox server and voice mailbox system
US7904506B2 (en) Context information management system

Legal Events

Date Code Title Description
WWE Wipo information: entry into national phase

Ref document number: 201180001340.0

Country of ref document: CN

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

Ref document number: 11867215

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 11867215

Country of ref document: EP

Kind code of ref document: A1