Configuration file analysis method and system, storage medium and electronic equipment

A configuration file and analysis method technology, applied in the field of data analysis, can solve the problems of large memory burden, sudden increase of memory data, failure, etc., to reduce the memory burden and improve work efficiency.

Pending Publication Date: 2020-02-04
WUHAN DOUYU NETWORK TECH CO LTD
View PDF0 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] With the development of live broadcasting, more and more people watch live broadcasting, and the content involved in live broadcasting is becoming more and more extensive. The data that the live broadcasting platform needs to process gradually becomes more and more complex. Putting the entire information into the memory will lead to a surge of data in the memory. When the memory is insufficient, due to the large memory burden, problems such as failures will occur, which will bring a lot of inconvenience to the daily data analysis work

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
  • Configuration file analysis method and system, storage medium and electronic equipment
  • Configuration file analysis method and system, storage medium and electronic equipment
  • Configuration file analysis method and system, storage medium and electronic equipment

Examples

Experimental program
Comparison scheme
Effect test

Embodiment 1

[0063] see figure 1 as well as figure 2 As shown, the embodiment of the present invention provides a method for parsing configuration files, including the following steps:

[0064] In step S1, the configuration file to be parsed is copied to obtain a temporary file;

[0065] Specifically, the step S1 specifically includes:

[0066] S11: Obtain the configuration file that needs to be parsed, and identify the size of the configuration file;

[0067] S12: Set a cache unit, divide the configuration file into N file units smaller than the cache unit, and combine the file units into a temporary file one by one through the cache unit, where N is an integer greater than 0.

[0068] As an optional implementation manner, in step S1, the specific implementation manner of this step includes:

[0069] Convert the configuration file into a file object srcFile;

[0070] Create a temporary file and convert the temporary file into a file object targetFile;

[0071] Convert the file obje...

Embodiment 2

[0116] Such as image 3 As shown, the fourth embodiment of the present invention also provides a configuration file parsing system, which includes:

[0117] Temporary file obtaining unit 1, used to obtain the configuration file that needs to be parsed, and copy the configuration file to obtain the temporary file;

[0118] Temporary file analysis unit 2 is used to obtain the label of the first line position and the last line position of the temporary file, if the first line position and the last line position are invalid labels, then delete the invalid label, if the first line position and the last line position are valid labels, Then save the configuration information corresponding to the valid label to the memory loading file, and delete the valid label and the corresponding configuration information;

[0119] The recursive calling unit 3 is used to analyze the temporary file by using the temporary file analysis unit multiple times until the temporary file is empty,...

Embodiment 3

[0148] The third embodiment of the present invention provides a computer-readable storage medium on which a computer program is stored, and when the computer program is executed by a processor, all or part of the method steps in the first embodiment are implemented.

[0149] The present invention realizes all or part of the process in the method of the first embodiment above, and it can also be completed by instructing related hardware through a computer program. The computer program can be stored in a computer-readable storage medium, and the computer program is processed by the processor. During execution, the steps in the above-mentioned various method embodiments can be realized. Wherein, the computer program includes computer program code, and the computer program code may be in the form of source code, object code, executable file or some intermediate form. The computer-readable medium may include: any entity or device capable of carrying computer program code, recor...

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 configuration file analysis method and system, a storage medium and electronic equipment, and relates to the field of data analysis. The method comprises the following steps:S1, obtaining a configuration file to be analyzed, and copying the configuration file to obtain a temporary file; s2, obtaining tags of a first row position and a tail row position of the temporary file, if the first row position and the tail row position are invalid tags, deleting the invalid tags, and if the first row position and the tail row position are valid tags, storing configuration information corresponding to the valid tags into a memory loading file, and deleting the valid tags and the corresponding configuration information; and S3, repeating the step S2 until the temporary fileis empty, and finishing the analysis of the configuration file. According to the method, the configuration file is copied, the temporary file imported into the memory for analysis is obtained, the temporary file is analyzed in a mode of simultaneous analysis from the head to the tail and timely deletion, the configuration information in the temporary file is obtained, and the analysis mode can improve the working efficiency and reduce the memory burden.

Description

technical field [0001] The invention relates to the field of data analysis, in particular to a configuration file analysis method, storage medium, electronic equipment and system. Background technique [0002] In the traditional solution, the configuration file is usually an XML format file. To parse the XML configuration file, the entire XML configuration is usually loaded into the memory and then parsed; [0003] With the development of live broadcasting, more and more people watch live broadcasting, and the content involved in live broadcasting is becoming more and more extensive. The data that the live broadcasting platform needs to process gradually becomes more and more complex. Putting the entire information into the memory will lead to a surge of data in the memory. When the memory is insufficient, problems such as failures will occur due to the large memory burden, which will bring a lot of inconvenience to the daily data analysis work. Contents of the invention ...

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
IPC IPC(8): G06F40/14
Inventor 张磊
Owner WUHAN DOUYU NETWORK TECH CO LTD
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