CN107085570A - Data processing method, application server and router - Google Patents
Data processing method, application server and router Download PDFInfo
- Publication number
- CN107085570A CN107085570A CN201610084423.5A CN201610084423A CN107085570A CN 107085570 A CN107085570 A CN 107085570A CN 201610084423 A CN201610084423 A CN 201610084423A CN 107085570 A CN107085570 A CN 107085570A
- Authority
- CN
- China
- Prior art keywords
- business object
- data
- tables
- logical partition
- application server
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Granted
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F16/00—Information retrieval; Database structures therefor; File system structures therefor
- G06F16/20—Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
- G06F16/22—Indexing; Data structures therefor; Storage structures
- G06F16/2282—Tablespace storage structures; Management thereof
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Software Systems (AREA)
- Data Mining & Analysis (AREA)
- Databases & Information Systems (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
Abstract
The embodiment of the present invention provides a kind of data processing method, application server and router.The data processing method of the present invention may include:Application server receives business object request to create message;Business object request to create message includes the type of business object;Application server determines that the corresponding logical partition of business object is encoded according to the type of business object;Application server generates at least one tables of data of business object;Wherein, the major key of each tables of data includes the corresponding logical partition coding of business object, and the corresponding logical partition coding of business object is corresponding with database.The embodiment of the present invention can improve the efficiency of data processing, improve the performance of the achievable business function of data processing.
Description
Technical field
The present embodiments relate to data processing technique, more particularly to a kind of data processing method, using clothes
Business device and router.
Background technology
With widely available, increasing memory data output and the visit capacity of the Internet, applications so that number
Increasing according to the data volume stored in storehouse, the access pressure of database is increasing, i.e., data access please
The amount of asking is increasing.The data access request of magnanimity so that the load of the computer where database is higher,
This gives the stability and autgmentability of the operation system for including database place computer to cause very big ask
Topic.
It can be located at for the database of a service application on a computer, can be by by this
The database of service application is divided into multiple databases of a service application by level point storehouse, should
Multiple databases can be located on different computers respectively, so as to reduce the load of single computer, reduce
The damage that single computer is brought due to the overburden machine of delaying.For the data processing of a service application,
Can be sent data access request into router by application server, the number is determined by the router
Corresponding database is route according to access request, and the data access request is sent to the data access request
The processor of computer where corresponding database, is carried out by the processor according to the data access request
Processing.The application server can be point storehouse field included according to the data access request, and this is counted
Routed to according to access request on the corresponding database of this point of storehouse field.That is, the data processing method
In, either must all have a point storehouse field, the application server in data access request or tables of data
It can just be route.To simplify the data processing method, the major key of tables of data can be regard as a point storehouse field.
, can be according to the tables of data of the business object if the business object to service application carries out data processing
Major key determine corresponding database, then carry out data processing.
However, a business object can have multiple tables of data, the major key of different pieces of information table is different, different
A point storehouse field can correspond to different databases, if the major key of tables of data may be such that as a point storehouse field
The corresponding database of different pieces of information table of one business object is different.If carrying out data to a business object
Processing, it is understood that there may be the inter-library processing of multiple databases so that data processing it is less efficient, so as to drop
The performance for the business function that low data processing is realized.
The content of the invention
The embodiment of the present invention provides a kind of data processing method, application server and router, to improve number
According to the efficiency of processing, the performance of business function is improved.
The embodiment of the present invention provides a kind of data processing method, including:
Application server receives business object request to create message;Business object request to create message includes industry
The type of business object;
Application server determines that the corresponding logical partition of business object is encoded according to the type of business object;
Application server generates at least one tables of data of business object;Wherein, the major key of each tables of data
Including the corresponding logical partition coding of business object, the corresponding logical partition coding of business object and database
Correspondence.
In the data processing method provided in an embodiment of the present invention, because the major key of each tables of data includes
The corresponding logical partition coding of the business object, the corresponding logical partition coding of the business object can be with data
Storehouse correspondence, thus, all tables of data of the business object can correspond to same database, to the business pair
Be not in the inter-library processing of multiple databases during carrying out data processing, improve data processing
Efficiency, improve the achievable business function of data processing performance.
Also, the major key of each tables of data includes the corresponding logical partition coding of the business object, should
The corresponding logical partition coding of business object can be corresponding with database, thus to the tables of data of the business object
When recorded data conducts interviews, without in the tables of data of data access request message and database
The extra point storehouse field of addition, can simplify the implementation process of business function, so as to simplify opening for business function
Hair and maintenance, reduce the development and maintenance cost of business function.
Optionally, application server determines the corresponding logic coding of business object according to the type of business object,
Including:
Application server is according to the type and default business object type of business object with dividing storehouse field
Corresponding relation, determines corresponding point of storehouse field of business object;
Application server determines the corresponding logical partition of business object according to corresponding point of storehouse field of business object
Coding.
Optionally, application server generates at least one tables of data of business object, including:
Application server generates the sequential value of tables of data, and sequential value is used to uniquely identify in a tables of data
One record;
Sequential value logical partition coding corresponding with business object is combined by application server;
Application server is created is combined as major key with sequential value logical partition coding corresponding with business object
The tables of data.
Optionally, at least one tables of data includes the main table and relation sublist of business object;This method may be used also
Including:
Application server adds business pair during production Methods sublist in the external key of relation sublist
As corresponding logical partition coding.
Optionally, the external key of logical partition coding is added to be used for the father of points relationship sublist in relation sublist
The external key of table.
The embodiment of the present invention also provides a kind of data processing method, including:
Router receives the data access request message that application server is sent;Data access request message with
Major key in the tables of data of business object is access consideration;Major key includes the corresponding logical partition of business object
Coding and the sequential value for the record in unique mark data table;
Router splits out logical partition coding from major key, and tables of data institute is determined according to logical partition coding
Database;
Router sends data access request message the database to where tables of data, and sequential value is marked
The record of knowledge conducts interviews.
In the data processing method provided in an embodiment of the present invention, without in data access request message and
Extra point storehouse field is added in the tables of data of database, the implementation process of business function can be simplified, so that
Simplify the exploitation and maintenance of business function, reduce the development and maintenance cost of business function.
Optionally, router encodes the database where determining tables of data according to logical partition, can include:
Router is encoded according to logical partition, and, default logical partition coding is corresponding with database to close
System, determines the database where tables of data.
Optionally, data access request message also includes access type;Access type include data query,
Data modification and/or data are deleted.
Optionally, data access request message is the access request message of structuralized query voice SQL statement.
The embodiment of the present invention also provides a kind of application server, including:
Receiving module, for receiving business object request to create message;Business object request to create message package
Include the type of business object;
Determining module, for determining that the corresponding logical partition of business object is encoded according to the type of business object;
Generation module, at least one tables of data for generating business object;Wherein, each tables of data
Major key includes:Business object corresponding logical partition coding, the corresponding logical partition coding of business object with
Database correspondence.
Optionally, determining module, is additionally operable to the type and default business object class according to business object
The corresponding relation of type and point storehouse field, determines corresponding point of storehouse field of business object;According to business object pair
Point storehouse field answered determines the corresponding logical partition coding of business object.
Optionally, generation module, is additionally operable to generate the sequential value of tables of data, and sequential value is used to uniquely mark
Know a record in a tables of data;Sequential value logical partition coding corresponding with business object is carried out
Combination;Create with the number for being combined as major key of sequential value logical partition coding corresponding with business object
According to table.
Optionally, at least one tables of data includes the main table and relation sublist of the business object;
Generation module, is additionally operable to during production Methods sublist, is added in the external key of relation sublist
The corresponding logical partition coding of business object.
The embodiment of the present invention also provides a kind of router, including:
Receiving module, the data access request message for receiving application server transmission;Data access please
Message is sought using the major key in the tables of data of business object as access consideration;It is corresponding that major key includes business object
Logical partition is encoded and the sequential value for the record in unique mark data table;
Determining module, for splitting out logical partition coding from major key, encodes according to logical partition and determines
Database where tables of data;
Sending module, for data access request message to be sent to the database to where tables of data, to sequence
The record that train value is identified conducts interviews.
Optionally, determining module, is additionally operable to be encoded according to logical partition, and, default logical partition is compiled
The corresponding relation of code and database, determines the database where tables of data.
The embodiment of the present invention also provides a kind of application server, including processor, memory, communication interface
And bus;Wherein, processor is connected with memory, communication interface by bus;
Memory is used for store instruction;
Processor is used for execute instruction, when the instruction of computing device memory storage so that processor
Perform any data processing method that above-mentioned application server is performed.
The embodiment of the present invention also provides a kind of router, including:Processor, memory, communication interface and
Bus;Wherein, processor is connected with memory, communication interface by bus;
Memory is used for store instruction;
Processor is used for execute instruction, when the instruction of computing device memory storage so that processor
Perform any data processing method performed by above-mentioned router.
The embodiment of the present invention provides a kind of data processing method, application server and router, application service
Device can determine the business according to the type of the business object in the business object request to create message received
The corresponding logical partition coding of object, and the major key of at least one tables of data of the business object is generated, its
In, the major key of each tables of data may include the corresponding logical partition coding of the business object, the business pair
As corresponding logical partition coding is corresponding with database.In the data processing method of the embodiment of the present invention, by
Include the corresponding logical partition coding of the business object in the major key of each tables of data of business object, should
The corresponding logical partition coding of business object can be corresponding with database, thus, all numbers of the business object
Same database can be corresponded to according to table, during carrying out data processing to the business object, is not in
The inter-library processing of multiple databases, improves the efficiency of data processing, improves the achievable business of data processing
The performance of function.
Brief description of the drawings
In order to illustrate more clearly about the embodiment of the present invention or technical scheme of the prior art, below will be to reality
The accompanying drawing used required for applying in example or description of the prior art does one and simply introduced, it should be apparent that, under
Accompanying drawing in the description of face is some embodiments of the present invention, for those of ordinary skill in the art,
On the premise of not paying creative labor, other accompanying drawings can also be obtained according to these accompanying drawings.
The Organization Chart for the network system that Fig. 1 is applicable by various embodiments of the present invention;
Fig. 2 is a kind of flow chart for data processing method that the embodiment of the present invention one is provided;
Fig. 3 is the schematic diagram of the tables of data of business object in the embodiment of the present invention two;
Fig. 4 is the flow chart for another data processing method that the embodiment of the present invention two is provided;
Fig. 5 is a kind of structural representation for application server that the embodiment of the present invention three is provided;
Fig. 6 is a kind of structural representation for router that the embodiment of the present invention four is provided;
Fig. 7 is a kind of structural representation for application server that the embodiment of the present invention five is provided;
Fig. 8 is a kind of structural representation for router that the embodiment of the present invention six is provided.
Embodiment
To make the purpose, technical scheme and advantage of the embodiment of the present invention clearer, below in conjunction with this hair
Accompanying drawing in bright embodiment, the technical scheme in the embodiment of the present invention is clearly and completely described,
Obviously, described embodiment is a part of embodiment of the invention, rather than whole embodiments.It is based on
Embodiment in the present invention, those of ordinary skill in the art are obtained under the premise of creative work is not made
The every other embodiment obtained, belongs to the scope of protection of the invention.
Service application of the data processing method that various embodiments of the present invention are provided suitable for operation system
Data are handled.The data of the service application can for the service application business object tables of data in
Data, the tables of data of the business object can be located in database.One service application may include at least one
Individual business object, each business object may include at least one tables of data.Fig. 1 is various embodiments of the present invention
The Organization Chart for the network system being applicable.As shown in figure 1, the applicable network system of various embodiments of the present invention
In may include application server 101, router 102 and storage device 103.Each storage device 103 is wrapped
Include at least one database.The storage device 103 can be computer equipment.The application server 101
In may include Object Relation Mapping (Object/Relation Mapping, abbreviation ORM) middleware, use
To realize the mapping of object and relation data.Wherein, the object and the relation data be Business Entity not
The same form of expression, the Business Entity shows as object in internal memory, Business Entity table in database
It is now relation data.The router 102 can be set positioned at independent physics respectively with application server 101
In standby.The router 102 can be used as two independences in a physical equipment with the application server 101
Processing module.The router 102 can be the equipment in point storehouse route processing layer.Wherein, the road
Can be to be connected with the application server 101 by device 102.The router 102 can also with this at least one
Storage device 103 is connected.
Fig. 2 is a kind of flow chart for data processing method that the embodiment of the present invention one is provided.This method can be by
Application server 101 in Fig. 1 as described above is performed.As shown in Fig. 2 this method may include:
S201, application server receive business object request to create message;The business object request to create disappears
Breath includes:The type of business object.
Specifically, the business object request to create message can be a business object of a service application
Corresponding request to create message.The business object can be corresponding with a business function of the service application
Business object.It may also include in the business object request to create message:The attribute information of the business object.
For example, the type of the business object can be for example student, and the attribute information of the business object is for example
Can be the information such as achievement, class, student number.
S202, the application server determine the corresponding logic of the business object according to the type of the business object
Zonal coding.
Specifically, different types of business object, the type of business object is different, then different types of industry
The corresponding logical partition coding of business object is also different.
Wherein, logical partition coding can be divided by a pre-defined point storehouse field.For example,
It can be one-level point storehouse field, the corresponding pass that the default point of storehouse field is encoded with logical partition to divide storehouse field
System for example can be as shown in table 1 below:
Table 1
Divide storehouse field (initial value) | Divide storehouse field (cutoff) | Logical partition is encoded |
0201 | 0202 | 1101 |
0201 | 0202 | 1102 |
0203 | 0204 | 1103 |
If corresponding point of storehouse field of the business object is 0201-0202, the corresponding logic point of the business object
Area's coding can be 1101;If corresponding point of storehouse field of the business object is 0203-0204, the business
The corresponding logical partition coding of object can be 1103.
Corresponding point of storehouse field of the business object can be two fraction storehouse fields, the default point of storehouse field with
The corresponding relation of logical partition coding for example can be as shown in table 2 below:
Table 2
If corresponding point of storehouse field 1 of the business object is 0201-0202, point storehouse field is 0000-5555,
Then the corresponding logical partition coding of the business object can be 1101;If corresponding point of storehouse word of the business object
Section 1 is 0201-0202, and point storehouse field is 6666-9999, then the corresponding logical partition of the business object is compiled
Code can be 1102;If corresponding point of storehouse field 1 of the business object is 0203-0204, a point storehouse field is
0000-9999, then the corresponding logical partition coding of the business object can be 1103.
It should be noted that corresponding point of storehouse field of the business object can also be other many fraction storehouses fields,
It will not be repeated here.
In addition, different types of business object has different point storehouse fields.Wherein, the class of business object
The corresponding relation of type and point storehouse field can divide defined in the field meta data file of storehouse.
In the S202 of embodiment as described above, application server is determined according to the type of the business object should
The corresponding logical partition coding of business object, it may include:Application server can be according to the class of business object
The corresponding relation of business object type and point storehouse field defined in type and point storehouse field meta data file,
Determine corresponding point of storehouse field of the business object.The application server is according to corresponding point of storehouse of the business object
Field determines the corresponding logical partition coding of the business object.
S203, the application server generate at least one tables of data of the business object;Wherein, per number
Include according to the major key of table:The corresponding logical partition coding of the business object;The corresponding logic of the business object
Zonal coding is corresponding with database.
Specifically, if the number of the tables of data of the business object is 1, a tables of data can be should
The main table of business object.If the number of the tables of data of the business object is multiple, the plurality of tables of data bag
Include:One main table of the business object, at least one relation sublist of the business object.
Specifically, the application server of this in S203 generates the process of the tables of data of the business object, it can wrap
Include:
The application server generates the sequential value of tables of data, and the sequential value is used to uniquely identify a data
A record in table;
Sequential value logical partition coding corresponding with the business object is combined by the application server;
The application server is created with the combination of sequential value logical partition coding corresponding with the business object
For the tables of data of major key.
Specifically, the application server can for example generate the sequential value of each tables of data according to serial device.
Therefore, the sequential value of different pieces of information table can be different.The application server for example can be using default suitable
Sequence, logical partition coding corresponding with the business object to the sequential value is combined.Preset order example
It can such as be encoded for the corresponding logical partition of the business object in preceding, the posterior arrangement mode of the sequential value.
It should be noted that the preset order can be also other modes, it will not be repeated here.
Fig. 3 is the schematic diagram of the tables of data of business object in the embodiment of the present invention two.For example, as schemed
Shown in 3, the tables of data of the business object may include:5 tables of data.5 tables of data include:Main table,
Relation sublist 1, relation sublist 2 and relation sublist 21.Wherein, main table is relation sublist 1 and closed
It is the parent table of sublist 2, relation sublist 2 is the parent table of relation sublist 21.
If the corresponding logical partition of the business object is encoded to 1101, the sequential value of main table is
1000000000000001, then the application server can be by 1101 and 1000000000000001 carry out groups
Close, create with the 10011000000000000001 main tables for major key;If the sequence code of relation sublist 1 is
1000000000000789, then the application server can be by 1101 and 1000000000000789 carry out groups
Close, create with the 10011000000000000789 relation sublists 1 for major key;If the sequence of relation sublist 2
Row code is 1000000000000790, then the application server can be by 1101 and 1000000000000790
It is combined, creates with the 10011000000000000790 relation sublists 2 for major key;If relation sublist
21 sequence code is 10000000000008744, then the application server can be by 1101 Hes
10000000000008744 are combined, and create with 100110000000000008744 passes for major key
It is sublist 21.
Optionally, at least one tables of data includes the main table and relation sublist of the business object;This method
It may also include:
The application server is added during the relation sublist is generated in the external key of the relation sublist
The corresponding logical partition coding of the business object.
The external key of logical partition coding is added to be used for the father for pointing to the relation sublist in the relation sublist
The external key of table.
For example, in the Fig. 3, main table is the parent table of relation sublist 1 and relation sublist 2, relator
Table 2 is the parent table of relation sublist 21.So the application server generate the relation sublist 1 during,
The corresponding logical partition coding of the business object, relation sublist 1 are also added in the external key of relation sublist 1
In be used for points relationship sublist 1 parent table external key can be 10011000000000000001;The application
Server also adds the business during the relation sublist 2 is generated in the external key of relation sublist 2
It is used for the external key of the parent table of points relationship sublist 2 in the corresponding logical partition coding of object, relation sublist 2
Can be 10011000000000000001;The application server is generating the process of the relation sublist 21
In, the corresponding logical partition coding of the business object, relator are also added in the external key of relation sublist 21
External key in table 21 for the parent table of points relationship sublist 21 can be 10011000000000000790.
The logical partition that the major key of each tables of data of the business object includes the business object is encoded, also
It is to say, the major key logical partition including the business object of all tables of data of the business object is encoded,
There is the major key of the different pieces of information table of the business object the corresponding logical partition of the identical business object to compile
Code.Because the corresponding logical partition coding of the business object is corresponding with database, the business object is corresponding
The corresponding database of logical partition coding can be the corresponding physical database of the business object.The industry
The corresponding physical database of business object for example can be the database to the corresponding service application of the business object
Behind carry out level point storehouse, obtained horizontal cutting divided data storehouse divides being located at for the obtained business object
Database in one storage device.
The data processing method that the embodiment of the present invention one is provided, application server can be according to the business received
The type of the business object in Object Creation request message determines that the corresponding logical partition of the business object is compiled
Code, and at least one tables of data of business object is generated, wherein, the major key of each tables of data may include this
The corresponding logical partition coding of business object, the corresponding logical partition coding of the business object and database pair
Should.In the data processing method of the embodiment of the present invention, because the major key of each tables of data of business object is equal
Including the business object corresponding logical partition coding, the corresponding logical partition coding of the business object can be with
Database correspondence, thus, all tables of data of the business object can correspond to same database, to the industry
It is engaged in during object progress data processing, being not in the inter-library processing of multiple databases, improving data
The efficiency of processing, improves the performance of the achievable business function of data processing.
Optionally, the embodiment of the present invention two also provides a kind of data processing method.Fig. 4 is implemented for the present invention
The flow chart for another data processing method that example two is provided.As shown in figure 4, this method is any of the above-described
On the basis of method described in embodiment, it may also include:
S401, the application server receive data access request message;The data access request message is with this
Major key in the tables of data of business object is access consideration, and the major key includes the corresponding logic of the business object
Zonal coding and the sequential value for uniquely identifying the record in the tables of data.
Specifically, the data access request message can be represented with the corresponding processing code of router.If the road
It is a point storehouse route code by the corresponding processing code of device, then the data access request message can be this point of storehouse
The corresponding access request message of route code, such as structuralized query voice (Structured Query
Language, abbreviation SQL) the corresponding access request message of sentence.
S402, the application server send the data access request message to router.
S403, the router split out logical partition coding from the major key, are compiled according to the logical partition
Code determines the database where the tables of data.
Specifically, the router can be according to default routing rule, and the logical partition is encoded, to this
Data access request message is route, that is, determines the database where the tables of data.For example, should
Default routing rule can be represented by routing table.It may include in the default routing rule:At least one
Logical partition encodes the corresponding relation with database.
Optionally, the router determines the tables of data according to logical partition coding in S403 as described above
The database at place can include:
The router is encoded according to the logical partition, and, pair of default logical partition coding and database
It should be related to, determine the database where the tables of data.
Specifically, the corresponding relation of logical partition coding and database can be represented by routing table, the road
It may include the corresponding relation of at least one logical partition coding and database in table.The routing table can be
It is as shown in table 3 below.
Table 3
Divide storehouse field (initial value) | Divide storehouse field (cutoff) | Logical partition is encoded | Database |
0201 | 0202 | 1101 | P1 |
0201 | 0202 | 1102 | P2 |
0203 | 0204 | 1103 | P3 |
Wherein, the corresponding database of business object can pass through the Physical Extents where database in the routing table
Mark is represented.If the logical partition is encoded to 1101, router can determine that the data where the tables of data
Storehouse is the database on Physical Extents P1;If the logical partition is encoded to 1102, the router can be true
Database where the fixed tables of data is the database on Physical Extents P2;If the logical partition is encoded to
1103, then the database where the router can determine that the tables of data is the database on Physical Extents P3.
Optionally, the data access request message may also include:Access type;The access type includes:
Data query, data modification and/or data are deleted.
Optionally, the data access request message can be the corresponding access request message of SQL statement.
S404, the router send the data access request message to the database where the tables of data,
The record that the sequential value is identified is conducted interviews.
The data processing method that the embodiment of the present invention two is provided, application server also visits the data received
Ask that request message is sent to router so that the router can from the data access request message industry
Logical partition coding is split out in the major key of the tables of data of business object, is then encoded according to the logical partition true
Database where the fixed tables of data, and the data access request message is sent to where the tables of data
The record that database is identified with the sequential value in the tables of data conducts interviews, and realizes business object correspondence
Business function.In method provided in an embodiment of the present invention, due to without data access request message with
And extra point storehouse field is added in the tables of data of database, the implementation process of business function can be simplified, from
And simplify the exploitation and maintenance of business function, reduce the development and maintenance cost of business function.
The present invention implements three and provides a kind of application server.Fig. 5 is one kind that the embodiment of the present invention three is provided
The structural representation of application server.As shown in figure 5, the application server 500 may include:Receive mould
Block 501, determining module 502 and generation module 503.
Receiving module 501, for receiving business object request to create message;The business object request to create
Message includes the type of business object.
Determining module 502, for determining the corresponding logic of the business object according to the type of the business object
Zonal coding.
Generation module 503, at least one tables of data for generating the business object;Wherein, per number
Include the corresponding logical partition coding of the business object, the corresponding logic point of the business object according to the major key of table
Area's coding is corresponding with database.
Optionally, determining module 502, are additionally operable to the type and default business according to the business object
The corresponding relation of object type and point storehouse field, determines corresponding point of storehouse field of the business object;According to this
Corresponding point of storehouse field of business object determines the corresponding logical partition coding of the business object.
Optionally, generation module 503, are additionally operable to generate the sequential value of each tables of data, and the sequential value is used
In uniquely identifying one in each tables of data record;The sequential value is corresponding with the business object
Logical partition coding is combined;Create and encoded with sequential value logical partition corresponding with the business object
The each tables of data for being combined as major key.
Optionally, at least one tables of data includes the main table and relation sublist of the business object;
Generation module 503, is additionally operable to during the relation sublist is generated, in the outer of the relation sublist
The corresponding logical partition coding of the business object is added in key.
The application server that the embodiment of the present invention three is provided, available for any application in execution above-described embodiment
Data processing method performed by server, beneficial effect is similar to the above embodiments, will not be repeated here.
The embodiment of the present invention four also provides a kind of router.Fig. 6 is one kind that the embodiment of the present invention four is provided
The structural representation of router.As shown in fig. 6, router 600 may include receiving module 601, determination
Module 602 and sending module 603.
Receiving module 601, the data access request message for receiving application server transmission;The data
Access request message is using the major key in the tables of data of business object as access consideration;The major key includes:The industry
The corresponding logical partition coding of business object and the sequential value for uniquely identifying the record in the tables of data;
Determining module 602, for splitting out logical partition coding from the major key, according to the logic point
Area's coding determines the database where the tables of data;
Sending module 603, for the data access request message to be sent to the data where the tables of data
Storehouse, conducts interviews to the record that the sequential value is identified.
Optionally, determining module 602, are additionally operable to be encoded according to logical partition, and, default logic point
Area encodes the corresponding relation with database, determines the database where the tables of data.
The router that the embodiment of the present invention four is provided, available for either router institute in execution above-described embodiment
The data processing method of execution, beneficial effect is similar to the above embodiments, will not be repeated here.
The embodiment of the present invention five also provides a kind of application server.Fig. 7 is what the embodiment of the present invention five was provided
A kind of structural representation of application server.As shown in fig. 7, application server 700 may include:Processing
Device 701, memory 702, communication interface 703 and bus 704.Wherein, processor 701 and memory
702nd, communication interface 703 is connected by bus 704.
Wherein, processor 701, can be central processing unit (Central Processing Unit, abbreviation
CPU).Processor 701 can also be other general processors, digital signal processor (Digital Signal
Processing, abbreviation DSP), application specific integrated circuit (Application Specific Integrated Circuit,
Abbreviation ASIC), field programmable gate array (Field-Programmable Gate Array, abbreviation FPGA)
Or other PLDs, discrete gate or transistor logic, discrete hardware components etc..
General processor can be microprocessor or the processor can also be any conventional processor etc..
Memory 702, can include volatile memory (volatile memory), such as arbitrary access
Memory (Random-Access Memory, abbreviation RAM);Memory 702 can also include non-
Volatile memory (Non-volatile memory), such as read-only storage (Read-Only Memory,
Abbreviation ROM), flash memory (Flash Memory), hard disk (Hard Disk Drive, referred to as
) or solid state hard disc (Solid-State Drive, abbreviation SSD) HDD;Memory 702 can also include
The combination of the memory of mentioned kind.
Communication interface 703, can be interface circuit, and for receiving and sending messages, communication interface 703 receives outer
After the information that portion's equipment is sent, handled to processor 701;In addition, communication interface 703 can be by having
Line communicates or radio communication communicates with network and other equipment.
Memory 702 is used for store instruction;Processor 701 is used for execute instruction, when processor 701 is held
During the instruction that line storage 702 is stored so that processor 701 performs the number that above-mentioned application server is performed
According to processing method.
The application server that the embodiment of the present invention five is provided, available for any application in execution above-described embodiment
Data processing method performed by server, beneficial effect is similar to the above embodiments, will not be repeated here.
The embodiment of the present invention six also provides a kind of router.Fig. 8 is one kind that the embodiment of the present invention six is provided
The structural representation of router.As shown in figure 8, the router 800 may include processor 801, storage
Device 802, communication interface 803 and bus 804.Wherein, processor 801 with memory 802, communicating connects
Mouth 803 is connected by bus 804.
Wherein, processor 801, can be CPU.Processor 801 can also for other general processors,
DSP, ASIC, FPGA or other PLDs, discrete gate or transistor logic,
Discrete hardware components etc..General processor can be microprocessor or the processor can also be it is any often
Processor of rule etc..Memory 802, can include RAM;Memory 802 can also include non-volatile
Property memory, such as ROM, flash memory, HDD) or SSD;Memory 802 can also be wrapped
Include the combination of the memory of mentioned kind.Communication interface 803, can be interface circuit, for receiving and dispatching letter
Breath, communication interface 803 is received after the information that external equipment is sent, and is handled to processor 801;In addition,
Communication interface 803 can be communicated by wire communication or radio communication with network and other equipment.
Memory 802 is used for store instruction;Processor 801 is used for execute instruction, when processor 801 is held
During the instruction that line storage 802 is stored so that processor 801 is performed at the data that above-mentioned router is performed
Reason method.
The router that the embodiment of the present invention four is provided, available for either router institute in execution above-described embodiment
The data processing method of execution, beneficial effect is similar to the above embodiments, will not be repeated here.
One of ordinary skill in the art will appreciate that:Realize all or part of step of above-mentioned each method embodiment
Suddenly it can be completed by the related hardware of programmed instruction.Foregoing program can be stored in a computer can
Read in storage medium.The program upon execution, performs the step of including above-mentioned each method embodiment;And
Foregoing storage medium includes:ROM, RAM, magnetic disc or CD etc. are various can be with store program codes
Medium.
Finally it should be noted that:Various embodiments above is merely illustrative of the technical solution of the present invention, rather than right
It is limited;Although the present invention is described in detail with reference to foregoing embodiments, this area it is common
Technical staff should be understood:It can still modify to the technical scheme described in foregoing embodiments,
Or equivalent substitution is carried out to which part or all technical characteristic;And these modifications or replacement, and
The essence of appropriate technical solution is not set to depart from the scope of various embodiments of the present invention technical scheme.
Claims (17)
1. a kind of data processing method, it is characterised in that including:
Application server receives business object request to create message;The business object request to create message package
Include:The type of business object;
The application server determines the corresponding logic of the business object according to the type of the business object
Zonal coding;
The application server generates at least one tables of data of the business object;Wherein, each data
The major key of table includes:The corresponding logical partition coding of the business object, the business object is corresponding to patrol
Collect zonal coding corresponding with database.
2. according to the method described in claim 1, it is characterised in that the application server is according to described
The type of business object determines the corresponding logic coding of the business object, including:
The application server is according to the type and default business object type of the business object with dividing
The corresponding relation of storehouse field, determines corresponding point of storehouse field of the business object;
The application server determines the business object pair according to corresponding point of storehouse field of the business object
The logical partition coding answered.
3. method according to claim 1 or 2, it is characterised in that the application server generation
At least one tables of data of the business object, including:
The application server generates the sequential value of the tables of data, and the sequential value is used to uniquely identify
A record in one tables of data;
The application server carries out sequential value logical partition coding corresponding with the business object
Combination;
The application server is created to be encoded with sequential value logical partition corresponding with the business object
The tables of data for being combined as major key.
4. method according to claim 3, it is characterised in that at least one described tables of data includes
The main table and relation sublist of the business object;Methods described also includes:
The application server is during the relation sublist is generated, in the external key of the relation sublist
It is middle to add the corresponding logical partition coding of the business object.
5. method according to claim 4, it is characterised in that add the logical partition coding
The external key be the relation sublist in be used for point to the relation sublist parent table external key.
6. a kind of data processing method, it is characterised in that including:
Router receives the data access request message that application server is sent;The data access request disappears
Breath is using the major key in the tables of data of business object as access consideration;The major key includes:The business object
Corresponding logical partition coding and the sequential value for uniquely identifying the record in the tables of data;
The router splits out the logical partition coding from the major key, according to the logical partition
Coding determines the database where the tables of data;
The router sends the data access request message to the database where the tables of data,
The record that the sequential value is identified is conducted interviews.
7. method according to claim 6, it is characterised in that the router is according to the logic
Zonal coding determines the database where the tables of data, including:
The router is encoded according to logical partition, and, pair of default logical partition coding and database
It should be related to, determine the database where the tables of data.
8. the method according to claim 6 or 7, it is characterised in that the data access request disappears
Breath also includes:Access type;The access type includes:Data query, data modification and/or data are deleted
Remove.
9. the method according to any one of claim 6-8, it is characterised in that the data access
Request message is the access request message of structuralized query voice SQL statement.
10. a kind of application server, it is characterised in that including:
Receiving module, for receiving business object request to create message;The business object request to create disappears
Breath includes:The type of business object;
Determining module, for determining the corresponding logic of the business object according to the type of the business object
Zonal coding;
Generation module, at least one tables of data for generating the business object;Wherein, each data
The major key of table includes:The corresponding logical partition coding of the business object, the business object is corresponding to patrol
Collect zonal coding corresponding with database.
11. application server according to claim 10, it is characterised in that
The determining module, is additionally operable to the type and default business object class according to the business object
The corresponding relation of type and point storehouse field, determines corresponding point of storehouse field of the business object;According to the industry
Business corresponding point of storehouse field of object determines the corresponding logical partition coding of the business object.
12. the application server according to claim 10 or 11, it is characterised in that
The generation module, is additionally operable to generate the sequential value of the tables of data, and the sequential value is used for unique
One tables of data of mark in one record;By sequential value logic corresponding with the business object
Zonal coding is combined;Create and encoded with sequential value logical partition corresponding with the business object
The tables of data for being combined as major key.
13. application server according to claim 12, it is characterised in that at least one described number
Include the main table and relation sublist of the business object according to table;
The generation module, is additionally operable to during the relation sublist is generated, in the relation sublist
External key in add the business object corresponding logical partition coding.
14. a kind of router, it is characterised in that including:
Receiving module, the data access request message for receiving application server transmission;The data are visited
Ask request message using the major key in the tables of data of business object as access consideration;The major key includes:It is described
The corresponding logical partition coding of business object and the sequence for uniquely identifying the record in the tables of data
Value;
Determining module, for splitting out the logical partition coding from the major key, according to the logic
Zonal coding determines the database where the tables of data;
Sending module, for the data access request message to be sent to the data where the tables of data
Storehouse, conducts interviews to the record that the sequential value is identified.
15. router according to claim 14, it is characterised in that
The determining module, is additionally operable to be encoded according to logical partition, and, default logical partition coding with
The corresponding relation of database, determines the database where the tables of data.
16. a kind of application server, it is characterised in that including:Processor, memory, communication interface
And bus;Wherein, the processor is connected with the memory, the communication interface by the bus;
The memory is used for store instruction;
The processor is used for execute instruction, when the instruction of memory storage described in the computing device,
So that the data processing method any one of the computing device the claims 1-5.
17. a kind of router, it is characterised in that including:Processor, memory, communication interface and total
Line;Wherein, the processor is connected with the memory, the communication interface by the bus;
The memory is used for store instruction;
The processor is used for execute instruction, when the instruction of memory storage described in the computing device,
So that the data processing method any one of the computing device the claims 6-9.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610084423.5A CN107085570B (en) | 2016-02-14 | 2016-02-14 | Data processing method, application server and router |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610084423.5A CN107085570B (en) | 2016-02-14 | 2016-02-14 | Data processing method, application server and router |
Publications (2)
Publication Number | Publication Date |
---|---|
CN107085570A true CN107085570A (en) | 2017-08-22 |
CN107085570B CN107085570B (en) | 2020-08-14 |
Family
ID=59614060
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610084423.5A Active CN107085570B (en) | 2016-02-14 | 2016-02-14 | Data processing method, application server and router |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107085570B (en) |
Cited By (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107862090A (en) * | 2017-12-04 | 2018-03-30 | 中企动力科技股份有限公司 | The horizontal extension method and device of database |
CN108009883A (en) * | 2017-11-30 | 2018-05-08 | 泰康保险集团股份有限公司 | Method and device for order processing |
CN109684093A (en) * | 2018-12-24 | 2019-04-26 | 成都四方伟业软件股份有限公司 | Data processing method and system |
CN110196854A (en) * | 2019-06-11 | 2019-09-03 | 中国科学院寒区旱区环境与工程研究所 | Data processing method and device |
CN110955664A (en) * | 2019-12-03 | 2020-04-03 | 中国建设银行股份有限公司 | Method and device for routing messages in different banks and tables |
CN111061738A (en) * | 2019-12-16 | 2020-04-24 | 中国建设银行股份有限公司 | Data table pre-grouping method, device, equipment and storage medium |
CN111199386A (en) * | 2019-12-27 | 2020-05-26 | 天阳宏业科技股份有限公司 | Workflow engine and implementation method thereof |
CN111400110A (en) * | 2020-03-11 | 2020-07-10 | 中国建设银行股份有限公司 | Database access management system |
CN111506654A (en) * | 2020-04-17 | 2020-08-07 | 北京思特奇信息技术股份有限公司 | Data partitioning method for data routing |
CN114490674A (en) * | 2022-04-18 | 2022-05-13 | 北京奥星贝斯科技有限公司 | Partition table establishing method, partition table data writing method, partition table data reading method, partition table data writing device, partition table data reading device and partition table data reading device |
WO2023103279A1 (en) * | 2021-12-06 | 2023-06-15 | 北京达佳互联信息技术有限公司 | Service creation method and apparatus |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103473321A (en) * | 2013-09-12 | 2013-12-25 | 华为技术有限公司 | Database management method and system |
CN103995879A (en) * | 2014-05-27 | 2014-08-20 | 华为技术有限公司 | Data query method, device and system based on OLAP system |
US20150193504A1 (en) * | 2011-11-14 | 2015-07-09 | Google Inc. | Data Processing Service |
-
2016
- 2016-02-14 CN CN201610084423.5A patent/CN107085570B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20150193504A1 (en) * | 2011-11-14 | 2015-07-09 | Google Inc. | Data Processing Service |
CN103473321A (en) * | 2013-09-12 | 2013-12-25 | 华为技术有限公司 | Database management method and system |
CN103995879A (en) * | 2014-05-27 | 2014-08-20 | 华为技术有限公司 | Data query method, device and system based on OLAP system |
Cited By (13)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108009883A (en) * | 2017-11-30 | 2018-05-08 | 泰康保险集团股份有限公司 | Method and device for order processing |
CN107862090A (en) * | 2017-12-04 | 2018-03-30 | 中企动力科技股份有限公司 | The horizontal extension method and device of database |
CN109684093B (en) * | 2018-12-24 | 2021-03-09 | 成都四方伟业软件股份有限公司 | Data processing method and system |
CN109684093A (en) * | 2018-12-24 | 2019-04-26 | 成都四方伟业软件股份有限公司 | Data processing method and system |
CN110196854A (en) * | 2019-06-11 | 2019-09-03 | 中国科学院寒区旱区环境与工程研究所 | Data processing method and device |
CN110955664A (en) * | 2019-12-03 | 2020-04-03 | 中国建设银行股份有限公司 | Method and device for routing messages in different banks and tables |
CN111061738A (en) * | 2019-12-16 | 2020-04-24 | 中国建设银行股份有限公司 | Data table pre-grouping method, device, equipment and storage medium |
CN111199386A (en) * | 2019-12-27 | 2020-05-26 | 天阳宏业科技股份有限公司 | Workflow engine and implementation method thereof |
CN111400110A (en) * | 2020-03-11 | 2020-07-10 | 中国建设银行股份有限公司 | Database access management system |
CN111400110B (en) * | 2020-03-11 | 2023-12-19 | 中国建设银行股份有限公司 | Database access management system |
CN111506654A (en) * | 2020-04-17 | 2020-08-07 | 北京思特奇信息技术股份有限公司 | Data partitioning method for data routing |
WO2023103279A1 (en) * | 2021-12-06 | 2023-06-15 | 北京达佳互联信息技术有限公司 | Service creation method and apparatus |
CN114490674A (en) * | 2022-04-18 | 2022-05-13 | 北京奥星贝斯科技有限公司 | Partition table establishing method, partition table data writing method, partition table data reading method, partition table data writing device, partition table data reading device and partition table data reading device |
Also Published As
Publication number | Publication date |
---|---|
CN107085570B (en) | 2020-08-14 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107085570A (en) | Data processing method, application server and router | |
KR102226257B1 (en) | Method and device for writing service data to a blockchain system | |
RU2724136C1 (en) | Data processing method and device | |
US9077669B2 (en) | Efficient lookup methods for ternary content addressable memory and associated devices and systems | |
US20100312749A1 (en) | Scalable lookup service for distributed database | |
CN109325044A (en) | A kind of the audit log processing method and relevant apparatus of database | |
CN106407303A (en) | Data storage method and apparatus, and data query method and apparatus | |
CN107704202B (en) | Method and device for quickly reading and writing data | |
US20170083406A1 (en) | Method and apparatus for incremental backup | |
CN106970929A (en) | Data lead-in method and device | |
CN106570113B (en) | Mass vector slice data cloud storage method and system | |
CN105706092A (en) | Methods and systems of four-valued simulation | |
CN111680489B (en) | Target text matching method and device, storage medium and electronic equipment | |
CN106375425A (en) | Processing method and device for distributed caching | |
US10599614B1 (en) | Intersection-based dynamic blocking | |
CN108399175B (en) | Data storage and query method and device | |
CN107609011A (en) | The maintaining method and device of a kind of data-base recording | |
CN116760661A (en) | Data storage method, apparatus, computer device, storage medium, and program product | |
CN110928941A (en) | Data fragment extraction method and device | |
CN110321363A (en) | Data retrieval method and device | |
CN110221778A (en) | Processing method, system, storage medium and the electronic equipment of hotel's data | |
WO2018210178A1 (en) | File storage method and storage device | |
CN115658680A (en) | Data storage method, data query method and related device | |
CN116127154A (en) | Knowledge tag recommendation method and device, electronic equipment and storage medium | |
CN105095283A (en) | Quasi-friend recommending method in social networking system and quasi-friend recommending system in social networking system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |