CN103577441B - A user operating a data storage method and apparatus - Google Patents

A user operating a data storage method and apparatus Download PDF

Info

Publication number
CN103577441B
CN103577441B CN201210266469.0A CN201210266469A CN103577441B CN 103577441 B CN103577441 B CN 103577441B CN 201210266469 A CN201210266469 A CN 201210266469A CN 103577441 B CN103577441 B CN 103577441B
Authority
CN
China
Prior art keywords
operation
user
data
time
total
Prior art date
Application number
CN201210266469.0A
Other languages
Chinese (zh)
Other versions
CN103577441A (en
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 CN201210266469.0A priority Critical patent/CN103577441B/en
Publication of CN103577441A publication Critical patent/CN103577441A/en
Application granted granted Critical
Publication of CN103577441B publication Critical patent/CN103577441B/en

Links

Abstract

本发明公开了一种用户操作数据存储方法及装置,属于计算机领域。 The present invention discloses a method and a user operating a data storage device, a computer belonging to the field. 所述方法包括:接收用户标识以及与所述用户标识相对应的用户单次操作数据,所述用户单次操作数据包括操作类型;从操作数据库提取与所述用户标识一一对应的用户总操作数据;将所述用户单次操作数据存储入所述用户总操作数据,然后将所述用户总操作数据存储入所述操作数据库。 The method comprising: receiving a user identifier and a user identifier corresponding to the user data of a single operation, a single operation of the user data includes the type of operation; extracting from the operation database correspond to the user identification of user operations total transactions; single operation of the user into the user data store total operation data, and then the overall operation of the user data is stored into the operation database. 本发明通过根据用户标识提取该用户的用户总操作数据,并将用户单次操作数据存储在用户总操作数据中,最后将用户总操作数据存储入操作数据库,达到集中存储同一用户的用户操作数据,便于对同一用户的用户操作数据进行管理维护,间接提高用户操作数据读取和处理的实时性的目的。 The present invention, by extracting the total operation of the user data in accordance with user's user ID, and user data is stored in a single operation of the total user data in the operation, and finally the total user data storing operation into the operation database, to a user operation data set stored in the same user easy to operate user data management and maintenance of the same user, the indirect object of improving the real-time user data reading and processing operation.

Description

用户操作数据存储方法及装置 A user operating a data storage method and apparatus

技术领域 FIELD

[0001] 本发明涉及计算机领域,特别涉及一种用户操作数据存储方法及装置。 [0001] The present invention relates to computers, and more particularly, to a method and a user operating a data storage device.

背景技术 Background technique

[0002]随着计算机和网络的不断发展,人们越来越多的依赖网络来获取自己感兴趣的内容。 [0002] With the development of computers and networks, more and more people rely on the network to get the content of interest. 为了向用户提供更好的用户体验,运营商往往通过分析用户历史操作记录来推测用户的兴趣类别,以便向用户推送相关内容。 In order to provide a better user experience for users, operators tend to analyze user operation history records to infer user interest categories in order to push relevant content to the user through. 这就需要运营商预先将用户的历史操作以数据形式存储起来。 This requires operators to advance the user's operating history stored in data form.

[°003]以用户在网络音乐播放应用中对歌曲进行操作为例,用户的每一次操作都可以用一笔用户操作数据来表示,这样的一笔用户操作数据可以称为用户单次操作数据,用户单次操作数据中可以包括用户标识、歌曲标识、操作类型和操作时间等。 [° 003] In operation a user of the song in the music player application in the network, for example, every operation the user can use the data to represent a sum of a user operation, the user operates the sum of such data may be referred to as user data of a single operation , a single user operation data may include a user identification, a song identifier, operation type and operation time. 现有的用户操作数据存储方法,将一至多条用户单次操作数据按照时间顺序,以表格的形式存储在关系数据库中。 Existing user operation data storing method, a single operation to a plurality of user data in chronological order, in the form of a table stored in a relational database. 具体的,请参见图1所示的操作数据组织示意图,其中,用户标识可以是用户账号(图中以A、B和C分别对应用户A、用户B和用户C的用户标识);同一用户的多条用户单次操作数据在表格中可能不连续,比如,图1中用户A的多条用户单次操作数据分别位于表格第1、第4、 第8……第999行。 Specifically, the operation see Figure 1 is a schematic data structure shown, wherein the user identifier may be the user account (FIG to A, B and C correspond to user A, user B and user identifier of the user C); the same user a plurality of single user operation data in the table may not be contiguous, for example, FIG. 1 of the user a plurality of user data are located in a single operation form 1, 4, 8 ...... 999 lines. 当音乐推荐系统需要提取某一用户的操作数据时,需要查找表格中所有包含该用户的用户标识的行,将查找到的每一行的内容提取为一条用户单次操作数据,并将由提取到的所有用户单次操作数据所组成的数据集作为查找结果。 When the music recommendation system requires a user to extract operational data, you need to find all the rows in a table that contains the user's user ID of the contents to find each line extracted as a single user operating data, and to extract from the All user data set consisting of a single operation data as a search result.

[0004] 在实现本发明的过程中,发明人发现现有技术至少存在以下问题: [0004] During the implementation of the present invention, the inventors found that the prior art has at least the following problems:

[0005] 由于同一用户的多条用户单次操作数据存储可能较为分散,当需要对同一用户的所有用户单次操作数据单独进行管理维护时,需要根据用户标识检索数据库中所有数据, 管理维护的过程较为繁杂,并且,当需要提取某一用户的所有操作数据时,必须根据用户标识对整个数据库中所有用户单次操作数据进行筛选,每次提取耗费大量时间,实时性较差。 [0005] Since the same user a plurality of users in a single operation data storage may be more dispersed, when required all users to a single operation data of the same user manage and maintain the separate, users need to mark search database all the data, management and maintenance process is more complicated, and, when all the operations needed to extract a user's data, the whole database must be screened in a single operation for all user data according to the user identifier, each extraction time-consuming, less real-time.

发明内容 SUMMARY

[0006] 为了解决现有技术中用户操作数据不易管理维护,操作数据提取实时性差的问题,本发明实施例提供了一种用户操作数据存储方法及装置。 [0006] In order to solve the prior art, the user operates the data maintenance easy management, real-time operation data of poor extraction problem, embodiments provide a user operating a data storage method and apparatus of the present invention. 所述技术方案如下: The technical solutions are as follows:

[0007] 一方面,提供了一种用户操作数据存储方法,所述方法包括: [0007] In one aspect, a user operating a data storage, the method comprising:

[0008] 接收用户标识以及与所述用户标识相对应的用户单次操作数据,所述用户单次操作数据包括操作类型、操作对象标识和本次操作时间; [0008] The user receives a user ID and a single operation with the user identification data corresponding to said single user data operation includes an operation type, an operation object ID and the time of this operation;

[0009] 从操作数据库提取与所述用户标识一一对应的用户总操作数据,所述用户总操作数据用于集中存储所述用户标识对应的所有用户单次操作数据,所述用户总操作数据包括至少一个数据分区,每个所述数据分区用于存储对应的一种操作类型的操作对象记录,每条所述操作对象记录包括一个操作对象的操作对象标识和所述操作对象在预定时间段内的最近操作时间和总操作次数; [0009] Extraction of total user operations correspond to the user identification data from a database operation, the total user data for all users operating a single operation data set stored in the user identification corresponding to the user operation data total comprising at least one data partition for each partition method of operating a data storage corresponding to the type of the operation target records, each record includes the operation object the operation object ID and operation target of the operation target in a predetermined period of time recently the operating time and the total number of operations;

[0010] 将所述用户单次操作数据存储入所述用户总操作数据,然后将所述用户总操作数据存储入所述操作数据库。 [0010] The single operation of the user into the user data store total operation data, and then the overall operation of the user data is stored into the operation database.

[0011] 所述将所述用户单次操作数据存储入所述用户总操作数据,具体包括: [0011] The single operation of the user into the user data store total operation data, comprises:

[0012] 根据所述用户单次操作数据中的操作类型查询对应的数据分区; [0012] The query data partition corresponding to a single operation of the user data in the operation type;

[0013] 将所述用户单次操作数据存储入查询到的所述数据分区。 [0013] The user data stored in a single operation into a query to the data partition.

[0014] 所述将所述用户单次操作数据存储入查询到的所述数据分区,具体包括: [0014] The single operation of the user data is stored into a query to the data partition comprises:

[0015] 查询是否存在操作对象标识与所述用户总操作数据中的操作对象标识相同,最近操作时间与所述用户总操作数据中的本次操作时间处于同一预定时间段内的操作对象记录; [0015] Query operation whether the same object identification and object identification to the user operation of the overall operation of the data, this operation time of the last operation of the overall operation time and the user data recording operation target in the same predetermined period of time;

[0016] 如果存在,则将所述操作对象记录的最近操作时间更新为所述本次操作时间,并将所述操作对象记录的总操作次数+1; [0016] If present, then the operation object recording time is updated to the most recent operation of the time of this operation, and the total number of actions the +1 operation object record;

[0017] 如果不存在,则新增一条操作对象记录,将新增的操作对象记录的最近操作时间设置为所述本次操作时间,并将新增的操作对应记录中的总操作次数设置为1。 [0017] If not, the operation target is a new record, the new record operation target operation time nearest to the time of this operation, and to set the total number of operations corresponding to the operation of the new record is 1.

[0018] 每个数据分区各自拥有预先设置的最大操作对象记录数; [0018] Each data partition has a respective maximum number of recording operation target set in advance;

[0019] 所述新增一条操作对象记录之前,所述方法还包括: Before [0019] The operation of a new object record, said method further comprising:

[0020] 判断所述数据分区中的当前操作对象记录总数是否等于所述数据分区的最大操作对象记录数; [0020] The maximum operating current recording operation target object is equal to the total number of data records to determine whether the partition number of partition data;

[0021] 如果是,则将所述数据分区中最近操作时间最早的操作对象记录删除。 [0021] If so, then the most recent operation of the data partition oldest record delete operation target.

[0022] 所述操作数据库为基于固态硬盘的键值数据库。 [0022] The operation of the database based on the SSD key database.

[0023]另一方面,提供了一种用户操作数据存储装置,所述装置包括: [0023] On the other hand, a user operating a data storage device, said apparatus comprising:

[0024] 接收模块,用于接收用户标识以及与所述用户标识相对应的用户单次操作数据, 所述用户单次操作数据包括操作类型、操作对象标识和本次操作时间; [0024] a receiving module, configured to receive a user identifier and a user identifier corresponding to the user data of a single operation, a single operation of the user data includes an operation type, an operation object ID and the time of this operation;

[0025]提取模块,用于从操作数据库提取与所述接收模块接收到的用户标识一一对应的用户总操作数据,所述用户总操作数据用于集中存储所述用户标识对应的所有用户单次操作数据,所述用户总操作数据包括至少一个数据分区,每个所述数据分区用于存储对应的一种操作类型的操作对象记录,每条所述操作对象记录包括一个操作对象的操作对象标识和所述操作对象在预定时间段内的最近操作时间和总操作次数; [0025] extraction means for extracting received user identification module receiving the user always correspond to the operation data from the operation database, the user data for the total operation of the single stored centrally for all users corresponding to the user identifier data operations, the overall operation of user data includes at least one data partitions, each data partition for operating a storage type of the object corresponding to the recording operation, each operation object the operation object comprises a recording operation target and identifying the operation target in recent times and the total operating time of a predetermined period of operation;

[0026] 第一存储模块,用于将所述接收模块接收到的用户单次操作数据存储入所述提取模块提取的用户总操作数据; [0026] The first storage module, for receiving the received user module total single user operation data is stored into the operation data extracted by the extraction module;

[0027]第二存储模块,用于将所述用户总操作数据存储入所述操作数据库。 [0027] The second storage module, for the overall operation of the user data is stored into the operation database.

[0028] 所述第一存储模块,包括: [0028] The first storage module, comprising:

[0029] 分区查询单元,用于根据所述用户单次操作数据中的操作类型查询对应的数据分区; _ [0029] The partition query unit configured to query according to the type of operation corresponding to a single operation of the user data in the data partitions; _

[0030] 所述第一存储模块,用于将所述用户单次操作数据存储入所述分区查询单元查询到的所述数据分区。 [0030] The first storage module, for a single operation of the user data is stored into the partition query unit queries to the data partition.

[0031] 所述第一存储模块,具体还包括:记录查询单元、第一存储单元和第二存储单元; [0031] The first storage module is further comprising: posting query unit, a first storage unit and a second storage unit;

[0032] 所述记录查询单元,用于查询是否存在操作对象标识与所述用户总操作数据中的操作对象标识相同,最近操作时间与所述用户总操作数据中的本次操作时间处于同一预定时间段内的操作对象记录; [0032] The posting query unit configured to query whether the same operation target identifier identifying the user operation target data overall operation, the operation time of the most recent operation of this time and the total user data in the operation in the same predetermined recording operation target time period;

[0033] 如果存在操作对象标识与所述用户总操作数据中的操作对象标识相同,最近操作时间与所述用户总操作数据中的本次操作时间处于同一预定时间段内的操作对象记录,则所述第一存储单元,用于将所述操作对象记录的最近操作时间更新为所述本次操作时间, 并将所述操作对象记录的总操作次数+1; [0033] If the presence of the same operation target identifier identifying the user operation target data overall operation, the operation time of the most recent operation of this total operation time and the user data in the operation target in a predetermined period of time in the same record, then said first storage unit, the operation target for the recording operation time of the most recent update of the time of this operation, and the total number of actions the +1 operation object record;

[0034] 如果不存在操作对象标识与所述用户总操作数据中的操作对象标识相同,最近操作时间与所述用户总操作数据中的本次操作时间处于同一预定时间段内的操作对象记录, 则所述第二存储单元,用于新增一条操作对象记录,将新增的操作对象记录的最近操作时间设置为所述本次操作时间,并将新增的操作对应记录中的总操作次数设置为1。 [0034] If the same operation as the operation object identification and object identification to the user operation data in total, and the most recent operation time this total operation time of the user operation is the operation target data records for the same predetermined period of time does not exist, the total number of times the operation of the second storage unit, the operation target for a new record, the latest operating time is added to the operation target record the time of this operation, and add the corresponding record in the operation is set to 1.

[0035] 每个数据分区各自拥有预先设置的最大操作记录数; [0035] Each data partition has a respective maximum number of recording operation set in advance;

[0036] 所述第二存储单元包括:判断子单元和删除子单元; [0036] The second storage unit includes: a determination subunit and a subunit deleted;

[0037] 判断子单元,用于在第一存储模块将所述用户单次操作数据存储入查询到的所述数据分区之前,判断所述分区查询模块查询到的所述数据分区当前操作记录数是否等于所述数据分区的最大操作记录数; [0037] determining subunit, a first memory module prior to the user data stored in a single operation into a query to the data partition, the partition querying module determines the data partition to the current operation record number It is equal to the maximum number of recording operation of the data partitions;

[0038] 如果所述判断子单元判断查询到的所述数据分区当前操作记录数等于所述数据分区的最大操作记录数,则所述删除子单元,用于将最近一次操作时间最早的操作对象记录删除。 [0038] If the determination subunit determines the data partition to query the current operation equal to the maximum number of records that record operand data partition, then the deletion subunit, the last time for the first operation target operation record deleted.

[0039] 所述操作数据库为基于固态硬盘的键值数据库。 [0039] The operation of the database based on the SSD key database.

[0040] 本发明实施例提供的技术方案带来的有益效果是: [0040] Embodiments of the invention provide a technical solution is beneficial effects:

[0041] 通过根据用户标识提取该用户的用户总操作数据,并将用户单次操作数据存储在用户总操作数据中,最后将用户总操作数据存储入操作数据库,达到集中存储同一用户的用户操作数据,便于对同一用户的用户操作数据进行管理维护,间接提高用户操作数据读取和处理的实时性的目的。 [0041] By extracting the user's user data in accordance with the overall operation of the user identifier, and user data is stored in a single operation of the total user data in the operation, and finally the total user data is stored into the operation database operation, to achieve the same centrally stored user operation of the user data, the user operates facilitate data management and maintenance of the same user, the indirect object of improving the real-time user data reading and processing operation.

附图说明 BRIEF DESCRIPTION

[0042] 为了更清楚地说明本发明实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。 [0042] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, as briefly described in the introduction to the accompanying drawings required for use in describing the embodiments. Apparently, the drawings in the following description are only some of the present invention. embodiments, those of ordinary skill in the art is concerned, without creative efforts, can derive from these drawings other drawings.

[0043] 图1是本发明背景技术提供的操作数据组织示意图; [0043] FIG. 1 is a schematic diagram of data organization operating the present invention provides the background art;

[0044] 图2是本发明实施例一提供的用户操作数据存储方法的方法流程图; [0044] FIG. 2 is a method of operating a user data storing method according to an embodiment of the present invention to provide a flow chart;

[0045] 图3是本发明实施例二提供的用户操作数据存储方法的方法流程图; [0045] FIG. 3 is a method of operating a user data storing method according to a second embodiment of the present invention, a flow chart;

[0046] 图4是本发明实施例二提供的用户总操作数据的组织结构示意图; [0046] FIG. 4 is a schematic view of the overall operation of the data structure of the user organization according to a second embodiment of the present invention;

[0047] 图5是本发明实施例三提供的用户操作数据存储装置的装置结构图; [0047] FIG. 5 shows the structure of a user operating a data storage apparatus according to a third embodiment of the present invention;

[0048] 图6是本发明实施例三提供的用户操作数据存储装置的另一种装置结构图; [0048] FIG. 6 shows the structure of another user operating a data storage apparatus according to a third embodiment of the present invention;

[0049] 图7是本发明实施例三提供的第二存储单元的装置结构图。 [0049] FIG. 7 shows the structure of the second memory cell according to a third embodiment of the present invention.

具体实施方式 Detailed ways

[0050] 为使本发明的目的、技术方案和优点更加清楚,下面将结合附图对本发明实施方式作进一步地详细描述。 [0050] To make the objectives, technical solutions, and advantages of the present invention will become apparent in conjunction with the accompanying drawings of the following embodiments of the present invention will be described in further detail.

[0051] 实施例一 [0051] Example a

[0052] 请参见图2,其示出了本实施例一提供的用户操作数据存储方法的方法流程图,该方法可以应用于存储用户操作数据。 [0052] Referring to Figure 2, which illustrates a method of operating a user data storing method according to a first embodiment of the present flow chart, the method can be used to store user data operation. 本实施例一提供的用户操作数据存储方法可以包括如下步骤: A user operation according to a first data storage method of the present embodiment may include the steps of:

[0053] 步骤101,接收用户标识以及与该用户标识相对应的用户单次操作数据,该用户单次操作数据包括操作类型; [0053] Step 101, the user receives a user ID and a single operation data corresponding to the user identifier, the user data includes a single operation type operation;

[0054]用户的每一次操作都可以用一串文本数据来表示,这样的文本数据称为用户单次操作数据,其中,操作类型为用户对操作对象的各种操作,比如用户在音乐播放器中进行播放、下载、收藏、推荐以及删除等。 [0054] Each time a user's operation can be represented by a string of text data, text data such as a single operation referred to as user data, wherein the operation type is the user operation for the operation of various objects, such as music player, the user in play, download, collection, recommendations, and delete. 另外,用户标识可以包含在用户单次操作数据中,也可以独立在用户单次操作数据之外;用户单次操作数据中除了包括用户标识和操作类型之外, 还可以包括操作对象标识(比如歌曲ID)以及本次操作时间等。 Further, the user ID may be included in the user data in a single operation, it may be independently a single operation outside the user data; single user operation data in addition to the user ID and the operation type includes addition, the operation target may further comprise identification (such as song ID) and time of this operation.

[0055] 步骤102,从操作数据库提取与该用户标识一一对应的用户总操作数据; [0055] Step 102, extracting data identifying a user operating the total correspondence with the user operation from the database;

[0056]同一个用户标识对应的所有用户单次操作数据都集中存储在同一条与该用户标识相关联的数据中,这样的数据称为用户总操作数据,每个用户标识在数据库中仅对应一条用户总操作数据。 [0056] All single user operation data corresponding to the same user identification are centrally stored with an identification associated with the user data, such data is referred to as user data of the total operation, each user identifier in the database corresponds only a total user data operation.

[0057]实际应用中,操作数据库可以是基于固态硬盘的键值数据库,存储服务器或者有多个存储服务器组成的云存储系统可以将同一用户的所有单次操作数据存储为一个用户总操作数据,并将用户总操作数据存储在固态硬盘中。 [0057] In practical applications, the database may be based on a key operation SSD database, a cloud storage server or storage system have multiple storage servers may be all the same user data is stored as a single operation a total user data operation, the total operation and user data stored in the SSD. 当提取用户总操作数据时,只需要通过用户标识即可在操作数据库中快速查找并提取用户总操作数据。 When extracting user total operating data, only to quickly find and extract the user data in the operation total operation through a database user ID.

[0058]步骤103,将该用户单次操作数据存储入该用户总操作数据,然后将该用户总操作数据存储入操作数据库; [0058] Step 103, the user data storing operation into a single overall operation of the user data and the user data storing operation into the overall operation of the database;

[0059]为了便于对用户历史操作记录进行分析,可以在用户总操作数据中分区存储用户单次操作数据,其中,每个分区对应一种操作类型。 [0059] In order to facilitate user operation history records analyzed, the partition may store a single user operation data in the user data of the total operation, wherein, each partition corresponding to the type of operating.

[0060]上述提供的用户操作数据存储方法,将同一个用户的所有操作数据存储在一条用户总操作记录中,当需要提取该用户的所有操作数据时,只需要根据用户标识提取该用户总操作数据即可。 When [0060] the user operates the data storage method provided above, will be a total user operation record, when it is necessary to extract all of the operation data of the user all the operational data store with a user, only need to extract the total user operation according to the user identifier data can be.

[0061]综上所述,本实施例一提供的用户操作数据存储方法,通过根据用户标识提取该用户的用户总操作数据,并将用户单次操作数据存储在用户总操作数据中,最后将用户总操作数据存储入基于固态硬盘的键值数据库,达到集中存储同一用户的用户操作数据,便于对同一用户的用户操作数据进行管理维护,间接提高用户操作数据读取和处理的实时性的目的。 [0061] In summary, the user operates the data storing method according to a first embodiment of the present, by extracting the user data in accordance with user operations total user identifier, and user data is stored in a single operation of the total user data in the operation, and finally the total user data storing operation into the database based on the SSD key value, a user operation to achieve the same centrally stored user data, user-friendly data to manage and maintain the same user, the indirect object of improving the real-time user data reading and processing operation .

[0062] 实施例二 [0062] Second Embodiment

[0063] 为了对实施例一提供的用户操作数据存储方法做进一步描述,请参见图3,其以在多媒体文件播放中的应用中为例对该用户操作数据存储方法进行说明。 [0063] The data storage method for a user operation according to a first embodiment of the further description, see Figure 3, which is in the multimedia playback application in a user operation in an example of the data storing method will be described. 其中,多媒体文件可以是音频文件(比如MP3、WMA等格式文件)、视频文件(比如等格式文件)等, 多媒体文件ID (Identity,身份标识号码)为操作对象标识,操作ID为操作标识。 Among them, multimedia files can be audio files (such as MP3, WMA and other formats), video files (such as file format, etc.) and other multimedia files ID (Identity, identification number) for the object identification operation, operation ID to identify the operation. 本发明实施例提供了用户操作数据存储方法可以包括如下步骤: Embodiments of the present invention provides a user operating a data storage method may comprise the steps of:

[0064]步骤201,服务器接收客户端发送的用户标识以及与该用户标识相对应的用户单次操作数据,该用户单次操作数据包括操作类型; _5]用户在网络多媒体播放应用客户端(比如各类音乐播放器、视频播放器或内嵌于浏览器的音视频播放插件等)中对多媒体文件的每一次操作都可以用一串文本数据来表示,这样的文本数据称为用户单次操作数据,其中,用户标识可以包含在用户单次操作数据中,也可以独立在用户单次操作数据之外。 [0064] Step 201, the server receives the client sends a user ID and a user single operation data associated with the user ID corresponding to the user a single operation data includes the type of operation; _5] user network multimedia player application client (such as audio and video playback plug-ins and other kinds of music player, video player or embedded in the browser) in each operation of multimedia files can be represented by a string of text data, such as text data called user in a single operation data, wherein the user identifier may be included in the user data in a single operation, may be independently a single operation outside the user data. 用户在客户端中进行一次操作之后,客户端生成一条用户单次操作数据,并将该用户单次操作数据发送给服务器,以便服务器对用户操作数据进行存储和分析。 After the user performs one operation in the client, the client generates a single user operation data, and transmits the single user operation data to the server, the user operation data to the server for storage and analysis.

