WO2014190622A1 - 一种离线消息的存储方法及服务器 - Google Patents

一种离线消息的存储方法及服务器 Download PDF

Info

Publication number
WO2014190622A1
WO2014190622A1 PCT/CN2013/081476 CN2013081476W WO2014190622A1 WO 2014190622 A1 WO2014190622 A1 WO 2014190622A1 CN 2013081476 W CN2013081476 W CN 2013081476W WO 2014190622 A1 WO2014190622 A1 WO 2014190622A1
Authority
WO
WIPO (PCT)
Prior art keywords
memory
offline
message
read
messages
Prior art date
Application number
PCT/CN2013/081476
Other languages
English (en)
French (fr)
Inventor
田丽平
刘勇
Original Assignee
中兴通讯股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 中兴通讯股份有限公司 filed Critical 中兴通讯股份有限公司
Publication of WO2014190622A1 publication Critical patent/WO2014190622A1/zh

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/10Protocols in which an application is distributed across nodes in the network
    • H04L67/1097Protocols in which an application is distributed across nodes in the network for distributed storage of data in networks, e.g. transport arrangements for network file system [NFS], storage area networks [SAN] or network attached storage [NAS]

Definitions

  • the present invention relates to the field of data storage technology based on message queues, and in particular, to a method and a server for storing offline messages.
  • Message Queuing is an asynchronous transfer mode that enables communication between multiple different applications. Applications that communicate with each other can be distributed on the same machine or distributed anywhere in the connected network.
  • the sender of the message stores the message he wants to send into the message queue, and the local or remote message recipient then retrieves the message from the queue.
  • the sender does not have to worry about whether the receiver is started or not. If the message is successfully sent to the message queue, the process can be considered complete. The receiver only needs to receive the message when it starts or is in the normal state. So this mechanism is very suitable for the storage of offline messages (such as offline SMS, offline MMS, offline QQ messages, etc.).
  • the message queue used for offline message storage can be stored in memory or on a physical disk, but regardless of the storage method, it is stored in the memory or disk of a single physical server. Message loss can occur when the memory or disk of this server fails or the server itself fails.
  • the technical problem to be solved by the embodiments of the present invention is to provide a method and a server for storing offline messages, so as to overcome the defect that the message is lost when the server is faulty in the offline message storage system.
  • a method for storing offline messages including:
  • the step of creating a data space for saving data includes:
  • the foregoing storage method further has the following features: the step of creating a data space for saving data includes:
  • the storage mode includes any one of the following:
  • the offline message is first stored in the memory of the physical server, and when the remaining memory of the memory reaches a specified value, the offline message satisfying the predetermined condition in the memory is replaced with the solid state hard disk; the offline message is first read from the memory Reading, when not read from the memory, reading from the solid state hard disk, and simultaneously replacing the offline message into the memory;
  • the offline message is directly stored in the disk, and when the offline message is read, the offline message is stored in the memory; the offline message is simultaneously written into the memory and the disk of the physical server, and when the remaining memory of the memory reaches the specified value, An offline message deletion in the memory that satisfies a predetermined condition; when the offline message is read, it is first read from the memory, and when it is not read from the memory, it is read from the disk and will be read from the disk The offline message retrieved is converted into memory.
  • a server wherein:
  • the creation module is configured to: create a data space for saving data, and create a message queue on the data space;
  • the storage module is configured to: after receiving the offline message through the message queue, store the offline message as N copies, and store each copy to N different physical servers, where N is greater than or equal to 2.
  • the above server also has the following features:
  • the creation module is configured to create a data space for saving data as follows: The copy parameter N of the offline message to be stored.
  • the above server also has the following features:
  • the creation module is arranged to create a data space for saving data as follows: Setting a storage mode of the offline message.
  • the storage mode set by the creating module includes any one of the following:
  • the offline message is first stored in the memory of the physical server, and when the remaining memory of the memory reaches a specified value, the offline message satisfying the predetermined condition in the memory is replaced with the solid state hard disk; the offline message is first read from the memory Reading, when not read from the memory, reading from the solid state hard disk, and simultaneously replacing the offline message into the memory;
  • the offline message is directly stored in the disk, and when the offline message is read, the offline message is stored in the memory; the offline message is simultaneously written into the memory and the disk of the physical server, and when the remaining memory of the memory reaches the specified value, An offline message deletion in the memory that satisfies a predetermined condition; when the offline message is read, it is first read from the memory, and when it is not read from the memory, it is read from the disk and will be read from the disk The offline message retrieved is converted into memory.
  • the offline message storage method and server of the above technical solution can overcome the defect that the message is lost when the server is faulty in the offline message storage system, and the security of the offline message storage is greatly improved.
  • FIG. 1 is a flowchart of a method for storing an offline message according to an embodiment of the present invention
  • FIG. 2 is a schematic diagram of a storage structure according to an embodiment of the present invention.
  • FIG. 3 is a schematic diagram of a server according to an embodiment of the present invention.
  • FIG. 1 is a flowchart of a method for storing an offline message according to an embodiment of the present invention. As shown in FIG. 1 , the storage method in this embodiment includes the following steps:
  • step S11 the process of creating a data space for saving data may include: setting a copy parameter N of the offline message to be stored.
  • the process of creating a data space for saving data may further include: setting a storage mode of the offline message.
  • the embodiment of the present invention uses a distributed cache message queue, and combines its own characteristics:
  • the data is stored in multiple copies and stored on different physical servers, which can overcome the defect that the message is lost when the server fails in the existing offline message storage system;
  • a variety of storage methods are optional, making data more secure while balancing storage performance.
  • the offline message storage structure based on the distributed cache message queue includes: a message sender, a distributed cache message queue and a data storage server, and a message receiver.
  • the distributed cache message queue is installed on multiple data storage servers to make it a cluster, which can be regarded as a storage device externally. Through the interface provided by the message queue, the sender sends the message to the queue, and the receiver Receive messages from the queue.
  • the method for storing an offline message includes the following steps:
  • Step 101 Create a data space (all data is logically stored in the data space), and set a copy parameter N to be stored when the message is written during the space creation process (N supports values of 1 ⁇ 5, setting N To ensure that there are indeed N physical servers available, simply set N>1 to ensure that data copies of other servers are available when a single server fails.
  • Step 102 Create a message queue on this data space
  • Step 103 The sender sends a message by using the interface provided by the message queue, and the message will save N copies to N different physical servers;
  • Step 104 The receiver receives the message by using the interface provided by the message queue.
  • the message is read from other available servers, and the receiver does not perceive the underlying server failure.
  • a plurality of modes of message storage may be set, which are both safe and efficient; and the following steps are specifically included:
  • Step 201 Create a data space (all data is logically stored in the data space), and set a mode of message storage during the process of creating the space.
  • Step 202 Create a message queue on the data space.
  • the currently supported modes are:
  • the secondary storage mode combining memory and disk. This mode is divided into two modes. In the first mode, the message is directly stored in the disk when the message is written, and the message is put into the memory only when the message is read. Method 2, writing the message At the same time, the message is written to both the memory and the disk (that is, two copies are written at the same time, and the message is actually written when both the memory and the disk have been written). When the memory is almost full, the oldest message is eliminated according to the LRU (Least Recently Used) algorithm. When reading a message, it first tries to get it from memory. When it is not available in memory (it is possible that the message has been eliminated), it goes to the disk to read it, and at the same time, the message read from the disk is replaced into the memory.
  • LRU Least Recently Used
  • Step 203 The sender sends a message through an interface provided by the message queue, and the message queue is selected and stored in the corresponding place according to the set storage mode.
  • Step 204 The receiver receives the message through the interface provided by the message queue, and the message queue reads from the corresponding location according to the set storage mode.
  • the above method stores offline messages as N copies, ensuring a single When the physical server is faulty, there are still other servers that can provide services. At the same time, there are three modes of storage on a single service. Users can select different modes according to different requirements of security and performance.
  • the invention solves the problem that the offline message storage system has the risk of message loss when the server is faulty, and the security and performance can be balanced by setting different storage copies and storage modes.
  • FIG. 3 is a schematic diagram of a server according to an embodiment of the present invention. As shown in FIG. 3, the server in this embodiment includes a creating module 301 and a storage module 302, where:
  • the creation module 301 is configured to: create a data space for saving data, and create a message queue on the data space;
  • the storage module 302 is configured to: after receiving the offline message through the message queue, store the offline message as N copies, and store each copy to N different physical servers, where N is greater than or equal to 2.
  • the creating module 301 is configured to create a data space for saving data as follows: Set a copy parameter N of the offline message to be stored.
  • the creating module 301 is configured to create a data space for saving data as follows: Set a storage mode of the offline message.
  • the storage mode set by the creation module 301 includes any of the following:
  • the offline message is first stored in the memory of the physical server, and when the remaining memory of the memory reaches a specified value, the offline message satisfying the predetermined condition in the memory is replaced with the solid state hard disk; the offline message is first read from the memory Reading, when not read from the memory, reading from the solid state hard disk, and simultaneously replacing the offline message into the memory;
  • the offline message is directly stored in the disk, and when the offline message is read, the offline message is stored in the memory; the offline message is simultaneously written into the memory and the disk of the physical server, and when the remaining memory of the memory reaches the specified value, An offline message deletion in the memory that satisfies a predetermined condition; when the offline message is read, it is first read from the memory, and when it is not read from the memory, it is read from the disk and will be read from the disk The offline message retrieved is converted into memory.
  • the offline message storage method and server of the above technical solution can overcome the defect that the message is lost when the server is faulty in the offline message storage system, and the security of the offline message storage is greatly improved. Therefore, the present invention has strong industrial applicability.

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

一种离线消息的存储方法及服务器,该方法包括:创建用于保存数据的数据空间,在所述数据空间上创建消息队列;通过所述消息队列接收到离线消息后,将所述离线消息存储为N个副本,每个副本分别存储到N个不同的物理服务器,其中,N大于等于2。通过上述技术方案可以克服现有离线消息存储系统中服务器故障时会导致消息丢失的缺陷,并使得离线消息存储的安全性大大提高。

Description

一种离线消息的存储方法及服务器
技术领域
本发明涉及基于消息队列的数据存储技术领域, 尤其涉及一种离线消息 的存储方法及服务器。
背景技术
消息队列是在多个不同的应用之间实现相互通信的一种异步传输模式, 相互通信的应用可以分布在同一台机器上, 也可以分布于相连网络中的任一 位置。 消息发送者把自己想要发送的消息存入消息队列中, 本地或异地的消 息接收者再从该队列中取出消息。
釆用消息队列机制,发送方不必再担心接收方是否启动,状态是否正常, 只要消息成功发送到消息队列中就可以认为处理完成, 接收方只需在其启动 或者正常状态时接收消息即可, 所以此种机制很适合离线消息 (比如离线短 信、 离线彩信、 离线 QQ消息等) 的存储。
目前离线消息存储所用的消息队列,可以存储在内存中或者物理磁盘中, 但无论哪种存储方式, 都是存储在单台物理服务器的内存或者磁盘中。 当此 台服务器的内存或磁盘出现故障或者服务器本身故障时会导致消息丟失。 发明内容
本发明实施例要解决的技术问题是提供一种离线消息的存储方法及服务 器, 以克服目前离线消息存储系统中服务器故障时会导致消息丟失的缺陷。
为了解决上述技术问题, 釆用如下技术方案:
一种离线消息的存储方法, 包括:
创建用于保存数据的数据空间, 在所述数据空间上创建消息队列; 通过所述消息队列接收到离线消息后,将所述离线消息存储为 N个副本, 每个副本分别存储到 N个不同的物理服务器, 其中, N大于等于 2。 可选地, 上述存储方法还具有下面特点: 所述创建用于保存数据的数据 空间的步骤包括:
设置要存储的所述离线消息的副本参数 N。
可选地, 上述存储方法还具有下面特点: 所述创建用于保存数据的数据 空间的步骤包括:
设置所述离线消息的存储模式。
可选地, 上述存储方法还具有下面特点: 所述存储模式包括以下的任一 种:
将离线消息存储在所述物理服务器的内存中;
将离线消息首先存储在所述物理服务器的内存中, 当该内存剩余存储量 达到指定值时, 将该内存中满足预定条件的离线消息置换到固态硬盘中; 读 取离线消息时首先从该内存读取, 当从该内存中读取不到时, 从所述固态硬 盘中读取, 同时将该离线消息置换入内存中;
将离线消息直接存入磁盘,读取离线消息时,将该离线消息存放入内存; 将离线消息同时写入所述物理服务器的内存和磁盘中, 当该内存剩余存 储量达到指定值时, 将该内存中满足预定条件的离线消息删除; 读取离线消 息时首先从该内存读取, 当从该内存中读取不到时, 从所述磁盘中读取, 同 时将从所述磁盘中读取到的离线消息转换入内存中。
一种服务器, 其中, 包括:
创建模块设置成: 创建用于保存数据的数据空间, 在所述数据空间上创 建消息队列;
存储模块设置成: 通过所述消息队列接收到离线消息后, 将所述离线消 息存储为 N个副本, 每个副本分别存储到 N个不同的物理服务器, 其中, N 大于等于 2。
可选地, 上述服务器还具有下面特点:
所述创建模块设置成按照如下方式创建用于保存数据的数据空间: 设置 要存储的所述离线消息的副本参数 N。
可选地, 上述服务器还具有下面特点:
所述创建模块设置成按照如下方式创建用于保存数据的数据空间: 设置 所述离线消息的存储模式。
可选地, 上述服务器还具有下面特点: 所述创建模块设置的存储模式包 括以下的任一种:
将离线消息存储在所述物理服务器的内存中;
将离线消息首先存储在所述物理服务器的内存中, 当该内存剩余存储量 达到指定值时, 将该内存中满足预定条件的离线消息置换到固态硬盘中; 读 取离线消息时首先从该内存读取, 当从该内存中读取不到时, 从所述固态硬 盘中读取, 同时将该离线消息置换入内存中;
将离线消息直接存入磁盘,读取离线消息时,将该离线消息存放入内存; 将离线消息同时写入所述物理服务器的内存和磁盘中, 当该内存剩余存 储量达到指定值时, 将该内存中满足预定条件的离线消息删除; 读取离线消 息时首先从该内存读取, 当从该内存中读取不到时, 从所述磁盘中读取, 同 时将从所述磁盘中读取到的离线消息转换入内存中。
上述技术方案的离线消息的存储方法及服务器, 可以克服目前离线消息 存储系统中服务器故障时会导致消息丟失的缺陷, 并使得离线消息存储的安 全性大大提高。 附图概述
图 1为本发明实施例的一种离线消息的存储方法的流程图;
图 2是本发明实施例的存储结构的示意图;
图 3为本发明实施例的服务器的示意图。
本发明的较佳实施方式 为使本发明的目的、 技术方案和优点更加清楚明白, 下文中将结合附图 对本发明的实施例进行详细说明。 需要说明的是, 在不冲突的情况下, 本申 请中的实施例及实施例中的特征可以相互任意组合。
图 1为本发明实施例的一种离线消息的存储方法的流程图,如图 1所示, 本实施例的存储方法包括以下步骤:
511、创建用于保存数据的数据空间,在所述数据空间上创建消息队列;
512、 通过所述消息队列接收到离线消息后, 将所述离线消息存储为 N 个副本,每个副本分别存储到 N个不同的物理服务器,其中, N大于等于 2。
步骤 S11中, 创建用于保存数据的数据空间的过程中可以包括: 设置要 存储的所述离线消息的副本参数 N。
步骤 S11中, 创建用于保存数据的数据空间的过程中还可以包括: 设置 所述离线消息的存储模式。
本发明实施例使用了分布式緩存消息队列, 结合其自身的特性: 数据多 副本存储而且存储在不同的物理服务器上, 可以克服现有离线消息存储系统 中服务器故障时会导致消息丟失的缺陷;以及多种存储方式(内存或者磁盘) 可选, 使数据更加安全, 同时可以兼顾存储的性能。
基于分布式緩存消息队列的离线消息存储结构, 如图 2所示, 包括: 消 息发送者、 分布式緩存消息队列及数据存储服务器、 消息接收者。
其中, 分布式緩存消息队列被安装布置在多个数据存储服务器上, 使之 成为一个集群, 对外可视作一个存储设备, 通过消息队列提供的接口, 发送 者将消息发送到队列中, 接收者从队列中接收消息。
在上述系统中, 对离线消息的存储方法, 包括如下步骤:
步骤 101 :创建数据空间(所有数据在逻辑上都是保存在数据空间里的 ) , 在空间创建过程中设置写入消息时要存储的副本参数 N ( N支持的值为 1~5 , 设置 N值时要确保确实有 N台物理服务器可用) , 只要设置 N>1就能保证 单个服务器故障时还有其他服务器的数据副本可用;
步骤 102: 在此数据空间上创建消息队列;
步骤 103: 发送者用消息队列提供的接口发送消息, 消息会保存 N份到 N个不同的物理服务器上;
步骤 104: 接收者用消息队列提供的接口接收消息, 当有一台物理服务 器出现故障不能提供服务时, 会从其他可用服务器上读取消息, 接受者感知 不到下层的服务器故障。
在一可选实施例中, 可以设置多种消息存储的模式, 兼顾安全与高效; 具体包括以下步骤:
步骤 201 :创建数据空间(所有数据在逻辑上都是保存在数据空间里的 ) , 在创建空间过程中设置消息存储的模式。
步骤 202: 在数据空间上创建消息队列;
目前支持的模式有:
1 ) 纯内存模式, 此种模式下消息存储在服务器的内存中;
2 ) 内存与 SSD ( (Solid State Disk, 固态硬盘)结合的二级存储模式, 此 种模式下消息首先存储在内存中, 当内存快满时, 根据 LRU ( Least Recently Used, 最近最少使用)算法, 把最早的消息从内存中置换到 SSD设备中, 频 繁使用的消息一直驻留在内存中。 读取消息时首先尝试从内存中获取, 当内 存中获取不到时, 再去 SSD中读取, 同时把此条消息置换入内存中;
3 ) 内存与磁盘结合的二级存储模式, 此种模式又分两种方式; 方式一, 写入消息时直接存入磁盘, 只有读消息时才把消息放入内存; 方式二, 写入 消息时, 消息同时写入内存和磁盘中 (即同时写两份, 当内存和磁盘都写完 了此条消息才算真正写完)。当内存快满时,根据 LRU( Least Recently Used, 最近最少使用)算法,淘汰最早的消息。读取消息时首先尝试从内存中获取, 当内存中获取不到时(有可能消息已经被淘汰掉) , 再去磁盘中读取, 同时 把磁盘中读取到的消息置换入内存中。
步骤 203: 发送者通过消息队列提供的接口发送消息, 消息队列会按照 设置的存储模式选择存储在相应的地方;
步骤 204: 接收者通过消息队列提供的接口接收消息, 消息队列会按照 设置的存储模式从相应位置读取。
从上述说明可以看出, 上述方法将离线消息存储为 N个副本, 确保单个 物理服务器故障时仍旧有其他服务器可提供服务; 同时在单台服务上的存储 方式有三种模式可选, 使用者可依据自身应用对安全与性能的不同要求选择 不同的模式。 本发明解决了离线消息存储系统当服务器故障时存在消息丟失 的风险, 通过设置不同的存储副本以及存储模式, 可兼顾安全与性能。
图 3为本发明实施例的服务器的示意图, 如图 3所示, 本实施例的服务 器包括创建模块 301和存储模块 302, 其中:
创建模块 301设置成: 创建用于保存数据的数据空间, 在所述数据空间 上创建消息队列;
存储模块 302设置成: 通过所述消息队列接收到离线消息后, 将所述离 线消息存储为 N个副本,每个副本分别存储到 N个不同的物理服务器,其中, N大于等于 2。
其中, 所述创建模块 301设置成按照如下方式创建用于保存数据的数据 空间: 设置要存储的所述离线消息的副本参数 N。
其中, 所述创建模块 301设置成按照如下方式创建用于保存数据的数据 空间: 设置所述离线消息的存储模式。
所述创建模块 301设置的存储模式包括以下的任一种:
将离线消息存储在所述物理服务器的内存中;
将离线消息首先存储在所述物理服务器的内存中, 当该内存剩余存储量 达到指定值时, 将该内存中满足预定条件的离线消息置换到固态硬盘中; 读 取离线消息时首先从该内存读取, 当从该内存中读取不到时, 从所述固态硬 盘中读取, 同时将该离线消息置换入内存中;
将离线消息直接存入磁盘,读取离线消息时,将该离线消息存放入内存; 将离线消息同时写入所述物理服务器的内存和磁盘中, 当该内存剩余存 储量达到指定值时, 将该内存中满足预定条件的离线消息删除; 读取离线消 息时首先从该内存读取, 当从该内存中读取不到时, 从所述磁盘中读取, 同 时将从所述磁盘中读取到的离线消息转换入内存中。
本领域普通技术人员可以理解上述方法中的全部或部分步骤可通过程序 来指令相关硬件完成, 所述程序可以存储于计算机可读存储介质中, 如只读 存储器、 磁盘或光盘等。 可选地, 上述实施例的全部或部分步骤也可以使用 一个或多个集成电路来实现。 相应地, 上述实施例中的各模块 /单元可以釆用 硬件的形式实现, 也可以釆用软件功能模块的形式实现。 本发明不限制于任 何特定形式的硬件和软件的结合。
以上仅为本发明的可选实施例, 当然, 本发明还可有其他多种实施例, 在不背离本发明精神及其实质的情况下, 熟悉本领域的技术人员当可根据本 发明作出各种相应的改变和变形, 但这些相应的改变和变形都应属于本发明 所附的权利要求的保护范围。
工业实用性
上述技术方案的离线消息的存储方法及服务器, 可以克服目前离线消息 存储系统中服务器故障时会导致消息丟失的缺陷, 并使得离线消息存储的安 全性大大提高。 因此本发明具有很强的工业实用性。

