CN109429260A - A kind of method of calibration and device of northbound data - Google Patents

A kind of method of calibration and device of northbound data Download PDF

Info

Publication number
CN109429260A
CN109429260A CN201710730489.1A CN201710730489A CN109429260A CN 109429260 A CN109429260 A CN 109429260A CN 201710730489 A CN201710730489 A CN 201710730489A CN 109429260 A CN109429260 A CN 109429260A
Authority
CN
China
Prior art keywords
verified
file
data
verification rule
northbound data
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.)
Granted
Application number
CN201710730489.1A
Other languages
Chinese (zh)
Other versions
CN109429260B (en
Inventor
李阿琼
夏明博
张佳伟
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
ZTE Corp
Original Assignee
ZTE Corp
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by ZTE Corp filed Critical ZTE Corp
Priority to CN201710730489.1A priority Critical patent/CN109429260B/en
Publication of CN109429260A publication Critical patent/CN109429260A/en
Application granted granted Critical
Publication of CN109429260B publication Critical patent/CN109429260B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W24/00Supervisory, monitoring or testing arrangements
    • H04W24/08Testing, supervising or monitoring using real traffic

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Design And Manufacture Of Integrated Circuits (AREA)

Abstract

The embodiment of the invention provides a kind of method of calibration of northbound data and device, the method for calibration of northbound data includes: to obtain model file and verification rule description file;Model needs file is generated according to the model file, wherein the model needs file includes the attribute specification to northbound data to be verified;According to the verification rule description file generated verification rule;According to the model needs file and verification rule, northbound data to be verified is verified.The method of calibration and device of the northbound data of the embodiment of the present invention can support a variety of models by generating model needs file according to the model file, can solve the problems, such as the model poor compatibility in the verification of northbound data;The method of calibration and device of the northbound data of the embodiment of the present invention pass through according to the verification rule description file generated verification rule, verification rule can be loaded automatically, and verification rule can be diversified, can solve the problems, such as the verification rule poor compatibility in the verification of northbound data.

Description

A kind of method of calibration and device of northbound data
Technical field
The present invention relates to field of telecommunications, in particular to the method for calibration and device of a kind of northbound data.
Background technique
Northbound data is code requirement of the telecom network management system according to operator, is supplied to the number of Operator Specific Service system According to.These code requirements can not stop evolution forward according to different operators, different system versions, and telecom network management system It needs to guarantee that the northbound data generated closely conforms to north orientation specification, therefore the verification to northbound data, is telecommunications network all the time An important content in guard system test.It is largely that data are guaranteed by manual test in pervious test job Accuracy.But the data volume of northbound data is big (record of hundreds of thousands easily), data entry more (several hundred thousands of easily Attribute), it verifies be very easy to error manually, it is also difficult to accomplish all standing.Therefore there are also tools later to assist north orientation number According to verification, but these tools, both for some model version, some type of hardware is either by a certain operator The customization tools of offer, with model version evolution, tool can not be verified;Increase a type of hardware newly, tool i.e. can not Verification;The northbound data of Huan Liaoyige operator, tool can not also be verified.In addition, tool before regular for verification All be using will verify rule be fixed up in code by the way of, to northbound data verification rule be it is fixed, change one kind The verification rule of type of hardware or the northbound data of operator, tool can't change correspondingly.
Summary of the invention
In order to solve the above-mentioned technical problem, the embodiment of the invention provides a kind of method of calibration of northbound data and device, It can solve the problems, such as that the compatibility of northbound data calibration tool is poor.
One aspect according to an embodiment of the present invention provides a kind of method of calibration of northbound data, comprising:
Obtain model file and verification rule description file;
Model needs file is generated according to the model file;The model needs file contains to northbound data to be verified Attribute specification;
According to the verification rule description file generated verification rule;
According to the model needs file and verification rule, the northbound data to be verified is verified.
Other side according to an embodiment of the present invention additionally provides a kind of calibration equipment of northbound data, comprising:
Module is obtained, for obtaining model file and verification rule description file;
First generation module, for generating model needs file according to the model file, wherein the model needs text Part includes the attribute specification to northbound data to be verified;
Second generation module, for according to the verification rule description file generated verification rule;
Correction verification module, for verifying the north orientation number to be verified according to the model needs file and verification rule According to.
Another aspect according to an embodiment of the present invention additionally provides a kind of calibration equipment of northbound data, comprising: storage Device, processor and storage on a memory and the computer program that can run on a processor, the processor execution journey The step in the method for calibration of northbound data as described above is realized when sequence.
Another aspect according to an embodiment of the present invention additionally provides a kind of computer readable storage medium, stores thereon There is computer program, which realizes the step in the method for calibration of northbound data as described above when being executed by processor.
The embodiment of the present invention has the following beneficial effects:
Firstly, when generating model needs file according to the model file, the method for calibration and device of the embodiment of the present invention One or more critical fielies corresponding with the attribute specification of northbound data to be verified, root can be extracted from the model file Model needs file is generated according to the critical field, a variety of models can be supported in this way, the mould in the verification of northbound data can be solved The problem of type poor compatibility.
Further, it is generated in model needs file processes according to the model file, when will be to new version, new hard When the data that the model that part type, other operators define generates are verified, the method for calibration and dress of the embodiment of the present invention It sets and does not need modifiers code.
Secondly, when according to the verification rule description file generated verification rule, the method for calibration of the embodiment of the present invention And device is by generating corresponding with the regular description language according to the regular description language in the verification rule description file Verification rule, can load automatically in this way verification rule, and verify rule can diversification, can solve in the verification of northbound data Verification rule poor compatibility the problem of.
Further, under different scenes, when having different require to data check rule, the method for calibration of the embodiment of the present invention And device can automatically generate the verification rule for being suitble to the scene to need, can flexibly support according to verification rule description file A variety of data check scenes.
Detailed description of the invention
Fig. 1 is a kind of flow chart of the method for calibration of northbound data provided in an embodiment of the present invention;
Fig. 2 is a kind of structural schematic diagram of the calibration equipment of northbound data provided in an embodiment of the present invention;
Fig. 3 be another embodiment of the present invention provides a kind of northbound data calibration equipment structural schematic diagram.
Specific embodiment
To keep the technical problem to be solved in the present invention, technical solution and advantage clearer, below in conjunction with attached drawing and tool Body embodiment is described in detail.
Fig. 1 is a kind of flow chart of the method for calibration of northbound data provided in an embodiment of the present invention, referring to Fig. 1, the school Proved recipe method the following steps are included:
S101 obtains model file and verification rule description file.
It should be noted that the model file is the normative model for the north orientation that operator provides, the model file packet The transformation rule of north orientation model containing operator and to related contents such as the attribute specifications of northbound data.Different model versions Originally, different hardware type or the corresponding model file of different operators are different.
Optionally, in order to meet the method for calibration of the northbound data, the model file for needing operator to provide meets as follows Call format:
The model file uses Excel format, there is index sheet (index page) in Excel file, comprising each Each page of title where the MO (Managed Object manages object) of index information, these indexes and the model file is one by one It is corresponding, while column name is also required in page where these MO.It is necessary for for example, it is desired to define the corresponding column name of statistical coding " statistical coding ";The corresponding column name of different degree information is necessary for " different degree ";The corresponding column name of attribute-name information is necessary for " English Literary fame claims ", other fields and so on;The master pattern file that operator provides all can satisfy above-mentioned call format, For being unsatisfactory for the model file of above-mentioned requirements, then the device could be used to related north orientation number after needing first to meet the requirements it According to being verified.
It should be noted that the verification rule description regular description language of file record, describes language for the rule Speech can form the verification rule after conversion.
S102 generates model needs file according to the model file.
Wherein, model file is that operator provides, and is that equipment vendor generates northbound data and operator's verification northbound data Foundation;Model file is multifarious, all different between different model versions, different hardware type or different operators. Since in northbound data verifies, emphasis verification is the contents such as title, attribute coding, different degree, the value range of data, but The information of concern is certain several word in the several individual fields of certain in certain model file or model file The combination of section.One or more passes corresponding with the attribute specification of northbound data to be verified can be extracted from the model file Key field;Model needs file is generated according to the critical field.
The model needs file can be used for indicating the attribute specification to northbound data to be verified, described to north orientation to be verified The attribute specification of data includes: the requirement of many aspects such as attribute number, Property Name, attribute value, Attribute Significance.
Optionally, in the model needs file, containing one or more to the attribute specification of northbound data to be verified Critical field.
Specifically, critical field related with verification northbound data can be extracted in the model file, such as: attribute is compiled Code, different degree, Chinese, English name, manufacturer etc., and it is inserted into local data base according to certain rules.It is right below The preservation rule of critical field is illustrated.CM (Configuration Management, configuration management) in base station The critical field that model file extracts includes: field a, field b, field c, and local data base is provided with x column, y column, z column.Example Such as, can x column, y column, z column in field a, field b, field c and database be corresponded and is placed into database.
The critical field packet that PM (Performance management, performance management) model file in base station extracts It includes: corresponding x column, y column, z in the local data base that the fields such as field a, field b, field c, field d, field e, field f import In column, since x column, y column, z column are not an a pair in field a, field b, field c, field d, field e, field f and database It answers, needs by certain rule conversion.
(not simple be added or connection) forms for example, field a and field b are combined according to certain requirement One assembly finally arranges correspondence x of first assembly storage into local data base, and field c is individually stored in y column; It is combined field d, field e, field f to form the second assembly, second assembly is stored in z column, is finally completed Conversion of the model file to the model needs file.The model needs file has following key element: x=field a+ Field b, y=field c, z=field d+ field e+ field f.
It should be noted that the example above is two of them there are many kinds of the storage rules of critical field;It is understood that , do not limit the storage rule of critical field specifically in the present embodiment.
S103, according to the verification rule description file generated verification rule.
But in the verification of northbound data, in addition to northbound data needs to meet model needs, operator also requires northbound data The name for meeting filename requires, the total data record in a north direction document, and each attribute value cannot be all 0 or complete For empty requirement, attribute cannot excessive or missing requirement, requirement of file Header (file header) content etc. is a series of to be wanted It asks, can be verification rule by these requirements Uniform Name.It is required for different editions, different hardware type, different operators Northbound data, verification rule may be different.
It, in the present embodiment, can be according to verification rule description file in order to solve the compatibility issue of northbound data verification In regular description language, automatically generate the verification of this northbound data verification to be used is regular.
According to verification rule description file generated verification rule, there are many implementations, below with wherein optimal one The process of kind implementation is specifically described, and specific steps include:
11) judge whether the verification rule description file is preset verification rule description file;If the verification Rule description file is preset verification rule description file, executes step 12);If the verification rule description file is not Preset verification rule description file, executes step 13).
If 12) the verification rule description file is preset verification rule description file, directly acquires and advised with verification The corresponding preset verification rule of file is then described.
It should be noted that default rule describes preservation form there are many file and preset verification rules, Ke Yicun In the local database, there may also be in file.For example, there being preset verification rule description text in local database Part, and preset verification rule corresponding with preset verification rule description file.If the verification rule description file It is not required to during according to the verification rule description file generated verification rule for preset verification rule description file Additionally to increase, delete, modifying verification rule, preset verification rule need to be only obtained from database.
Wherein, the preset verification rule includes but is not limited to following several: the verification to northbound data file name Rule, the verification rule to northbound data file compression formats, the verification rule to northbound data fileversion number, to object Verification rule, to the verification rule of attribute, to verification rule of field etc..
For example, be to the verification rule of northbound data file name " ^ ([0-9A-Z]+-) * (V [0-9] [0-9] [0- 9] -) ([0-9A-Z]+-) * [0-9A-Z]+$ ", the verification rule to northbound data file compression formats is “equalsIgnoreCase("zip")”。
If 13) the verification rule description file is not preset verification rule description file, advised according to the verification The regular description language in file is then described, verification rule corresponding with the rule description language is generated.
S104 verifies northbound data to be verified according to the model needs file and verification rule.
It should be noted that northbound data to be verified is the northbound data original document that equipment vendor provides, original document is The compressed package of several forms such as zip (one kind of active record compressed format), gz (compressed file in unix system).
The checking procedure of northbound data to be verified in order to facilitate understanding, below to the checking process of northbound data to be verified into Row illustrates, and specifically includes following below scheme:
21) judge whether the filename of northbound data to be verified meets the name for verifying the filename in rule and want It asks;If the filename of northbound data to be verified is unsatisfactory for the name requirement of the filename in the verification rule, it is described to Verification northbound data is invalid data;If the filename of northbound data to be verified meets the filename in the verification rule When name requires, step 22) is executed.
22) if the name that the filename of northbound data to be verified meets the filename in the verification rule requires, Judge whether the attribute value of northbound data to be verified meets to be all 0 in the verification rule or be all empty requirement;If to be verified The attribute value of northbound data, which meets, to be all 0 in the verification rule or is all empty requirement, then northbound data to be verified is illegal number According to;If the attribute value of northbound data to be verified is unsatisfactory for being all 0 in the verification rule or is all empty requirement, then follow the steps 23)。
If 23) attribute value of northbound data to be verified is unsatisfactory for being all 0 in the verification rule or is all empty requirement, Judge whether the attribute value of northbound data to be verified meets in model needs file to the attribute specification of northbound data to be verified;Such as The attribute value of fruit northbound data to be verified meets to the attribute specification of northbound data to be verified in model needs file, then it is described to Verification northbound data is valid data;If the attribute value of northbound data to be verified is unsatisfactory in model needs file to be verified The attribute specification of northbound data, then the northbound data to be verified is invalid data.
To sum up, finally statistical information or illegal, the underproof data of verification are output in check results, verification knot Fruit is shown in the form of a file.
In the present embodiment, when generating model needs file according to the model file, the verification side of the embodiment of the present invention Method can extract one or more critical fielies corresponding with the attribute specification of northbound data to be verified from the model file, Model needs file is generated according to the critical field, a variety of models can be supported in this way, can solve in the verification of northbound data The problem of model poor compatibility.
Further, it is generated in model needs file processes according to the model file, when will be to new version, new hard When the data that the model that part type, other operators define generates are verified, the method for calibration of the embodiment of the present invention is not required to Want modifiers code.
When according to the verification rule description file generated verification rule, by according to the verification rule description file In regular description language, it is regular to generate verification corresponding with the regular description language, the method for calibration of the embodiment of the present invention Verification rule can be loaded automatically, and verifying rule can be diversified, the verification rule that can be solved in the verification of northbound data is compatible Property difference problem.
Further, under different scenes, when having different require to data check rule, the method for calibration of the embodiment of the present invention The verification rule for being suitble to the scene to need can be automatically generated, can flexibly support a variety of numbers according to verification rule description file According to verification scene.
Fig. 2 is a kind of structural schematic diagram of the calibration equipment of northbound data provided in an embodiment of the present invention, referring to fig. 2, institute State the calibration equipment 200 of northbound data, comprising: obtain module 201, the first generation module 202, the second generation module 203 and school Test module 204.
Wherein, the acquisition module 201, for obtaining model file and verification rule description file.
It should be noted that the model file is the normative model for the north orientation that operator provides, the model file packet The transformation rule of north orientation model containing operator and to related contents such as the attribute specifications of northbound data.Different model versions Originally, different hardware type or the corresponding model file of different operators are different.
First generation module 202, for generating model needs file according to the model file;The model needs File contains the attribute specification to northbound data to be verified.
Optionally, first generation module 202 includes:
The extraction unit, for extracting one or more attributes with northbound data to be verified from the model file It is required that corresponding critical field.
Can be extracted in the model file with the related critical field of verification northbound data, such as: attribute coding, important Degree, Chinese, English name, manufacturer etc., and it is inserted into local data base according to certain rules.For example, in base station The critical field that CM model file extracts includes: field a, field b, field c, and local data base is provided with x column, y column, z column.It can X column, y column, z column in field a, field b, field c and database are corresponded and are placed into database.It needs to illustrate It is that there are many kinds of the storage rules of critical field, the example above is one of which;It is understood that in the present embodiment The storage rule of critical field is not limited specifically.
First generation unit, for generating model needs file according to the critical field.
Second generation module 203, for according to the verification rule description file generated verification rule.
It should be noted that having preset verification rule in local database describes file, and with it is preset The corresponding preset verification rule of verification rule description file.If the verification rule description file is preset verification rule File is described, during according to verification rule description file generated verification rule, do not need additionally to increase, deletion, Modification verification rule need to only obtain preset verification rule from database.
Optionally, second generation module 203 includes: the first judging unit, acquiring unit and the second generation unit.
Wherein, first judging unit, for judging whether the verification rule description file is preset verification rule File is then described;
The acquiring unit, if being preset verification rule description file for the verification rule description file, directly It obtains and takes preset verification rule corresponding with verification rule description file;
Second generation unit, if not being preset verification rule description text for the verification rule description file Part generates verification corresponding with the rule description language according to the regular description language in the verification rule description file Rule.
The correction verification module 204, for verifying north orientation to be verified according to the model needs file and verification rule Data.
Optionally, the correction verification module 204 includes: second judgment unit, the first execution unit, third judging unit, Two execution units, the 4th judging unit, third execution unit and the 4th execution unit.
The second judgment unit, for judging whether the filename of northbound data to be verified meets in the verification rule Filename name requirement;
First execution unit, if the filename for northbound data to be verified is unsatisfactory in the verification rule The name requirement of filename, then the northbound data to be verified is invalid data;
The third judging unit, if the filename for northbound data to be verified meets the text in the verification rule When the name of part name requires, judges whether the attribute value of northbound data to be verified meets and be all 0 in the verification rule or be all Sky requires;
Second execution unit is all if the attribute value for northbound data to be verified meets in the verification rule 0 or it is all empty requirement, then northbound data to be verified is invalid data;
4th judging unit, if the attribute value for northbound data to be verified is unsatisfactory in the verification rule entirely 0 or to be all empty requirement, then judge whether the attribute value of northbound data to be verified meets in model needs file to north to be verified To the attribute specification of data;
The third execution unit, is treated if the attribute value for northbound data to be verified meets in model needs file The attribute specification of northbound data is verified, then the northbound data to be verified is valid data;
4th execution unit, if the attribute value for northbound data to be verified be unsatisfactory for it is right in model needs file The attribute specification of northbound data to be verified, then the northbound data to be verified is invalid data.
In the present embodiment, when generating model needs file according to the model file, pass through the first generation module 202 Extraction unit can extract one or more passes corresponding with the attribute specification of northbound data to be verified from the model file Key field generates model needs file, the verification dress of the embodiment of the present invention according to the critical field by the first generation unit A variety of models can be supported by setting, and can solve the problems, such as the model poor compatibility in the verification of northbound data.
Further, it is generated in model needs file processes according to the model file, when will be to new version, new hard When the data that the model that part type, other operators define generates are verified, the calibration equipment of the embodiment of the present invention is not required to Want modifiers code.
When according to the verification rule description file generated verification rule, by the second generation module 203 according to described Regular description language in verification rule description file, generates verification rule corresponding with the rule description language, the present invention The calibration equipment of embodiment can load verification rule automatically, and verifying rule can be diversified, can solve the verification of northbound data In verification rule poor compatibility the problem of.
Further, under different scenes, when having different require to data check rule, the calibration equipment of the embodiment of the present invention The verification rule for being suitble to the scene to need can be automatically generated, can flexibly support a variety of numbers according to verification rule description file According to verification scene.
Fig. 3 be another embodiment of the present invention provides northbound data calibration equipment structural schematic diagram.As shown in figure 3, The calibration equipment 300 of northbound data shown in Fig. 3 includes: that at least one processor 301, memory 302, at least one network connect Mouth 304 and user interface 303.Various components in the calibration equipment 300 of northbound data are coupled in one by bus system 305 It rises.It is understood that bus system 305 is for realizing the connection communication between these components.It includes data/address bus that bus system 305, which is removed, Except, it further include power bus, control bus and status signal bus in addition.It, will be various in Fig. 3 but for the sake of clear explanation Bus is all designated as bus system 305.
Wherein, user interface 303 may include display, keyboard or pointing device (for example, mouse, trace ball (track ball), touch-sensitive plate or touch screen etc..It is appreciated that the memory 302 in the embodiment of the present invention can be it is volatile Property memory or nonvolatile memory, or may include both volatile and non-volatile memories.Wherein, non-volatile memories Device can be read-only memory (Read-Only Memory, ROM), programmable read only memory (Programmable ROM, PROM), Erasable Programmable Read Only Memory EPROM (Erasable PROM, EPROM), electrically erasable programmable read-only memory (Electrically EPROM, EEPROM) or flash memory.Volatile memory can be random access memory (Random Access Memory, RAM), it is used as External Cache.By exemplary but be not restricted explanation, many forms RAM is available, such as static random access memory (Static RAM, SRAM), dynamic random access memory (Dynamic RAM, DRAM), Synchronous Dynamic Random Access Memory (Synchronous DRAM, SDRAM), Double Data Rate synchronous dynamic Random access memory (Double Data Rate SDRAM, DDRSDRAM), enhanced Synchronous Dynamic Random Access Memory (Enhanced SDRAM, ESDRAM), synchronized links dynamic random access memory (Synchlink DRAM, SLDRAM) and straight Meet rambus random access memory (Direct Rambus RAM, DRRAM).The system of description of the embodiment of the present invention and side The memory 302 of method is intended to include but is not limited to the memory of these and any other suitable type.
In some embodiments, memory 302 stores following element, executable modules or data structures, or Their subset of person or their superset: operating system 3021 and application program 3022.
Wherein, operating system 3021 include various system programs, such as ccf layer, core library layer, driving layer etc., are used for Realize various basic businesses and the hardware based task of processing.Application program 3022 includes various application programs, such as media Player (Media Player), browser (Browser) etc., for realizing various applied business.Realize the embodiment of the present invention The program of method may be embodied in application program 3022.
In embodiments of the present invention, by the program or instruction of calling memory 302 to store, specifically, can be application The program or instruction stored in program 3022, processor 301 can execute the method for calibration of above-mentioned northbound data.
The method that the embodiments of the present invention disclose can be applied in processor 301, or be realized by processor 301. Processor 301 may be a kind of IC chip, the processing capacity with signal.During realization, the above method it is each Step can be completed by the integrated logic circuit of the hardware in processor 301 or the instruction of software form.Above-mentioned processing Device 301 can be general processor, digital signal processor (Digital Signal Processor, DSP), dedicated integrated electricity Road (Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field Programmable Gate Array, FPGA) either other programmable logic device, discrete gate or transistor logic, Discrete hardware components.It may be implemented or execute disclosed each method, step and the logic diagram in the embodiment of the present invention.It is general Processor can be microprocessor or the processor is also possible to any conventional processor etc..In conjunction with institute of the embodiment of the present invention The step of disclosed method, can be embodied directly in hardware decoding processor and execute completion, or with the hardware in decoding processor And software module combination executes completion.Software module can be located at random access memory, and flash memory, read-only memory may be programmed read-only In the storage medium of this fields such as memory or electrically erasable programmable memory, register maturation.The storage medium is located at The step of memory 302, processor 301 reads the information in memory 302, completes the above method in conjunction with its hardware.
It is understood that the embodiment of the present invention description these embodiments can with hardware, software, firmware, middleware, Microcode or combinations thereof is realized.For hardware realization, processing unit be may be implemented in one or more specific integrated circuits (Application Specific Integrated Circuits, ASIC), digital signal processor (Digital Signal Processing, DSP), digital signal processing appts (DSP Device, DSPD), programmable logic device (Programmable Logic Device, PLD), field programmable gate array (Field-Programmable Gate Array, FPGA), general place It manages in device, controller, microcontroller, microprocessor, other electronic units for executing function of the present invention or combinations thereof.
For software implementations, can by execute the embodiment of the present invention described in function module (such as process, function etc.) come Realize technology described in the embodiment of the present invention.Software code is storable in memory and is executed by processor.Memory can With portion realizes in the processor or outside the processor.
In the present embodiment, computer program can realize following steps when being executed by processor 301: obtain model file and school Test rule description file;Model needs file is generated according to the model file;Wherein, the model needs file includes treating Verify the attribute specification of northbound data;According to the verification rule description file generated verification rule;According to the model needs File and verification rule, verify northbound data to be verified.
Optionally, following steps be can also be achieved when computer program is executed by processor 301: being mentioned from the model file Take one or more critical fielies corresponding with the attribute specification of northbound data to be verified;Mould is generated according to the critical field Type requires file.
Optionally, processor 301 is specifically used for: judging whether the verification rule description file is preset verification rule File is described;If the verification rule description file is preset verification rule description file, directly acquire and verification rule The corresponding preset verification rule of file is described;If the verification rule description file is not preset verification rule description text Part generates verification corresponding with the rule description language according to the regular description language in the verification rule description file Rule.
Optionally, following steps be can also be achieved when computer program is executed by processor 301: judging northbound data to be verified Filename whether meet it is described verification rule in filename name requirement;If the filename of northbound data to be verified is not Meet the name requirement of the filename in the verification rule, then the northbound data to be verified is invalid data;If to school When the name of filename that the filename for testing northbound data meets in the verification rule requires, northbound data to be verified is judged Whether attribute value, which meets, is all 0 in the verification rule or is all empty requirement;If the attribute value of northbound data to be verified meets 0 is all in the verification rule or is all empty requirement, then northbound data to be verified is invalid data;If northbound data to be verified Attribute value be unsatisfactory for being all 0 in verification rule or be all empty requirement, then judge that the attribute value of northbound data to be verified is It is no to meet in model needs file to the attribute specification of northbound data to be verified;If the attribute value of northbound data to be verified meets To the attribute specification of northbound data to be verified in model needs file, then the northbound data to be verified is valid data;If The attribute value of northbound data to be verified is unsatisfactory for the attribute specification of northbound data to be verified in model needs file, then it is described to Verification northbound data is invalid data.
Firstly, when generating model needs file according to the model file, it can be from the model file by processor 301 The one or more critical fielies corresponding with the attribute specification of northbound data to be verified of middle extraction, it is raw according to the critical field At model needs file, the calibration equipment of the embodiment of the present invention can support a variety of models, can solve in the verification of northbound data The problem of model poor compatibility.
Further, it is generated in model needs file processes according to the model file, when will be to new version, new hard When the data that the model that part type, other operators define generates are verified, the calibration equipment of the embodiment of the present invention is not required to Want modifiers code.
Secondly, when according to the verification rule description file generated verification rule, by processor 301 according to the school The regular description language in rule description file is tested, verification rule corresponding with the rule description language is generated, the present invention is real The calibration equipment for applying example can load verification rule automatically, and verifying rule can be diversified, can solve in the verification of northbound data Verification rule poor compatibility the problem of.
Further, under different scenes, when having different require to data check rule, the calibration equipment of the embodiment of the present invention The verification rule for being suitble to the scene to need can be automatically generated, can flexibly support a variety of numbers according to verification rule description file According to verification scene.
The embodiment of the invention also provides a kind of computer readable storage mediums, are stored thereon with computer program, the journey The step in the method for calibration of northbound data as described above is realized when sequence is executed by processor.
It should be understood that " one embodiment " or " embodiment " that specification is mentioned in the whole text mean it is related with embodiment A particular feature, structure, or characteristic is included at least one embodiment of the present invention.Therefore, occur everywhere in the whole instruction " in one embodiment " or " in one embodiment " not necessarily refer to identical embodiment.In addition, these specific features, knot Structure or characteristic can combine in any suitable manner in one or more embodiments.
In various embodiments of the present invention, it should be appreciated that magnitude of the sequence numbers of the above procedures are not meant to execute suitable Sequence it is successive, the execution of each process sequence should be determined by its function and internal logic, the implementation without coping with the embodiment of the present invention Process constitutes any restriction.
In embodiment provided herein, it should be appreciated that " B corresponding with A " indicates that B is associated with A, can be with according to A Determine B.It is also to be understood that determine that B is not meant to determine B only according to A according to A, it can also be according to A and/or other information Determine B.
In several embodiments provided herein, it should be understood that disclosed method and apparatus, it can be by other Mode realize.For example, the apparatus embodiments described above are merely exemplary, for example, the division of the unit, only For a kind of logical function partition, there may be another division manner in actual implementation, such as multiple units or components can combine Or it is desirably integrated into another system, or some features can be ignored or not executed.Another point, shown or discussed phase Coupling, direct-coupling or communication connection between mutually can be through some interfaces, the INDIRECT COUPLING or communication of device or unit Connection can be electrical property, mechanical or other forms.
It, can also be in addition, the functional units in various embodiments of the present invention may be integrated into one processing unit It is that the independent physics of each unit includes, can also be integrated in one unit with two or more units.Above-mentioned integrated list Member both can take the form of hardware realization, can also realize in the form of hardware adds SFU software functional unit.
The above-mentioned integrated unit being realized in the form of SFU software functional unit can store and computer-readable deposit at one In storage media.Above-mentioned SFU software functional unit is stored in a storage medium, including some instructions are used so that a computer Equipment (can be personal computer, server or network side equipment etc.) executes transmitting-receiving side described in each embodiment of the present invention The part steps of method.And storage medium above-mentioned includes: USB flash disk, mobile hard disk, read-only memory (Read-Only Memory, letter Claim ROM), random access memory (Random Access Memory, abbreviation RAM), magnetic or disk etc. is various to deposit Store up the medium of program code.
The above is a preferred embodiment of the present invention, it is noted that for those skilled in the art For, without departing from the principles of the present invention, it can also make several improvements and retouch, these improvements and modifications It should be regarded as protection scope of the present invention.

Claims (10)

1. a kind of method of calibration of northbound data characterized by comprising
Obtain model file and verification rule description file;
Model needs file is generated according to the model file, wherein the model needs file includes to north orientation number to be verified According to attribute specification;
According to the verification rule description file generated verification rule;
According to the model needs file and verification rule, the northbound data to be verified is verified.
2. method of calibration according to claim 1, which is characterized in that described to generate model needs according to the model file File, comprising:
One or more critical fielies corresponding with the attribute specification of northbound data to be verified are extracted from the model file;
Model needs file is generated according to the critical field.
3. method of calibration according to claim 1, which is characterized in that described according to the verification rule description file generated Verification rule, comprising:
Judge whether the verification rule description file is preset verification rule description file;
If the verification rule description file is preset verification rule description file, directly acquire and verification rule description text The corresponding preset verification rule of part;
If the verification rule description file is not preset verification rule description file, according to the verification rule description text Regular description language in part generates verification rule corresponding with the rule description language.
4. method of calibration according to claim 1, which is characterized in that described according to the model needs file and the school Rule is tested, northbound data to be verified is verified, comprising:
Judge whether the filename of northbound data to be verified meets the name requirement of the filename in the verification rule;
If the filename of northbound data to be verified is unsatisfactory for the name requirement of the filename in the verification rule, it is described to Verification northbound data is invalid data;
If the name that the filename of northbound data to be verified meets the filename in the verification rule requires, judge to school Whether the attribute value for testing northbound data, which meets, is all 0 in the verification rule or is all empty requirement;
0 is all in the verification rule or is all empty requirement if the attribute value of northbound data to be verified meets, north to be verified It is invalid data to data;
If the attribute value of northbound data to be verified is unsatisfactory for being all 0 in verification rule or is all empty requirement, judge to Whether the attribute value of verification northbound data meets in model needs file to the attribute specification of northbound data to be verified;
If the attribute value of northbound data to be verified meets in model needs file to the attribute specification of northbound data to be verified, The northbound data to be verified is valid data;
If the attribute value of northbound data to be verified is unsatisfactory in model needs file to the attribute specification of northbound data to be verified, Then the northbound data to be verified is invalid data.
5. method of calibration according to claim 1, which is characterized in that the attribute specification to northbound data to be verified, It include: attribute number, Property Name, attribute value and/or Attribute Significance.
6. a kind of calibration equipment of northbound data characterized by comprising
Module is obtained, for obtaining model file and verification rule description file;
First generation module, for generating model needs file according to the model file;The model needs file contains pair The attribute specification of northbound data to be verified;
Second generation module, for according to the verification rule description file generated verification rule;
Correction verification module, for verifying northbound data to be verified according to the model needs file and verification rule.
7. calibration equipment according to claim 6, which is characterized in that first generation module includes:
Extraction unit is one or more opposite with the attribute specification of northbound data to be verified for extracting from the model file The critical field answered;
First generation unit, for generating model needs file according to the critical field.
8. calibration equipment according to claim 6, which is characterized in that the correction verification module includes:
Second judgment unit, for judging whether the filename of northbound data to be verified meets the filename in the verification rule Name requirement;
First execution unit, if the filename for northbound data to be verified is unsatisfactory for the filename in the verification rule Name requires, then the northbound data to be verified is invalid data;
Third judging unit, if the filename for northbound data to be verified meets the life of the filename in the verification rule When name requires, judges whether the attribute value of northbound data to be verified meets and be all 0 in the verification rule or be all empty requirement;
Second execution unit is all 0 in the verification rule or is all if the attribute value for northbound data to be verified meets Sky requires, then northbound data to be verified is invalid data;
4th judging unit, if the attribute value for northbound data to be verified is unsatisfactory for being all 0 or complete in the verification rule It is required for sky, then judges whether the attribute value of northbound data to be verified meets in model needs file to northbound data to be verified Attribute specification;
Third execution unit, if the attribute value for northbound data to be verified meets in model needs file to north orientation to be verified The attribute specification of data, then the northbound data to be verified is valid data;
4th execution unit, if the attribute value for northbound data to be verified is unsatisfactory in model needs file to north to be verified To the attribute specification of data, then the northbound data to be verified is invalid data.
9. a kind of calibration equipment of northbound data characterized by comprising memory, processor and storage are on a memory simultaneously The computer program that can be run on a processor, the processor are realized when executing described program such as any one of Claims 1 to 5 Step in the method for calibration of the northbound data.
10. a kind of computer readable storage medium, is stored thereon with computer program, which is characterized in that the program is by processor The step in the method for calibration of northbound data as claimed in any one of claims 1 to 5 is realized when execution.
CN201710730489.1A 2017-08-23 2017-08-23 Method and device for checking northbound data Active CN109429260B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710730489.1A CN109429260B (en) 2017-08-23 2017-08-23 Method and device for checking northbound data

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710730489.1A CN109429260B (en) 2017-08-23 2017-08-23 Method and device for checking northbound data

Publications (2)

Publication Number Publication Date
CN109429260A true CN109429260A (en) 2019-03-05
CN109429260B CN109429260B (en) 2021-11-23

Family

ID=65498741

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710730489.1A Active CN109429260B (en) 2017-08-23 2017-08-23 Method and device for checking northbound data

Country Status (1)

Country Link
CN (1) CN109429260B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112256306A (en) * 2020-11-09 2021-01-22 北京沃东天骏信息技术有限公司 Compatibility verification method and device
CN112597111A (en) * 2020-12-23 2021-04-02 北京安博通科技股份有限公司 Data verification method, device, equipment and storage medium
CN114579712A (en) * 2022-05-05 2022-06-03 中科雨辰科技有限公司 Text attribute extraction and matching method based on dynamic model

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101021890A (en) * 2007-03-20 2007-08-22 华为技术有限公司 Method, system and server for checking page data
CN101753605A (en) * 2008-12-02 2010-06-23 北大方正集团有限公司 Data validation method and server
CN104391934A (en) * 2014-11-21 2015-03-04 深圳市银雁金融配套服务有限公司 Data calibration method and device
CN106603259A (en) * 2015-10-16 2017-04-26 大唐移动通信设备有限公司 Configuration data verification method and device of network element, and network management equipment

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101021890A (en) * 2007-03-20 2007-08-22 华为技术有限公司 Method, system and server for checking page data
CN101753605A (en) * 2008-12-02 2010-06-23 北大方正集团有限公司 Data validation method and server
CN104391934A (en) * 2014-11-21 2015-03-04 深圳市银雁金融配套服务有限公司 Data calibration method and device
CN106603259A (en) * 2015-10-16 2017-04-26 大唐移动通信设备有限公司 Configuration data verification method and device of network element, and network management equipment

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112256306A (en) * 2020-11-09 2021-01-22 北京沃东天骏信息技术有限公司 Compatibility verification method and device
CN112597111A (en) * 2020-12-23 2021-04-02 北京安博通科技股份有限公司 Data verification method, device, equipment and storage medium
CN114579712A (en) * 2022-05-05 2022-06-03 中科雨辰科技有限公司 Text attribute extraction and matching method based on dynamic model
CN114579712B (en) * 2022-05-05 2022-07-15 中科雨辰科技有限公司 Text attribute extraction and matching method based on dynamic model

Also Published As

Publication number Publication date
CN109429260B (en) 2021-11-23

Similar Documents

Publication Publication Date Title
CN111767704B (en) Excel form template generation method and device
CN109308285A (en) Database script management method, device, computer equipment and storage medium
CN109446072A (en) The generation method and device of test script
CN101977121A (en) Configuration file processing method, device and system
US20060259891A1 (en) System and method of generating an auto-wiring script
CN114048701B (en) Netlist ECO method, device, equipment and readable storage medium
CN110275861A (en) Date storage method and device, storage medium, electronic device
CN109429260A (en) A kind of method of calibration and device of northbound data
CN103970758A (en) Database accessing system and method
CN109033150A (en) Sensitive word verification method, device, computer equipment and storage medium
CN107171897A (en) A kind of interface test method and data-interface test system
CN110309099A (en) Interface managerial method, device, equipment and computer readable storage medium
CN107766124A (en) A kind of automatic verification method and device of WEB lists
CN109375943A (en) A kind of program file generation method and device
CN107357588B (en) Object code generation method and device
CN108959230A (en) A kind of method and apparatus generating report template
CN110750434A (en) Interface testing method and device, electronic equipment and computer readable storage medium
CN108984868A (en) The integration method and device of a kind of board internet data
CN105868639A (en) Kernel vulnerability repair method and device
CN111258884A (en) System for automatically generating interface accuracy verification script
CN103685259B (en) The method and its device of Account Logon
CN114443039A (en) Input parameter verification method and device, electronic equipment and storage medium
CN116048981A (en) Method, device, medium and equipment for designing rear-end interface test case
CN106648441A (en) Method and device for transferring equipment partition information
CN112148597B (en) Method for eliminating iOS device authorization dialog box, test method and storage medium

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
GR01 Patent grant
GR01 Patent grant