CN109992279A - Method for updating configuration data, calculates equipment and storage medium at device - Google Patents
Method for updating configuration data, calculates equipment and storage medium at device Download PDFInfo
- Publication number
- CN109992279A CN109992279A CN201711493128.6A CN201711493128A CN109992279A CN 109992279 A CN109992279 A CN 109992279A CN 201711493128 A CN201711493128 A CN 201711493128A CN 109992279 A CN109992279 A CN 109992279A
- Authority
- CN
- China
- Prior art keywords
- configuration data
- configuration
- version number
- data
- application module
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 51
- 238000003860 storage Methods 0.000 title claims abstract description 26
- 230000004044 response Effects 0.000 claims abstract description 14
- 230000006870 function Effects 0.000 claims description 24
- 230000007246 mechanism Effects 0.000 claims description 17
- 238000004590 computer program Methods 0.000 claims description 10
- 230000003068 static effect Effects 0.000 claims description 10
- 230000005540 biological transmission Effects 0.000 claims description 7
- 238000012544 monitoring process Methods 0.000 claims description 4
- 230000008520 organization Effects 0.000 claims description 2
- 230000008859 change Effects 0.000 description 9
- 230000000694 effects Effects 0.000 description 9
- 230000008569 process Effects 0.000 description 9
- 238000012545 processing Methods 0.000 description 8
- 238000004891 communication Methods 0.000 description 6
- 238000010586 diagram Methods 0.000 description 6
- 238000005516 engineering process Methods 0.000 description 5
- 230000001360 synchronised effect Effects 0.000 description 5
- 238000012423 maintenance Methods 0.000 description 4
- 230000008901 benefit Effects 0.000 description 3
- 238000006243 chemical reaction Methods 0.000 description 3
- 238000009826 distribution Methods 0.000 description 3
- 230000004048 modification Effects 0.000 description 3
- 238000012986 modification Methods 0.000 description 3
- 241001269238 Data Species 0.000 description 2
- 230000009471 action Effects 0.000 description 2
- 238000003491 array Methods 0.000 description 2
- 238000013461 design Methods 0.000 description 2
- 238000006467 substitution reaction Methods 0.000 description 2
- 230000006399 behavior Effects 0.000 description 1
- 230000006835 compression Effects 0.000 description 1
- 238000007906 compression Methods 0.000 description 1
- 230000009849 deactivation Effects 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 230000007812 deficiency Effects 0.000 description 1
- 238000001514 detection method Methods 0.000 description 1
- 238000005538 encapsulation Methods 0.000 description 1
- 230000002708 enhancing effect Effects 0.000 description 1
- 239000000835 fiber Substances 0.000 description 1
- 238000010191 image analysis Methods 0.000 description 1
- 230000001788 irregular Effects 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 230000002093 peripheral effect Effects 0.000 description 1
- 230000002688 persistence Effects 0.000 description 1
- 238000005096 rolling process Methods 0.000 description 1
- 239000004065 semiconductor Substances 0.000 description 1
- 238000000926 separation method Methods 0.000 description 1
- 239000007787 solid Substances 0.000 description 1
- 238000012360 testing method Methods 0.000 description 1
- 239000011800 void material Substances 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/60—Software deployment
- G06F8/65—Updates
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/70—Software maintenance or management
- G06F8/71—Version control; Configuration management
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- General Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Information Transfer Between Computers (AREA)
Abstract
The invention discloses method for updating configuration data, device, calculate equipment and storage medium, method includes: in response to the configuration data update for application module, configuration data coordinate and the configuration data version number of the configuration data of update are associatedly stored in configuration center, wherein, configuration data coordinate includes the module name of the application module corresponding to it, and configuration data version number associatedly stores with configuration data;Configuration data coordinate of the application module according to corresponding to it obtains configuration data version number from configuration center;Application module obtains the configuration data updated according to configuration data version number.Through the above scheme, high-volume and complicated configuration data dynamic can be updated, can be improved configuration data and update efficiency, reduces system operation risk.
Description
Technical field
The present invention relates to IT technical field more particularly to a kind of method for updating configuration data, device, calculate equipment and storage
Medium.
Background technique
With popularizing for distributed computing technology, the application system based on distributed computing technology is more and more.In addition Linux and virtual
Technology becomes current main-stream technology trend, and application system is no longer limited to minicomputer deployment, but by multiple x86 rolling reamer machines or void
The application system cluster of quasi- machine composition.
Clustering deployment facilitates application system extending transversely, linear improving performance, but it also brings one to O&M and management
Determine problem, for example, each node of cluster internal how to accomplish when facing configuration data and updating it is timely, uniformly, synchronized update, especially
When high-volume, structural data change, how to accomplish that the data of each node in cluster are synchronous.
Include: for the synchronous prior art of each node data
Restart application system, maintenance cost is higher, and some variation of data just needs maintenance personnel to restart application one by one.Together
When, application system restarts in production run and may cause influence to creation data, if restarting process takes a long time, may produce
Raw wrong data or dirty data increase added burden to system maintenance.
A timing detection program, switch state in timing Test database are done using database switch, once it detects
Switch is opened, then re-reads configuration data, refresh configuration data to local memory.But it is more due to the unicity that switch is semantic
A application program need to negotiate when the Resetting Switching.Application program needs to do a large amount of codings thus.
Using cluster management server zookeeper, configuration data concentration is published on the node of zookeeper, it is real
The centralized management and dynamic now configured updates.But ZooKeeper is not suitable for storing and transmitting mass data, is not suitable for storage
Structural data and the scene that configuration data frequently changes is not suitable for it.
Therefore, it is necessary to a kind of methods that distributed system configuration data dynamic updates.
Summary of the invention
For configuration data update low efficiency, the scene for not being suitable for the structuring of configuration data high-volume and frequently changing,
The embodiment of the invention provides a kind of method for updating configuration data, device, equipment and storage medium are calculated, configuration number can be improved
According to update efficiency, the quick update of configuration data that can be realized high-volume, frequently change.
In a first aspect, the embodiment of the invention provides a kind of method for updating configuration data, method includes:
In response to the configuration data update for application module, the configuration data of update is associatedly stored in configuration center
Configuration data coordinate and configuration data version number, wherein configuration data coordinate includes the module name of the application module corresponding to it,
Configuration data version number associatedly stores with configuration data;
Configuration data coordinate of the application module according to corresponding to it obtains configuration data version number from configuration center;
Application module obtains the configuration data updated according to configuration data version number.
Second aspect, the embodiment of the invention provides a kind of configuration data updating device, device includes: memory module,
One, which obtains module and second, obtains module.
Memory module can be updated in response to the configuration data for application module, associatedly store update in configuration center
Configuration data configuration data coordinate and configuration data version number, wherein configuration data coordinate includes the application corresponding to it
The module name of module, configuration data version number associatedly store with configuration data.
First acquisition module can be used for configuration data coordinate of the application module according to corresponding to it, obtain from configuration center
Configuration data version number.
Second, which obtains module, can obtain the configuration data updated according to configuration data version number.
The third aspect, the embodiment of the invention provides a kind of calculating equipment, comprising: at least one processor, at least one
Memory and computer program instructions stored in memory are realized such as when computer program instructions are executed by processor
The method of first aspect in above embodiment.
Fourth aspect, the embodiment of the invention provides a kind of computer readable storage mediums, are stored thereon with computer journey
The method such as first aspect in above embodiment is realized in sequence instruction when computer program instructions are executed by processor.
Method for updating configuration data provided in an embodiment of the present invention, calculates equipment and storage medium at device, may be implemented pair
High-volume and complicated configuration data dynamic update, and improve configuration data and update efficiency, reduce system operation risk.
Detailed description of the invention
In order to illustrate the technical solution of the embodiments of the present invention more clearly, will make below to required in the embodiment of the present invention
Attached drawing is briefly described, for those of ordinary skill in the art, without creative efforts, also
Other drawings may be obtained according to these drawings without any creative labor.
Fig. 1 shows the schematic flow chart of method for updating configuration data according to an embodiment of the invention;
Fig. 2 shows the signals of configuration data according to an embodiment of the invention and configuration data version number corresponding relationship
Figure;
Fig. 3 shows the schematic diagram of Watch mec hanism encapsulation logic according to an embodiment of the invention;
Fig. 4 shows the schematic flow chart that configuration data according to an embodiment of the invention updates;
Fig. 5 shows the schematic block diagram of configuration data updating device according to an embodiment of the invention;
Fig. 6 shows the hardware structural diagram provided in an embodiment of the present invention for calculating equipment.
Specific embodiment
The feature and exemplary embodiment of various aspects of the invention is described more fully below, in order to make mesh of the invention
, technical solution and advantage be more clearly understood, with reference to the accompanying drawings and embodiments, the present invention is further retouched in detail
It states.It should be understood that specific embodiment described herein is only configured to explain the present invention, it is not configured as limiting the present invention.
To those skilled in the art, the present invention can be real in the case where not needing some details in these details
It applies.Below the description of embodiment is used for the purpose of better understanding the present invention to provide by showing example of the invention.
It should be noted that, in this document, relational terms such as first and second and the like are used merely to a reality
Body or operation are distinguished with another entity or operation, are deposited without necessarily requiring or implying between these entities or operation
In any actual relationship or order or sequence.Moreover, the terms "include", "comprise" or its any other variant are intended to
Non-exclusive inclusion, so that the process, method, article or equipment including a series of elements is not only wanted including those
Element, but also including other elements that are not explicitly listed, or further include for this process, method, article or equipment
Intrinsic element.In the absence of more restrictions, the element limited by sentence " including ... ", it is not excluded that including
There is also other identical elements in the process, method, article or equipment of element.
Although cluster management server zookeeper, which can overcome to restart, detects program using with database switch timing
Defect, but the inherent shortcoming of itself further includes that znode size is restricted is not suitable for storage mass data, when data volume is more,
Network bandwidth deficiency will affect the processing to configuration data, and zookeeper is not suitable for structured data and is not suitable for frequency
The scene of numerous variation.Therefore the present invention is overcomes drawbacks described above, using the design pattern that configuration data is pressed to version number's management.Its
Advantage is that version number is invisible to application program, and the dynamic that data but may be implemented updates, to application almost without invasive.
Fig. 1 shows the schematic flow chart of method for updating configuration data according to an embodiment of the invention.
As shown in Figure 1, in the step s 100, can be updated in response to the configuration data for application module, in configuration
The heart associatedly stores configuration data coordinate and the configuration data version number of the configuration data of update, wherein configuration data coordinate packet
The module name of the application module corresponding to it is included, configuration data version number associatedly stores with configuration data.
Wherein, application module refers to the application program of processing business logic, can independent operating.Application program needs on startup
Static data and business configuration data are read, business logic processing is done.Data needed for configuration data refers to application module operation.?
It generally not only include static configuration data, but also business configuration data when including operation, application program is to static configuration in application process
Data are different with the storage mode of business configuration data, and static configuration data generally uses global (static state) variable storage, business
Configuration data generally uses JAVA class to store.For example, defining class in JAVA, keyword class completion can be used.Grammer is such as
Under: class class name { attribute (variable);Behavior (method);}.Business configuration data will specifically be divided into how many a JAVA classes and deposit
Storage is decided in its sole discretion by application program according to business and logic needs.The corresponding relationship of JAVA class and business configuration data is a pair of
It is more.
Configuration center can generate new configuration version number in administrator's (or operation maintenance personnel) configuration data and after issuing, can
The version number of configuration data to be registered in corresponding configuration data coordinate by creating version number.
Fig. 2 shows the signals of configuration data according to an embodiment of the invention and configuration data version number corresponding relationship
Figure.As shown in Fig. 2, one version number of a corresponding distribution of JAVA class.One JAVA class can store multiple configuration datas.
An embodiment according to the present invention, configuration data version number may include system version number, module name, data name, from
Increasing row number.
Wherein, system version number refers to the version number of product, and module name refers to using affiliated module title, corresponds to and applies mould
Block, data name refer to JAVA class name.Wherein the title of class is started according to rule by capitalization, the filename and class that JAVA is saved
Name is consistent.Since increasing row number generally from 0.The storage format of version number and configuration data can be with are as follows:
Configuration data version number | STRING/XML/JSON configuration data |
An embodiment according to the present invention, configuration data coordinate may include: organization name, department's name, system name, system version
Number, module name, data type, data name.
Wherein, configuration data coordinate refers to the information that can uniquely determine the data.The definition of coordinate can be with format are as follows: tissue
Name:: department's name:: system name:: system version number:: module name:: data type<db | k-v | properties>:: data name
The granularity of coordinate can be table, such as the title of a table, be also possible to generate after two table data correlations
Intermediate data;It can be key-value data;It is also possible to the section mode of configuration file.The storage mode of configuration data
It can be with are as follows:
Configuration data coordinate | Configuration data version number |
In step s 200, application module can match according to the configuration data coordinate corresponding to it from configuration center acquisition
Set versions of data number.
For example, application module can determine the configuration data coordinate where it according to module name, then sat by configuration data
Module name in mark finds its corresponding configuration data version number.
An embodiment according to the present invention, can be in response to associatedly storing new configuration data version with configuration data coordinate
This number, configuration center sends configuration data update notification to application module by api function predetermined.And in response to matching
Data update notification is set, application module API Function obtains configuration data version number from configuration center.
Wherein api function can be packaged into jar packet or a packet and call for application Module-embedding.Jar packet is usually to want when developing
Quoting general class breaks into packet convenient for storage and managenent.Such as api function can be defined as follows:
Configuration center can provide restful style API, restful may be considered it is a kind of establish http protocol it
On design pattern, the specific of http protocol is adequately utilized, indicates resource using URL, it is dynamic with each different HTTP
Word indicates the various actions to resource.The benefit done so is exactly resource and operation separation, and the management of resource is allowed more to standardize.
It can also support failover function.Failover is also known as failover, refers to one of them equipment or clothes in system
When business fails to running, another equipment or service can take over work performed by former deactivation system automatically.Any one
A node, which is broken down, does not influence other nodes normal work, guarantees higher stability.It is called inside API using address poll simultaneously
Algorithm guarantees that line node basis equalization is called.
API provides a variety of informing mechanisms, and client application can be with flexible choice.An embodiment according to the present invention, api function
Configuration data update notification can be sent to application module by broadcast mechanism or timing acquisition mechanism, wherein in broadcast mechanism
In, monitoring mechanism is established between the corresponding client of application module and configuration center.
Wherein, monitoring mechanism is a kind of proactive notification mode of asynchronous non-obstruction, i.e. Watch mechanism.Fig. 3 shows basis
The schematic flow chart of the Watch mechanism of one embodiment of the invention.
As shown in figure 3, can change every monitoring version number in 3s, after obtaining update if program return value is greater than 0
Version number.Client first wants the node state monitored to server-side successful registration, while client can locally store the prison
Listen the relevant information of device in WatchManager (management of monitor device), when the data mode that server-side is monitored changes,
Will proactive notification send corresponding event information and give associated session client, client will local response type readjustment it is related
The mechanism of message loop in the processing thread of Watcher (monitor).Different configuration data coordinates, call back function are different.
In timing acquisition mechanism, client at predetermined time intervals API Function to determine whether occur configuration data
It updates.
Wherein, periodically pulling (Pull) is that purposefully the active inquiry information on network, user give user from browser
Web issues request, obtains information needed by Web.Network environment in face of possessing massive information, search engine are effective networks
The gopher of information " pulling ".It can be combined with timing and push (Push) according to user's needs, purposefully, on time feel user
The information active transmission of interest is into client.
Distributed NoSQL storage configuration data can be used in an embodiment according to the present invention.
For example, using distribution NoSQL storage configuration data by memory module.NoSQL refers to non-relational database, point
For key assignments storing data library, column storage database, Document image analysis and graphic data base.Because NoSQL bottom uses distribution
Formula file persistence technology, can store the data of PB rank.Configuration center to using NoSQL key-value memory mechanism,
Value can store the binary data of arbitrary format.Common NoSQL includes key assignments (key/value) storage:
memcached,redis;The database of Oriented Documents: MongoDB, CouchDB;Database towards column: HBASE,
Cassandra etc..
In step S300, application module can obtain the configuration data updated according to configuration data version number.
Application module calls the API of configuration center, and the variation judgement and version number for completing version number obtain after changing
Obtain the configuration data of latest edition.
An embodiment according to the present invention, this method can also include: that the format of configuration data is converted to json format, solution
The configuration data for analysing json format replaces original class class using new class class, completes configuration data load.
For example, obtaining configuration data from configuration center according to configuration data version number.The data are Object format, are needed
Unserializing is at json format.The conversion of data format can be carried out by jar packet.Json data format can incite somebody to action
The one group of data indicated in JavaScript object are converted to character string, to transmit this character string between function, or
Character string is passed into server from Web client in asynchronous application.
The configuration data for parsing json format, can apply for new CLASS class again, by Line Procedure Mutually-exclusive, with new application
Class class replace JVM (Java Virtual Machine) inner original class class, added by the heat that memory refresh mode completes configuration data
Load comes into force, i.e., this class is dynamically loaded in the case where not restarting after the code for having modified class.It is biggish for configuration data
Message, settable automatic compression.To reduce network transmission expense.Memory refresh mode completes the java of the heat load of configuration data
Realize that code can be as follows:
public Configuration getConfiguration()throws OperationException{
Throwable cause=null;
If (configuration==null)
synchronized(this){
Try { final byte [] version=client.getData (constant.getConfigVersionPath
());
Configuration=loader.load (new String (version));
LastVersion=version;}
catch(final Exception e){
LOGGER.error("",e);
Cause=e;}}}
else{try{
Final byte [] version=client.getData (constant.getConfigVersionPath
());
if(!Arrays.equals(version,lastVersion)){
synchronized(this){
if(!Arrays.equals(version,lastVersion)){
Configuration=loader.load (new String (version));
LastVersion=version;
}}}}
catch(final Exception e){
LOGGER.error("",e);
Cause=e;}}
If (configuration==null)
throw
new OperationException(ResultCode.INTERNAL_SERVER_ERROR,cause);}
return configuration;}
By above-mentioned code, new profile data load can be got up in the case where not restarting server.
An embodiment according to the present invention, for static class configuration data, application module obtains configuration data letter by calling
Number is to obtain.For dynamic class configuration data, application module obtains configuration data version number function and acquisition configuration by calling
Data function obtains.
This programme can support the change of static and dynamic configuration data.Such as log of static loading data configures, and database is matched
It sets, number of concurrent etc.;Business configuration data refer to that configuration data and business relations needed for service operation are close when operation, this part
Data are usually structural data, and variation is more frequent, and as business changes, and may have batch to change.Static class is matched
It sets data (i.e. data infrequently change), application module can call directly getConfData (obtaining configuration data) and be referred to
Determine configuration data;For dynamic class configuration data (data often change), application program can voluntarily encapsulate getConfVersion
(obtaining configuration data version number) and getConfData (obtaining configuration data) method, dynamic obtain the data of variation.
Fig. 4 shows the schematic flow chart that configuration data according to an embodiment of the invention updates.As shown in figure 4, answering
Configuration data is obtained by corresponding configuration data coordinate and configuration data version number respectively with modules A, B, C, it is each to apply
Modules A, B, C monitor the corresponding version number of configuration center server configuration data coordinate by watch mechanism.Once the catalogue
It changes, configuration center broadcast event triggers watch call back function.Different configuration data coordinates, call back function are different.
Fig. 5 shows the schematic block diagram of configuration data updating device according to an embodiment of the invention.
As shown in figure 5, the device 500 may include: that memory module 510, first obtains module 520 and the second acquisition module
530。
Memory module 510 can be updated in response to the configuration data for application module, associatedly be stored in configuration center
The configuration data coordinate of the configuration data of update and configuration data version number, wherein configuration data coordinate includes corresponding to it
The module name of application module, configuration data version number associatedly store with configuration data.
First acquisition module 520 can be used for configuration data coordinate of the application module according to corresponding to it, from configuration center
Obtain configuration data version number.
Second, which obtains module 530, can obtain the configuration data updated according to configuration data version number.
An embodiment according to the present invention, the first acquisition module 520 may include transmission unit and call unit.
Transmission unit can be in response to associatedly storing new configuration data version number with configuration data coordinate, in configuration
The heart sends configuration data update notification to application module by api function predetermined.
Call unit can be obtained in response to configuration data update notification, application module API Function from configuration center
Configuration data version number.
An embodiment according to the present invention, the device 500 can also include: memory module.
Distributed NoSQL storage configuration data can be used in memory module.
An embodiment according to the present invention, the device 500 can also include: conversion module and parsing module.
The format of configuration data can be converted to json format by conversion module.
Parsing module can parse the configuration data of json format, replace original class class using new class class,
Complete configuration data load.
This programme solves configuration data dynamic replacement problem by introducing version number.Configuration version number is by configuration center pipe
Reason, classifies to configuration data by configuration version number, is managed.It, will by configuration center when configuration version number changes
New version number pushes to client, and client application correspondingly completes each application by calling the variation of API timing detection version number
The dynamic of configuration data updates.It may be implemented to update high-volume and complicated configuration data dynamic, improve configuration number
According to efficiency is updated, system operation risk is reduced.
The configuration data dynamic that marketing activity may be implemented in above scheme updates.Marketing activity is to show target customers
Recommend marketing specified activities according to certain rule, so marketing activity at least needs to include target customers, marketing rule is pushed away
The three parts data such as marketing activity recommended, marketing activity data are irregular configuration datas.A part of data of any of them become
Change is all considered as marketing activity configuration data and changes.Practical marketing activity often changes.To meet requirement of real-time, become
The marketing activity data of change need to realize and dynamically come into force that is, process does not need manual intervention in second grade.
In addition, the method for updating configuration data in conjunction with Fig. 1 embodiment of the present invention described can be realized by calculating equipment.
Fig. 6 shows the hardware structural diagram provided in an embodiment of the present invention for calculating equipment.
Calculating equipment may include processor 601 and the memory 602 for being stored with computer program instructions.
Specifically, above-mentioned processor 601 may include central processing unit (CPU) or specific integrated circuit
(Application Specific Integrated Circuit, ASIC), or may be configured to implement implementation of the present invention
One or more integrated circuits of example.
Memory 602 may include the mass storage for data or instruction.For example it rather than limits, memory
602 may include hard disk drive (Hard Disk Drive, HDD), floppy disk drive, flash memory, CD, magneto-optic disk, tape or logical
With the combination of universal serial bus (Universal Serial Bus, USB) driver or two or more the above.It is closing
In the case where suitable, memory 602 may include the medium of removable or non-removable (or fixed).In a suitable case, it stores
Device 602 can be inside or outside data processing equipment.In a particular embodiment, memory 602 is nonvolatile solid state storage
Device.In a particular embodiment, memory 602 includes read-only memory (ROM).In a suitable case, which can be mask
ROM, programming ROM (PROM), erasable PROM (EPROM), the electric erasable PROM (EEPROM), electrically-alterable ROM of programming
(EAROM) or the combination of flash memory or two or more the above.
Processor 601 is by reading and executing the computer program instructions stored in memory 602, to realize above-mentioned implementation
Any one method for updating configuration data in example.
In one example, calculating equipment may also include communication interface 603 and bus 610.Wherein, as shown in fig. 6, processing
Device 601, memory 602, communication interface 603 connect by bus 610 and complete mutual communication.
Communication interface 603 is mainly used for realizing in the embodiment of the present invention between each module, device, unit and/or equipment
Communication.
Bus 610 includes hardware, software or both, and the component for calculating equipment is coupled to each other together.For example and
It is unrestricted, bus may include accelerated graphics port (AGP) or other graphics bus, enhancing Industry Standard Architecture (EISA) bus,
Front side bus (FSB), super transmission (HT) interconnection, the interconnection of Industry Standard Architecture (ISA) bus, infinite bandwidth, low pin count (LPC)
Bus, memory bus, micro- channel architecture (MCA) bus, peripheral component interconnection (PCI) bus, PCI-Express (PCI-X)
Bus, Serial Advanced Technology Attachment (SATA) bus, Video Electronics Standards Association part (VLB) bus or other suitable buses
Or the combination of two or more the above.In a suitable case, bus 610 may include one or more buses.To the greatest extent
Specific bus has been described and illustrated in the pipe embodiment of the present invention, but the present invention considers any suitable bus or interconnection.
In addition, the embodiment of the present invention can provide a kind of computer in conjunction with the method for updating configuration data in above-described embodiment
Readable storage medium storing program for executing is realized.Computer program instructions are stored on the computer readable storage medium;The computer program refers to
Enable any one method for updating configuration data realized in above-described embodiment when being executed by processor.
In conclusion this programme is by introducing configuration data field for version number, configuration version number is by configuration center pipe
Reason, when configuration version number changes, pushes to client for new version number by configuration center.Without current by network element
Version number and the corresponding configuration file of target version number determine configured data difference list, can efficiently and effectively improve
The efficiency that configuration data updates.
It should be clear that the invention is not limited to specific configuration described above and shown in figure and processing.
For brevity, it is omitted here the detailed description to known method.In the above-described embodiments, several tools have been described and illustrated
The step of body, is as example.But method process of the invention is not limited to described and illustrated specific steps, this field
Technical staff can be variously modified, modification and addition after understanding spirit of the invention, or suitable between changing the step
Sequence.
Functional block shown in structures described above block diagram can be implemented as hardware, software, firmware or their group
It closes.When realizing in hardware, it may, for example, be electronic circuit, specific integrated circuit (ASIC), firmware appropriate, insert
Part, function card etc..When being realized with software mode, element of the invention is used to execute program or the generation of required task
Code section.Perhaps code segment can store in machine readable media program or the data-signal by carrying in carrier wave is passing
Defeated medium or communication links are sent." machine readable media " may include any medium for capableing of storage or transmission information.
The example of machine readable media includes electronic circuit, semiconductor memory devices, ROM, flash memory, erasable ROM (EROM), soft
Disk, CD-ROM, CD, hard disk, fiber medium, radio frequency (RF) link, etc..Code segment can be via such as internet, inline
The computer network of net etc. is downloaded.
It should also be noted that, the exemplary embodiment referred in the present invention, is retouched based on a series of step or device
State certain methods or system.But the present invention is not limited to the sequence of above-mentioned steps, that is to say, that can be according in embodiment
The sequence referred to executes step, may also be distinct from that the sequence in embodiment or several steps are performed simultaneously.
The above description is merely a specific embodiment, it is apparent to those skilled in the art that,
For convenience of description and succinctly, the system, module of foregoing description and the specific work process of unit can refer to preceding method
Corresponding process in embodiment, details are not described herein.It should be understood that scope of protection of the present invention is not limited thereto, it is any to be familiar with
Those skilled in the art in the technical scope disclosed by the present invention, can readily occur in various equivalent modifications or substitutions,
These modifications or substitutions should be covered by the protection scope of the present invention.
Claims (10)
1. a kind of method for updating configuration data, which is characterized in that the described method includes:
In response to the configuration data update for application module, the configuration of the configuration data of update is associatedly stored in configuration center
Data coordinates and configuration data version number, wherein the configuration data coordinate includes the module name of the application module corresponding to it,
The configuration data version number associatedly stores with the configuration data;
The configuration data coordinate of the application module according to corresponding to it obtains the configuration data from the configuration center
Version number;
The application module obtains the configuration data of the update according to the configuration data version number.
2. the method according to claim 1, wherein the configuration number of the application module according to corresponding to it
The configuration data version number is obtained according to coordinate, from the configuration center, comprising:
In response to associatedly storing new configuration data version number with configuration data coordinate, it is fixed in advance that the configuration center passes through
The api function of justice sends configuration data update notification to the application module;
In response to the configuration data update notification, the application module calls the api function, obtains from the configuration center
The configuration data version number.
3. the method according to claim 1, wherein
The configuration data coordinate includes: organization name, department's name, system name, system version number, module name, data type, data
Name.
The configuration data version number include system version number, module name, data name, from increasing row number.
4. the method according to claim 1, wherein the method also includes:
The configuration data is stored using distributed NoSQL.
5. according to the method described in claim 2, it is characterized in that, the configuration center by api function predetermined to
The application module sends configuration data update notification, comprising:
The configuration center is matched by broadcast mechanism or timing acquisition mechanism to application module transmission by the api function
Set data update notification, wherein
In the broadcast mechanism, monitoring machine is established between the corresponding client of the application module and the configuration center
System;
In the timing acquisition mechanism, the client calls the api function to determine whether occurring at predetermined time intervals
Configuration data updates.
6. the method according to claim 1, wherein the method also includes:
The format of the configuration data is converted into json format;
The configuration data for parsing json format replaces original class class using new class class, completes configuration data
Load.
7. the method according to claim 1, wherein further include:
For static class configuration data, the application module is obtained by calling acquisition configuration data function;
For dynamic class configuration data, the application module obtains configuration data version number function and acquisition configuration number by calling
It is obtained according to function.
8. a kind of configuration data updating device, which is characterized in that described device includes:
Memory module, for associatedly storing update in configuration center in response to the configuration data update for application module
The configuration data coordinate of configuration data and configuration data version number, wherein the configuration data coordinate includes answering corresponding to it
With the module name of module, the configuration data version number associatedly stores with the configuration data;
First obtains module, for the configuration data coordinate of the application module according to corresponding to it, from the configuration
The heart obtains the configuration data version number;
Second obtains module, for obtaining the configuration data of the update according to the configuration data version number.
9. a kind of calculating equipment characterized by comprising at least one processor, at least one processor and be stored in institute
The computer program instructions in memory are stated, are realized when the computer program instructions are executed by the processor as right is wanted
Seek method described in any one of 1-7.
10. a kind of computer readable storage medium, is stored thereon with computer program instructions, which is characterized in that when the calculating
Such as method of any of claims 1-7 is realized when machine program instruction is executed by processor.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711493128.6A CN109992279A (en) | 2017-12-30 | 2017-12-30 | Method for updating configuration data, calculates equipment and storage medium at device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201711493128.6A CN109992279A (en) | 2017-12-30 | 2017-12-30 | Method for updating configuration data, calculates equipment and storage medium at device |
Publications (1)
Publication Number | Publication Date |
---|---|
CN109992279A true CN109992279A (en) | 2019-07-09 |
Family
ID=67111135
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201711493128.6A Pending CN109992279A (en) | 2017-12-30 | 2017-12-30 | Method for updating configuration data, calculates equipment and storage medium at device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109992279A (en) |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111198711A (en) * | 2020-01-13 | 2020-05-26 | 陕西心像信息科技有限公司 | Collection version control method and system based on MongoDB |
CN111277432A (en) * | 2020-01-10 | 2020-06-12 | 腾讯科技(深圳)有限公司 | Configuration information updating method and device, electronic equipment and storage medium |
CN113312075A (en) * | 2021-06-25 | 2021-08-27 | 上海致景信息科技有限公司 | Configuration information issuing method and device, storage medium and processor |
CN113485767A (en) * | 2021-07-09 | 2021-10-08 | 绿盟科技集团股份有限公司 | Control configuration updating method and system and electronic equipment |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101540700A (en) * | 2009-04-10 | 2009-09-23 | 成都市华为赛门铁克科技有限公司 | Configuration linkage method, system, terminal and network equipment management server |
WO2010145272A1 (en) * | 2009-10-14 | 2010-12-23 | 中兴通讯股份有限公司 | Mobile terminal and updating method for configuration information thereof |
US20140122862A1 (en) * | 2012-10-28 | 2014-05-01 | Google Inc. | Configuration file updater |
CN106547576A (en) * | 2015-09-16 | 2017-03-29 | 腾讯科技(深圳)有限公司 | The acquisition methods and device of configuration file |
CN107368331A (en) * | 2017-06-26 | 2017-11-21 | 聚好看科技股份有限公司 | The configuration file update method and device of application program |
CN107465714A (en) * | 2017-01-23 | 2017-12-12 | 北京思特奇信息技术股份有限公司 | A kind of configuration data dynamic update system and method based on application cluster |
-
2017
- 2017-12-30 CN CN201711493128.6A patent/CN109992279A/en active Pending
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101540700A (en) * | 2009-04-10 | 2009-09-23 | 成都市华为赛门铁克科技有限公司 | Configuration linkage method, system, terminal and network equipment management server |
WO2010145272A1 (en) * | 2009-10-14 | 2010-12-23 | 中兴通讯股份有限公司 | Mobile terminal and updating method for configuration information thereof |
US20140122862A1 (en) * | 2012-10-28 | 2014-05-01 | Google Inc. | Configuration file updater |
CN106547576A (en) * | 2015-09-16 | 2017-03-29 | 腾讯科技(深圳)有限公司 | The acquisition methods and device of configuration file |
CN107465714A (en) * | 2017-01-23 | 2017-12-12 | 北京思特奇信息技术股份有限公司 | A kind of configuration data dynamic update system and method based on application cluster |
CN107368331A (en) * | 2017-06-26 | 2017-11-21 | 聚好看科技股份有限公司 | The configuration file update method and device of application program |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111277432A (en) * | 2020-01-10 | 2020-06-12 | 腾讯科技(深圳)有限公司 | Configuration information updating method and device, electronic equipment and storage medium |
CN111277432B (en) * | 2020-01-10 | 2023-05-23 | 腾讯科技(深圳)有限公司 | Configuration information updating method and device, electronic equipment and storage medium |
CN111198711A (en) * | 2020-01-13 | 2020-05-26 | 陕西心像信息科技有限公司 | Collection version control method and system based on MongoDB |
CN111198711B (en) * | 2020-01-13 | 2023-02-28 | 陕西心像信息科技有限公司 | Collection version control method and system based on MongoDB |
CN113312075A (en) * | 2021-06-25 | 2021-08-27 | 上海致景信息科技有限公司 | Configuration information issuing method and device, storage medium and processor |
CN113485767A (en) * | 2021-07-09 | 2021-10-08 | 绿盟科技集团股份有限公司 | Control configuration updating method and system and electronic equipment |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10798148B2 (en) | Configuring nodes of distributed systems | |
CN109818902B (en) | Automatic service deployment method, service scheduling management module and EPG platform | |
US11838351B1 (en) | Customizable load balancing in a user behavior analytics deployment | |
US11586697B2 (en) | Publishing rest API changes based on subscriber's customized request | |
US10509794B2 (en) | Dynamically-generated files for visualization sharing | |
US11815987B2 (en) | Log analysis in vector space | |
CN109992279A (en) | Method for updating configuration data, calculates equipment and storage medium at device | |
CN111580884B (en) | Configuration updating method, device, server and electronic equipment | |
US20190334781A1 (en) | Network functions virtualization | |
CN108319463B (en) | Application upgrading method and device | |
US20190095599A1 (en) | Customizing a user behavior analytics deployment | |
US9223640B2 (en) | Strategy based event notification chain | |
US20080172583A1 (en) | Objective assessment of application crashes from a customer environment | |
CN111182089B (en) | Container cluster system, method and device for accessing big data assembly and server | |
US8799923B2 (en) | Determining relationship data associated with application programs | |
US10476768B2 (en) | Diagnostic and recovery signals for disconnected applications in hosted service environment | |
CN110019312B (en) | Read-write data separation scheduling method, device, equipment and medium | |
CN111970198A (en) | Service routing method, device, electronic equipment and medium | |
US11314553B2 (en) | Method, apparatus, and computer program product for determining usage change rate of storage system | |
IL270524B2 (en) | Matching and attribution of user device events | |
US20210019323A1 (en) | Information processing apparatus, data management system, data management method, and non-temporary computer readable medium including data management program | |
CN106909429A (en) | A kind of synchronous upgrade method and device | |
CN110765165A (en) | Method, device and system for synchronously processing cross-system data | |
CN111064626A (en) | Configuration updating method, device, server and readable storage medium | |
US11169863B2 (en) | Dynamic management method for menu, server and system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20190709 |