CN101958838B - Data access method and device - Google Patents

Data access method and device Download PDF

Info

Publication number
CN101958838B
CN101958838B CN2010105065432A CN201010506543A CN101958838B CN 101958838 B CN101958838 B CN 101958838B CN 2010105065432 A CN2010105065432 A CN 2010105065432A CN 201010506543 A CN201010506543 A CN 201010506543A CN 101958838 B CN101958838 B CN 101958838B
Authority
CN
China
Prior art keywords
data
access
sign
visited
network application
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.)
Active
Application number
CN2010105065432A
Other languages
Chinese (zh)
Other versions
CN101958838A (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.)
Union Mobile Pay Co Ltd
Original Assignee
Union Mobile Pay Co Ltd
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 Union Mobile Pay Co Ltd filed Critical Union Mobile Pay Co Ltd
Priority to CN2010105065432A priority Critical patent/CN101958838B/en
Publication of CN101958838A publication Critical patent/CN101958838A/en
Application granted granted Critical
Publication of CN101958838B publication Critical patent/CN101958838B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The invention discloses data access method and device which are used for solving the problem that many processing resources of network application systems are consumed because the data access scheme provided by the prior art requires all the network application systems to set respective DAOs (Data Access Objects). The method comprises the following steps of: acquiring the identifier of data to be accessed sent by at least one network application system by a data access server; determining the type information of an access policy and a storage medium corresponding to the identifier of the data to be accessed according to the correspondence preset in the server between data information and the type information of access policies and storage media; determining the storage access of the data to be accessed through executing the determined access policy, and determining the corresponding access interface from the correspondence preset in the server between the type information of the storage media and the access interface according to the determined type information of the storage medium; and accessing the data to be accessed stored in the determined storage access through the determined access interface.

Description