[0066] 其中,用户标识可以是表征用户身份的标识符,比如用户注册的账号。 [0066] wherein the user identification can be characterized as a user identifier, such as a registered user account. 用户对多媒体文件的操作类型可以分为三种,分别为重要操作、点播操作和删除操作等,其中,下载、推荐、收藏以及分享等操作都可以归类为重要操作;操作类型可以用操作ID的形式表示,比如,ID1表示重要操作,ID2表示点播操作,ID3表示删除操作。 User operation type of multimedia file can be divided into three types, namely an important operation, on-demand and delete operations, of which, download, recommend, collection and sharing operations can be classified as an important operation; type of operation can operate ID expressed in the form, for example, ID1 indicates important operation, ID2 represents on-demand operation, ID3 represents a delete operation.

[0067]另外,用户单次操作数据中除了包括用户标识和操作类型之外,还可以包括多媒体文件标识(比如歌曲ID或视频ID等)、本次操作时间等。 [0067] Further, a single user operation data in addition to including the user ID and the operation type, but also may include a multimedia file identifier (ID, such as a song or video ID, etc.), this operation time. t〇〇68] 步骤202,服务器根据用户标识从操作数据库提取相应的用户总操作数据,该用户总操作数据中包括一至多个数据分区,每个数据分区对应一种操作类型; t〇〇68] Step 202, the server extracts the user ID from the operation of the overall database operation corresponding user data, the user data includes a total operation to a plurality of data partitions, each data partition corresponding to the type of operating;

