CN102855280B - A kind of Heterogeneous Data Processing method and apparatus - Google Patents

A kind of Heterogeneous Data Processing method and apparatus Download PDF

Info

Publication number
CN102855280B
CN102855280B CN201210271639.4A CN201210271639A CN102855280B CN 102855280 B CN102855280 B CN 102855280B CN 201210271639 A CN201210271639 A CN 201210271639A CN 102855280 B CN102855280 B CN 102855280B
Authority
CN
China
Prior art keywords
data
processing unit
business object
data fields
isomeric
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
CN201210271639.4A
Other languages
Chinese (zh)
Other versions
CN102855280A (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.)
Beijing Eren Eben Information Technology Co Ltd
Original Assignee
Beijing Eren Eben Information Technology 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 Beijing Eren Eben Information Technology Co Ltd filed Critical Beijing Eren Eben Information Technology Co Ltd
Priority to CN201210271639.4A priority Critical patent/CN102855280B/en
Publication of CN102855280A publication Critical patent/CN102855280A/en
Application granted granted Critical
Publication of CN102855280B publication Critical patent/CN102855280B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Stored Programmes (AREA)
  • Devices For Executing Special Programs (AREA)

Abstract

This application discloses a kind of Heterogeneous Data Processing method, described method comprises: set up corresponding many data fields processing unit based on isomeric data layer; Obtain the parameter information of described isomeric data layer; Described parameter information is mated, obtains corresponding many data fields processing unit; Described many data fields processing unit generates business object, and described business object comprises data manipulation object.Disclosed herein as well is a kind of Heterogeneous Data Processing device.The application is by the parameter of coupling isomeric data layer, find corresponding many data fields processing unit to generate business object, the process scene of isomeric data layer is simplified, the process details to many data fields can be avoided in the data Layer development phase, developer can flexible as developing the application of single data layer in the past, complete development easily, and can not the little detail brought by multiple domain scene disturb, ensure that the efficiency of exploitation.

Description

A kind of Heterogeneous Data Processing method and apparatus
Technical field
The application relates to a kind of data processing method, particularly relates to a kind of Heterogeneous Data Processing method and apparatus.
Background technology
The development of Internet technology, makes the application of data Layer more and more extensive, often can face the operational issue of isomeric data layer.Isomeric data layer refers to the set of a series of data manipulation objects of the identical or different realization following same-interface.Such as, ORACLE, SQL Server and MySQL etc., even as the data Layer of increasing income of MySQL mono-class, also have various implementation.In prior art, the ccf layer that operates in for isomeric data layer realizes, and writes often process code accordingly for a certain data Layer, these codes are constantly piled up, make logical boundary more and more unintelligible, mutual calling also seems chaotic, and development efficiency is low.
Summary of the invention
The application provides a kind of Heterogeneous Data Processing method and apparatus ensureing development efficiency.
According to the first aspect of the application, the application provides a kind of Heterogeneous Data Processing method, and described method comprises:
Corresponding many data fields processing unit is set up based on isomeric data layer;
Obtain the parameter information of described isomeric data layer;
Described parameter information is mated, obtains corresponding many data fields processing unit;
Described many data fields processing unit generates business object, and described business object comprises data manipulation object.
Wherein said many data fields processing unit generates business object and comprises: load data field configuration information; Business object is generated according to described data field configuration information.
Wherein saidly coupling is carried out to described parameter information comprise: the mode mapped by URL(uniform resource locator) is analyzed and mated.
Wherein also comprise the process that generated business object is shown.
Said process is by supertext pre-service language, JAVA, Python, any one is realized.
According to the second aspect of the application, the application provides a kind of Heterogeneous Data Processing device, and described device comprises:
Many data fields processing unit, described many data fields processing unit is corresponding with described isomeric data layer;
Matching unit, for obtaining the parameter information of described isomeric data layer, mates described parameter information, calls corresponding many data fields processing unit and processes;
Described many data fields processing unit is also for generating business object, and described business object comprises data manipulation object.
Wherein said many data fields processing unit, also for loading data field configuration information, generates business object according to described data field configuration information.
The mode of wherein said matching unit also for being mapped by URL(uniform resource locator) carries out analyzing and mating.
Said apparatus also comprises display unit, for showing the business object generated.
Said apparatus is also for by supertext pre-service language, JAVA, Python, any one realizes the generation of the business object of described isomeric data layer.
Owing to have employed above technical scheme, the beneficial effect that the application is possessed is:
In the embodiment of the application, by the parameter of coupling isomeric data layer, find corresponding many data fields processing unit to generate business object, the process scene of isomeric data layer is simplified, the process details to many data fields can be avoided in the data Layer development phase, developer can flexible as developing the application of single data layer in the past, complete development easily, and can not the little detail brought by multiple domain scene disturb, ensure that the efficiency of exploitation.
Accompanying drawing explanation
Fig. 1 is the process flow diagram of an embodiment according to the application's Heterogeneous Data Processing method;
Fig. 2 is the process flow diagram of another embodiment according to the application's Heterogeneous Data Processing method;
Fig. 3 is the structural representation of an embodiment according to the application's Heterogeneous Data Processing device;
Fig. 4 is the structural representation of another embodiment according to the application's Heterogeneous Data Processing device.
Embodiment
By reference to the accompanying drawings the application is described in further detail below by embodiment.
Embodiment one:
As shown in Figure 1, the Heterogeneous Data Processing method of the application, its a kind of embodiment, comprises the following steps:
Step 102: set up corresponding many data fields processing unit based on isomeric data layer; Such as to generate business object (BO:Business Object) for ORACLE data Layer will be operated, need to set up the many data fields processing unit corresponding to this ORACLE data Layer.
Step 104: the parameter information obtaining isomeric data layer; It should be appreciated by those skilled in the art that step 104 and step 102 can exchange order.
Step 106: mate parameter information, obtains corresponding many data fields processing unit;
Step 108: many data fields processing unit generates business object, and this business object comprises data manipulation object.
In one implementation, parameter information is mated in step 106, comprising: the mode being mapped (URL Mapping) by URL(uniform resource locator) carries out analyzing and mating.
In one implementation, step 108 specifically comprises: load data field configuration information; BO is generated according to data field configuration information.
We call BO data manipulation object.The configuration information of all BO that data field configuration information provides under comprising this territory, each BO specific configuration information depends on its bottom layer realization, can comprise for the BO that a data Layer realizes:
A1:BO realizes class;
A2: data Layer type;
A3: data Layer address and port;
A4: data Layer user name and password;
A5: data Layer coded format.
For one by the general distributed High-performance cache system of memcached() BO that realizes says and comprises:
B1:BO realizes class;
B2:memcached address, port;
B3: user name and password (optional).
Due to the diversity of BO implementation, the content in configuration information is also not quite similar, and it should be appreciated by those skilled in the art that the content in configuration information should support that this BO carries out the initial work of related resource, can design as required.
About the process generating BO, first the main points emphasized are: " business object of all instantiations must follow a unified interface, upper strata is used BO by this unified interface, and and be indifferent to the establishment of concrete BO and the process of loading ", the establishment of concrete BO is then that framework passes through to import configuration information into, call the building method that concrete BO realizes class to complete, BO related resource (data Layer handle, memcached connect etc.) initial work can construct time complete, also can be undertaken in initialized delays in work to concrete operational approach according to performance need.
BO specific implementation can be more flexible, the effect of BO provides calling of operational approach by unified interface to upper strata, BO on an ordinary meaning can comprise one or more data manipulation object (DAO), but also can support to be realized by non-DAO, or the complexity that DAO realizes in conjunction with other modes is formed.The realization of concrete BO is not subject to the restriction of framework, and developer can realize flexibly, and what framework was paid close attention to is the unified calling interface that these BO externally provide.
In one implementation, the process that the business object generated is shown also is comprised in the method for the application.This display obviously independent of generative process, so can obtain realizing irrelevant view object define method with concrete template engine, thoroughly can be removed the coupled relation of framework and template engine, makes developer in the selection of template engine, have larger degree of freedom.
In one implementation, the method for the application is by supertext pre-service language (PHP:Hypertext Preprocessor), JAVA, Python, any one is realized.It should be appreciated by those skilled in the art that those support that the language of script can realize the technical scheme of the application.
The concept of many data fields is that the demand scene of corresponding " application engine, a multiple data back-end " proposes, and its essence is and can operate multiple isomeric data layer.Under the support of above-described embodiment, developer can be flexible as developing the application of single data layer in the past, complete development easily, and can not the little detail brought by many data fields territory scene disturb, ensure that the efficiency of exploitation, even when tackling the demand scene of forms data rear end, many data fields framework is research and development, test, produce the benefit that each stage brings isolation, this is embodied in production data territory and is separated with test data territory, developer can under the prerequisite not disturbing production data, test to applied logic and adjustment work is completed based on test data.
Be different from framework just simple proposition ORM(and Object-Relational Mapping in the past, Object Relation Mapping) scheme and clearly do not propose the concept of business object, simple ORM scheme cannot meet complicated application demand, these application demands pay close attention to the concept possessing the business object of unified operation interface, the specific implementation of business object does not then limit, after business object has configured by many data fields, framework is responsible for miscellaneous service subjects transparent to be injected in web services process, with other frame assembly collaborative work, this transparent refer to many data fields processing unit developer transparent, which BO they use without the need to paying close attention to themselves.
Fig. 2 illustrates the process flow diagram of the another kind of embodiment according to the application's Heterogeneous Data Processing method, this embodiment is implemented on PHP language, also portable is on other web development languages, such as: Java, Python etc., the present embodiment uses the Smarty view engine by default of PHP, it should be appreciated by those skilled in the art, other template engine also can be used to realize, such as templatelite, php-sugar etc.Use PHP language to generate business object, fully can meet complicated demand compared to ORM.
Step 202: system initialization, creates the configuration information of BO;
Step 204: send Heterogeneous Data Processing request, this process request contains the parameter information of many data fields, and this information can be embodied as a character string, by various ways transmission such as http parameters, adopts following mode in this example:
URL:/controller/action/param1/param2
In this example, many data fields processing unit is embodied as controller class, and this controller class comprises action method, and param1, param2 are the parameter transmitted.This information also can be transmitted by the form of http header value.
Step 206: obtain this request by index.php script.
Step 208: mated by the PHP class of responsible reception and assignment request of access, dispatcher is embodied as in this example, dispatcher resolves most according to field parameter, again http request of access is undertaken analyzing and mating by URLMapping rule, find corresponding many data fields processing unit to process.Parameter in http request can be passed to controller with the form of action method parameter by dispatcher.
Such as, there is http request: GET/test/hello HTTP/1.1, X-Domain:web
After entering dispatcher, control class TestController (supposing that TestController has business object class title boGreeting to be implanted) is looked for by first order directory name test according to set matched rule, instantiation it, this time domain parameter is web, then find the relevant configuration information of GreetingBO under web territory, instantiation GreetingBO is also injected into TestController.boGreeting attribute, then finds control method hello () by second level directory name hello at TestController according to set coupling and calls the method.Framework also reserved by URL pattern match to " control class. control method " extension point.
Step 210: create the many data field processing unit corresponding with each isomeric data layer.In the present embodiment, many data fields processing unit is embodied as controller class, specifically controller class corresponds to the action method of different structure isomeric data layer, those skilled in the art should understand that, corresponding can be embodied as different classes, or other mode, such as function, subroutine etc.Controller class, according to the class title meeting the BO of injection condition of statement, builds the BO meeting this data field in isomeric data layer.In the present embodiment, this injection condition is embodied as the rule by Property Name agreement.BO represents the data Layer object under this data field, the configuration information of these BO creates when system initialization, and these configuration informations can be found by the data field parameter imported into, thus carry out instantiation when needs, such as: have business object MessageCenter, data field A is configured to the MysqlMessageCenter realized by Mysql, data field B is configured to the MongoMessageCenter realized by Mongodb, when the majority of asking to carry is B according to field parameter, framework is responsible for instantiation MongoMessageCenter and is injected.
After step 212:controller->action is finished, to a view object (VO:View Object) described with PHP array structure be returned to dispatcher, the definition of view object is irrelevant with realization, and dispatcher is responsible for resolving this view object and is submitted to view engine and completes the tasks such as last page output.
Step 214:Smarty is responsible for playing up and shows with the page.
The application is by the generation of business object and being separated of display, and releasing framework is coupled with template engine, improves the flexibility ratio of exploitation.
Embodiment two:
As shown in Figure 3, the Heterogeneous Data Processing device of the application, its a kind of embodiment, comprises many data fields processing unit and matching unit, and many data fields processing unit is corresponding with isomeric data layer, and each many data fields processing unit may correspond to an isomeric data layer; Matching unit, for obtaining the parameter information of isomeric data layer, mates parameter information, calls corresponding many data fields processing unit and processes; Many data fields processing unit is for generating business object, and this business object comprises data manipulation object.
In one embodiment, this many data fields processing unit, also for loading data field configuration information, generates business object according to data field configuration information.
In one embodiment, the mode of this matching unit also for being mapped by URL(uniform resource locator) carries out analyzing and mating.
In one embodiment, this device also comprises display unit, for showing the business object generated.
In one embodiment, this device is also for by PHP, JAVA, Python, any one realizes the generation of the business object of isomeric data layer.
Fig. 4 illustrates the structural representation of a kind of instantiation according to the application's Heterogeneous Data Processing device, this embodiment is based on the method shown in Fig. 2, its core component is the PHP class of being responsible for receiving and assigning request of access: dispatcher, it achieves the function of matching unit.Also comprise the controller class for generating BO, such comprises action method, in the present embodiment, each action method corresponds to a kind of BO, those skilled in the art should understand that, also can be embodied as the controller class corresponding to each BO or other implementation, such as function, subroutine etc., and for show Smarty class, for receiving the Index.php of request.The workflow of these classes, with reference to the embodiment shown in figure 2, repeats no more here.
Above content is the further description done the application in conjunction with concrete embodiment, can not assert that the concrete enforcement of the application is confined to these explanations.For the application person of an ordinary skill in the technical field, under the prerequisite not departing from the application's design, some simple deduction or replace can also be made, all should be considered as the protection domain belonging to the application.

Claims (10)

1. a Heterogeneous Data Processing method, is characterized in that, described method comprises:
Set up corresponding many data fields processing unit based on isomeric data layer, described isomeric data layer refers to that a series of data manipulations of the identical or different realization following same-interface are to the set of picture;
Obtain the parameter information of described isomeric data layer;
Described parameter information is mated, obtains corresponding many data fields processing unit;
Described many data fields processing unit generates the business object possessing unified interface, and described business object comprises data manipulation object.
2. the method for claim 1, is characterized in that, described many data fields processing unit generates business object and comprises:
Load data field configuration information;
Business object is generated according to described data field configuration information.
3. the method for claim 1, is characterized in that, describedly carries out coupling to described parameter information and comprises:
The mode mapped by URL(uniform resource locator) carries out analyzing and mating.
4. the method for claim 1, is characterized in that, also comprises the process shown generated business object.
5. the method as described in as arbitrary in Claims 1-4, it is characterized in that, described method is by supertext pre-service language, JAVA, Python, any one is realized.
6. a Heterogeneous Data Processing device, is characterized in that, described device comprises:
Many data fields processing unit, described many data fields processing unit is corresponding with isomeric data layer, and described isomeric data layer refers to that a series of data manipulations of the identical or different realization following same-interface are to the set of picture;
Matching unit, for obtaining the parameter information of described isomeric data layer, mates described parameter information, calls corresponding many data fields processing unit and processes;
Described many data fields processing unit is also for generating the business object possessing unified interface, and described business object comprises data manipulation object.
7. device as claimed in claim 6, is characterized in that, described many data fields processing unit, also for loading data field configuration information, generates business object according to described data field configuration information.
8. device as claimed in claim 6, it is characterized in that, the mode of described matching unit also for being mapped by URL(uniform resource locator) carries out analyzing and mating.
9. device as claimed in claim 6, is characterized in that, also comprise display unit, for showing the business object generated.
10. the device as described in as arbitrary in claim 6 to 9, is characterized in that, described device is also for by supertext pre-service language, JAVA, Python, any one realizes the generation of the business object of described isomeric data layer.
CN201210271639.4A 2012-07-31 2012-07-31 A kind of Heterogeneous Data Processing method and apparatus Active CN102855280B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210271639.4A CN102855280B (en) 2012-07-31 2012-07-31 A kind of Heterogeneous Data Processing method and apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210271639.4A CN102855280B (en) 2012-07-31 2012-07-31 A kind of Heterogeneous Data Processing method and apparatus

Publications (2)

Publication Number Publication Date
CN102855280A CN102855280A (en) 2013-01-02
CN102855280B true CN102855280B (en) 2015-10-21

Family

ID=47401868

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210271639.4A Active CN102855280B (en) 2012-07-31 2012-07-31 A kind of Heterogeneous Data Processing method and apparatus

Country Status (1)

Country Link
CN (1) CN102855280B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105808534B (en) * 2014-12-27 2019-06-11 株洲中车时代电气股份有限公司 A kind of method that isomeric data merges extraction initial data in file
WO2019183918A1 (en) * 2018-03-30 2019-10-03 Beijing Yi Zhang Yun Feng Technology Co., Ltd. Cross-domain mapped compound network instruction system
CN110502662A (en) * 2019-08-23 2019-11-26 南京信易达计算技术有限公司 A kind of Heterogeneous Data Processing system and method

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1093060A2 (en) * 1999-10-14 2001-04-18 Dharma Systems, Inc. SQL interface for business application software
CN101114226A (en) * 2007-08-28 2008-01-30 北京中企开源信息技术有限公司 Code automatically generating device based on model component, system and method
CN101281466A (en) * 2008-05-27 2008-10-08 北京中企开源信息技术有限公司 Service object modeling method based on service main body characteristic

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP1093060A2 (en) * 1999-10-14 2001-04-18 Dharma Systems, Inc. SQL interface for business application software
CN101114226A (en) * 2007-08-28 2008-01-30 北京中企开源信息技术有限公司 Code automatically generating device based on model component, system and method
CN101281466A (en) * 2008-05-27 2008-10-08 北京中企开源信息技术有限公司 Service object modeling method based on service main body characteristic

