Unlock instant, AI-driven research and patent intelligence for your innovation.

Configuration file processing method and device

A technology of configuration files and processing methods, which is applied in the computer field, can solve problems such as program exceptions, and achieve the effect of increasing stability

Pending Publication Date: 2021-06-11
海南视联通信技术有限公司
View PDF0 Cites 0 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

If the configuration file on the disk is changed during the running of the program, the program will still read the old parameters from the configuration file previously loaded into the memory, causing the program to be abnormal, and the changed configuration file cannot be loaded until the program is restarted. There is a problem with the changed configuration file, which will also cause the program to be abnormal

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 processing method and device
  • Configuration file processing method and device

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0059] In order to make the above objects, features and advantages of the present invention more comprehensible, the present invention will be further described in detail below in conjunction with the accompanying drawings and specific embodiments.

[0060] Programs (including system programs and application programs) usually load the configuration files in the disk into the memory during the startup phase, and the program can read the required parameters from the memory during operation. Configuration files can include various format types, such as JSON, XML, INI, and so on.

[0061] In order to enable the program to load the changed configuration file in time after the configuration file is changed, and if there is a problem with the currently loaded configuration file, the user can roll back the configuration file to the required version, the embodiment of the present invention can detect whether the configuration file is changed, after the configuration file change is dete...

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 embodiment of the invention provides a configuration file processing method and device.The method comprises the steps that after a program is started and a configuration file in a disk is loaded to a memory, obtaining basic information of the configuration file and writting it into a cache; detecting whether the configuration file in the disk is changed or not according to the basic information in the cache; if it is detected that the configuration file in the disk is changed, reloading the configuration file in the disk to the memory; according to the reloaded configuration file and the basic information in the cache, generating change record information, and storing the change record information in a database; and when the recovery condition is met, recovering the configuration file according to the change record information in the database, storing the configuration file in the disk, and re-loading the configuration file in the disk to the memory. According to the embodiment of the invention, whether the configuration file in the disk is changed or not can be monitored in time in the program running process, and the changed configuration file is reloaded to the memory, so that the stability of the program is improved.

Description

technical field [0001] The invention relates to the technical field of computers, in particular to a method for processing configuration files and a processing device for configuration files. Background technique [0002] The configuration file is a file that records the configuration parameters of the program. The program usually loads the configuration file from the disk into the memory at one time when the program is started. When a configuration parameter is needed later, the configuration parameter can be obtained directly from the memory. [0003] Due to program updates or malicious attacks, the configuration files in the disk may be changed frequently. If the configuration file on the disk is changed during the running of the program, the program will still read the old parameters from the configuration file previously loaded into the memory, causing the program to be abnormal, and the changed configuration file cannot be loaded until the program is restarted. There ...

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): G06F9/445G06F11/14
CPCG06F9/44505G06F11/1448
Inventor 吕亚亚李云鹏谢文龙杨春晖
Owner 海南视联通信技术有限公司