Claims

权 利 要 求 书
1、 一种离线消息的存储方法, 包括:
创建用于保存数据的数据空间, 在所述数据空间上创建消息队列; 通过所述消息队列接收到离线消息后,将所述离线消息存储为 N个副本, 每个副本分别存储到 N个不同的物理服务器, 其中, N大于等于 2。
2、如权利要求 1所述的存储方法, 其中: 所述创建用于保存数据的数据 空间的步骤包括:
设置要存储的所述离线消息的副本参数 N。
3、如权利要求 1所述的存储方法, 其中: 所述创建用于保存数据的数据 空间的步骤包括:
设置所述离线消息的存储模式。
4、如权利要求 3所述的存储方法, 其中: 所述存储模式包括以下的任一 种:
将离线消息存储在所述物理服务器的内存中;
将离线消息首先存储在所述物理服务器的内存中, 当该内存剩余存储量 达到指定值时, 将该内存中满足预定条件的离线消息置换到固态硬盘中; 读 取离线消息时首先从该内存读取, 当从该内存中读取不到时, 从所述固态硬 盘中读取, 同时将该离线消息置换入内存中;
将离线消息直接存入磁盘,读取离线消息时,将该离线消息存放入内存; 将离线消息同时写入所述物理服务器的内存和磁盘中, 当该内存剩余存 储量达到指定值时, 将该内存中满足预定条件的离线消息删除; 读取离线消 息时首先从该内存读取, 当从该内存中读取不到时, 从所述磁盘中读取, 同 时将从所述磁盘中读取到的离线消息转换入内存中。
5、 一种服务器, 包括创建模块和存储模块, 其中:
所述创建模块设置成: 创建用于保存数据的数据空间, 在所述数据空间 上创建消息队列;
所述存储模块设置成: 通过所述消息队列接收到离线消息后, 将所述离 线消息存储为 N个副本,每个副本分别存储到 N个不同的物理服务器,其中, N大于等于 2。
6、如权利要求 5所述的服务器, 其中, 所述创建模块设置成按照如下方 式创建用于保存数据的数据空间:
设置要存储的所述离线消息的副本参数 N。
7、如权利要求 5所述的服务器, 其中, 所述创建模块设置成按照如下方 式创建用于保存数据的数据空间:
设置所述离线消息的存储模式。
8、如权利要求 7所述的服务器, 其中: 所述创建模块设置的存储模式包 括以下的任一种:
将离线消息存储在所述物理服务器的内存中;
将离线消息首先存储在所述物理服务器的内存中, 当该内存剩余存储量 达到指定值时, 将该内存中满足预定条件的离线消息置换到固态硬盘中; 读 取离线消息时首先从该内存读取, 当从该内存中读取不到时, 从所述固态硬 盘中读取, 同时将该离线消息置换入内存中;
将离线消息直接存入磁盘,读取离线消息时,将该离线消息存放入内存; 将离线消息同时写入所述物理服务器的内存和磁盘中, 当该内存剩余存 储量达到指定值时, 将该内存中满足预定条件的离线消息删除; 读取离线消 息时首先从该内存读取, 当从该内存中读取不到时, 从所述磁盘中读取, 同 时将从所述磁盘中读取到的离线消息转换入内存中。
PCT/CN2013/081476 2013-05-30 2013-08-14 一种离线消息的存储方法及服务器 WO2014190622A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201310209321.8 2013-05-30
CN201310209321.8A CN104216659A (zh) 2013-05-30 2013-05-30 一种离线消息的存储方法及服务器

Publications (1)

Publication Number Publication Date
WO2014190622A1 true WO2014190622A1 (zh) 2014-12-04

Family

ID=51987918

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2013/081476 WO2014190622A1 (zh) 2013-05-30 2013-08-14 一种离线消息的存储方法及服务器

Country Status (2)

Country Link
CN (1) CN104216659A (zh)
WO (1) WO2014190622A1 (zh)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106657357A (zh) * 2016-12-29 2017-05-10 北京奇虎科技有限公司 发送离线消息的方法及装置
CN106656763A (zh) * 2016-12-29 2017-05-10 北京奇虎科技有限公司 发送离线消息的方法及装置
CN106685804A (zh) * 2016-12-29 2017-05-17 北京奇虎科技有限公司 发送离线消息的方法及装置
CN108810832B (zh) * 2018-04-20 2020-08-18 广州市玄武无线科技股份有限公司 短信下发方法、装置与计算机可读存储介质
CN109240609B (zh) * 2018-08-23 2022-02-18 郑州云海信息技术有限公司 一种基于aep内存的数据空间读写方法及系统
SG10201913065QA (en) 2019-12-23 2021-07-29 Sensetime Int Pte Ltd Data processing method and apparatus, and edge device

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101459627A (zh) * 2008-04-07 2009-06-17 中兴通讯股份有限公司 消息管理方法
CN102023974A (zh) * 2009-09-14 2011-04-20 中国移动通信集团公司 一种通过消息队列处理消息的方法、装置和系统

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1794722B (zh) * 2005-09-19 2010-05-05 华为技术有限公司 一种离线消息发送方法以及即时消息服务器

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101459627A (zh) * 2008-04-07 2009-06-17 中兴通讯股份有限公司 消息管理方法
CN102023974A (zh) * 2009-09-14 2011-04-20 中国移动通信集团公司 一种通过消息队列处理消息的方法、装置和系统

