Data storage method and storage device

A storage device and data storage technology, applied in the direction of electrical digital data processing, special data processing applications, instruments, etc., can solve the problems of low retrieval efficiency, improve generation efficiency, reduce storage and use costs, and optimize data retrieval performance Effect

Active Publication Date: 2018-05-18
阿里巴巴华北技术有限公司
View PDF3 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0006] The invention provides a data storage method and storage device, which solves the problem of low retrieval efficiency in a big data environment

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Data storage method and storage device
  • Data storage method and storage device
  • Data storage method and storage device

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0057] The embodiment of the present invention provides a kind of data storage method, comprises:

[0058] S1. Read the first field information of the data information to be stored;

[0059] In this embodiment, the acquired data information needs to be reclassified before being stored. Specifically, for example, the acquired data information within a fixed period (for example, 1 hour) needs to be stored in a corresponding storage device. In a preferred embodiment, the storage device may be a magnetic disk, an optical disk, a hard disk, a cloud storage device, a fixed hard disk, and the like.

[0060]The server can read the obtained data information one by one, and grab the first field information in each data information one by one. The first field information may be any field information in the data information, such as: campaign_id, ad_slot_id, strategy_id, request_time, cookie_id or url and other arbitrary field information. In another preferred solution, the first field ...

Embodiment 2

[0077] The data storage method provided by the embodiment of the present invention rearranges the acquired data information and then writes it into the storage device for storage, specifically:

[0078] It is necessary to store the data shown in Table 1 according to the constructed index table, and then perform index retrieval as needed, specifically:

[0079] 201. The data information obtained by the server is shown in Table 1, and the data information at least includes fields such as campaign_id, ad_slot_id, strategy_id, request_time, cookie_id or url:

[0080] Table 1

[0081]

[0082] 202. The server reads the obtained data information one by one. According to the requirement, an index table can be built according to fields such as campaign_id and ad_slot_id. Specifically, the server reads the data with a value of 16331 in the field of campaign_id, and counts the value of the field of campaign_id as 16331 There are four pieces of data information. The server reads the ...

Embodiment 3

[0094] The embodiment of the present invention provides a data storage method, assuming that the data information stored in the storage device (disk) is as shown in Table 3, the server needs to query the data information whose campaign_id value is equal to 16331, and set to read only the data information in the data information The three fields of campaign_id, strategy_id, and request_time are described as examples. Specifically:

[0095] 301. The server sends an instruction to the storage device, requesting to retrieve data whose campaign_id value is equal to 16331, and only reads the three fields of campaign_id, strategy_id and request_time in the data information;

[0096]302. According to the data information retrieved by the request, the server determines that the first field is the campaign_id field, the value of the first field is 16331, and the server searches the index table for the starting position of the data information whose campaign_id value is 16331, as shown in...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

PUM

No PUM Login to view more

Abstract

A data storage method and storage device. The method comprises reading first field information about data information to be stored (S1); counting the number of items of first data information with the first field value being N, pre-reserving a storage location for the first data information on a storage device according to the number of items of first data information, and constructing an index table of the storage locations of the first field and the first data information (S2); and storing the first data information on the storage device (S3). By using the data storage method and storage device, data related to an index field is stored in a concentration area of a magnetic disk, thereby avoiding a lot of random reading operations of a magnetic disk generated in data reading, and reducing the storage and usage cost of an index.

Description

technical field [0001] The present invention relates to the technical field of data storage, in particular to a data storage method and a storage device. Background technique [0002] In the service based on spatial data, the retrieval of spatial data is a basic service, and it is the main way for users to locate and obtain data. In the face of a large amount of collected spatial data, it is necessary to establish a suitable spatial data index to improve the retrieval speed, and provide a stable and reliable incremental index processing method to process the newly collected data. [0003] After years of development, a large number of spatial data indexing technologies have emerged. The main early indexing methods include B-tree and hash index, lattice file and its deformation, quadtree and its deformation tree, k-d tree and its deformation tree , R tree and its deformation tree, etc. [0004] Under the same hardware conditions, the retrieval speed of spatial data is mainly...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to view more

Application Information

Patent Timeline
no application Login to view more
Patent Type & Authority Patents(China)
IPC IPC(8): G06F17/30
CPCG06F16/00
Inventor 孙承应贾玮肖锐程小军
Owner 阿里巴巴华北技术有限公司
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products