Data access method and device
Technical field
The present invention relates to field of network computing, relate in particular to a kind of data access method and device.
Background technology
Network application system be unable to do without Data Acquisition and storage.Along with the continuous evolution of internet, applications, the quantity of network application system is increasing, and network application system is also increasing to the storage and the visit data volume more and more frequent, visit of data, and the data class of visit is also more and more.
At first; The problem that is difficult to network enabled application system frequent access database to single database; In practical application; Consider network application system to the frequency of the performed read operation of data frequency, can solve this problem through the measure of implementing " read-write separates " much larger than write operation.Promptly to the network application system different operating type performed to data, correspondence is visited different databases respectively, can effectively alleviate the pressure of MDL like this.
Secondly; Problem to all can't complete preservation network application system required data of single main frame or single database; In practical application, its solution is that parallel being distributed on multiple host and a plurality of database of the data of magnanimity preserved, and takes stripping strategy that data are carried out fragment process; Such as; Can carry out burst to subscriber's meter according to integer id value scope, can carry out burst to tran list, perhaps can also carry out burst or the like to the tables of data of some kind according to the hash of a plurality of field values according to exchange hour.Corresponding to different branch sheet modes, network application system need adopt different access strategies that it is conducted interviews.
In addition; Because the storage type is also more and more; The data of different types that the consolidated network application system is visited often is stored in the different storage mediums; Such as, storage medium possibly be a relational database, also possibly be storage medium, data, services storage medium of document database, memory database, Key-Value buffer memory medium, storage file formatted data or the like.When needing to use different API (API, Application Programming Interface) and different class libraries to being stored in data in the different storage mediums when conducting interviews.
Based on above-mentioned data storage method; When network application system need conduct interviews to data; Its visit sketch map is as shown in Figure 1, and wherein, RDB1,2 is a relational database; Cache is a kind of storage medium that is used to store data, is called cache memory File for then being another kind of storage medium.And DAO is a DAO, and its information that need comprise comprises action type, access strategy, API information and the data message to be visited that network application system is carried out data at least.According to the action type that comprises among the DAO, access strategy and API information; Network application system is achieved through certain API, with certain access strategy and action type realize to according to certain minute sheet mode be stored in the indicated data of data message in certain storage medium, to be visited and conduct interviews.
The defective that the above-mentioned access mode that provides in the prior art exists is: each network application system need be provided with the DAO that it adopts respectively; Because the quantity of network application system is very big; And the quantity of corresponding network application system also is very big; Therefore, the mode that adopts each network application system that DAO is set respectively realizes need expending the more processing resource of network application system to the visit of data.
Summary of the invention
The embodiment of the invention provides a kind of data access method and device, and the data access scheme that provides in order to the solution prior art needs each network application system respectively DAO to be set and to cause expending network application system than the multiprocessing problem of resource.
The embodiment of the invention adopts following technical scheme:
A kind of data access method comprises:
Data Access Server obtains the sign of the data to be visited of at least one network application system transmission; In the corresponding relation of the type information of data message from be arranged on said server in advance and access strategy, storage medium, confirm the access strategy corresponding, the type information of storage medium with the sign of data to be visited; And through carrying out the access strategy of confirming; Confirm the memory address of said data to be visited; And according to the type information of the storage medium of confirming; In storage media types information from be arranged on said server in advance and the corresponding relation, confirm corresponding access interface to the access interface of dissimilar storage medium; Through the access interface of confirming, the said to be visited data of access stored in the memory address of confirming.
Preferably, said method also comprises:
Data Access Server receives that said network application system sends is used to indicate the action type information that said data to be visited are operated, said action type information is that said network application system is chosen from the some action type information that are provided with in advance; And the data that have access to are carried out the indicated operation of said action type information that receives.
Preferably, Data Access Server obtains the sign of being transmitted the data to be visited of the said network application system transmission that comes by load-balanced server; Wherein, when load-balanced server conforms to a predetermined condition at the load information of judging Data Access Server, the sign of said data to be visited is transmitted to Data Access Server.
Preferably, Data Access Server is provided with a plurality of interfaces of supporting different agreement respectively; And the sign that Data Access Server obtains said data to be visited specifically comprises: Data Access Server receives the protocol message of the sign that is packaged with data to be visited that said network application system sends through first interface in said a plurality of interfaces; Wherein, the said first interface support is used to encapsulate the agreement of the sign of said data to be visited; And according to the protocol type of this protocol message, choose corresponding serializing processing mode and said protocol message is carried out serializing handle, obtain the sign of said data to be visited.
Preferably, said method also comprises: Data Access Server obtains the data that have access to, and the data that get access to are compressed, and the data after will compressing sends to said network application system after encrypting.
Preferably, said method also comprises:
The temporal information of the sign of the said data to be visited of the definite reception of said Data Access Server and the sign of said network application system; And, from the corresponding relation of sign, temporal information and the data access bandwidth of the network application system that is provided with in advance, choose corresponding data access bandwidth according to the sign of said temporal information and said network application system; And according to access strategy of determining and the required parameter information of visit data, utilize the access bandwidth choose, the said to be visited data of access stored in the indicated storage medium of the type information of the storage medium of confirming.
Preferably; The sign that Data Access Server obtains said data to be visited specifically comprises: the thread that the Data Access Server utilization specifies number is monitored the data access request message that said network application system sends; Wherein, said specifying number less than the total number that is connected between said Data Access Server and the all-network application system; And from the data access request message that listens to, resolve the sign obtain said data to be visited.
A kind of DAA comprises: the sign acquiring unit is used to obtain the sign of the data to be visited that at least one network application system sends; First confirms the unit; Be used for from the corresponding relation of the type information of the sign of the data that are arranged on said device in advance and access strategy, storage medium, confirm the access strategy corresponding, the type information of storage medium with the sign that identifies the data to be visited that acquiring unit gets access to; Memory address is confirmed the unit, is used for confirming the access strategy that the unit is confirmed through carrying out first, confirms the memory address of said data to be visited; Access interface is confirmed the unit; Be used for type information according to the definite storage medium in first definite unit; In storage media types information from be arranged on said device in advance and the corresponding relation, confirm corresponding access interface to the access interface of dissimilar storage medium; Addressed location is used for confirming the access interface that the unit is confirmed through access interface, the said to be visited data of access stored in the memory address that memory address is confirmed to confirm the unit.
The beneficial effect of the embodiment of the invention is following:
In the such scheme that the embodiment of the invention provides; Through the management of Data Access Server to the type information of access strategy, storage medium; Network application system only needs to send to Data Access Server the sign of data to be visited; By Data Access Server from the corresponding relation of the type information of the sign that is arranged on the data the Data Access Server in advance and access strategy, storage medium; Confirm the access strategy corresponding, the type information of storage medium, thereby realize treating the visit of visit data with the sign of data to be visited.Because the scheme that adopts the embodiment of the invention to provide; Data Access Server can carry out unified management to the corresponding relation of the type information of the sign of data and access strategy, storage medium; Network application system need not to dispose respectively DAO again; And only need provide the sign of data to be visited to get final product, therefore, saved the processing resource of network application system greatly.And; When changing, stripping strategy cause access strategy to change; Perhaps storage medium changes (comprising the variation of storage media types and the increase and decrease of certain storage medium quantity etc.) and when causing API to change; This scheme that adopts the embodiment of the invention to provide only needs to revise above-mentioned corresponding relation to this process object of Data Access Server, need not a plurality of network application systems and respectively the DAO that it adopts is made amendment; Thereby also can realize in this case, handling the saving of resource.
Description of drawings
The sketch map that Fig. 1 conducts interviews to data for network application system in the prior art;
The idiographic flow sketch map of a kind of data access method that Fig. 2 provides for the embodiment of the invention;
The enforcement sketch map of data access method in reality that Fig. 3 provides for the embodiment of the invention;
Fig. 4 is the concrete sketch map that is provided with the data access system of load-balanced server;
The applied environment sketch map of data access method in reality that Fig. 5 provides for the embodiment of the invention;
The concrete structure sketch map of a kind of DAA that Fig. 6 provides for the embodiment of the invention.
Embodiment
For the data access scheme that solves prior art and provide needs each network application system respectively DAO to be set and to cause expending network application system than the multiprocessing problem of resource; Influence to network application system when the inventor changes based on complexity that reduces the network application system function and access strategy etc. should be minimum; So that realize the principle of network application system high availability; Defined a kind of flexible and consistent access mode; Need not to expend the more processing resource of network application system, just can accomplish visit mass data.
Particularly; The embodiment of the invention provides a kind of data access scheme; Come the corresponding relation of the type information of data and access strategy, storage medium is managed through newly-increased Data Access Server between network application system and data to be visited; Thereby realize simplification, realize practicing thrift the purpose that network application system is handled resource the network application system function.Particularly, the embodiment of the invention at first provides a kind of data access method, and the concrete realization flow sketch map of this method is as shown in Figure 2, may further comprise the steps:
Step 21, Data Access Server are obtained the sign of the data to be visited of at least one network application system transmission, in embodiments of the present invention; Can the system that comprise a plurality of network application systems and Data Access Server be called " data access system ", in this data access system, a plurality of network application systems can link to each other with a data access server; Look the actual demand difference, a data access system one or more Data Access Servers can be set, when a plurality of network application systems all have the data access demand; Just can send the sign of data to be visited to this Data Access Server; The data of heterogeneous networks application system desire visit can be identical, also can be different, the sign of data to be visited can but to be not limited to be type of data sign to be visited; It also can be name identification of data to be visited or the like; Preferably, in the embodiment of the invention, network application system can be through sending universal resource identifier (URI; Uniform Resource Identifier) mode is carried on the sign of data to be visited and sends to Data Access Server among the URI;
Step 22; From the corresponding relation of the type information that is arranged on data message and access strategy the Data Access Server, storage medium in advance; Confirm the access strategy corresponding, the type information of storage medium with the sign of data to be visited; In embodiments of the present invention; Can utilize API to call the access strategy corresponding, the type information of storage medium according to the sign of data to be visited with this information, can also be with corresponding to the type information of the access strategy of the sign of data to be visited, storage medium, the required respectively parameter information of visit data be packaged into one " Dalet resource " and it is stored in the Data Access Server in dissimilar storage mediums; Such as, can be stored in the Dalet processing module that Data Access Server comprises;
Step 23 through carrying out definite access strategy, is confirmed the memory address of data to be visited; And according to the type information of the storage medium of confirming; From be arranged on storage media types information and the corresponding relation the Data Access Server in advance, confirm corresponding access interface, in this step 23 to the access interface of dissimilar storage medium; Access strategy can be based on the access strategy of hash algorithm etc.; Through carrying out this access strategy corresponding with data to be visited, can confirm the memory address of data to be visited, and because the corresponding different access interface of different storage media types information meeting; Therefore, also need confirm and which type of access interface to visit this data to be visited through;
Step 24, through the access interface of confirming, the to be visited data of access stored in the memory address of confirming.
The core of the said method that the embodiment of the invention provides is to have increased newly a data access server; And in this server, be provided with a general data message of cover and the corresponding relation of Dalet resource; Thereby when network application system need be visited different data; Only need network application system that the sign of its data that need visit is made amendment; Carry out the type information of the access strategy among the DAO, storage medium etc. is configured and need not network application system, thus the processing resource of having practiced thrift network application system greatly.Especially; When access strategy and API change; Only need carry out to revise getting final product the corresponding relation in the data access server, because a plurality of network application systems may use same corresponding relation, and a data access server can provide service for a plurality of network application systems; In data access system; The quantity of Data Access Server is the quantity that is far smaller than network application system, therefore, corresponding relation in the data access server is carried out to revise the resource that is spent be very little with respect to the resource that modification spent to network application system.
In embodiments of the present invention; When network application system also need be operated the data that have access to; Network application system can be chosen pending action type information and send to Data Access Server from the some action type information that are provided with in advance; Thereby Data Access Server receives that network application system sends be used to indicate treat the action type information that visit data operates after; Follow-up after having access to data, just can carry out the indicated operation of action type information that receives, thereby realize operation data to the data that have access to.Need to prove; In the time need the data that have access to being sent to network application system; For the fail safe that strengthens data transfer procedure and in order to practice thrift transfer resource; Data Access Server can compress the data that get access to, and then the data after will compressing send to network application system after encrypting.
The enforcement sketch map of the said method that the embodiment of the invention provides in reality is as shown in Figure 3, compared to Figure 1, and in Fig. 3; Increase Data Access Server newly between network application system and the data, be provided with the sign of data and the corresponding relation of Dalet in this Data Access Server, wherein; The quantity of Dalet is generally more; Such as being directed against data of different types, having data of different titles or the like, all there is corresponding D alet corresponding with it, like the Dalet1 among Fig. 3, Dalet2.......
The said method that the embodiment of the invention provides can also further carry out following transformation, to obtain better technique effect:
Preamble is mentioned; In a data access system, a plurality of Data Access Servers can be arranged; In the present invention implemented, in order to reach the load balancing between the different pieces of information access server, which Data Access Server network application system is connected to was adjustable.Particularly, can a plurality of load-balanced servers be set between Data Access Server and network application system, the concrete sketch map of data access system that is provided with load-balanced server is as shown in Figure 4.The effect of load-balanced server is to receive the sign of the data to be visited that network application system sends; And the load information through the Data Access Server collected; Whether the load information of the Data Access Server in the judgment data access system conforms to a predetermined condition; And the sign of the data to be visited that network application system is sent is transmitted to Data Access Server, thereby Data Access Server just can get access to the sign of the data of being transmitted by load-balanced server to be visited.Wherein, above-mentioned " predetermined condition " can perhaps be present load minimal data access server or the like in the data access system for the load of the Data Access Server load threshold less than regulation.Through load-balanced server is set the reception object of the sign of the data to be visited of network application system transmission is adjusted, can be realized the load balancing of Data Access Server, strengthen the stability of data access system.
In embodiments of the present invention; Send the situation of the protocol message of the sign that is packaged with data to be visited to the heterogeneous networks application system; For compatible different agreement message; Data Access Server can also be designed to can support to comprise the multiple network agreement of HTTP, thereby the realization data server can be monitored a plurality of ports (PORT) simultaneously.
From concrete realization, a plurality of interfaces of supporting different agreement respectively can be set in Data Access Server, can handle the protocol message of the sign that is packaged with data to be visited of network application system transmission respectively with realization.In embodiments of the present invention, through a plurality of interfaces are set in the data access device, when receiving message; Data Access Server can receive this protocol message through first interface in a plurality of interfaces that are provided with; Wherein, this first interface need satisfy the agreement of supporting to be used to encapsulate the sign of data to be visited, and Data Access Server is after receiving this protocol message; In order therefrom to obtain the sign of data to be visited; Can choose corresponding serializing processing mode this protocol message is carried out the serializing processing according to the protocol type of this protocol message, obtain the sign of data to be visited.Need to prove; When network application system comes when Data Access Server provides the sign of data to be visited through the mode of sending URI; This URI can imply and show protocol type; The URI that shows transmission like http://host:port1/sqlid/rdb1/query.xml uses http protocol, and the data of returning should meet the xml form, and for example cm20: //host:port2/sqlid/rdb2/query.json; Its URI that shows transmission uses the CM20 agreement, and the data of returning should meet the json form.
In addition; In embodiments of the present invention; Data Access Server can be respectively each network application system and distribute a thread to include the sign of data to be visited in order to monitoring, but such mode in the quantity of network application system more for a long time, need the more thread resources of cost; Therefore; Can also utilize the thread that specifies number to monitor the data access request message that a large amount of network application systems send, and from the data access request message that listens to, resolve the sign that obtains said data to be visited based on the NIO technology in the embodiment of the invention; Because specifying number of preceding text, thereby can practice thrift thread resources less than the total number that is connected between Data Access Server and the all-network application system.
Further; May visit the situation that different demands is arranged to data in different time to the heterogeneous networks application system; The method of the data access that the embodiment of the invention provides can further be improved; With to the network application system of various network application system in the different access demand of different time sections to data, be the corresponding access resources of different access demand assignment.Particularly, in the method after improvement, can adopt following step to realize above-mentioned purpose: at first, Data Access Server can confirm to receive temporal information and the sign of network application system of sending the sign of these data to be visited of the sign of data to be visited; Then, according to the temporal information of confirming and the sign of network application system, Data Access Server is chosen corresponding data access bandwidth from the corresponding relation of sign, temporal information and the data access bandwidth of the network application system of setting in advance; At last, according to the sign of access strategy of determining and data to be visited, Data Access Server just can utilize this access bandwidth of choosing, the to be visited data of access stored in the storage medium of confirming.
Below the data access method that provides with the embodiment of the invention in reality, be applied as example, introduce the application flow of this method in reality in detail.The applied environment sketch map of this application flow is as shown in Figure 5; This applied environment can be regarded the said data access system of preamble as; In this system; Network application system is in " applied logic layer ", and Data Access Server is in " data access layer ", and data then are in " data resource layer ".Based on this applied environment; The core concept of the scheme that the embodiment of the invention provides is between applied logic layer and data resource layer to insert an independently distributed data access layer, will be arranged in DAO that the network application system of applied logic layer uses the in the prior art Dalet that the Data Access Server that is arranged in data access layer uses that develops.
Below according to the order of " applied logic layer "-" data access layer "-" data resource layer ", successively each layer is introduced:
At first; To the applied logic layer; The data access interface of this layer can adopt HTFP or type HTTP standard agreement, compares the simple a lot of implementation of traditional DAO thereby this interface is one, and the sign of data to be visited is indicated with URI; The form of this URI can wherein, the implication of each item that this form comprises be following for " scheme: //host:port/resouce_path/resouce_id.fmt ":
Use scheme sign various network communication protocol, capable of supporting several protocols in service end;
Use host to identify different main frames, can conveniently realize distributed deployment;
Use port sign different port, the default different port that takies of each scheme;
Use resouce_path sign data of different types, can realize load balancing to it in service end;
Use resouce_id to indicate specific data, promptly in order to indicate the sign of data to be visited;
Use fmt to come the form of recognition data, can support multiple serializing form in service end.
Method then treats the action type information that visit data is operated in order to indication, and the action type here can be as shown in table 1 below:
Table 1:
The action type information that Method is indicated The operation that action type information is indicated
GET ?/resource_path Obtain the Resources list
POST /resource_path Establishing resource
GET ?/resource_path/id.fmt Obtain resource
PUT ?/resource_path/id.fmt Revise resource status
DELETE/resource_path/id.fmt The deletion resource
In the applied logic layer; Network application system can be an ignorant for storage medium relevant with data to be visited and stripping strategy; Its needs provide the sign of data to be visited, and from the Method that is provided with in advance, choose one or more action type information and get final product.Wherein, the sign of data to be visited can be carried among the URI with the action type information of choosing, and uses corresponding protocols; Like http protocol or CM20 agreement, construct request message on request, issue Data Access Server; (comprise the parsing message header, deciphering decompresses and Data Access Server is through a series of resolvings; Unserializing message body etc.), the sign that finally from this request message, gets access to data to be visited and the action type information of choosing etc.
To data access layer; The Data Access Server that is in this layer can comprise NIO network protocol adapter (comprising message header resolver and message body resolver), Dalet engine (comprising resource distributor and operation map device), Dalet container (comprising a plurality of Dalet, such as Dalet1, Dalet2 etc.).Wherein, the message header resolver is in order to resolve message header, and the message body resolver obtains the sign of data to be visited and the Method that network application system is chosen then in order to message body is resolved.Operation map device in the Dalet engine is in order to the corresponding relation of the sign of sign and the Dalet of storage data; The resource distributor is in order to the sign of the data to be visited that parse according to the NIO network protocol adapter; From operation map device stored relation; Confirm sign, and from the Dalet of Dalet container storage, choose the indicated Dalet of sign of this definite Dalet corresponding to the Dalet of this information.In embodiments of the present invention, the configuration code of certain Dalet (such as being Dalet4Sqlid) can be as follows:
GET.sql_select=SELECT{fields}FROM{tables}WHERE{wheres}{others}
PUT.sql_insert =INSERT?INTO{tables}({fields})VALUES({values})
PUT.sql_update=UPDATE{tables}SET{fieled_values}WHERE{wheres}
In data access layer; The different Dalet that choose to the Dalet engine; Can use different interfaces to visit corresponding data, such as, can be through the data of storing among the jdbc interface accessing RDB; Can be through the data of storing among the relevant api interface visit of the Cache Cache, and through the data of storing among the interface accessing File relevant with operating system etc.
The analyzing efficiency of considering http protocol is poor; And the support to long connection and Chinese character is more loaded down with trivial details; So can define the CM20 network communication protocol of a kind HTTP in embodiments of the present invention,, can adopt fixed news head length degree to accelerate decoding speed according to this agreement.This agreement is supported multiple cipher mode, multiple compressed format, multiple serializing form, multiple character set.
To the data resource layer, its employed interface is the internal interface of data access service, and this interface is claimed inner Dalet interface again.Data accessing engine can pass through inner Dalet interface, call concrete Dalet processing module, and the Dalet processing module can make amendment easily and expand.
When needing the various dissimilar mass data of frequent access; The scheme that adopts prior art to provide; Need come data are conducted interviews through multiple DAO is provided; The defective that this mode exists is mainly: with setting such as api interface and data access strategy and be solidificated in each network application system, thereby cause network application system too complicated, lack flexibility.Especially when a plurality of network application systems are visited same set of data; The data access mode that provided in the prior art will seriously hinder carries out any change and optimization to data storage mode (comprising storage medium, read-write separate mode, data fragmentation mode etc.); Immediately can change network application system, also be very difficult but change a plurality of network application systems simultaneously.
And after the scheme that the employing embodiment of the invention provides; Because Data Access Server can be to the type information of the sign of data and access strategy, storage medium, the corresponding relation of the required respectively parameter information of visit data carries out unified management in dissimilar storage mediums; Network application system need not to dispose respectively DAO again; And only need provide the sign of data to be visited to get final product, therefore, saved the processing resource of network application system greatly.And; When changing, stripping strategy cause access strategy to change; Perhaps storage medium changes (comprising the variation of storage media types and the increase and decrease of certain storage medium quantity etc.) and when causing API to change; This scheme that adopts the embodiment of the invention to provide only needs to revise above-mentioned corresponding relation to this process object of Data Access Server, need not a plurality of network application systems and respectively the DAO that it adopts is made amendment; Thereby also can realize in this case, handling the saving of resource.
The data access method that provides corresponding to the embodiment of the invention; The embodiment of the invention also provides a kind of DAA, and the data access scheme that provides in order to the solution prior art needs each network application system respectively DAO to be set and to cause expending network application system than the multiprocessing problem of resource.The concrete structure sketch map of this device is as shown in Figure 6, comprises following functional unit:
Sign acquiring unit 61 is used to obtain the sign of the data to be visited that at least one network application system sends;
First confirms unit 62; Be used for from the corresponding relation of the type information of the sign of the data that are arranged on this DAA in advance and access strategy, storage medium, confirm the access strategy corresponding, the type information of storage medium with the sign that identifies the data to be visited that acquiring unit 61 gets access to;
Memory address is confirmed unit 63, is used for confirming the access strategy that unit 62 is confirmed through carrying out first, confirms the memory address of data to be visited;
Access interface is confirmed unit 64; Be used for the type information of confirming the storage medium that unit 62 is confirmed according to first; In storage media types information from be arranged on this device in advance and the corresponding relation, confirm corresponding access interface to the access interface of dissimilar storage medium;
Addressed location 65 is used for confirming the access interface that unit 64 is confirmed through access interface, the to be visited data of access stored in the memory address that memory address is confirmed to confirm unit 63.
Preferably, the said apparatus that provides of the embodiment of the invention can also be operated the data that have access to realizing through further comprising the following function unit:
Information receiving unit is used to receive that network application system sends is used to indicate the action type information that visit data is operated of treating, and wherein, action type information is that network application system is chosen from the some action type information that are provided with in advance; Operating unit, the data that are used for addressed location is had access to are carried out the indicated operation of action type information that information receiving unit receives.
Preferably; In the embodiment of the invention; Can also realize the load balancing in the data access system through load-balanced server; When also being provided with load-balanced server in the data access system, sign acquiring unit 61 specifically can be used to obtain the sign of being transmitted the data to be visited of being sent by network application system of coming by load-balanced server, wherein; Load-balanced server can be when the load information of judging Data Access Server conforms to a predetermined condition, and the sign of data to be visited is transmitted to Data Access Server.
Preferably, the said apparatus that the embodiment of the invention provides can comprise a plurality of interfaces of supporting different agreement respectively, and when this device comprised a plurality of interface, sign acquiring unit 61 can also further be divided into following functional module:
The message sink module is used for the protocol message that first interface through a plurality of interfaces receives the sign that is packaged with data to be visited that network application system sends, and wherein, the first interface support is used to encapsulate the agreement of the sign of said data to be visited; The protocol translation module is used for the protocol type according to this protocol message of message sink module reception, chooses corresponding serializing processing mode protocol message is carried out the serializing processing, obtains the sign of data to be visited.
Preferably, the said apparatus that the embodiment of the invention provides can further include: data capture unit is used to obtain the data that addressed location has access to; Transmitting element is used for the data that the data acquiring unit gets access to are compressed, and the data after will compressing send to network application system after encrypting.
Preferably; The said apparatus that the embodiment of the invention provides can further include: second confirms the unit, is used for confirming that sign acquiring unit 61 obtains temporal information and the sign of network application system of sending the sign of these data to be visited of the sign of data to be visited; Choose the unit, be used for confirming the temporal information and the sign of network application system confirmed the unit according to second, from the corresponding relation of sign, temporal information and the data access bandwidth of the network application system of setting in advance, choose corresponding data access bandwidth.
Based on comprising that second confirms unit and the said apparatus of choosing the unit; Above-mentioned addressed location 65 can also specifically be used for confirming access strategy and the required parameter information of visit data that unit 62 is determined according to first; The access bandwidth of unit selection is chosen in utilization, the to be visited data of access stored in the indicated storage medium of the type information of the storage medium of confirming.
Preferably, corresponding to a kind of implementation of sign acquiring unit 61 functions, the logical above-mentioned sign acquiring unit 61 of the embodiment of the invention can also specifically be divided into following functional module:
Monitor module, the data access request message that is used to utilize the thread listens for network application system that specifies number to send, wherein, this specifies number less than the total number that is connected between Data Access Server and the all-network application system; Parsing module is used for resolving the sign that obtains data to be visited from the data access request message that the monitoring module listens to.
Obviously, those skilled in the art can carry out various changes and modification to the present invention and not break away from the spirit and scope of the present invention.Like this, belong within the scope of claim of the present invention and equivalent technologies thereof if of the present invention these are revised with modification, then the present invention also is intended to comprise these changes and modification interior.

Claims (14)

1. a data access method is characterized in that, comprising:
Data Access Server obtains the sign of the data to be visited of being sent by at least one network application system;
In the corresponding relation of the type information of data message from be arranged on said server in advance and access strategy, storage medium, confirm the access strategy corresponding, the type information of storage medium with the sign of data to be visited; And
Through carrying out definite access strategy; Confirm the memory address of said data to be visited; And according to the type information of the storage medium of confirming; In storage media types information from be arranged on said server in advance and the corresponding relation, confirm corresponding access interface to the access interface of dissimilar storage medium;
Through the access interface of confirming, the said to be visited data of access stored in the memory address of confirming.
2. the method for claim 1 is characterized in that, also comprises:
Data Access Server receives that said network application system sends is used to indicate the action type information that said data to be visited are operated, said action type information is that said network application system is chosen from the some action type information that are provided with in advance; And
Data to having access to are carried out the indicated operation of said action type information that receives.
3. according to claim 1 or claim 2 method is characterized in that, Data Access Server obtains the sign of being transmitted the data to be visited that the said network application system that comes sends by load-balanced server;
Wherein, when load-balanced server conforms to a predetermined condition at the load information of judging Data Access Server, the sign of said data to be visited is transmitted to Data Access Server.
4. according to claim 1 or claim 2 method is characterized in that Data Access Server is provided with a plurality of interfaces of supporting different agreement respectively; And the sign that Data Access Server obtains said data to be visited specifically comprises:
Data Access Server receives the protocol message of the sign that is packaged with data to be visited that said network application system sends through first interface in said a plurality of interfaces, and wherein, the said first interface support is used to encapsulate the agreement of the sign of said data to be visited; And
According to the protocol type of this protocol message, choose corresponding serializing processing mode said protocol message is carried out the serializing processing, obtain the sign of said data to be visited.
5. according to claim 1 or claim 2 method is characterized in that, also comprises:
Data Access Server obtains the data that have access to, and the data that get access to are compressed, and the data after will compressing sends to said network application system after encrypting.
6. according to claim 1 or claim 2 method is characterized in that, also comprises:
The temporal information of the sign of the said data to be visited of the definite reception of said Data Access Server and the sign of said network application system; And
According to the sign of said temporal information and said network application system, from the corresponding relation of sign, temporal information and the data access bandwidth of the network application system that is provided with in advance, choose corresponding data access bandwidth; And
According to access strategy of determining and the required parameter information of visit data, utilize the access bandwidth choose, the said to be visited data of access stored in the indicated storage medium of the type information of the storage medium of confirming.
7. according to claim 1 or claim 2 method is characterized in that the sign that Data Access Server obtains said data to be visited specifically comprises:
The thread that the Data Access Server utilization specifies number is monitored the data access request message that said network application system sends, wherein, and said specifying number less than the total number that is connected between said Data Access Server and the all-network application system; And
From the data access request message that listens to, resolve the sign that obtains said data to be visited.
8. a DAA is characterized in that, comprising:
The sign acquiring unit is used to obtain the sign by the data to be visited of at least one network application system transmission;
First confirms the unit; Be used for from the corresponding relation of the type information of the sign of the data that are arranged on said device in advance and access strategy, storage medium, confirm the access strategy corresponding, the type information of storage medium with the sign that identifies the data to be visited that acquiring unit gets access to;
Memory address is confirmed the unit, is used for confirming the access strategy that the unit is confirmed through carrying out first, confirms the memory address of said data to be visited;
Access interface is confirmed the unit; Be used for type information according to the definite storage medium in first definite unit; In storage media types information from be arranged on said device in advance and the corresponding relation, confirm corresponding access interface to the access interface of dissimilar storage medium;
Addressed location is used for confirming the access interface that the unit is confirmed through access interface, the said to be visited data of access stored in the memory address that memory address is confirmed to confirm the unit.
9. device as claimed in claim 8 is characterized in that, also comprises:
Information receiving unit; Be used to receive that said network application system sends that to be used to indicate the action type information that said data to be visited are operated, said action type information be that said network application system is chosen from the some action type information that are provided with in advance;
Operating unit, the data that are used for addressed location is had access to are carried out the indicated operation of action type information that information receiving unit receives.
10. like claim 8 or 9 described devices, it is characterized in that the sign acquiring unit specifically is used to obtain the sign of being transmitted the data to be visited of the said network application system transmission that comes by load-balanced server;
Wherein, when load-balanced server conforms to a predetermined condition at the load information of judging Data Access Server, the sign of said data to be visited is transmitted to Data Access Server.
11., it is characterized in that said device comprises a plurality of interfaces of supporting different agreement respectively like claim 8 or 9 described devices; And said sign acquiring unit specifically comprises:
The message sink module; Be used for receiving the protocol message of the sign that is packaged with data to be visited of said network application system transmission through first interface of said a plurality of interfaces; Wherein, the said first interface support is used to encapsulate the agreement of the sign of said data to be visited;
The protocol translation module is used for the protocol type according to this protocol message of message sink module reception, chooses corresponding serializing processing mode said protocol message is carried out the serializing processing, obtains the sign of said data to be visited.
12. like claim 8 or 9 described devices, it is characterized in that, also comprise:
Data capture unit is used to obtain the data that addressed location has access to;
Transmitting element is used for the data that the data acquiring unit gets access to are compressed, and the data after will compressing send to said network application system after encrypting.
13. like claim 8 or 9 described devices, it is characterized in that, also comprise:
Second confirms the unit, is used for confirming that the sign acquiring unit obtains temporal information and the sign of said network application system of the sign of said data to be visited;
Choose the unit, be used for confirming the temporal information and the sign of network application system confirmed the unit according to second, from the corresponding relation of sign, temporal information and the data access bandwidth of the network application system of setting in advance, choose corresponding data access bandwidth; And
Said addressed location specifically is used for confirming access strategy and the required parameter information of visit data that the unit is determined according to first; The access bandwidth of unit selection is chosen in utilization, the said to be visited data of access stored in the indicated storage medium of the type information of the storage medium of confirming.
14., it is characterized in that said sign acquiring unit specifically comprises like claim 8 or 9 described devices:
Monitor module, be used to utilize the thread that specifies number to monitor the data access request message that said network application system sends, wherein, said specifying number less than the total number that is connected between said DAA and the all-network application system;
Parsing module is used for resolving the sign that obtains said data to be visited from the data access request message that the monitoring module listens to.
CN2010105065432A 2010-10-14 2010-10-14 Data access method and device Active CN101958838B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN2010105065432A CN101958838B (en) 2010-10-14 2010-10-14 Data access method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN2010105065432A CN101958838B (en) 2010-10-14 2010-10-14 Data access method and device

