Data query, data query processing method and processing deviceTechnical field
The present invention relates to the communications field, in particular to a kind of data query, data query processing method and processing device.
Background technology
In communication network, network is made up of many communication apparatus nodes, and these network nodes are called network element.Between network elementIt is attached by communication line, the diversified forms such as including fiber optic cables.Network element dispersed distribution is in each area, and some is in cityIn communication building laboratory in, some network elements are in remote districts.The equipment of the network element of these office different geographicals needs to carry outConfiguration, safeguard and monitoring, it is impossible to often locate all to send someone on duty, thus need a central site network management system, centreComputer room, each node on network is configured, safeguarded and monitored by telecommunication.
It is one by software defined network (Software Defined Network, abbreviation SDN) controller management networkThe emerging network management control system of kind.In this control system, in traditional network management to the control function of service resourcesIt is independent, it is solely focused on service resources.Controller can be by tree-shaped stratification tissue, to manage large scale network.DirectlyManaged network element is domain controller (Domain Controller, D-Controller, abbreviation DC);The controller on upper strata(Super Controller, S-Controller, abbreviation SC) not direct managed network element, but manage domain controller, Ran HouzaiThe virtual network management provided by domain controller, realizes the management to real network.
Fig. 1 is the NE management figure of SDN controllers in correlation technique, as shown in figure 1, in Fig. 1 model, controller shapeInto tree-shaped management system, upper strata is S-Controller (i.e. top level control device, abbreviation SC), lower floor be D-Controller (i.e.Lower floor's controller, abbreviation DC), DC division management domains, manage communication network and network element.Controller leads to except south orientation and the network equipmentCross interface to be managed, also northbound interface can allow the network application APP of application layer to access and carry out network management, in addition can be withBy side interface, with webmaster plane (including EMS Element management systems, NMS NMSs, or OSS operation supports systemSystem) communication management information.Network AP P is the practical business application to network, and it can use the resource that controller provides, and send industryThe requests such as business is created, deleted, modification.And controller is created according to network AP P request, deleted, modification business, and to businessAlarm and performance are monitored.Fig. 2 is the graph of a relation of SDN controllers and other entities in correlation technique.As shown in Fig. 2 DC is straightAdapter reason communication network, SC management DC, while can also be interacted with legacy network management system, finally provide money to APPSource and service.
In real network management, network may be very big, has tens of thousands of individual network element nodes, has thousands of ends up to ten thousand in network elementMouthful or end point resource need to manage, the sum of such port or end point is up to more than one hundred million.Accordingly, the business number of foundationAlso there are several ten million bars.When the superior system of controller needs query resource, big data quantity problem may be faced with, works as satisfactionWhen the data of querying condition are a lot, controller is very big to the response bag that superior system is formed, by communicate connection beam back shouldAnswer and may require that for a long time, superior system, which also differs, surely to be treated.Moreover, big data quantity inquiry can also influence the whole of systemRunning body efficiency, and then influence the operation of other functions.
In traditional network management system corba interfaces, can once it be returned by the way of paging query, as page turningReturn page of data.After having handled, superior system looks into lower page of data again.But so webmaster needs to maintain the state of inquiry, andAnd since it is desired that supporting the inquiry of multiple superior systems, webmaster needs to realize the mechanism of similar session, on internal memory keeps eachThe state and data of multiple different inquiry sessions of level system, so that superior system page turning is inquired about.Although so solves partProblem, for lower system (webmaster or controller that service is provided), it is also desirable to increase many expenses, can also increase lower floorExploitation realize difficulty.
In SDN controller network environment, controller uses the stateless such as openflow, netconf interface protocol and upperLayer system communicates, and is to avoid stateless management plus the design philosophy due to SDN controllers, above-mentioned prior art is also not suitable forUsed in controller environment.Therefore, it is not based on during the data query of network system (such as SDN system) of sessionThe problems such as query process is complicated, and search efficiency is low and causes seriously to bear to network system be present.
The content of the invention
The embodiments of the invention provide a kind of data query, data query processing method and processing device, at least to solve correlationIt is not based on query process complexity being present during the data query of the network system of session in technology, search efficiency is low and rightThe problems such as network system causes seriously to bear.
According to one embodiment of present invention, there is provided a kind of data query method, including:It is not based under conversational systemThe first inquiry request that superior system is sent in batches to lower system, first inquiry request are used for requesting query and support to criticizeMeasure the data of inquiry;The superior system receives the first inquiry knot that the lower system is sent according to batch query requestFruit;The superior system sends the second inquiry request to the lower system, and second inquiry request is supported for requesting queryData in the data of batch query in addition to first Query Result;The superior system receives the lower system foundationThe second Query Result that second inquiry request is sent.
Alternatively, the superior system for being not based on the network system of session is asked to the first inquiry that lower system is sent in batchesAsk, including:The first query argument for being buffered in and being pre-defined in the superior system is called, and the query argument is carriedIn first inquiry request.
Alternatively, the query argument comprises at least following parameter:Query filter condition, job lot, inquire about batch, look intoAsk target, query context and sort criteria.
Alternatively, the superior system receives the first inquiry that the lower system is sent according to batch query requestAs a result, including:When the superior system does not receive the Query Result that the lower system is sent in the given time, numberIt is investigated that ask failure.
Alternatively, the lower system is received in the superior system to look into according to batch query request is sent firstAfter asking result, methods described also includes:According to first Query Result, number corresponding with first Query Result is updatedAccording to.
Alternatively, data corresponding with first Query Result are updated, including:According in first Query ResultIdentification information, detect whether the data repeated with the identification information be present;In the case where the judgment result is yes, replace orAbandon the data repeated with the identification information.
Alternatively, the superior system sends the second inquiry request to the lower system, in addition to:Calling is buffered in instituteThe second query argument pre-defined in superior system is stated, and second query argument is carried in second inquiry requestIn, wherein, second query argument comprises at least following information:Number in query filter condition, first Query ResultAccording to identification information, inquiry target and query context.
Alternatively, the superior system receives the second inquiry that the lower system is sent according to second inquiry requestAs a result, including:When the superior system does not receive second Query Result of the lower system transmission in the given timeWhen, determine that no missing data needs to handle.
Alternatively, the superior system receives the second inquiry that the lower system is sent according to second inquiry requestAs a result, in addition to, when no missing data needs processing, second Query Result is sky, when there is missing data to need to locateDuring reason, second Query Result is identification information corresponding to the missing data.
Alternatively, the superior system comprises at least:The system of top level control device, APP or the access top level control device;And/or the lower system is the controller for carrying out query processing.
According to still another embodiment of the invention, a kind of data query processing method is additionally provided, including:It is not based on sessionLower system under system receives the first inquiry request that superior system is sent in batches, wherein, first inquiry request is used forRequesting query supports the data of batch query;The lower system determines the first Query Result according to first inquiry request,And first Query Result is sent to the superior system;The lower system receives second that the superior system is sentInquiry request, second inquiry request are used in the data of requesting query support batch query in addition to first Query ResultData;The lower system determines the second Query Result according to second inquiry request, and by second Query ResultIt is sent to the superior system.
Alternatively, the lower system determines the first Query Result according to first inquiry request, including:The subordinateSystem is according to putting in order in first inquiry request and requires in batches, is taken out from the data of the support batch queryAccess evidence;The the first response parameter for being buffered in and being pre-defined in the lower system is called, and according to the data after the extractionGenerate first Query Result.
Alternatively, the first response parameter comprises at least following information:The identification information of data after the extraction, look intoAsk batch and total lot number.
Alternatively, the lower system determines the second Query Result according to second inquiry request, including:The subordinateSystem is looked into according to the data identification information in first Query Result in second inquiry request from the support batchThe data for being not sent to the superior system are excluded in the data of inquiry;Calling is buffered in the lower system and pre-definedThe second response parameter, and generate second Query Result according to the data for being not sent to the superior system.
Alternatively, the second response parameter comprises at least:Not described the in the data for supporting batch queryThe identification information of the data of appearance in one Query Result.
Alternatively, the data for being not sent to the superior system are excluded in the data from the support batch queryAfterwards, methods described also includes:After it is determined that the data of all support batch queries are sent to the superior system, to instituteState superior system and send the 3rd Query Result, wherein, the 3rd Query Result is empty information.
According to another embodiment of the invention, a kind of data query arrangement is additionally provided, in superior system, bagInclude:First sending module, for when needing to carry out batch query, generating batch query according to the interface command of batch query pleaseAsk, and be handed down to lower system;First receiving module, ask to send according to the batch query for receiving the lower systemThe first Query Result;Second sending module, for sending the second inquiry request, second inquiry request to the lower systemThe data in addition to first Query Result in the data of batch query are supported for requesting query;Second receiving module, useIn the second Query Result that the reception lower system is sent according to second inquiry request.
Alternatively, first sending module is additionally operable to:Call first for being buffered in and being pre-defined in the superior systemQuery argument, and by the query argument carry in first inquiry request, wherein, the query argument comprise at least withLower parameter:Query filter condition, job lot, inquiry batch, inquiry target, query context and sort criteria.
Alternatively, described device also includes:Update module, for according to first Query Result, renewal and described theData corresponding to one Query Result, including, according to the identification information in first Query Result, detect whether to exist with it is describedThe data that identification information repeats;In the case where the judgment result is yes, replace or abandon the number repeated with the identification informationAccording to.
Alternatively, second sending module, which is additionally operable to call, is buffered in second looking into of being pre-defined in the superior systemParameter is ask, and second query argument is carried in second inquiry request, wherein, second query argument is at leastIncluding following information:Query filter condition, the data identification information in first Query Result, inquiry target and inquiry modelEnclose.
Alternatively, described device also includes:When no missing data needs processing, second Query Result is sky,When there is missing data to need processing, second Query Result is identification information corresponding to the missing data.
According to still a further embodiment, a kind of data query processing unit is additionally provided, in lower system,Including:First receiving module, the first inquiry request sent in batches for receiving superior system, wherein, first inquiry pleaseSeek the data that batch query is supported for requesting query;First sending module, for determining according to first inquiry requestOne Query Result, and first Query Result is sent to the superior system;Second receiving module, it is described for receivingThe second inquiry request that level system is sent, second inquiry request are used in the data of requesting query support batch query except describedData outside first Query Result;Second sending module, for determining the second Query Result according to second inquiry request,And second Query Result is sent to the superior system.
Alternatively, first sending module includes:Extracting unit, for according to the arrangement in first inquiry requestRequire sequentially and in batches, data are extracted from the data of the support batch query;First generation unit, cached for callingThe the first response parameter pre-defined in the lower system, and according to data generation first inquiry after the extractionAs a result, wherein, the first response parameter comprises at least following information:The identification information of data after the extraction, inquiry batchSecondary and total lot number.
Alternatively, second sending module includes:Rejected unit, for according to described in second inquiry requestData identification information in first Query Result, exclude and be not sent on described from the data of the support batch queryThe data of level system;Second generation unit, call and be buffered in the second response parameter pre-defined in the lower system, and according toSecond Query Result is generated according to the data for being not sent to the superior system, wherein, the second response parameter is at leastIncluding:The identification information of not no data of the appearance in first Query Result in the data for supporting batch query.
According to another embodiment of the present invention, a kind of data query system is additionally provided, positioned at being not based on conversational systemIn, including:Superior system, for the first inquiry request sent to lower system in batches, first inquiry request is used forRequesting query supports the data of batch query;The second inquiry request is sent to the lower system, second inquiry request is used forData in the data of requesting query support batch query in addition to first Query Result;The lower system, for connecingReceive first inquiry request that the superior system is sent in batches;The first inquiry knot is determined according to first inquiry requestFruit, and first Query Result is sent to the superior system;Receive second inquiry that the superior system is sentRequest;The second Query Result is determined according to second inquiry request, and second Query Result is sent to the higher levelSystem.
According to another embodiment of the invention, a kind of storage medium is additionally provided.The storage medium is arranged to storage and usedIn the program code for performing following steps:
S11, the first inquiry request that the superior system being not based under conversational system is sent in batches to lower system, this is describedFirst inquiry request is used for the data that requesting query supports batch query;
S12, the superior system receive the first inquiry knot that the lower system is sent according to batch query requestFruit;
S13, the superior system send the second inquiry request to the lower system, and second inquiry request is used to askData in the data of inquiry support batch query in addition to first Query Result;
S14, the superior system receive the second inquiry knot that the lower system is sent according to second inquiry requestFruit.
Alternatively, storage medium is also configured to the program code that storage is used to perform following steps:
S21, according to first Query Result, update data corresponding with first Query Result.
Alternatively, storage medium is also configured to the program code that storage is used to perform following steps:
S31, according to the identification information in first Query Result, detect whether there is what is repeated with the identification informationData;
S32, in the case where the judgment result is yes, replace or abandon the data repeated with the identification information.
According to still a further embodiment, a kind of storage medium is additionally provided.The storage medium is arranged to storage and usedIn the program code for performing following steps:
S11, the lower system being not based under conversational system receive the first inquiry request that superior system is sent in batches, itsIn, first inquiry request is used for the data that requesting query supports batch query;
S12, the lower system determines the first Query Result according to first inquiry request, and described first is inquired aboutAs a result it is sent to the superior system;
S13, the lower system receive the second inquiry request that the superior system is sent, and second inquiry request is used forData in the data of requesting query support batch query in addition to first Query Result;
S14, the lower system determines the second Query Result according to second inquiry request, and described second is inquired aboutAs a result it is sent to the superior system.
Alternatively, storage medium is also configured to the program code that storage is used to perform following steps:
S21, the lower system is according to the Data Identification in first Query Result in second inquiry requestInformation, the data for being not sent to the superior system are excluded from the data of the support batch query;
S22, the second response parameter for being buffered in and being pre-defined in the lower system is called, and foundation is not sent to instituteThe data for stating superior system generate second Query Result.
By the present invention, due to superior system using lower system for superior system send in batches to supporting batch to look intoThe Query Result of the inquiry request of the data of inquiry, while looking into for the data inquired about in batches can also be carried by issuingRequest is ask, to obtain the Query Result of missing data.Therefore, can solve the network system that session is not based in correlation techniqueThe problems such as query process is complicated, and search efficiency is low and causes seriously to bear to network system during data query be present,So as to reach efficient inquiry mass data, and inquiry mode is simple, the effect do not omitted.
Brief description of the drawings
Accompanying drawing described herein is used for providing a further understanding of the present invention, forms the part of the application, this hairBright schematic description and description is used to explain the present invention, does not form inappropriate limitation of the present invention.In the accompanying drawings:
Fig. 1 is the NE management figure of SDN controllers in correlation technique;
Fig. 2 is the graph of a relation of SDN controllers and other entities in correlation technique;
Fig. 3 is a kind of flow chart of data query method according to embodiments of the present invention;
Fig. 4 is a kind of flow chart of data query processing method according to embodiments of the present invention;
A kind of timing diagram of data query according to embodiments of the present invention Fig. 5;
Fig. 6 is a kind of structure chart of data query arrangement according to embodiments of the present invention;
Fig. 7 is the structure chart of another data query arrangement according to embodiments of the present invention;
Fig. 8 is a kind of structure chart of data query processing unit according to embodiments of the present invention;
Fig. 9 is the structure chart of another data query processing unit according to embodiments of the present invention;
Figure 10 is the structure chart of another data query processing unit according to embodiments of the present invention;
Figure 11 is a kind of structure chart of data query system according to embodiments of the present invention;
Figure 12 is a kind of structure chart of controller according to embodiments of the present invention.
Embodiment
Describe the present invention in detail below with reference to accompanying drawing and in conjunction with the embodiments.It should be noted that do not conflictingIn the case of, the feature in embodiment and embodiment in the application can be mutually combined.
It should be noted that term " first " in description and claims of this specification and above-mentioned accompanying drawing, "Two " etc. be for distinguishing similar object, without for describing specific order or precedence.
Embodiment 1
The data query method of the system architecture shown in a kind of Fig. 1 and/Fig. 2 is provided in the present embodiment, wherein, controlDevice processed forms tree-shaped management system, and upper strata is S-Controller (i.e. top level control device, abbreviation SC), and lower floor is D-Controller (i.e. lower floor's controller, abbreviation DC), DC divide management domain, manage communication network and network element.
Fig. 3 is a kind of flow chart of data query method according to embodiments of the present invention, as shown in figure 3, the flow includesFollowing steps:
Step S302, the first inquiry request that the superior system being not based under conversational system is sent in batches to lower system,First inquiry request is used for the data that requesting query supports batch query;
Alternatively, the first query argument for being buffered in and being pre-defined in the superior system is called, and the inquiry is joinedNumber is carried in first inquiry request.
Specifically, the pre-defined implication in step 302 is, in conversational system is not based on (such as in SDN systemIn system) superior system carry out data query before, batch query and lower system are carried out to superior system and carry out return responseCarry out parameter definition.In the present embodiment, due to pertaining only to superior system side, therefore, only batch is carried out using superior systemParameter (i.e. the first query argument) used in inquiry.
Specifically, first query argument comprises at least:Query filter condition, job lot, inquiry batch, inquiry meshMark, query context and sort criteria.It is pointed out that query filter condition, job lot, inquiry batch, sort criteriaThis four parameters are necessarily placed among the first query argument.And target, query context are inquired about then as optional two ginsengsNumber, for carrying out more accurate inquiry.
Alternatively, the data inquired about in the present embodiment can be the tunnel Tunnel data of the whole network.In actual queriesIn scene, the Tunnel data are at least by hundreds of thousands bar.Certainly the method provided in the present invention is also applied to tensAmong the scene of less than ten thousand.
Alternatively, before step S302, the data attribute to inquire about data is also needed in conversational system is not based onDefined accordingly.Specifically, the data attribute comprises at least:Identification information id, user tag userlabel, directionDirection, type tunneltype, source network element ID sourceNEID, place network element ID destNEID, QOS information qos withAnd controlled state adminStatus.It is pointed out that for higher level and lower system, by identifying processing data attributeIdentification information carry out data uniqueness differentiation.
Step S304, the superior system receive the lower system and looked into according to batch query request is sent firstAsk result;
Alternatively, when the superior system does not receive the Query Result of the lower system transmission in the given timeWhen, data query failure.
Specifically, the scheduled time is not fixed value, can be needed to be adjusted according to user, it should be pointed out thatThe scheduled time can be determined by the first query argument, naturally it is also possible to determined according to the hobby of user,
Alternatively, after the first Query Result is received, according to first Query Result, renewal and the described first inquiryAs a result corresponding data.
Specifically, the renewal refers to the identification information in first Query Result, detect whether exist with it is describedThe data that identification information repeats, in the case where the judgment result is yes, replace or abandon the number repeated with the identification informationAccording to.
Step S306, the superior system send the second inquiry request to the lower system, and second inquiry request is usedData in the data that requesting query supports batch query in addition to first Query Result;
Alternatively, based on the reason for identical with repetition, data renewal is repeatedly there may be during inquiry, causes sequenceChange.Accordingly, it is possible to there can be the problem of inquiry is omitted.Call the second inquiry for being buffered in and being pre-defined in the superior systemParameter, and second query argument is carried in second inquiry request, wherein, second query argument at least wrapsInclude following information:Query filter condition, the data identification information in first Query Result, inquiry target and inquiry modelEnclose.
Specifically, second query argument also enters line number in superior system with the first query argument similarlyIt is investigated that ask before carry out it is pre-defined, effect be indicate superior system inquiry missing data.
By the way that the data identification information in the first Query Result is carried in the second query argument, therefore, can assistDownlink system knows which data have been carried out inquiring about, and is inquired about on which data theory, but does not have actuallyThere are the data for carrying out inquiry.
Alternatively, the above-mentioned process that the second inquiry request is sent to lower system can be sent in batches, that is, receiveAfter the first Query Result sent per a collection of lower system, the second inquiry request is issued for the batch data.It is above-mentioned to send in batchesThe method of second inquiry request can more accurately inquire about missing data, ensure that low missing rate.Can also be simultaneously upperAfter level system receives the first Query Result of all batches, the second inquiry request is disposably issued.It is above-mentioned once to send secondThe method of inquiry request can save the time in mass data query process.User can confirm transmission according to their needsThe method of two inquiry requests.For example, if the data volume of inquiry is not especially big (such as thousands of or tens of thousands of, but be not limited toThis), while if the low missing rate of user's pursuit, then it can take and send the second inquiry request in batches, and if the number of inquiryIt is very big (such as several ten million or more than one hundred million, but not limited to this) according to amount, then using the method for once sending the second inquiry request.WhenSo, among actual application, the second inquiry request of multiple batches can also together be sent, this method is in certain journeyIt ensure that on degree to the accurate of missing data inquiry, while also taken into account query time.
Step S308, the superior system receive the lower system and looked into according to second inquiry request is sent secondAsk result.
Alternatively, when the superior system does not receive second inquiry of the lower system transmission in the given timeWhen as a result, determine that no missing data needs to handle.
Alternatively, when no missing data needs processing, second Query Result is sky, when there is missing data needsDuring processing, second Query Result is identification information corresponding to the missing data.
Alternatively, the superior system referred in above example is top level control device, APP or the access top level control deviceSystem, lower system is the controller for carrying out query processing.
By above-mentioned steps, solve during the data query for the network system that session is not based in correlation technique and existThe problems such as query process is complicated, and search efficiency is low and causes seriously to bear to network system, it is efficiently a large amount of so as to reachData are inquired about, and inquiry mode is simple, the effect do not omitted.
Through the above description of the embodiments, those skilled in the art can be understood that according to above-mentioned implementationThe method of example can add the mode of required general hardware platform to realize by software, naturally it is also possible to by hardware, but a lotIn the case of the former be more preferably embodiment.Based on such understanding, technical scheme is substantially in other words to existingThe part that technology contributes can be embodied in the form of software product, and the computer software product is stored in a storageIn medium (such as ROM/RAM, magnetic disc, CD), including some instructions to cause a station terminal equipment (can be mobile phone, calculateMachine, server, or network equipment etc.) perform method described in each embodiment of the present invention.
Embodiment 2
A kind of data query processing method for running on system architecture in Fig. 1 and/Fig. 2, Fig. 4 are provided in the present embodimentIt is a kind of flow chart of data query processing method according to embodiments of the present invention, as shown in figure 4, the flow includes following stepSuddenly:
Step S402, the lower system being not based under conversational system receives the first inquiry that superior system is sent in batches pleaseAsk, wherein, first inquiry request is used for the data that requesting query supports batch query;
Step S404, the lower system determine the first Query Result according to first inquiry request, and by describedOne Query Result is sent to the superior system.
Alternatively, the lower system requires according to putting in order in first inquiry request and in batches, from instituteState in the data for supporting batch query and extract data;Call the first response ginseng for being buffered in and being pre-defined in the lower systemNumber, and generate the first Query Result according to the data after the extraction.
It is pointed out that enter line number in the superior system that (such as in SDN system) is not based in conversational systemIt is investigated that before asking, batch query is carried out to superior system and lower system carries out return response and carried out parameter definition.In this realityApply in example, due to pertaining only to lower system side, therefore, only using lower system carry out return response parameter (i.e. first answerAnswer parameter).
Alternatively, the first response parameter comprises at least following information:The identification information of data after the extraction, look intoAsk batch and total lot number.
It is pointed out that also need to carry out accordingly the data attribute for inquire about data in conversational system is not based onDefinition.Specifically, the data attribute comprises at least:Identification information id, user tag userlabel, direction direction,Type tunneltype, source network element ID sourceNEID, place network element ID destNEID, QOS information qos and controlled stateadminStatus.Therefore, other data attributes that can also be answered extraction data identification information pair in the first response parameter are sentTo superior system.It can specifically send in the form of a list.
Step S406, the lower system receive the second inquiry request that the superior system is sent, and second inquiry pleaseSeek the data in addition to first Query Result in the data that batch query is supported for requesting query.
Step S408, the lower system determine the second Query Result according to second inquiry request, and by describedTwo Query Results are sent to the superior system.
Alternatively, the lower system is according to the data mark in first Query Result in second inquiry requestKnow information, the data for being not sent to the superior system are excluded from the data of the support batch query.
Specifically, by comparing the data identification information in the first Query Result in the second inquiry request and supporting to criticizeMeasure the identification information of the data of inquiry.During if there is there is no treated Data Identification in upper once query processing, thenIt is missing data to determine the data, that is, is defined as being not sent to the data of the superior system.
Alternatively, the second response parameter for being buffered in and being pre-defined in the lower system is called, and according to not sendingData to the superior system generate the second Query Result.
With the first response parameter similarly, the second response parameter also superior system carry out data query itIt is preceding carry out it is pre-defined, effect be indicate lower system determine missing data.Specifically, the second response parameter includes:InstituteState the identification information of not no data of the appearance in first Query Result in the data for supporting batch query.
Specifically, if lower system finds not having missing data in the second inquiry request, then lower systemThen can superior system send the 3rd Query Result, the 3rd Query Result for sky.Therefore superior system will be according to the 3rdWithout any data of omission in the first Query Result that Query Result determines to receive.
Alternatively, the superior system referred in above example is top level control device, APP or the access top level control deviceSystem, lower system is the controller for carrying out query processing.
In addition, a kind of application scenarios are additionally provided in the present invention, applied to above-described embodiment 1 and embodiment 2.Fig. 5A kind of timing diagram of data query according to embodiments of the present invention.It is pointed out that as shown in figure 5, the scene includes:
Step 1:The Tunnel data structures of batch query are supported in definition, and its unique key is id.It is main to include in followingHold:Unique mark:Id, user tag:Userlabel, direction:Direction, type:TunnelType, source NE ID:SourceNEID, place NE ID:DestNEID, QOS information:Qos, controlled state:adminStatus.
Step 2:The interface command of batch query is defined, it is specific as follows so that SC carries out batch query:SC systems issueInquire about the whole network tunnel command.Input parameter is:Inquiry target, query context, job lot, sort criteria, inquiry batch and answerAnswering parameter is:It is as follows to inquire about batch, total lot number and the data list for meeting condition, the form of list cell:Unique mark:Id, user tag:Userlabel, direction:Direction, type:TunnelType, source NE ID:SourceNEID, place netFirst ID:DestNEID, QOS information:Qos, controlled state:adminStatus.
Step 3:Definition inquire about remaining Tunnel interface be:The query argument that superior system is sent:Query filter condition,Obtain Tunnel id lists, inquire about target, query context.
And the response parameter that downlink system returns, including:Remaining Tunnel list objects in system.The lattice of list cellFormula is as follows:Unique mark:Id, user tag:Userlabel, direction:Direction, type:TunnelType, source network elementID:SourceNEID, place NE ID:DestNEID, QOS information:Qos, controlled state:adminStatus.
Step 4:For superior system after the completion of initialization, dynamic service heavy-route module starts inquires about the whole network in batchesTunnel, using the batch query order in step 2, query argument is constructed, is handed down to lower system, every time inquiry 2000,Batch is inquired about since 1 to be incremented by.
It is as follows that querying command fills in parameter:Inquire about target:The whole network tunnel;Query context:Whole network data;Query filter barPart:Unconditional inquiry;Job lot:2000;Sort criteria:According to direction sequencing;Inquire about batch:1.
Step 5:After subordinate's DC systems receive inquiry request, Tunnel data records are collected according to querying condition, then pressedIt is ranked up according to Tunnel direction, then according to the batch requirement of inquiry request, extracts 2000 to be returned Tunnel pairsAs list, superior system is returned to.Wherein, the response parameter is:Inquire about batch:1st batch;Total lot number:100;Meet conditionData list, list cell are as follows:Unique mark:Id=xsdjfw34o-epiwer034873;User tag:userlabelThe tunnel that=xx companies rent;Direction:Direction=is two-way;Type:TunnelType=LSP;Source NE ID:SourceNEID=sdfjlsdgt-epiwer34667;Place NE ID:DestNEID=w3fsa2t56-epiwer03dsr3;QOS information:Qos=glod;Controlled state:AdminStatus=active.
Step 6:Higher level SC systems preserve the batch Tunnel data that receive, update internal storage data, in renewal process, according toTunnel id keywords carry out rapid comparison, if the tunnel data repeated, are directly abandoned.
Step 7:Repeat step 4 to 6, inquiry the 2nd, 3,4 ... N ... batches, have been inquired about until Tunnel data are whole successivelyFinish.
Step 8:Remaining Tunnel data is inquired about, according to step 3, all Tunnel keywords id inquired are doneBased on data, issue inquire about remaining Tunnel data-interface, inquired about.Wherein command parameter corresponding to the inquiry is:Look intoAsk target:The whole network tunnel, query context:Whole network data, query filter condition:Unconditional inquiry.The Tunnel gotId lists:Id=xsdjfw34o-epiwer034873;I d=xsdjfw34o-epiwer034874 ... ...
Step 9:After lower system receives the order of remaining record of inquiry, data are collected according to querying condition again, thenThe Tunnel data representated by Data Identification that matching exclusion had returned, leave the Tunnel data not returned.AndReturn to superior system.If without missing data, empty list is returned.It was found that there are the data record of omission, return parameters:
The data list of omission, list cell are as follows:Unique mark:Id=sg345h6-epiert6664;User tag:The tunnel that userlabel=yy companies rent;Direction:Direction=is two-way;Type:TunnelType=LSP;Source network elementID:SourceNEID=sdfjlsdgt-epiwer346356;Place NE ID:DestNEID=w3fsa2t56-epiwer03ds776;QOS information:Qos=silver;Controlled state:AdminStatus=active.
Embodiment 3
A kind of data query arrangement is additionally provided in the present embodiment, and the device is used to realize above-described embodiment and preferred realityMode is applied, had carried out repeating no more for explanation.As used below, term " module " can realize the soft of predetermined functionThe combination of part and/or hardware.Although device described by following examples is preferably realized with software, hardware, orThe realization of the combination of software and hardware is also what may and be contemplated.
Fig. 6 is a kind of structure chart of data query arrangement according to embodiments of the present invention, as shown in fig. 6, the device is located atIn superior system, including:First sending module 62, the first receiving module 64, the second sending module 66 and the second receiving module68。
First sending module 62, for when needing to carry out batch query, being criticized according to the generation of the interface command of batch queryInquiry request is measured, and is handed down to lower system.First receiving module, for receiving the lower system according to the batch queryAsk the first Query Result sent;
Alternatively, the first sending module 62 is additionally operable to call the first inquiry for being buffered in and pre-defining in the superior systemParameter, and the query argument is carried in first inquiry request, wherein, the query argument comprises at least following ginsengNumber:Query filter condition, job lot, inquiry batch, inquiry target, query context and sort criteria.
It is pointed out that pre-defined implication is to be not based in conversational system (such as in SDN system)The first sending module 62 carry out data query before, batch query and lower system are carried out to superior system and carry out return responseCarry out parameter definition.In the present embodiment, due to pertaining only to the first sending module 62 in superior system, therefore, only using upperLevel system carries out the parameter (i.e. the first query argument) used in batch query.
It is pointed out that query filter condition, job lot, inquiry batch, sort criteria this four parameters are necessaryIt is arranged among the first query argument.And inquire about target, query context and be then used as optional two parameters, it is more accurate for carrying outInquiry.
Alternatively, the data inquired about in the present embodiment can be the tunnel Tunnel data of the whole network.In actual queriesIn scene, the Tunnel data are at least by hundreds of thousands bar.Certainly the method provided in the present invention is also applied to tensAmong the scene of less than ten thousand.
First receiving module 64, the first inquiry sent for receiving the lower system according to batch query requestAs a result;
Alternatively, looked into when first receiving module 64 does not receive in the given time described in the lower system transmissionWhen asking result, data query failure.
Specifically, the scheduled time is not fixed value, can be needed to be adjusted according to user, it should be pointed out thatThe scheduled time can be determined by the first query argument, naturally it is also possible to determined according to the hobby of user,
Second sending module 66, for sending the second inquiry request to the lower system, second inquiry request is used forData in the data of requesting query support batch query in addition to first Query Result;
Alternatively, second sending module 66 is additionally operable to call second for being buffered in and pre-defining in the superior systemQuery argument, and second query argument is carried in second inquiry request, wherein, second query argument is extremelyInclude following information less:Query filter condition, the data identification information in first Query Result, inquiry target and inquiryScope.
Specifically, second query argument also enters line number in superior system with the first query argument similarlyIt is investigated that ask before carry out it is pre-defined, effect be indicate superior system inquiry missing data.
By the way that the data identification information in the first Query Result is carried in the second query argument, therefore, can assistDownlink system knows which data have been carried out inquiring about, and is inquired about on which data theory, but does not have actuallyThere are the data for carrying out inquiry.
Alternatively, the process that above-mentioned second sending module 66 sends the second inquiry request to lower system can be sent out in batchesSend, i.e., after the first Query Result sent per a collection of lower system is received, the second inquiry request is issued for the batch data.The above-mentioned method for sending the second inquiry request in batches can more accurately inquire about missing data, ensure that low missing rate.SimultaneouslyCan also be after the first receiving module 64 receives the first Query Result of all batches, disposably issuing the second inquiry pleaseAsk.The above-mentioned method for once sending the second inquiry request can save the time in mass data query process.User can rootAccording to the method for itself needing confirmation to send the second inquiry request.For example, if the data volume of inquiry is not especially big (such as thousands ofOr it is tens of thousands of, but not limited to this), while if the low missing rate of user's pursuit, then the inquiry of transmission second in batches can be taken to askAsk, and if the data volume of inquiry is very big (such as several ten million or more than one hundred million, but not limited to this), then using once sending secondThe method of inquiry request.Certainly, among actual application, the second inquiry request of multiple batches can also together be sent outSend, this method ensure that to the accurate of missing data inquiry to a certain extent, while also take into account query time.
Second receiving module 68, the second inquiry sent for receiving the lower system according to second inquiry requestAs a result.
Alternatively, looked into when the second receiving module 68 does not receive described the second of the lower system transmission in the given timeWhen asking result, determine that no missing data needs to handle.
Alternatively, when no missing data needs processing, second Query Result is sky, when there is missing data needsDuring processing, second Query Result is identification information corresponding to the missing data.
Fig. 7 is the structure chart of another data query arrangement according to embodiments of the present invention, as shown in fig. 7, the device removesOutside including all modules shown in Fig. 7, in addition to:Update module 72.
Update module 72, for according to first Query Result, updating data corresponding with first Query Result,Including according to the identification information in first Query Result, detecting whether the data repeated with the identification information be present;In the case that judged result is is, the data repeated with the identification information are replaced or abandoned.
It may be noted that but, the problem of due to the time difference, data renewal is repeatedly there may be during inquiry, causes sequence to be sent outChanging.The data that so each batch directly returns, may there is part repetition.For example, it may be possible to have two in the first Query ResultIndividual identification information is xsdjfw34o-epiwer034873 data.Now, second identification information can be by superior systemXsdjfw34o-epiwer034873 data are abandoned.The data can also be replaced by certain superior system, be replacedFor the data of other identification informations.
It should be noted that above-mentioned modules can be realized by software or hardware, for the latter, Ke YitongCross in the following manner realization, but not limited to this:Above-mentioned module is respectively positioned in same processor;Or above-mentioned modules are with anyThe form of combination is located in different processors respectively.
Embodiment 4
Additionally provide a kind of data query processing unit in the present embodiment, the device is used to realizing above-described embodiment and excellentEmbodiment is selected, had carried out repeating no more for explanation.As used below, term " module " can realize predetermined functionSoftware and/or hardware combination.Although device described by following examples is preferably realized with software, hardware,Or the realization of the combination of software and hardware is also what may and be contemplated.
Fig. 8 is a kind of structure chart of data query processing unit according to embodiments of the present invention, as shown in figure 8, the deviceIn superior system, including:First receiving module 82, the first sending module 84, the second receiving module 86 and second are sentModule 88.
First receiving module 82, the first inquiry request sent in batches for receiving superior system, wherein, described first looks intoAsk request and be used for the data that requesting query supports batch query;
First sending module 84, for determining the first Query Result according to first inquiry request, and by described firstQuery Result is sent to the superior system;
Fig. 9 is the structure chart of another data query processing unit according to embodiments of the present invention, as shown in figure 9, thisOne sending module includes:The generation unit 94 of extracting unit 92 and first.
Extracting unit 92, for requiring according to putting in order in first inquiry request and in batches, from the branchHold in the data of batch query and extract data;
First generation unit 94, the first response parameter pre-defined in the lower system is buffered in for calling, andThe first Query Result is generated according to the data after the extraction, wherein, the first response parameter comprises at least following information:InstituteState identification information, inquiry batch and the total lot number of the data after extracting.
It is pointed out that enter line number in the superior system that (such as in SDN system) is not based in conversational systemIt is investigated that before asking, batch query is carried out to superior system and lower system carries out return response and carried out parameter definition.In this realityApply in example, due to pertaining only to lower system side, therefore, only using lower system carry out return response parameter (i.e. first answerAnswer parameter).
It is pointed out that also need to carry out accordingly the data attribute for inquire about data in conversational system is not based onDefinition.Specifically, the data attribute comprises at least:Identification information id, user tag userlabel, direction direction,Type tunneltype, source network element ID sourceNEID, place network element ID destNEID, QOS information qos and controlled stateadminStatus.Therefore, other data attributes that can also be answered extraction data identification information pair in the first response parameter are sentTo superior system.It can specifically send in the form of a list.
Second receiving module 86, the second inquiry request sent for receiving the superior system, second inquiry requestThe data in addition to first Query Result in the data of batch query are supported for requesting query;
Second sending module 88, for determining the second Query Result according to second inquiry request, and by described secondQuery Result is sent to the superior system.
Figure 10 is the structure chart of another data query processing unit according to embodiments of the present invention, as shown in Figure 10, shouldSecond sending module 88 includes:The generation unit 1004 of rejected unit 1002 and second.
Rejected unit 1002, for according to the Data Identification in first Query Result in second inquiry requestInformation, the data for being not sent to the superior system are excluded from the data of the support batch query;
Specifically, rejected unit 1002 is believed by comparing the Data Identification in the first Query Result in the second inquiry requestThe identification information of the data of breath and support batch query.There is no treated number if there is in upper once query processingDuring according to mark, rejected unit 1002 then determines that the data are missing data, that is, is defined as being not sent to the superior systemData.
Second generation unit 1004, the second response parameter pre-defined in the lower system is buffered in for calling,And the second Query Result is generated according to the data for being not sent to the superior system, wherein, the second response parameter is at leastIncluding:The identification information of not no data of the appearance in first Query Result in the data for supporting batch query.
With the first response parameter similarly, the second response parameter also superior system carry out data query itIt is preceding carry out it is pre-defined, effect be indicate lower system determine missing data.Specifically, the second response parameter includes:InstituteState the identification information of not no data of the appearance in first Query Result in the data for supporting batch query.
Specifically, if lower system finds not having missing data in the second inquiry request, then lower systemThen can superior system send the 3rd Query Result, the 3rd Query Result for sky.Therefore superior system will be according to the 3rdWithout any data of omission in the first Query Result that Query Result determines to receive.
It should be noted that above-mentioned modules can be realized by software or hardware, for the latter, Ke YitongCross in the following manner realization, but not limited to this:Above-mentioned module is respectively positioned in same processor;Or above-mentioned modules are with anyThe form of combination is located in different processors respectively.
Embodiment 5
A kind of data query system is additionally provided in the present embodiment.Figure 11 is a kind of data according to embodiments of the present inventionThe structure chart of inquiry system, as shown in figure 11, the device are located in superior system, including:Superior system 1102 and system of subordinateSystem 1104.
Superior system 1102, for the first inquiry request sent to lower system 1104, first inquiry in batchesAsk the data for requesting query support batch query;The second inquiry request is sent to the lower system 1104, this secondInquiry request is used for the data in addition to first Query Result in the data of requesting query support batch query;
Lower system 1104, first inquiry request sent in batches for receiving the superior system 1102;FoundationFirst inquiry request determines the first Query Result, and first Query Result is sent into the superior system;ReceiveSecond inquiry request that the superior system 1102 is sent;The second Query Result is determined according to second inquiry request,And second Query Result is sent to the superior system 1102.
Figure 12 is a kind of structure chart of controller according to embodiments of the present invention, and as shown in figure 12, the controller 1202 isController corresponding to lower system.The inquiry request that superior system sends is received by northbound interface, by batch query module,After the module such as resource management module and service management module is handled, the result after inquiry is returned by northbound interface and looked intoAsk request.In addition, after inquiry, when superior system needs to be managed renewal to gateway, via northbound interface and south orientationThe order of management update is sent to each network element by interface, lower system.
Embodiment 6
Embodiments of the invention additionally provide a kind of storage medium.Alternatively, in the present embodiment, above-mentioned storage medium canThe program code for performing following steps to be arranged to storage to be used for:
S11, the first inquiry request that the superior system being not based under conversational system is sent in batches to lower system, this is describedFirst inquiry request is used for the data that requesting query supports batch query;
S12, the superior system receive the first inquiry knot that the lower system is sent according to batch query requestFruit;
S13, the superior system send the second inquiry request to the lower system, and second inquiry request is used to askData in the data of inquiry support batch query in addition to first Query Result;
S14, the superior system receive the second inquiry knot that the lower system is sent according to second inquiry requestFruit.
Alternatively, storage medium is also configured to the program code that storage is used to perform following steps:
S21, according to first Query Result, update data corresponding with first Query Result.
Alternatively, storage medium is also configured to the program code that storage is used to perform following steps:
S31, according to the identification information in first Query Result, detect whether there is what is repeated with the identification informationData;
S32, in the case where the judgment result is yes, replace or abandon the data repeated with the identification information.
Alternatively, in the present embodiment, above-mentioned storage medium can include but is not limited to:USB flash disk, read-only storage (ROM,Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disc orCD etc. is various can be with the medium of store program codes.
Embodiment 7
According to still a further embodiment, a kind of storage medium is additionally provided.The storage medium is arranged to storage and usedIn the program code for performing following steps:
S11, the lower system being not based under conversational system receive the first inquiry request that superior system is sent in batches, itsIn, first inquiry request is used for the data that requesting query supports batch query;
S12, the lower system determines the first Query Result according to first inquiry request, and described first is inquired aboutAs a result it is sent to the superior system;
S13, the lower system receive the second inquiry request that the superior system is sent, and second inquiry request is used forData in the data of requesting query support batch query in addition to first Query Result;
S14, the lower system determines the second Query Result according to second inquiry request, and described second is inquired aboutAs a result it is sent to the superior system.
Alternatively, storage medium is also configured to the program code that storage is used to perform following steps:
S21, the lower system is according to the Data Identification in first Query Result in second inquiry requestInformation, the data for being not sent to the superior system are excluded from the data of the support batch query;
S22, the second response parameter for being buffered in and being pre-defined in the lower system is called, and foundation is not sent to instituteThe data for stating superior system generate the second Query Result.
Obviously, those skilled in the art should be understood that above-mentioned each module of the invention or each step can be with generalComputing device realize that they can be concentrated on single computing device, or be distributed in multiple computing devices and formedNetwork on, alternatively, they can be realized with the program code that computing device can perform, it is thus possible to they are storedPerformed in the storage device by computing device, and in some cases, can be with different from shown in order execution hereinThe step of going out or describing, they are either fabricated to each integrated circuit modules respectively or by multiple modules in them orStep is fabricated to single integrated circuit module to realize.So, the present invention is not restricted to any specific hardware and software combination.
The preferred embodiments of the present invention are the foregoing is only, are not intended to limit the invention, for the skill of this areaFor art personnel, the present invention can have various modifications and variations.Within the spirit and principles of the invention, that is made any repaiiesChange, equivalent substitution, improvement etc., should be included in the scope of the protection.