Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

Structured data storage method and device

A structured data and structure technology, applied in the field of data processing, can solve the problems of excessive storage space, poor flexibility, and inability to dynamically modify the schema, and achieve high efficiency and flexible adaptation.

Inactive Publication Date: 2013-11-13
BEIJING BAIDU NETCOM SCI & TECH CO LTD
View PDF2 Cites 23 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] In the existing technology, the efficiency of the compact binary storage method is very high, but the flexibility is too poor, and the dynamic modification of the schema cannot be achieved, and it cannot be applied to the actual storage application of Link data.
Tag-based text serialization methods such as XML and JSON have high flexibility, but require a lot of additional storage space, resulting in low storage and transmission performance; protobuf is an open source structured file provided by Google. Data packaging method, compared with XML and JSON, protobuf uses binary tags instead of text tags, which reduces the packaging capacity to a certain extent and improves storage efficiency
However, it still stores meta-information such as field name or field number, and when the content of the field itself is small, it will cause a serious waste of storage space

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
  • Structured data storage method and device
  • Structured data storage method and device
  • Structured data storage method and device

Examples

Experimental program
Comparison scheme
Effect test

specific Embodiment approach

[0131] According to a specific implementation manner of the present invention, the identification information generating unit 810 may specifically be used for:

[0132] According to the name of the structure to be stored, a hash algorithm is used to generate the identification information of the structure.

[0133] According to a specific implementation manner of the present invention, the writing unit 830 includes a fixed-length part writing subunit, which is specifically used for:

[0134] Write to the byte boundary fixed-length field of the structure;

[0135] Write the bit-bounded fixed-length field of the structure.

[0136] According to a specific implementation of the present invention, the fixed-length part written into the subunit is also used for:

[0137] Write the attribute value of the optional field of the structure.

Embodiment approach

[0138] According to a specific implementation manner of the present invention, the writing unit 830 includes a variable-length part writing subunit, which is specifically used for:

[0139] Write to the byte boundary variable-length field of the structure;

[0140] Write to the bit-bounded variable-length field of the structure.

[0141] According to a specific embodiment of the present invention, the variable-length part writing subunit, when the variable-length field to be written is a non-array type, writes the length identifier and field content of the field in sequence.

[0142] According to a specific implementation of the present invention, the variable-length part is written into the subunit. When the variable-length field to be written is an array type, the length identifier of the array is first written, and then the length identifier of the array is written in sequence. The length identifier of each element in the array and the content of the element.

[0143] For...

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

The invention discloses a structured data storage method and a structured data storage device. The structured data storage method comprises the following steps: generating identification information of a structural body to be stored; determining the type of a field to be stored in the structural body to be stored; writing the identification information of the structural body, a fixed-length data part of the structural body and a variable-length data part of the structural body in sequence to generate serialized structural body data in a storage space; and establishing unique correspondence of the identification information and a storage format of the serialized structural body. By applying the scheme provided by the invention, high efficiency close to compact binary storage can be provided by using a compact storage scheme without losing the flexibility similar to that of protobuf, so that flexible adaptation of structural body data of different versions can be realized.

Description

technical field [0001] The invention relates to the technical field of data processing, in particular to a structured data storage method and device. Background technique [0002] In the fusion application of the spider architecture, LinkCache needs to store the relevant attribute data of the Link. Link data is characterized by a large number of fields, but most of the fields are short, even bit (bit) fields, so data storage efficiency has a greater impact on data performance. On the other hand, in practical applications, the schema (structure) of Link data often involves modification of fields, so it also has high requirements for data flexibility. [0003] In the prior art, the compact binary storage method has high efficiency, but its flexibility is too poor to implement dynamic modification of the schema, and cannot be applied to the actual storage application of Link data. Tag-based text serialization methods such as XML and JSON have high flexibility, but require a l...

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 Applications(China)
IPC IPC(8): G06F17/30
Inventor 蒋锦鹏
Owner BEIJING BAIDU NETCOM SCI & TECH CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products