Publications (2)

Publication Number Publication Date
CN101958838A CN101958838A (en) 2011-01-26
CN101958838B true CN101958838B (en) 2012-08-22

Family

ID=43485956

Family Applications (1)

Application Number Title Priority Date Filing Date
CN2010105065432A Active CN101958838B (en) 2010-10-14 2010-10-14 Data access method and device

Country Status (1)

Country Link
CN (1) CN101958838B (en)

Families Citing this family (22)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102694830B (en) * 2011-03-24 2015-12-16 腾讯科技(深圳)有限公司 A kind of mthods, systems and devices realizing Web content and share
JP6176020B2 (en) * 2013-09-17 2017-08-09 株式会社リコー Apparatus, information processing system, information processing method, information processing program, and storage medium storing information processing program
CN103678609B (en) * 2013-12-16 2017-05-17 中国科学院计算机网络信息中心 Large data inquiring method based on distribution relation-object mapping processing
CN104899079B (en) * 2014-03-05 2018-07-31 阿里巴巴集团控股有限公司 A kind of method and device of data processing
CN105323206B (en) * 2014-06-04 2019-03-08 同程网络科技股份有限公司 Ip defence method
CN105608085A (en) * 2014-11-17 2016-05-25 北京明略软件系统有限公司 Data query method and device of hybrid storage media
CN104766027A (en) * 2015-03-25 2015-07-08 深圳市金立通信设备有限公司 Data access method
CN104766026A (en) * 2015-03-25 2015-07-08 深圳市金立通信设备有限公司 Terminal
CN105307055A (en) * 2015-10-30 2016-02-03 深圳云聚汇数码有限公司 Timestamp-based network data access encryption method
CN105610907A (en) * 2015-12-18 2016-05-25 华夏银行股份有限公司 Server access method and device
CN105653720B (en) * 2016-01-07 2020-03-27 北京人大金仓信息技术股份有限公司 Flexibly configurable hierarchical database storage optimization method
CN106991276B (en) * 2017-03-17 2020-01-21 浙江大学 Data interface dynamic generation method based on openEHR template
CN107506369A (en) * 2017-07-06 2017-12-22 联动优势科技有限公司 A kind of data access method and equipment
CN107391622B (en) * 2017-07-06 2020-12-04 联动优势科技有限公司 Data access method and equipment
CN107577958B (en) * 2017-09-08 2020-09-15 中国联合网络通信集团有限公司 Privacy-removing opening method and device and privacy-removing data backtracking method and device
CN109818900B (en) * 2017-11-20 2021-11-26 阿里巴巴(中国)有限公司 Data management system and application server
CN109062960A (en) * 2018-06-26 2018-12-21 国电南瑞科技股份有限公司 Electric network model and real time data decoupling method in electric power scheduling automatization system
CN110008682B (en) * 2019-03-31 2020-12-29 西安邮电大学 Method for updating data in different types of storage media based on PKI
CN110287152A (en) * 2019-06-27 2019-09-27 深圳市腾讯计算机系统有限公司 A kind of method and relevant apparatus of data management
CN114189476B (en) * 2021-01-26 2023-12-08 长威信息科技发展股份有限公司 Multi-element interface shunting calling method and terminal
CN115712660B (en) * 2022-01-29 2023-05-30 杭州宇信数字科技有限公司 Data storage method, device, server and storage medium
CN117850329A (en) * 2022-05-17 2024-04-09 南京昇榕智能科技有限公司 PLC system, PLC data transmission method and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1496075A (en) * 2002-09-24 2004-05-12 Method for managing gateway configuration by gateway user
CN1599372A (en) * 2004-06-25 2005-03-23 港湾网络有限公司 Entity searching method of 802.1* identification based on media access control
CN1819555A (en) * 1999-07-30 2006-08-16 英特尔公司 Method of parsing a packet header and computer system

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7468968B2 (en) * 2002-10-15 2008-12-23 Telefonaktiebolaget Lm Ericsson (Publ) System and method for connecting peripheral devices to a supporting network through a mobile station

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1819555A (en) * 1999-07-30 2006-08-16 英特尔公司 Method of parsing a packet header and computer system
CN1496075A (en) * 2002-09-24 2004-05-12 Method for managing gateway configuration by gateway user
CN1599372A (en) * 2004-06-25 2005-03-23 港湾网络有限公司 Entity searching method of 802.1* identification based on media access control