[0069] 其中,同一个用户标识对应的所有用户单次操作数据都集中存储在同一条与该用户标识相关联的数据流中,这样的数据流称为用户总操作数据。 [0069] wherein all users with a single operation data corresponding to the user identification are centrally stored with an identification associated with the user data stream, this data stream referred to as user data of the total operation.

[0070] 请参见图4所示的用户总操作数据组织结构示意图,其中,用户总操作数据最前部为用户标识(即图4中的用户账号),服务器提取用户总操作数据时,可以根据该用户标识提取相应的用户总操作数据。 When [0070] Referring to FIG 4 a schematic diagram of data organization structures total user operation Figure, wherein the total user data operation portion is a foremost user identification (i.e., user account in FIG. 4), the server extracts the user data of total operations, according to the extracting the user identification data corresponding to a user operation overall. 另外,操作数据库可以是基于固态硬盘的键值数据库。 In addition, the operation of the database may be based on a key database SSD.

[0071] 步骤203,查询该用户总操作数据中与该用户单次操作数据所包含的操作类型相对应的数据分区; [0071] Step 203, the user can always query the type of operation to the user operation data in a single operation included in the data corresponding to the data partitions;

[0072] 为了便于对用户历史操作记录进行分析,服务器存储用户单次操作数据时,可以在用户总操作数据中按照操作类型对用户单次操作数据进行分区存储,每个分区对应一种操作类型。 [0072] In order to facilitate user operation history recorded for analysis, when the server stores user data of a single operation, the user may be a single operation to partition data storage operation type according to the total user data in the operation, one partition for each action type .

[0073] 步骤204,查询是否存在操作对象标识与该用户总操作数据中的操作对象标识相同,最近操作时间与该用户总操作数据中的本次操作时间处于同一预定时间段内的操作对象记录,如果是,进入步骤205,否则,进入步骤206; [0073] Step 204, queries whether the same operation target identifier identifying the operation target of the user operation data in total, and the most recent operation time this operation time of the overall operation of user data in the operation target in a predetermined period of time records for the same if yes, proceeds to step 205, otherwise, proceeds to step 206;

[0074] 请参见图4,其中,每个数据分区中包含有若干条操作对象记录,操作对象记录由多媒体文件ID、操作ID、该多媒体文件在预定时间段内的最近操作时间和总操作次数组成; 具体的,在本实施例中,可以将同一天内对同一个多媒体文件的同一种操作用同一条操作对象记录来存储,同时标记同一天内的总操作次数。 [0074] Referring to FIG. 4, wherein each data partition contains several pieces of object recording operation, the recording operation target by a multimedia file ID, as ID, the multimedia file in the last period of a predetermined operating time and the total number of operations composition; specifically, in the present embodiment, the same operation may be on the same media file on the same day with the same operation target record is stored, while the total number of marking operations within the same day.

[0075] 步骤205,将该操作对象记录中的最近操作时间更新为该用户单次操作数据中的本次操作时间,并将该操作对象记录的操作次数+1; [0075] Step 205, the latest update time of the operation target recording operation for this operation in a single operation time of the user data, the number of operations and the +1 operation target record;

[0076] 具体的,如果查询到的数据分区中包含有最近操作时间与该用户单次操作数据所包含的本次操作时间处于同一天,且多媒体文件ID和操作ID与该用户单次操作数据中的多媒体文件ID和操作ID均相同的操作对象记录,则将该操作对象记录的最近一次操作时间更新为该用户单次操作数据所包含的本次操作时间,并将该操作对象记录的总操作次数+1。 [0076] Specifically, if the query to the data partition contains the most recent operation of this operating time period to the user a single operation data contained in the same day, and a multimedia file ID and the operation ID of the user in a single operation data the multimedia file ID and the operation ID of the operation target are the same record, then the record operation target operation time of the last update time of this operation for the user data included in a single operation, and the operation target record total + 1's operation. [0077] 步骤206,判断该数据分区当前操作对象记录数是否等于该数据分区的最大操作对象记录数,如果是,进入步骤207,否则,进入步骤208; [0077] Step 206, the operation target is determined maximum data partition if the current operation target of the data records is equal partition number of records, and if so, proceeds to step 207, otherwise, proceeds to step 208;

[0078] 请参见图4,为了权衡数据存储与处理的速度,压缩存储数据量,可以对每个数据分区预先设置最大操作对象记录数,不同数据分区的最大操作对象记录数可以相同,也可以不同,对此,本实施例不做具体限定。 [0078] Referring to FIG 4, in order to weigh the data storage and processing speed, the compressed data storage, the partition can be set in advance the maximum number of records for each operation target data, the operation target maximum number of records different data partitions can be the same or different from this, the present embodiment is not particularly limited.

[0079] 如果查询到的数据分区中不包含最近操作时间与该用户单次操作数据所包含的本次操作时间处于同一天,且多媒体文件ID和操作ID与该用户单次操作数据中的多媒体文件ID和操作ID均相同的操作对象记录,则进一步判断该数据分区当前操作对象记录数是否等于该数据分区的最大操作对象记录数。 [0079] If the query data partitions which this operation time of the last operation time to the user a single operation data contained in the same day, and the multimedia multimedia file ID and operation ID to the user a single operation data operation ID and file ID are the same recording operation target, it is further determined whether the data recording operation target partition is currently equal to the maximum number of data that the operation target partition number of records. 具体判断时,可以根据用户总操作数据的数据头中的对应数据分区操作对象记录条数(即图4中的重要操作记录数、点播操作记录数或删除记录操作数)进行判断。 Specifically determination may be based on the corresponding operand data object header partition of records user data in the overall operation (i.e., number of records is important in the operation of FIG 4, the recording operation of recording the number of operands on demand or delete) is determined.

[0080] 步骤207,将该数据分区中最近操作时间最早的操作对象记录删除; [0080] Step 207, the operation time of the most recent data partition first operation target records deleted;

[0081]如果判断该数据分区当前操作对象记录数等于该数据分区的最大操作对象记录数,则将该数据分区中最近操作时间最早的操作对象记录删除。 [0081] If it is judged that the current operation target data partition equal to the maximum number of records that record the number of the operation target data partition, then the latest operation time data partition first operation target record is deleted.

[0082] 步骤208,新增一条操作对象记录,将该用户单次操作数据的操作对象标识、操作类型和本次操作时间设置为该新增操作对象记录的操作对象标识、操作类型和最近操作时间,并将该新增操作对象记录的总操作次数设为1。 [0082] Step 208, a new object record operation, the user operating a single operation object identification data, the type of operation and the operation time setting for this new recording operation of the operation target object identifier, operation type, and the most recent operation time, and the total number of the new operation to an object record operation.

[0083]具体的,在判断该数据分区当前操作对象记录数不等于该数据分区的最大操作对象记录数,或者,判断该数据分区当前操作对象记录数等于该数据分区的最大操作对象记录数且删除该数据分区中最近操作时间最早的操作对象记录之后,新增一条操作对象记录,将该用户单次操作数据的多媒体文件ID、操作ID和本次操作时间设置为该新增操作对象记录的多媒体文件ID、操作ID和最近操作时间,并将该新增操作对象记录的操作次数设为1。 [0083] Specifically, it is determined that the data area to which the number of target recording operation is not equal to the maximum operation target data partition number of records, or determines that the data area to which the operation target number of records equal to the maximum operation target data partition number of records and delete the data partition after the most recent operation of the operation target oldest record, a new record operation target, the operation of a single multimedia file data user ID, operation ID and the operation time setting for this new recording operation target multimedia file ID, operation ID and time of the most recent operation, and the operation of the new object record number of operations set to 1.

[0084]需要说明的是,本实施例提供的用户操作数据存储方法仅以用户对多媒体文件的操作数据为例加以说明,实际应用中,本方法也可以用于存储其他类型的数据,对此,本实施例不做具体限定。 [0084] Incidentally, the user operates the data storage method provided in this embodiment only a user operation of the multimedia data files will be described as an example, a practical application, the present method may also be used for other types of data storage, this , the present embodiment is not particularly limited.

[0085]综上所述,本实施例二提供的用户操作数据存储方法,通过根据用户标识提取该用户的用户总操作数据,并将用户单次操作数据存储为用户总操作数据中的一条操作对象记录,最后将用户总操作数据存储入基于固态硬盘的键值数据库,达到集中存储同一用户的用户操作数据,便于对同一用户的用户操作数据进行管理维护,间接提高用户操作数据读取和处理的实时性的目的;另外,通过对每个操作分区设置最大操作记录数,达到压缩数据量的目的。 [0085] In summary, the user operates the data storing method according to the second embodiment of the present, by extracting the user data in accordance with user operations total user identifier, and user data is stored as a single operation of the total user data in an operation of the operation object records, and finally the total user data is stored into the operation database based on the SSD key value, a user operation to achieve the same centrally stored user data, user-friendly data to manage and maintain the same user, the user operates indirectly enhance data reading and processing real-time purposes; Further, by setting the maximum number of operations for each operation record partition, the amount of compressed data to achieve the purpose.

[0086] 实施例三 [0086] Example three

[0087] 参见图5,其示出了本发明实施例三提供的用户操作数据存储装置的装置结构图, 该装置可以应用于在多媒体文件推荐系统中存储用户对多媒体文件的操作数据。 [0087] Referring to Figure 5, which shows a configuration diagram of the present invention, a user apparatus operating a data storage apparatus according to a third embodiment, the operation of the data storage device can be applied to the user multimedia files in a multimedia file recommendation system. 该装置可以包括: The apparatus may comprise:

[0088] 接收模块401,用于接收用户标识以及与该用户标识相对应的用户单次操作数据, 用户单次操作数据包括操作类型; [0088] The receiving module 401 for receiving a user identifier and a user identifier corresponding to the user data of a single operation, a single user data operation includes an operation type;

[0089]提取模块4〇2,用于从操作数据库提取与接收模块401接收到的用户标识——对应的用户总操作数据; [0089] 4〇2 extraction module configured to extract the user from the operation receiving module 401 and a database received identification - the total operational data corresponding to the user;

[0090]第一存储模块403,用于将接收模块401接收到的用户单次操作数据存储入提取模块402提取的用户总操作数据; [0090] The first storage module 403, a user module for receiving the operation data of the user received a total of 401 single operation data storage module 402 extracted by the extraction;

[0091] 第二存储模块404,用于将用户总操作数据存储入操作数据库。 [0091] The second memory module 404, a user data storing operation into the overall database operation.

[0092] 其中,用户总操作数据包括至少一个数据分区,每个数据分区对应一种操作类型; [0092] wherein the user data comprises at least one of total operating data partitions, each data partition corresponding to the type of operating;

[0093] 请参见图6,其示出了本实施例三提供的用户操作数据存储装置的另一种装置结构图,其中,第一存储模块403,包括: [0093] Referring to FIG. 6, which illustrates another configuration diagram of a user apparatus operating a data storage apparatus according to a third embodiment of the present, wherein the first storage module 403, comprising:

[0094] 分区查询单元4031,用于根据用户单次操作数据中的操作类型查询对应的数据分区; [0094] partition query unit 4031, configured to query the user data partition corresponding to a single operation of the operation type data;

[0095] 第一存储模块403,用于将用户单次操作数据存储入分区查询单元4031查询到的数据分区。 [0095] The first storage module 403, configured to store the user data into a single operating unit 4031 partitions the query into a query data partition.

[0096] 另外,用户单次操作数据还包括操作对象标识和本次操作时间;并且,数据分区用于存储对应操作类型的操作对象记录,每条操作对象记录包括一个操作对象的操作对象标识和操作对象在预定时间段内的最近操作时间和总操作次数; [0096] Further, a single user operation data further includes an operation object identification and the current operation time; and, for storing the corresponding operational data partition type of the operation target records, each record comprises operating the operation target object identification and an operation target the total number of operations and the operation target in a predetermined period of time of the most recent operation;

[0097] 第一存储模块403,具体还包括:记录查询单元4032、第一存储单元4033和第二存储单元4034; [0097] The first storage module 403, particularly further comprising: posting query unit 4032, a first storing unit 4033 and the second storage unit 4034;

[0098] 记录查询单元4032,用于查询是否存在操作对象标识与用户总操作数据中的操作对象标识相同,最近操作时间与用户总操作数据中的本次操作时间处于同一预定时间段内的操作对象记录; [0098] posting query unit 4032, configured to query whether the same operation target identifier identifying a user operation target total operation data, and operation time of this latest operation time user data in the operation of the overall operation of the same predetermined period of time object records;

[0099] 如果存在操作对象标识与用户总操作数据中的操作对象标识相同,最近操作时间与用户总操作数据中的本次操作时间处于同一预定时间段内的操作对象记录,则第一存储单元4033,用于将操作对象记录的最近操作时间更新为本次操作时间,并将操作对象记录的总操作次数+1; [0099] If the same operation as the operation target object identifier identifying the user data in the overall operation, the operation target recently operated operation time record of this time the total user data in the same operation a predetermined time period exists, the first storage unit 4033, the operation target for the recording operation time is updated to the latest time operations, and the total number of actions the +1 operation object record;

[0100] 如果不存在操作对象标识与用户总操作数据中的操作对象标识相同,最近操作时间与用户总操作数据中的本次操作时间处于同一预定时间段内的操作对象记录,则第二存储单元4034,用于新增一条操作对象记录,将新增的操作对象记录的最近操作时间设置为本次操作时间,并将新增的操作对应记录中的总操作次数设置为1。 [0100] If the same operation as the operation target object identifier identifying the user data in the overall operation, the operation time of the most recent operation of this total operation time of the user data in the operation target record is not present the same predetermined period of time, the second memory unit 4034, an operation target for the new record, the latest operating time of the operation target record new set time-based operations, and operations corresponding to the new total number of recording operation is set to 1.

[0101]另外,每个数据分区各自拥有预先设置的最大操作记录数; [0101] Further, each data partition has a respective maximum number of recording operation set in advance;

[0102] 请参见图7,其示出了本实施例三提供的第二存储单元的装置结构图,其中,第二存储单元4034包括:判断子单元4034a和删除子单元4034b; [0102] Referring to FIG. 7, which shows a block diagram of a second apparatus according to a third storage unit of the present embodiment, wherein the second storage unit 4034 comprises: determining sub-unit 4034a and a deleting subunit 4034b;

[0103]判断子单元4034a,用于在第一存储模块403将用户单次操作数据存储入查询到的数据分区之前,判断分区查询模块查询到的数据分区当前操作记录数是否等于数据分区的最大操作记录数; _4] 如果判断子单元4034a判断查询到的数据分区当前操作记录数等于数据分区的最大操作记录数,则删除子单元4034b,用于将最近一次操作时间最早的操作对象记录删除。 [0103] determination sub-unit 4034a, a memory module 403 before the first user data is stored into a single operation to query the data partition, the partition is determined querying module to partition the data record number is equal to the current operation of the maximum data partition recording operation; maximum recording operand 4] If the determination subunit determines 4034a queries the data recording operation is equal to the number of the current partition of the data partition, deleting sub-unit 4034b, the last operation for the first time the object record delete operation. [0105] 需要说明的是,上述操作数据库为基于固态硬盘的键值数据库。 [0105] Note that the key database is a database-based operating SSD.

[0106] 综上所述,本发明实施例三提供的用户操作数据存储装置,通过根据用户标识提取该用户的用户总操作数据,并将用户单次操作数据存储为用户总操作数据中的一条操作对象记录,最后将用户总操作数据存储入基于固态硬盘的键值数据库,达到集中存储同一用户的用户操作数据,便于对同一用户的用户操作数据进行管理维护,间接提高用户操作数据读取和处理的实时性的目的;另外,通过对每个操作分区设置最大操作记录数,达到压缩数据量的目的。 [0106] In summary, the user operates the data storage device according to a third embodiment of the present invention, by extracting the user data in accordance with user operations total user identifier, and user data is stored as a single operation of the total user data in one operation recording operation target, and finally the total user data is stored into the operation database based on the SSD key value, a user operation to achieve the same centrally stored user data, user-friendly data to manage and maintain the same user, the user operates the data read indirectly enhance and real-time processing purposes; Further, by setting the maximum number of partitions for each operation of the recording operation, the amount of compressed data to achieve the purpose.

[0107] 需要说明的是:上述实施例提供的用户操作数据存储装置在存储用户操作数据时,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将装置的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。 [0107] It should be noted that: a user operating a data storage device of the above-described embodiments provide a user operation at the time of storing data, division of the foregoing functional modules is illustrated, in practice, may be assigned by the above-described functions according to the needs different functional modules is completed, the internal structure of the apparatus is divided into different functional modules, all or part of the functions described above. 另外,上述实施例提供的用户操作数据存储装置与用户操作数据存储方法实施例属于同一构思,其具体实现过程详见方法实施例,这里不再赘述。 Further, the user operates the above-described embodiment the data storage means provided in the user operation data storing method embodiment belong to the same concept, embodiments of the method specific implementation process thereof will not be repeated here.

[0108] 上述本发明实施例序号仅仅为了描述,不代表实施例的优劣。 Embodiment [0108] The present invention No. merely for description, the embodiments do not represent the merits embodiment.

[0109] 本领域普通技术人员可以理解实现上述实施例的全部或部分步骤可以通过硬件来完成,也可以通过程序来指令相关的硬件完成,所述的程序可以存储于一种计算机可读存储介质中,上述提到的存储介质可以是只读存储器,磁盘或光盘等。 [0109] Those of ordinary skill in the art may understand that the above embodiments all or part of the steps may be implemented by hardware, by a program instruction may be relevant hardware, the program may be stored in a computer-readable storage medium in the above-mentioned storage medium may be a read-only memory, magnetic or optical disk.

[0110] 以上所述仅为本发明的较佳实施例,并不用以限制本发明,凡在本发明的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本发明的保护范围之内。 [0110] The foregoing is only preferred embodiments of the present invention, not intended to limit the present invention within the spirit and principle of the present invention, any modification, equivalent replacement, or improvement, it should be included in the present within the scope of the invention.

Claims (9)

1. 一种用户操作数据存储方法,其特征在于,所述方法包括: 接收用户标识以及与所述用户标识相对应的用户单次操作数据,所述用户单次操作数据包括操作类型、操作对象标识和本次操作时间; 从操作数据库提取与所述用户标识一一对应的用户总操作数据,所述用户总操作数据用于集中存储所述用户标识对应的所有用户单次操作数据,所述用户总操作数据包括至少一个数据分区,每个所述数据分区用于存储对应的一种操作类型的操作对象记录,每条所述操作对象记录包括一个操作对象的操作对象标识和所述操作对象在预定时间段内的最近操作时间和总操作次数; 将所述用户单次操作数据存储入所述用户单次操作数据对应的数据分区,然后将所述用户总操作数据存储入所述操作数据库。 A user operating a data storage method, wherein the method comprises: receiving a user identifier and a user identifier corresponding to the user data of a single operation, a single operation of the user data includes operation type, the operation target the identification and operation time; extraction of total user identifier and the user operation data from the operation correspondence database, the total user data for all users operating a single operation of the user data set corresponding to the identifier is stored, the the total user operation data including at least one data partition, each said data object record comprising an object identifier and the operation of the operation target partition for operating a storage type of the object corresponding to the recording operation, each of said operating one operation target in the last period of a predetermined operating time and the total number of operations; the user data storage into a single operation of the user operation data corresponding to a single data partition, then the overall operation of the user data is stored into the operation database .
2. 根据权利要求1所述的用户操作数据存储方法,其特征在于,所述将所述用户单次操作数据存储入所述用户单次操作数据对应的数据分区,具体包括: 根据所述用户单次操作数据中的操作类型查询所述用户单次操作数据对应的数据分区; 将所述用户单次操作数据存储入查询到的所述数据分区。 The user operation data storing method according to claim 1, wherein said single operation of the user data is stored into a single operation of the user data corresponding to the data partition comprises: according to the user querying the user operating a single type of operational data operational data corresponding to a single data partition; the user data is stored into a single operation to query the data partition.
3. 根据权利要求2所述的用户操作数据存储方法,其特征在于,所述将所述用户单次操作数据存储入查询到的所述数据分区,具体包括: 查询是否存在操作对象标识与所述用户总操作数据中的操作对象标识相同,最近操作时间与所述用户总操作数据中的本次操作时间处于同一预定时间段内的操作对象记录; 如果存在,则将所述操作对象记录的最近操作时间更新为所述本次操作时间,并将所述操作对象记录的总操作次数+1; 如果不存在,则新增一条操作对象记录,将新增的操作对象记录的最近操作时间设置为所述本次操作时间,并将新增的操作对应记录中的总操作次数设置为1。 3. The user operates the data storage method as claimed in claim 2, wherein said single operation of the user data is stored into the data partition to query comprises: identifying whether the query operation target is present identifying said user operation target the same total operation data, the operation time and the user has recently total operation time of this operation is the operation target data records for the same predetermined period of time; and, if present, the object of the recording operation operating time of the latest update time of this operation, the total number of operations and the +1 operation target record; if not, the operation target is a new record, the new record latest operation target time setting operation this is the operation time, and set the total number of operations corresponding to the new operation is a record.
4. 根据权利要求3所述的用户操作数据存储方法,其特征在于,每个数据分区各自拥有预先设置的最大操作对象记录数; 所述新增一条操作对象记录之前,所述方法还包括: 判断所述数据分区中的当前操作对象记录总数是否等于所述数据分区的最大操作对象记录数; 如果是,则将所述数据分区中最近操作时间最早的操作对象记录删除。 4. The user operates the data storage method according to claim 3, characterized in that each data partition each have a maximum pre-set number of operation target record; new one before the operation target record, said method further comprising: Total current operation target record is equal to the maximum number of data partitions operation target determining the recording data in the partition; if so, the most recent operation of the data partition oldest record delete operation target.
5. 根据权利要求1所述的用户操作数据存储方法,其特征在于,所述操作数据库为基于固态硬盘的键值数据库。 The user operates the data storing method according to claim 1, wherein said operation database based on the SSD key database.
6. —种用户操作数据存储装置,其特征在于,所述装置包括: 接收模块,用于接收用户标识以及与所述用户标识相对应的用户单次操作数据,所述用户单次操作数据包括操作类型、操作对象标识和本次操作时间; 提取模块,用于从操作数据库提取与所述接收模块接收到的用户标识一一对应的用户总操作数据,所述用户总操作数据用于集中存储所述用户标识对应的所有用户单次操作数据,所述用户总操作数据包括至少一个数据分区,每个所述数据分区用于存储对应的一种操作类型的操作对象记录,每条所述操作对象记录包括一个操作对象的操作对象标识和所述操作对象在预定时间段内的最近操作时间和总操作次数; 第一存储模块,用于将所述接收模块接收到的用户单次操作数据存储入所述用户单次操作数据对应的数据分区; 第二存储模块,用于将 6. - Species user operating a data storage apparatus, wherein said apparatus comprising: a receiving module configured to receive a user ID and user data with a single operation corresponding to the user identifier, the user data includes a single operation operation type, an operation object ID and operation time of the current; extraction module for extracting received user identification module receiving the user always correspond to the operation data from the operation database, the user data for the total operation of centralized storage the user identifier corresponding to a single operation all user data, said user data includes at least a total operating data partitions, each data partition for operating a storage type of the object corresponding to the recording operation, each of the operation identifying the object record comprising an operation target and an operation target of the operation target in the most recent predetermined period of operation time and the total number of operations; first storage module, the receiving module for receiving the user data storage single operation into a single operation of the user data corresponding to the data partition; second storage module, configured to 所述用户总操作数据存储入所述操作数据库。 The total operation of the user data is stored into the operation database.
7. 根据权利要求6所述的用户操作数据存储装置,其特征在于,所述第一存储模块,包括: 分区查询单元,用于根据所述用户单次操作数据中的操作类型查询所述用户单次操作数据对应的数据分区; 所述第一存储模块,用于将所述用户单次操作数据存储入所述分区查询单元查询到的所述数据分区。 7. The user operates the data storage device according to claim 6, wherein said first memory module, comprising: partitioning the query means, for the operation of a single operation of the user data in the user types the query operation data corresponding to a single data partition; the first storage module, for a single operation of the user data is stored into the data partition means partitioning the query to the query.
8. 根据权利要求7所述的用户操作数据存储装置,其特征在于,所述第一存储模块,具体还包括:记录查询单元、第一存储单元和第二存储单元; 所述记录查询单元,用于查询是否存在操作对象标识与所述用户总操作数据中的操作对象标识相同,最近操作时间与所述用户总操作数据中的本次操作时间处于同一预定时间段内的操作对象记录; 如果存在操作对象标识与所述用户总操作数据中的操作对象标识相同,最近操作时间与所述用户总操作数据中的本次操作时间处于同一预定时间段内的操作对象记录,则所述第一存储单元,用于将所述操作对象记录的最近操作时间更新为所述本次操作时间,并将所述操作对象记录的总操作次数+1; 如果不存在操作对象标识与所述用户总操作数据中的操作对象标识相同,最近操作时间与所述用户总操作数据中的本次操 8. The user operates the data storage device according to claim 7, wherein said first storage module is further comprising: posting query unit, a first storage unit and a second storage unit; the posting query unit, whether the same operation for the query object identification and object identification to the user operation of the overall operation of the data, this time the total operation time of the most recent operation of the user operation is the operation target data records for the same predetermined period of time; if identifying the presence of the operation target with the user identification data the same as the operation object in the total operation time of the most recent operation of this operating time and the total user operation is the operation target data records for the same predetermined period of time, then the first a storage unit for recording the operation target of the most recent update time of the operation of this operating time, total number of operations and the +1 operation target record; total operation if the operation of the object identification and the user does not exist object identification data in the same operation, the operation time and the most recent operation of the total user data in the operation of this 时间处于同一预定时间段内的操作对象记录,则所述第二存储单元,用于新增一条操作对象记录,将新增的操作对象记录的最近操作时间设置为所述本次操作时间,并将新增的操作对应记录中的总操作次数设置为i。 Recently recording operation time operation target object recording time in the same operation a predetermined period of time, then the second storage unit, the operation target for a new record, add to the set time of this operation, and the total number of operations corresponding to the operation of the new record is set to i.
9. 根据权利要求8所述的用户操作数据存储装置,其特征在于,每个数据分区各自拥有预先设置的最大操作记录数; 所述第二存储单元包括:判断子单元和删除子单元; 判断子单元,用于在第一存储模块将所述用户单次操作数据存储入查询到的所述数据分区之前,判断所述分区查询单元查询到的所述数据分区当前操作记录数是否等于所述数据分区的最大操作记录数; 如果所述判断子单元判断查询到的所述数据分区当前操作记录数等于所述数据分区的最大操作记录数,则所述删除子单元,用于将最近一次操作时间最早的操作对象记录删除。 9. The user operates the data storage device according to claim 8, characterized in that each data partition has a respective maximum number of recording operation set in advance; the second storage unit comprises: a determination subunit and a subunit deleted; Analyzing subunit in a first memory module prior to the user data stored in a single operation into a query to the data partition, the partition is determined to the query unit queries whether the current operation data partition is equal to the number of records the maximum recording operand data partitions; determining subunit determines if the query to the data partition is currently equal to the maximum number of records in the operation recording operand data partition, then the deletion subunit, for the most recent operation the oldest operating object records deleted. ' 10.根据权利要求6所述的用户操作数据存储装置,其特征在于,所述操作数据库为基于固态硬盘的键值数据库。 '10. The user operates the data storage device as claimed in claim 6, wherein said operation database based on the SSD key database.
CN201210266469.0A 2012-07-30 2012-07-30 A user operating a data storage method and apparatus CN103577441B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210266469.0A CN103577441B (en) 2012-07-30 2012-07-30 A user operating a data storage method and apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210266469.0A CN103577441B (en) 2012-07-30 2012-07-30 A user operating a data storage method and apparatus