Also Published As

Publication number Publication date
CN102855280A (en) 2013-01-02

Similar Documents

Publication Publication Date Title
CA2915619C (en) Method and apparatus for customized software development kit (sdk) generation
US10331422B1 (en) System and method for generating API devlopment code for integrating platforms
CN111580820B (en) Applet generation method and device
CN108415710B (en) The method and system of API is issued, called in Intelligent dialogue development platform
US9747353B2 (en) Database content publisher
US20160050128A1 (en) System and Method for Facilitating Communication with Network-Enabled Devices
AU2023251465A1 (en) System and method for generating api development code for integrating platforms
CN101976199A (en) Object-oriented middleware distributed system development platform
Rajam et al. E-learning computational cloud (elc2): Web services platform to enhance task collaboration
Kim Development of Mobile Cloud Applications using UML.
CN106230889B (en) resource management method and system for mobile application service components
CN103957255A (en) Lightweight application development cloud service platform and method for having access to resources thereof
CN102855280B (en) A kind of Heterogeneous Data Processing method and apparatus
Farwick et al. A web-based collaborative metamodeling environment with secure remote model access
CN102638572B (en) Short-message sending service system based on Web Element mechanism and operating method thereof
CN105847319A (en) Mobile terminal network request method and system
Hernandez-Mendez et al. A Model-driven Approach for Generating RESTful Web Services in Single-Page Applications.
CN101409731A (en) Remote control method for household electrical equipment through IE
Vinoski Convenience over correctness
KR101190597B1 (en) Method port apparatus and composition method for robot software component
Sefid‐Dashti et al. A reference architecture for mobile SOA
CN109976713A (en) Script processing method and device for Service Assembly
KR20210040333A (en) Request processing method, apparatus, device and computer storage medium
Benmerar et al. Toward a cloud architecture for medical imagery grid applications: The acigna-g project
Bryksin et al. Ubiq Mobile+ QReal a Technology for Development of Distributed Mobile Services

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