Also Published As

Publication number Publication date
CN104216659A (zh) 2014-12-17

Similar Documents

Publication Publication Date Title
JP5714571B2 (ja) キャッシュクラスタを構成可能モードで用いるキャッシュデータ処理
WO2014190622A1 (zh) 一种离线消息的存储方法及服务器
CN103763383B (zh) 一体化云存储系统及其存储方法
CN109376197B (zh) 一种数据同步方法、服务器及计算机存储介质
US10484449B2 (en) Email webclient notification queuing
US8930501B2 (en) Distributed data storage system and method
CN108733311B (zh) 用于管理存储系统的方法和设备
CN105493474B (zh) 用于支持用于同步分布式数据网格中的数据的分区级别日志的系统及方法
CN106446159B (zh) 一种存储文件的方法、第一虚拟机及名称节点
CN103516549B (zh) 一种基于共享对象存储的文件系统元数据日志机制
WO2015106656A1 (zh) 一种跨数据中心的数据同步方法
JPWO2008139521A1 (ja) リモートファイルシステム、端末装置およびサーバ装置
CN105278882A (zh) 一种分布式文件系统的磁盘管理方法
CN110633046A (zh) 一种分布式系统的存储方法、装置、存储设备及存储介质
WO2019089057A1 (en) Scalable storage system
WO2018157605A1 (zh) 一种集群文件系统中消息传输的方法及装置
CN102523105B (zh) 一种数据存储的故障恢复方法及其适用的数据分布架构
KR20160068881A (ko) 분산 저장 시스템에서의 캐시 및 비-캐시 사용
JP5475702B2 (ja) メール保存バックアップシステムおよびバックアップ方法
WO2019000423A1 (zh) 一种数据存储方法及设备
JP2006048122A (ja) 通信システム
JP2014229088A (ja) データ処理システム、データ処理装置および記憶媒体
US8812900B2 (en) Managing storage providers in a clustered appliance environment
CN112104729A (zh) 一种存储系统及其缓存方法
CN115981561A (zh) 分布式存储系统的硬盘管理方法、装置、设备及存储介质

Legal Events

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

Ref document number: 13885811

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: 13885811

Country of ref document: EP

Kind code of ref document: A1