Publications (2)

Publication Number Publication Date
CN103577441A CN103577441A (en) 2014-02-12
CN103577441B true CN103577441B (en) 2017-07-21

Family

ID=50049246

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210266469.0A CN103577441B (en) 2012-07-30 2012-07-30 A user operating a data storage method and apparatus

Country Status (1)

Country Link
CN (1) CN103577441B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105279169A (en) * 2014-06-26 2016-01-27 中兴通讯股份有限公司 Database operation processing method and apparatus

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101079824A (en) * 2006-06-15 2007-11-28 腾讯科技(深圳)有限公司 A generation system and method for user interest preference vector
CN101551806B (en) * 2008-04-03 2012-04-18 北京搜狗科技发展有限公司 Personalized website navigation method and system

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB2385156B (en) * 2002-02-06 2005-08-10 Inventec Corp Automatic storage and retrieval system and method

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101079824A (en) * 2006-06-15 2007-11-28 腾讯科技(深圳)有限公司 A generation system and method for user interest preference vector
CN101551806B (en) * 2008-04-03 2012-04-18 北京搜狗科技发展有限公司 Personalized website navigation method and system

Also Published As

Publication number Publication date
CN103577441A (en) 2014-02-12

Similar Documents

Publication Publication Date Title
US9645787B1 (en) Tag-based electronic media playlist processing
US20040034650A1 (en) Media identifier registry
RU2531869C2 (en) Differential recoveries of file and system from peer-to-peer nodes of network and cloud
Niemenmaa et al. Hadoop-BAM: directly manipulating next generation sequencing data in the cloud
KR101279763B1 (en) Method for synchronizing data and data synchronizing system
KR100961461B1 (en) Multiple step identification of recordings
CN102332029B (en) Hadoop-based mass classifiable small file association storage method
US8706697B2 (en) Data retention component and framework
GB2439578A (en) Virtual file system with links between data streams
JP2014505925A (en) Method and system for performing cross-store coupled multi-tenant Store
CN102163210B (en) Quick update the index metadata
KR20090040855A (en) Information processing terminal device, information processing device, information processing method, and program
CN101984437A (en) Music resource individual recommendation method and system thereof
CN102483731B (en) The fingerprint identification system having a media database search load is equalized
US9792327B2 (en) Self-described query execution in a massively parallel SQL execution engine
CA2610002C (en) Device specific content indexing for optimized device operation
JP4767057B2 (en) Hash value generating program, a storage management program, judging program and data change verification device
KR20050041970A (en) Information processing device and method, computer program and contents browsing apparatus
CN103605805B (en) A method of storing vast amounts of time series data
US20070162546A1 (en) Sharing tags among individual user media libraries
CN102110146B (en) Key-value storage-based distributed file system metadata management method
JP4740060B2 (en) Duplicate detection program, duplicate data detection method and duplicate data detection device
US20100023489A1 (en) Method of distributing contents and system
US7949649B2 (en) Automatically acquiring acoustic and cultural information about music
US7711729B2 (en) Searching a document based on a customer defined metadata schemata

Legal Events

Date Code Title Description
C06 Publication
C10 Entry into substantive examination
LICC Enforcement, change and cancellation of record of contracts on the licence for exploitation of a patent or utility model