Flexible log storage and acquisition method

An acquisition method and log technology, which is applied in the field of flexible log storage and acquisition, can solve the problems of complex acquisition and low efficiency, and achieve the effects of reducing reading, reducing space occupation, and reducing the number of visits and data transmission volume

An acquisition method and log technology, which is applied in the field of flexible log storage and acquisition, can solve the problems of complex acquisition and low efficiency, and achieve the effects of reducing reading, reducing space occupation, and reducing the number of visits and data transmission volume

CN102880718AActive Publication Date: 2013-01-16BEIJING BYTEDANCE NETWORK TECH CO LTD

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • Flexible log storage and acquisition method

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0024] The present invention introduces an index and a data content identification box. When the log hash is recorded, each file that records data has a unique representation of a rule, such as using the data type and unique identification ID provided by the data. The name of the log file is, for example, type_1.log type_2.log. The so-called index concept refers to a general index log file, for example, the name is index.log, and the content placed in it is as follows:

[0025] Each row stores a data index, in order to facilitate data index reading.

[0026] The identification of which file the data content is stored in, such as type and id, through which the corresponding file can be found.

[0027] The data file is stored in the starting line number of the corresponding file or the location identifier of the written content.

[0028] Additional information, such as actions for this type of data, data recording time, data length, etc., are used for fast data screening and p...

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 relates to a flexible log storage and acquisition method, which comprises a data writing process and a data reading process. The method is based on multi-file hash, and under the condition of single file reading-writing entry when a plurality of files are required to be frequently read and written, an index-based file storage and reading mode is provided, so that the files can be conveniently stored in a hash way, and required logs can be easily read.

Description

technical field [0001] The invention relates to a method for storing and obtaining flexible logs. Background technique [0002] Incremental log means that the content in the log file will increase with time, and it is not fixedly provided for one-time reading. The log file is used as a data communication medium, that is to say, it is operated by one or a series of programs to generate certain data information, which is stored in the log file, and then the data is read by one or more files, so that a series of operate. At present, the most commonly used log recording methods are roughly as follows: 1. Write a bunch of content to the log sequentially, and then another program reads the specified log to obtain the content. This is recorded into a single log file. 2. Divide the log file by time, such as by month, day, hour, etc., and record it into multiple files. 3. The log file is divided by a certain identification of the content, such as unique ID, type and other record...

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
16 Jan 2013
Publication
CN102880718A
IPC
G06F17/30; G06F11/34
Inventors
潘海东; 梅春