Also Published As

Publication number Publication date
CN101958838A (en) 2011-01-26

Similar Documents

Publication Publication Date Title
CN101958838B (en) Data access method and device
CN107508795B (en) Cross-container cluster access processing device and method
CN111291079A (en) Data query method and device
CN101383839A (en) Data distribution system based on data server and implementation method
CN106503008B (en) File storage method and device and file query method and device
CN108228322B (en) Distributed link tracking and analyzing method, server and global scheduler
CN102333130A (en) Method and system for accessing cache server and intelligent cache scheduler
CN110022221A (en) A kind of monitoring method of system interface data, apparatus and system
CN112732756B (en) Data query method, device, equipment and storage medium
CN106790601A (en) The reading device of address of service, system and method
CN106202848A (en) The acquisition methods of medical image file, user terminal and master server
CN104468222A (en) Method, device and system for reporting log information
CN101521606A (en) Log information processing method, log server and communication system
CN105320676A (en) Customer data query service method and device
CN107277087B (en) Data processing method and device
CN114374965A (en) User subscription data processing method, system, device and medium
CN105471626A (en) Method and system for distributing storage data of internal memory
CN104391876A (en) Static data storing and querying method and system
CN103778258A (en) Method for sending and receiving data of database, client terminal and server
CN101957830A (en) System, device and method for inquiring lists
CN102216930A (en) Web request scheduling method and system
CN111859127A (en) Subscription method and device of consumption data and storage medium
CN102238505B (en) Method and system for processing multi-user parallel signalling tracking at client
CN113076380B (en) Data synchronization method, device, system, equipment and storage medium
CN107249017B (en) A kind of method and server obtaining HLS content by CDN network

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant