CN101630259B - Transparent EJB supports and horizontal data is split - Google Patents
Transparent EJB supports and horizontal data is split Download PDFInfo
- Publication number
- CN101630259B CN101630259B CN200910163430.4A CN200910163430A CN101630259B CN 101630259 B CN101630259 B CN 101630259B CN 200910163430 A CN200910163430 A CN 200910163430A CN 101630259 B CN101630259 B CN 101630259B
- Authority
- CN
- China
- Prior art keywords
- class
- data base
- database
- data
- ejb
- 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.)
- Expired - Fee Related
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/20—Software design
-
- 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
-
- 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/28—Databases characterised by their database models, e.g. relational or object models
- G06F16/289—Object oriented databases
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/54—Interprogram communication
- G06F9/541—Interprogram communication via adapters, e.g. between incompatible applications
Landscapes
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Databases & Information Systems (AREA)
- Data Mining & Analysis (AREA)
- Stored Programmes (AREA)
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
The present invention relates to transparent EJB support and horizontal data segmentation, relate to a kind of application development using public object framework (COF).Specifically, the present invention relates to be used for COF actually with the aspects such as the component model of measured server end and remote method invocation (RMI) protocol-compliant.The other side of the present invention relates in intermediary service application layer, i.e. on database layer, data base is carried out horizontal segmentation.Other aspects of the present invention are included in segmentation in object, change histories and the international combination of field.The specific aspect of the present invention is described in claim, specification and drawings.
Description
The application is the divisional application of following application for a patent for invention:
Application number: 03825733.5
The applying date: on August 21st, 2003
Denomination of invention: transparent EJB supports and horizontal data is split
Copyright notice
Disclosed in patent document, a part comprises copyrighted content.Copyright owner do not oppose according to patent and
The patent document or the record that occur in trademark office duplicate this patent documentation or patent publication like that, otherwise retain all copyrights.
Technical field
The present invention relates to a kind of application development using public object framework (COF).Specifically, the present invention one side
Face relate to being used for COF actually with component model and the remote method invocation (RMI) protocol-compliant of measured server end.This
The other side of invention relates in intermediary service application layer, i.e. horizontal segmentation data base on database layer.It is included in object
The international combination of interior segmentation, change histories and field is other aspects of the present invention.The specific aspect of the present invention is described in
In claim, specification and drawings.
Background technology
Multilamellar application has become with distribution, the common method of reliable and scalable mode configuration service logic.In multilamellar
(multi-tiered), in system, system services layer provides data base, transaction processing program and other infrastructure.Intermediate layer carries
For arriving the path of service logic.Client layer accesses this service logic.Client layer can have simple or complicated client computer
User, or the program of such as Web Service client.Multilamellar application is especially to supporting from single application platform
Many clients are highly useful.Multilamellar application may be used for many clients and processes the data of similar structure, and its advantage includes code weight
With with flexible.
J2EE and Enterprise JavaBeansTM(EJB) conduct encapsulates in multilamellar environment and offer business is patrolled
Volume, the most integrated for data management mechanism architecture and occur.Application server provides and accesses system service with basic
The path of facility.The application management server storage of object or holding to encapsulating service logic and data.See Sun,
Simplified Guide to the JavaTM2 Platform, EnterpriseEdition (1999).Microsoft's
Competition architecture is known as .NET framework and DCOM.Monson-Haefel, Richard, Enterprise JavaBeans
3d Ed., p.17O ' Reilly (2001).The older framework with some similar characteristics is known as CORBA.
The life cycle of multilamellar, encapsulation service application includes initial exploitation and maintenance subsequently.(in this article,
Service application is used for including business and non-commercial applications, and they include the centre of one or more resident so-called service logic
Layer.) multilamellar, encapsulation being originally developed of service application can start in OO visual analysis and modeling tool,
Develop into relational database mapping by object process, and be configured to multilamellar, the service application of encapsulation.Maintenance can include point
The service application assembly that section (staging) and configuration (deployment) have updated.Configuration may need internationalization (to be abbreviated as
I18N: " i " and " n " is plus 18 middle letters) dynamic data of such as name of product and description.
Instrument for being originally developed includes visual analyzing and modeling tool, its observe UML (UML) and
Produce this language application program to be used and the object-oriented model of data.The visualization that RationalRose is main divides
Analysis and modeling tool.Other products includes Enterprise Studio's and NeuVis of VisualAge, Boland of IBM
NeuArchitect.Design tool can be also used for visual analyzing and modeling, such as Visio or Flowcharter.
OR instrument can be used for exploitation, and object-oriented model is mapped as relational database.TopLink be by
Object-oriented model is mapped to the main tool of relational database.Competitive tools be by SunMicrosystems, IBM,
Borland, Oracle, Microsoft, Thought company and Tibco produce.Modeling work including some OR mapping functions
Tool is the most limited, and can not perform well in supporting the scope of availability database.
Application server for multilamellar, encapsulation service application can be compatible with J2EE standard or similar standard.With
Application server in J2EE and EJB2.0 is by Sun, JBoss.org, Borland, IBM, BEA Systems, Warp
Solutions, Macromedia, Oracle and other a lot of companies provide.Application server can rely on various data base
Obtain persistence, including the data base provided by Oracle, Microsoft, IBM, Siebel, Sysbase and other company.
Two weakness of the instrument provided are that limited integrated and shortage is to safeguarding and the support of useful properties in configuration.
The limited integrated user of meaning needs re-enter data or follow detailed Programming Guide, thus in visual analyzing and modeling
The application program developed in instrument and map in OR instrument just can meet the competition of the service application configuration of a multilamellar, encapsulation
Standard.Can be used for supporting so that the feature that developer need not utilize existing instrument manually implemented includes segmentation, configuration history
Internationalization with dynamic data.Segmentation can include the module tested for live data test new module and configuration.Go through
History refers to record this configuration and record segmentation and/or test new module alternatively.One or more base is added to by specifying
Language in this language or country or country, the International Support of dynamic data adds the attached of the foreign language translation of support dynamic data
Add field and list.
The desired feature not manifested in current system is in intermediate layer horizontal segmentation data, thus data can
To be positioned in multiple physical database independent of each other, it might even be possible to be positioned at multiple foundation data in different vendor platforms
In storehouse, such as oracle database and SQL Server2000.At this with following, version " 2000 " is only used as reference, is not intended to
And limit the software version that can be used for implementing the present invention.Machine for horizontal segmentation existing, that provided by database supplier
System uses multiple physical volume in the system of a tight management, and all these volumes are all by the database manager control of supplier
System.Such as horizontal segmentation technology, sees Klein, U.S.Pat.No.6453313, Database Management System
and Method forDequeuing Rows Published to a Database Table(1992);Lohman et al.,
U.S.Pat.No.6112198, Optimization of Data Repartitioning During Parallel
QueryOptimization(2000);Baru et al., U.S.Pat.No.5970495, Method and Apparatus
forAchieving Uniform Data Distribution in a Parallel Database System(1999).Just
As Klein explains, the transparent horizontal segmentation of large database table between node and equipment in group's machine flexible and
Dispersion calculated load.Horizontal segmentation means divided by table or be divided into two or more files, and each part stores to be had
The record (tuples) of corresponding key value scope.Such as, each part in two or more parts of a customer table
May be used to the record corresponding to the customer name started with the corresponding scope of letter A-L.Table can also come according to cryptographic Hash
Segmentation.Such as, using the hash function of recording indexes can have any one in N number of (such as 4) value, a table is permissible
Being divided into N number of part, hash function is for determining the part wherein storing each table row.Additionally, each part can be stored in
In the different nodes of system or physical equipment, to be beneficially distributed calculated load in this system.
Horizontal segmentation is integrated in intermediate layer rather than database manager and may support multiple visitors to same application
Family is useful.
When with the addition of more client or again having split data base, transparent water is divided cut branch equally and is held developer can be made to exempt from
In their service logic of amendment.
Therefore, all going out with modeling to each stage that configure and safeguard multilamellar, that encapsulate service application from visual analyzing
Show and preferably supported and the chance of Integrated Development.
Summary of the invention
The present invention relates to a kind of application development using public object framework (COF).Specifically, the present invention one side
Face relate to being used for COF actually with component model and the remote method invocation (RMI) protocol-compliant of measured server end.This
The other side of invention relates in intermediary service application layer, i.e. horizontal segmentation data base on database layer.It is included in object
The international combination of interior segmentation, change histories and field is other aspects of the present invention.The specific aspect of the present invention is described in
In claim, specification and drawings.
According to the present invention, it is provided that a kind of including the multilamellar service application of at least database layer and intermediary service application layer
In carry out horizontal segmentation object across multiple self contained data bases method, including: state at least one object one or more can
For the field that special object is distributed to certain database;Set up the connection with multiple data bases, to the plurality of data
Object described in storehouse can be by horizontal segmentation;Cache one or more object needing to find, create, right including by horizontal segmentation
As;And when finding or create, utilize the field of statement to decompose the certain database belonging to this object, and call number
According to this certain database in the layer of storehouse perform described in find or create.
According to the present invention, additionally provide a kind of should at the many layer services including at least database layer and intermediary service application layer
The method carrying out horizontal segmentation object across multiple self contained data bases in, including: set up the connection with multiple data bases, to described many
At least one object of individual data base can be by horizontal segmentation;Certain database belonging to described object is set;This setting steps it
Before or afterwards, cache one or more object needing and finding, create, including described object;And finding or creating
Time, call this certain database in database layer and perform to find or create.
Accompanying drawing explanation
Fig. 1 is the high level block diagram of multilamellar application.
Fig. 2 illustrates how to use the EJB on the J2EE server providing intermediate layer to realize public object framework.
Fig. 3 illustrates object and the relation of simple shopping cart application Visualization Model.
Fig. 4 illustrates the CBOF label 401 in the pop-up window added to for specifying class feature.
Fig. 5 illustrates the CBOF label 401 added in the pop-up window of assigned operation characteristic.
Fig. 6 illustrates the CBOF model that may be used for EJB shell.
Fig. 7 illustrates for supporting class CmoBase701 of EJB and J2EE, CmsBase702 and CmoAttribute703
The class figure of aspect.
Fig. 8-10 illustrates that EJB and J2EE support is suitable for by COF instrument and model.
Figure 11 briefly shows horizontal segmentation.
Figure 12 illustrates the class that can be used for realizing horizontal segmentation in TopLink environment in intermediate layer.
Detailed description of the invention
Detailed description below is made referring to the drawings.Preferred embodiment illustrates the present invention, but is not limited to by right
Require limited range.Those skilled in the art is it is known that change various equivalences described below.
Fig. 1 illustrates J2EE and the EJB standard initiated by Sun, and they may be used for one embodiment of the present of invention.See
The The J2EE Tutorial of Bodoff et al., p.10 Addison Wesley (2002).Module in Fig. 1 is explained by Sun
As follows.Part when J2EE server 120 is the operation of J2EE product.J2EE server provides Enterprise Java Bean container 125 and Web container
121, and manage the access to underlying database layer 130.Enterprise JavaBeans (EJB) container 125 manages J2EE
The execution of enterprise's bean (enterprise beans) of application.Enterprise's bean 126,127 and container 125 thereof are at J2EE server 120
Upper operation.Web container 121 manages JSP page 123 applied for J2EE and the execution of servlet 122 assembly.Web assembly
122,123 and container 121 run on J2EE server 120.Application client container 113 manages application client 112 groups
The execution of part.Application client 112 and container 113 thereof run in client computer 110.Applet Container Management applet holds
OK.This container includes web browser 111 and one or more java plug-in program run in client computer 110.
More putting it briefly, Fig. 1 is illustrated based on component model and the remote method invocation (RMI) agreement of the server end of standard.
The .NET framework of Microsoft includes similar assembly with CORBA.Monson-Haefel, EnterpriseJavaBeans,
pp.5-18.The aspect of the present invention and standard are compatible, current version when wherein these aspects are to indicate here or to submit the application
Or version subsequently meets any version or the derivant of this standard.Essence compatibility is very useful, it is not necessary to all compatible.?
Recognize that completely compatible with standard is considered as the feature of unwanted standard sometimes for realizing, this cost is too big or change not
Fixed.Additionally, it is also recognized that some enforcement can include may being introduced for strengthening product and along with standard evolution and user adhere to
Law support is possible and becomes off-gauge feature.Standard mean to cover specification that such as EJB etc. controls by committee and
The specification that such as .NET framework etc. are controlled by supplier.
Fig. 2 illustrates how to use the EJB on the J2EE server providing intermediate layer to implement public object framework.Fig. 2's
A lot of assemblies and the component matching of Fig. 1, and indicate according to Fig. 1.In fig. 2 it is described that web container and enterprise's bean
Content.In web container 121, application include public object framework (COF) 240A, role apply 241, web services engine 242
With cooperating process manager 243.COF provides for persistable object and supports and provide the access to it, applies 241 reducing role
Developer processes the needs of persistence, transaction management and inter-related task.By using the application and the Shen merged by quoting
Method described in please, COF can support segmentation, change histories, internationalization and horizontal segmentation alternatively.Web service engine 242
It is for providing the assembly of web services by Commerce One with cooperating process manager;These application in web container
Details is immaterial to the invention.But, cooperating process manager 243 is connected to the filled arrows of COF240A and incites somebody to action
CPM243 be connected to COF240B and EJB127 Enterprise Java Bean container shown in phantom 124 provide service and data support replace
The option of the service that the COF240A code in web container 121 is provided.By the COF code in Web container 121 and enterprise's bean
126 be labeled as similarly 240A, 240B means represent COF code can pack for EJB processs, and change with little or no
There is in the case of rewriteeing COF code the compatible interface of EJB.As it can be seen, COF can obtain in web container or Enterprise Java Bean container
?.Application can access the COF assembly in two containers.Application terminals simultaneously or concurrently can be carried out actively with two set COF assemblies
Session.Although Fig. 2 is shown in the enforcement in the linguistic context of EJB environment, it will also be recognized by those skilled in the art that identical method
May be used for other measured server-side component model and remote method invocation (RMI) agreement, such as DCOM.
So-called public object framework provide the whole software life-cycle for managing business object basic to realize and
Instrument, this is described in more detail in the application merged.This includes that design, uml model, complete code and data base produce
Raw, these all include transparent internationalization, segmentation, change histories and custom attributes.For ongoing to relying on data base's
The maintenance of code, data and pattern provides instrument.The kind of public object frame assembly includes utility program (utilities)
Storehouse, business object framework and system management facility.Utility program library component includes the utility program of common code level, as
Exceptions (international) (exception), Logging (daily record), Cryptography (password) and Configuration (join
Put) access.Utility program library component also includes internationalization function, such as explorer, date, numerical value and text.Business object
Framework be used for designing business object, produce for continuing, internationalization, data sectional, vncsion history, Dynamic Customization attribute and complete
Create/read/update/delete the code of (CRUD) function.This framework also includes extending any business object, across multiple services
The support of the cache coherency of device and scheduler program.System management facility is set up on the basis of business object framework, bag
Include the data organizing tool changed for the release creating data base, loading data, renewal database schema and more new data.Also
Have for the extraction procedure with localization tool bag and the installation procedure of internationalizing.
COF or the COF of standard compatibility that EJB is compatible can be realized by various component softwares and alternatively real with them
Existing.The generation of the design of object model and code or metadata (machine-readable data) can use Rational Rose
2001a or more highest version realize.At this with following, version " 2001a " is also served only for reference, is not meant to can be used for reality
The version of the software executing aspect of the present invention limits.When using Rational Rose, an addition Item is installed figure is provided
Function that is shown in 4-5 and that be explained below.TopLink3.6.1, SQL Server 2000, Oracle 8.1.7 can be used
Or the suitable JDBC driver of DB2 and such as I-netOPTA4.15, Seropto or IDS JDBC Lite3.5.4 reflects
Penetrate, create and access data base.The Enterprise Java Bean container of such as WebSphere and WebLogic7.0 can be used.
The new of COF compatible for EJB and the module strengthened can be combined by multiple useful mode.These modules generate remotely
With local EJB interface, thus any COF object can be accessed as EJB and use.They use TOPLink4.0 to make
For OR mapping tool, it is provided that the access to the EJB-QL as the query language for finding object.These module management data
Storehouse server session, including supporting the horizontal segmentation accessed while multiple data bases and to data.Pass between data base
System cannot be supported.The application to conducting interviews any object of these modules provides client session.They are loss
Data base connects the configurable retry mechanism of offer.They are supported and affairs based on EJB JTA and between database server
Unique uniquely coupled object identifier carries out integrated, with the object of reservation identifier realize level when migrating between data base
Segmentation.Object change event message as Object Creation, update and deletes configurable event generation.There is provided to the object realized
Check, for rear Object Creation, front object updates, rear object refreshes and front object is deleted.Provide for Rational Rose
Design and Code Generator.Data base creates instrument design based on visual model and generates data base or DDL script.Work
Tool produces application server configuration describer by the EJB generated.Support that WebLogic6.1sp2 and WebSphere 5.0 (needs
Want the support of EJB2.0spec).
Fig. 3 illustrates object and the relation of the simple shopping cart application of visual model.Model in this figure be utilize for
UML (UML) symbol of class figure creates.In this embodiment, CmsCart object 301 is for providing multiple side exposed
Method.CmsCart rather than CmoCart object is used to mean that this object exists during session, and to later session not
Being lasting, this is contrary with client and order, and the latter is lasting.Shopping cart 301 can by order 311 with CmoOrder pair
As 303 associations.In this embodiment, an order object relates to a shopping cart.CmoOrder object 303 should pass through in the completed
CmoCustomer object 302 associates with client 313.Along the opposite direction of this relation, continuing client 302 can be by 312 with more than
One order 303 associates.Order 303 comprises one or more CmoProductLineItem object 305.Relational term 314 will be ordered
Single 303 are connected with its line project 305.Line project 305 is filled with the product 304 being connected to this line project by product 315 relation.
In UML, the object of such as shopping cart can be modeled as a class.In the case of acquiescence, in the present invention
The persistable object of all top (i.e. not having parent) in embodiment is all inherited from the basic object of referred to as CmoBase, as
Below by explanation in the context of Fig. 5.Or, temporary object can be inherited from the object of referred to as CmsBase.This base
This object can provide in CAT (or unit) file, and this document can be loaded in object modeling program, and is drawn by other class
With.This basic class of purpose is that the object to all general common interfaces and realization provides basic function.
The model of the class setting up UML form by object modeling program may comprise steps of.First, bag is created
(package) level, with specify such should and the bibliographic structure that produces there.Then class name, class document can be specified
And generic attribute.The generic attribute using as shown in Figure 4 and explained later instrument to support includes: lasting, interim, make a summary, give birth to
Code, data base's table name, sectional, maximum version number, top layer (Table-Level) constraint database is become (to be such as combined only
One constraint), display in the gui, display name, display description, generate and generate EJB.
The attribute of class can be specified below.Can be long with specified attribute name, type, document, database column name, database column
Degree, the null value allowed and this attribute are the most unique.Additionally, attribute can be static, final and/or interim.Attribute is permissible
It is defined as shielded (protected), thus subclass and reflection code can access these attributes.But, other class and should
These attributes of getter and setter way access can only be passed through with code.Support following attribute type: int, boolean,
Float, long, short, double, char, String, Date, Time, Timestamp, Interger, Boolean,
Float, Long, Short, Double, BigInterger, BigDecimal, Character, Object, byte, Byte,
Char, Character, EncryptedString, HashedString and TranslatebleString.
These types can suitably be hinted obliquely at for Java fundamental type, and the latter can be mapped as the class specific to data base
Type.The BLOB type that Object, byte, Byte can be mapped as in data base is to store byte stream.Char, Character can
With the CLOB type that is mapped as in data base to store big character stream.EncryptedString, HashedString type is
Specific type, they are character string, but produced code can encrypt/hash (hash) this value before setting a property, and
This code can decipher this value when returning this attribute by getter and setter method.TranslatableString attribute is also
Being only a character string, but produced code also produces an add list, row therein represent the translation value of this attribute.This makes
The particular community of the class that must specify demonstrates that multiple translation values of this attribute can be to support that localization is stored in data base
Object value and exist.
Then the relation of class can be specified.In UML, employing has the straight of the arrow from an object to another object
Line comes specified relationship or association.The each party of this association is referred to as role.The class that role name is square equal to " source " of this association
Attribute-name.Role should be protected control (the same as attribute).Each role can specify multiformity.Support
" 0...1 ", " 1 " and " 0..* "." 0...1 " specifies 0 of object in this role side or the example can be in this relation
In.Equally, " 1 " specifies what a example proper of object of this role side should (usually representative and this relation in this relation
The row of the association of the class of source side specify not null constraint).Equally, " 0...* " specifies 0 of object or the more example can be at this
In relation.This relation being equivalent to comprise an affiliated partner set.
Relation can also be two-way.This means that each party of association can see the opposing party.In two way relation
Multifarious any displacement defined above can be there is.Additionally, a side of this relation can be shown as set (coming in relation
Represent with opening rhombus in the side of source).The example of " purpose " class that set relations appointment " source " class is proprietary.Thus create and delete
Except the example of " purpose " class is the responsibility of " source " class.
Object modeling program allows definition can be arranged on each single bag, class, attribute, relation and relationship role
Bells and whistles.To each type of object, can by object modeling program, " CBOF " label be added in attribute, such as figure
Shown in 3.It can be the specific properties that arranges of every kind of object that this label is listed.Generate the metadata corresponding to visual model or machine
The module of readable data can access any characteristic of any object.Therefore, by adding characteristic, the additional spy of class can be set
Property customize the generation of later code, and such other is supported.
Specifically, Rational Rose object modeling program allows to add and comprises the bells and whistles for various objects
The extension of value.When creating object model (there is the features such as such as class, attribute, association), can refer on these object models
Determine and/or one group of characteristic is set.This group characteristic can extend for the purpose that customizes and add.Fig. 4 illustrates and adds ejection to
For specifying the CBOF label 401 of class feature in window.402 feature collections or characteristic subset can be selected to handle.For mould
, there is property name 411, value 412 and source 413 (be such as shown as acquiescence or cover) in type characteristic.Control user and handle this
A little characteristics.The characteristic with non-default value is runic, is highlighted or focuses on display.
It can be the characteristic added of various types of object that explained below is listed, and one or more for control routine
Generation and to class other support mode:
1.Project Properties (project characteristic): think that an object model is one " project ".Therefore, it can
The characteristic that some are the overall situation for whole corresponding item objects is set.
The copyright notice of CopyrightNotice (the copyright notice)-covering code output to generate.
The class name of OR map entries class that ProjectName (project name)-covering will be generated.
ProjectDescription (the item description)-OR map entries that will be stored in generation as static variable is set
The description of apoplexy due to endogenous wind.
2.Class Properties (class feature): one class can include the uml class object created according to class figure.
By clicking on one group of standard feature, can add referred to as the new label of " Cmo ", it has the property that
Generate (generation)-be set to "No" is avoided generating code for some class only existed for achieving purpose.
GenerateEJB-is set to "Yes" and generates the one or more EJB interfaces with class.
TableName-covers the acquiescence table name of class.In default situations, before this capitalization class name, 27 characters are permissible
It it is table name.
IsStageable-is set to "false" and avoids generating any pitch capability into this certain kinds, as will be detailed below in detail
Describe.
MaxNumVersions-be set greater than 0 with arrange over change number, to keep specific class example.
ReplaceClass-specifies such to realize the complete trails class name of the existing class replaced.
WrapperPackageName-specifies the bag name generating shell (ImplC) class.
ImplPackageName-specifies to generate and persistently realizes and the bag name of major capsid (Impl and ImplW) class.
StageablePackageName-specifies and generates the bag name continuing sectional realization (ImplS).
Constraint1 to Constraint7-specifies the top layer to a class to retrain.Such as " UNIQUE (name,
owningMember)”。
IsDisplayed-designates whether to need, in given user interface, class name is shown to user.
DisplayName-covers such acquiescence display name.In default situations, class name is by eliminating any " Cmo "
At the capitalization of prefix the most followed by lower case, insertion space generates.
DisplayDescription-arranges the description shoulding be such display.
3.Attribute Properties (attribute characteristic): can be that the attribute of above-mentioned fundamental type adds in certain kinds
Additive attribute.Attribute can have referred to as the new label of " Cmo ", has characteristics that
ColumnName-covers this attribute in the acquiescence row name in the table of this Attribute class.In default situations, use
It can be row name that ' _ ' separates 30 characters before the capitalization attribute-name of word boundary.
I18NConstraintName-be covered as that these row add _ the DEFAULT constraint name of IN table is (if this attribute is set to
Uniquely).
4.Association Properties (associate feature): association can be added between two certain kinds.Association
Can include two sides, they are referred to as role.Association itself can have referred to as the new label of " CBOF ", has characteristics that
If RelationTableName-association represent multi-to-multi or unidirectional many-one relationship, then can add centre or
" relation " table.This characteristic is set with specified relationship table name.Under default situations, this relation table name attempts to take the class name of this relation both sides
And use " TO " in centre.If this title oversize (more than 27 characters), then use the character string being followed by this class name miscellaneous
Gather the class name initial (initial of word boundary) of code.
One side of 5.Role Properties (role characteristics): character representation association.One association have role side A and
Role side B.Therefore, if adding characteristic to character object, then two additional labels, i.e. " CBOF can be added to associate feature
A " and " CBOF B ", have the property that
ColumnName-covers this acquiescence row name being associated in the table of this association class.Under default situations, with ' _ ' divide
Before the capitalization role name of word boundary, 30 characters can be row name.
GenerateForeignKeyConstraint-is set to "false", if this side not shoulding be association generates
If foreign key constraint.
ForeignKeyConstraintName-covers the acquiescence foreign key constraint name associating this side.
As discussed below, horizontal segmentation can distribute to include a group objects as project characteristic, or special as class
Property distributes to include related object.The most all of class, attribute and relation model the most, and code is generated as.
Can also assigned operation, and the characteristic that these operated distributes as shown in Figure 5.CBOF addition Item label 501 is shown.
At least two characteristic 521 is to be accessed for, and it indicates whether to generate EJB local interface and/or EJB remote interface.For
Each characteristic shows that title 511, value 512 and source 513.More roughly speaking, local interface follows first with less expense
Agreement, it is adaptable to reside in calling and invoked object in same web container 121 or same bag.Remote interface is with bigger
Expense follows second protocol, it is adaptable to remote method invocation (RMI).Remote method invocation (RMI) agreement is for such as CORBA, JavaRMI,
MicrosoftTransaction Server, Microsoft COM/DCOM, Microsoft.NET Framework and
Specification and the product of Enterprise JavaBeans (EJB) and provide.The selection generating local and remote interface controls to adjust
With exposing of expense and/or interface.
Fig. 6 illustrates the CBOF model that may be used for EJB encapsulation.With reference to Fig. 6, according to embodiments of the invention, object box is shown
The block diagram of frame 610.In alternative embodiments, object-oriented framework 610 can include other assemblies various or configuration, with supplement or
Replace the assembly that those embodiments combining Fig. 6 are discussed.
The useful aspect that COF/CBOF realizes includes following combination: Rational Rose is used for setting up the model of object,
But it is not restricted to object model design;Service logic method generation for customization has the code of placeholder or dash line;Produce
Create, read, update and delete (CRUD) when code carrys out the operation of support target, and Rational Rose's is anti-without using
To engineering;In addition to user states mapping parameters, with a small amount of or do not have user alternatively to carry out object to relation (OR) mapping;
Generate persistence map information so that business object is continued (persist) to relational database;Definition and establishment relation table peace treaty
Bundle, including needing for the information creating database schema and this information creating of use and/or the instrument of transplanting data base;Can lead to
Straightforward procedure that cross one group of standard API Access, that create, read, update and delete (CRUD) when being used for running, it is thus possible to easily
Ground creates, reads, updates and deletes any business object in this framework.Affairs example is used to create, update and delete one
Group uses the object of these data base's Atom affairs.The life-span of affairs can be the longest, because data base is until the delivery time
Also it is not affected by impact and employs optimization locking.Data sectional, to support at the existing production version not affecting this object
In the case of change business object, until test, ratify and configure this change;Data variation history is supported, including any object
The monitoring of base attribute change is followed the tracks of;Produce code and information creates and can be used for transparent storage and save turning over of business object
Translate the database schema of string attribute;Support to Add New Attribute to any object dynamically at runtime, and do not affect this number
According to storehouse pattern;Support target change is noticed, and is creating including being configured to business object have, is updating or delete this object Shi Sheng
The option of event become, these event duration are to data base, and can be serviced by event notification and manage, and in business
After object builds the most in memory (init ()), after inserting in data base (postInsert ()), adding to
After in the affairs updated (postAddForUpdate ()), affairs update (preCommit before data base
()), after loading from data base/refresh (postRefresh ()), finally (preDelete before deleting from data base
()), the method that this business object can also realize performing certain action itself.
In the embodiment in fig 6, one group of 5 basic class shows on transverse axis 614, and can preferably include basic
Enliven object class CmoBaseImpl630, basic interface class CmoBase634, basic segmentation class CmoBaseImplS638, basic
Internationalization class CmoBaseI18N642 and basic shell class CmoBaseImplW644.These basic class of functions and use outline
It is described in the application merged by quoting to property.
In the embodiment in fig 6, one group of root class shows between transverse axis 614 and transverse axis 618, and can preferably include
Each root class come from corresponding basic Similar integral above.In the embodiment in fig 6, root class can preferably include root enliven right
As class AbstractXImpl646, root interface class AbstractX650, root segmentation class AbstractXImplS654, root internationalization
Class AbstractXI18N658, root shell class AbstractXImplW662, root customization class AbstractXImplC666.
In the embodiment in fig 6, one group of subclass shows under transverse axis 618, and preferably includes from correspondence above basic
Class and root Similar integral and each subclass of coming.In the embodiment in fig 6, give class preferably include son enliven object class XImpl670,
Sub-interface class X674, sub-segmentation class XImplS678, sub-internationalization class XI18N682, subshell class XImplW686 and son customization class
XImplC690。
Additionally, in figure 6, above-cited interface class series shows in the left side of the longitudinal axis 622.Shell class series shows
Between the longitudinal axis 622 and the longitudinal axis 626.Additionally, be stored persistently in data base 120 one group of class shows on the right side of the longitudinal axis 626.Connect
Mouth is to expose to the public Java interface of this system user.These interface definition obtain, arrange, add, delete and custom service
The method of logic.The java document that these interfaces also comprise API is for reference.Generate these interfaces, and can not manual modification,
Because manual modification will not allow the code regenerated below.
In one embodiment, these classes are mutual with the TopLink as component software.Although explanation below is specific
In TopLink, but those skilled in the art is to be understood that identical method may be used for other Database Mapping and pipe
Reason module.Continuing class is to describe to realize class to TopLink, as comprising lasting attribute and being mapped to the class of relational database.
Three kinds continue class and include Impl, ImplS and I18N.Object in Impl class representation database cuts with effect version really.ImplS class
Covering or segmentation version of effective object in representation database.All acquisitions described in the interface class/arrange/add/delete
Except method all realizes at these apoplexy due to endogenous wind.All service logics API are all dished out UnsupportedOperationException.
I18N class comprises interpretable string attribute and translation place.Impl and ImplS class and I18N class are the relations of one-to-many.Nothing
When opinion calls the acquisition/method to set up that can translate string attribute, all accesses according to the current place arranged on thread
The suitable example of I18N class.Generate these classes and can not manually change.
Shell class realizes affairs support, segmentation, change histories and custom service logic function.There are two class shell classes:
ImplW and ImplC.ImplW class is a kind of abstract class, and it implements the acquisition/setting/interpolation/delet method from interface class.
These methods suitably check whether retrieval or arrange Impl object, ImplS object or their suitable TOPLink transactional replication
The value of product.Setting/interpolation/delet method is dished out CeNotInTransactionException, without because in affairs
Update and if adding this example.If attempting to access that the clone's shell outside affairs, then preparation method will be dished out to have and " be visited
Ask invalid shell " CeRuntimeException of message.When accessing or creating any persistable object, ImplC class is real
The concrete kind of example.Such is from corresponding ImplW Similar integral.ImplC class can be with manual modification, to comprise any custom service
The realization of logical method.ImplW class produces completely along with regenerating every time.ImplC class generally produces once, then conduct
The personalization files that can keep and add source control.Note the succession structure of ImplW and ImplC class.ImplW class is from its superclass
ImplC inherit.ImplC is from its corresponding ImplW Similar integral.It is also noted that ImplW is not implemented in interface apoplexy due to endogenous wind and retouches
Service logic API stated.These API are realized by ImplC class.Class can be stated the most in a model, and this can make ImplC class
Abstract.
It is also noted that lasting class and relevant TOPLink transactional replication product can quote its corresponding shell.In TOPLink caching
Lasting example point to the read-only version of its shell.Copy points to the rewritable versions of its shell.When giving copy and closing
And to time in the caching example of TOPLink, corresponding shell becomes invalid.The shell of copy can quote its correspondence read-only outside
Shell, and this can obtain by this shell is called getReadOnlyObject () method.
Need basic class of level to describe this document group.Fig. 6 illustrates the embodiment of this basic class hierarchy.Top at figure
There are 5 basic classes: CmoBaseImpl630, CmoBase634, CmoBaseImplW644, CmoBaseImplS638,
CmoBaseI18N642。
CmoBase634 is the interface class that all objects 332 are all inherited from it and realized.This interface comprises all right
As the 332 all base attributes all must implemented and the descriptions of operation.The various features of this object-oriented framework 610 comprise adds this to
Attribute in interface and method, such that it is able to realize these attributes and method in all objects.CmoBase634 also serves as mark
Remember the approach of the object 332 generated by the mechanism provided in this framework.Replacement class CmsBase702 can be provided, as it is shown in fig. 7,
For need not lasting temporary object.
CmoBaseImplW644 represent include by other realize object (CmoBaseImpl, CmoBaseImplS,
What access CmoBaseI18N) carried out packing realizes shell object.CmoBaseImplW class realizes CmoBase interface.
The purpose of CmoBaseImplW class determines that Impl (for enlivening object) or which example of ImplS (for segmentation object)
Should be called to implement operation.Such has 4 important relationship.LiveObject has the example of CmoBaseImpl object,
The latter's representation database mainly enlivens business object.ShadowObject has the example of CmoBaseImplS object, after
Person's representation database enlivens covering or segmentation version of business object.When clonedObject put into for create or update
After in affairs, this object has the copy of liveObject or shadowObject.When clonedObject comprises
During the copy of shadowObject (this occur in order to update in affairs and create and during this object of segmentation),
LiveClonedObject has the copy of liveObject.
LiveObject has read-only shell.Shell can be made writeable by adding read-only shell to affairs, this returns one
Individual new shell, including the liveObject can being modified in the case of just accessing the user of liveObject not affecting other
Copy.When submitting affairs to, this copy is for sending renewal to data base, and these changes is merged into
In liveObject.Once have submitted writeable shell, this writeable shell is the most useful, and must access read-only shell (this
Writeable shell is made to become rubbish to save memorizer).When implementing any action (create, read, access relation and renewal),
Such example returns to user.
CmoBaseImpl630 representation database enlivens persistable object.Such comprises control object and relationship map
Characteristic.This information allows to create and includes table, arranges, constrains in interior form.Such is included in the attribute defined in object model,
Attribute including representation relation (or there is the single-relation of this object type or use many relations of aggregate type).
Such also realizes CmoBase interface 634.Implement attribute and the acquisition of relation and setting, to access relevant attribute or relation.Its
He service logic method (the describing in a model) UnsupportedOperationException that dishes out prevents the method
Cold call.Only ImplW class should access such, and it should not call any service logic method to Impl class.
CmoBaseImplS638 is exactly substantially the copy of CmoBaseImpl class, but represent Impl strength cover or
" segmentation " value.These fragmentation values are stored in a single table, and are single examples, are thus provided that one individually
Class represents the segmentation being mapped to this independent table.The use of CmoBaseImplS638 is also in the application merged by quoting
It is discussed.
CmoBaseI18N642 is the basic class for International Support.Such have all have can translate string value
The base attribute that is required for of table.When generating the Impl class of object, the inner classes come from CmoBaseI18N642 succession is also
It is generated, if such has can translate string attribute.The example of CmoBaseI18N 642 can corresponding to Impl class
The language translation of translation string attribute.Fragmentation value for this translation provides additional example.Translation list is saved in class layering
Every one-level.This allows to add/delete at any time can translate string attribute, and without CmoBaseI18N class and table point
Rotating fields.These features record in more detail in the application merged by quoting.
When generating object (such as AbstractX646), the class generated extends the most basic class.Such as Fig. 6 institute
Showing, AbstractX646 is the interface inherited from CmoBase basic interface and come.AbstractXImplW 662 from
CmoBaseImplW 644 inherits.AbstractXImpl 646 inherits from CmoBaseImpl 630.
AbstractXImplS 654 inherits from CmoBaseImplS 638.Additionally, due to there is the word translated of AbstractX
Symbol string attribute, AbstractXI18N 658 inherits from CmoBaseI18N 642.
There is also another customization class being referred to as AbstractImplC 666, it is inherited from AbstractXImplW 662
?.ImplC class comprises the business logic codes specific to user of the service logic method for adding interface in model to.
This allows ImplC to can be only generated once, then can only update when needs add, change, or delete business logic codes.Other
The type (interface, ImplW, Impl, ImplS, I18N) of class is always given birth to from object model 320 again when each model changes
Become.Which solving to generate needs manual customization arbitrarily to need reverse design to the code of the change in model, but also allows for write
Can the service logic realization that change over time.The code generated is in need not any writable ImplC
Code in the case of just can use.The service logic method specific to user that ImplC is to be achieved provides place.
Additionally, Fig. 6 illustrates that another is referred to as how the class of X further expands AbstractX class.Each generation class of X
Type all inherit from the suitable Class Type of AbstractX.But, XimplW686 inherits from AbstractXImplC666
, thus the enforcement of XimplC686 can cover any service logic method of AbstractX class, just look like such
It is that direct subclass is such.One aspect of the present invention is to automatically process the succession structure for managing these classes relations and generation
The complexity of code.Intuitively, the business logic codes that user has only to be concerned about in the object of visual modeling and ImplC realizes.
Fig. 7 is to illustrate class CmoBase701 for supporting EJB and J2EE, CmsBase702, CmoAttribute703's
The class figure of aspect.Lasting, the modifiable object of user is inherited from CmoBase701.But, a lot of attributes can be to face
Time and can not be changed by user, therefore their quiescent value can distribute in memorizer create object work replicate
Product.These temporal properties can be inherited from CmsBase702, and the latter has and is applicable to provisional characteristic and attribute.Belonging to
Property the continuing of level, user can change object and include title, description, version maximum number, notice behavior.CmoBase class 701 includes main
Want keyword, " id " i.e. automatically generated.ID is unique for a line in a DB and type.Therefore, completely with complete
The unique ID of office connects database identifier, type and id field.The unique identifier of this connection meets the current of unique ID
The requirement of EJB2.0.The unique identifier connected is additionally operable to horizontal segmentation discussed below, because the ID in CmoBase701 is only
Ensure that be unique in a data base and type.The adeditive attribute of CmoBase701 includes shown state, versioned
With segmentation attribute.As shown in Figure 10, structure from CmoBase inherit or corresponding to such CmoBaseLocal with
CmoBaseRemote class.CmoAttribute703 supports as object customization attribute, such as institute in the application that merges by quoting
Describe.
Fig. 8-10 illustrates that COF instrument and model are supported for EJB and J2EE.Preferably, the business object interface in system
Should expand from the javax.ejb.EJBLocalObject1013 of Figure 10.This mode of extension provides at same Java virtual
The approach of call method on the EJB object run in machine (JVM), without causing the expense relevant to remote access.Each
The business object that individual needs are accessed remotely through computer networks requires that title is identical with local interface and is placed on the independent interface under " ejb " bag.
Remote interface extends avax.ejb.EJBObject1012 and only comprises the method that can be accessed remotely through computer networks.Except local and remote
Outside interface, ejb explanation needs domestic interface to create and finds ejb object, as shown in Figure 9.Each business object has expansion
Open up the local domestic interface 912 of javax.ejb.EJBLocalHome911 and the remote of extension javax.ejb.EJBHome901
Cheng Jiayong interface 902.
The bean class comprising the code implementing service logic generally adds suffix " ImplC " by docking port title orders
Name.The most in fig. 8, PersonImplC842 and EmployeeImplC862 is intended to comprise corresponding to Person and Employ
The object of the service logic of interface 821,841.It not that all operational approaches in " ImplC " can remotely access.Remote parties
Method is implemented by the parameter of nation method and return value are set to serializability (must do so in order to meet EJB).For
Realizing this point, framework has suffix " Bean " (such as local generation that can implement additional long-range operational approach
PersonBean) class.In addition to providing service logic to implement, also implement multiple answer specific to EJB.These answer logical
Cross the javax.ejb.EntityBean interface 1011 in enforcement CmoBaseImplW class (in Fig. 6 644) to be supplied to continue
Object.For providing the answer of EJB function to include ejbCreate (), ejbPostCreate (), ejbFindByPrimaryKey
(PrimaryKey key), ejbLoad (), ejbStore (), ejbRemove (), ejbActivate (), ejbPassivate
(), setEntityContext (EntityContext ctx) and unsetEntityContext ().In these are answered, when
Client computer calls ejbCreate () method when calling create () method on domestic interface.EJB (Enterprise Java Bean) container creates bean (ImplC
Class) example and on this bean, call ejbCreae () method.Enforcement should provide method for: obtain or create
CmoTransaction;This bean is added to these affairs;Initialize shell object;Allocate object ID in advance;Submit affairs to;Return
PrimaryKey object.Need the method that overloads under many circumstances, in order to right by initializing in non vacuum data storehouse retrains
As required parameter.
This container calls ejbPostCreate () method after calling ejbCreate () method immediately.The method should
With ejbCreate (), there is argument as much, and additional initialization is provided and distributes the resource needed within its life-span.
EjbFindByPrimaryKey is called when client computer calls findByPrimaryKey () on domestic interface
(PrimaryKey key) method.This realization should provide method for: instruction need not affairs;According to object id in data
Storehouse is found this object (using CmoClientSession.findById () method);And return PrimaryKey object.The party
Method needs overload to custom-built query.
EjbLoad () answer method corresponds roughly to " reading " function of entity bean.In the reality realizing aspect of the present invention
Execute in example, generally use TOPLink OR to map during create () or find () method and initialize this bean, therefore should
Method may be used for some post-processing operation.
EjbStore () answer method corresponds roughly to " renewal " function of entity bean.This function has been encapsulated in us
CmoTransaction in, except CmoTransaction need be activated and in order to update needs this object is added to
In these affairs, this is true.
EjbRemove () answer method deletes this object from Data Store.CmoTransaction is activated also
Add to delete in this object.
During activation processes, the ejbActivate () method on bean example is called, followed by EjbLoad
() method.Once bean be activated and its state by appropriate with underlying database recording synchronism, then operational approach continues.Appoint
This operational approach is called by subsequently is the most directly entrusted to bean example.
EjbPassivate () uses between deactivation period.During Passivation Treatment, container calls on bean example
ejbStore().Bean example is responsible for more new database.After database update, container calls on bean example
EjbPassivate () method, allows and oneself has an opportunity before passivation bean to discharge the most allocated any resource.
SetEntityContext (EntityContext ctx) side is called by the linguistic context of bean during bean initializes
Method.This linguistic context storage comes for application in the future.UnsetEntityContext () supplements this and arranges linguistic context.If container determines
The resource that release is used by bean, then container can collect the bean of merging as collecting rubbish, and in this situation
Lower affairs can return non-existent state.In this conversion method, container calls the method.The method release is used by this bean
Any resource.
Fig. 8 illustrates that the CBOF object model of compatible EJB is applied to the simple object of personnel and employee, and it has local and remote
Journey accesses and interface.Person821,824 and Employee841,834 objects from
EJBLocalObject811heEJBObject814 implements.The implementing of native object support local, decrease expense
Access.The enforcement of EJBObject supports that remote object accesses.The standard feature of native object is to inherit from CmoBase812
, as mentioned above.In fig. 8, suffix ImplW and ImplC is used for shell and creates enforcement.EntityBean813 passes through
CmoBaseImplW822 implements.The enforcement of Person821 and Employee841 object is from CmoBaseImplW822 succession
Come.These implement to include PersonImplW832, PersonImplC842, EmployeeImplw852 and
EmployeeImplC862.Such as what the context of Fig. 9 was discussed, provide two home object for local and remote interface
EJBLocalHome853 and EJBHome833.The enforcement of these home object includes PersonLocalHome863,
PersonHome 843, EmployeeLocalHome 864 and EmployeeHome 844.
Fig. 9 summarises a part of Fig. 8, and illustrates and need the example compatible to the conventional EJB in one residence of object.For
Remotely and native object and interface 901,911 each provide place.Each business object has and extends
The remote domestic interface 902 of javax.ejb.EJBHome 901 and the basis extending javax.ejb.EJBLocalHome 911
Ground domestic interface 912.Long-range and local domestic interface 902,912 is also by CmoApplicationConfigRemoteHome
903 and CmoApplicationConfigLocalHome 913 extend.
Figure 10 also summarises a part of Fig. 8, and illustrates the additional mechanism supporting EJB.Object
Javax.ejb.EJBObject1012 and javax.ejb.EJBLocalObject1013 expands to CmoBaseRemote1022
And CmoBaseLocal1023.
The relation of EJB inter-entity is supported in EJB2.0 explanation.3 fundamental relation radixes (one to one, one-to-many and multi-to-multi)
All it is supported.Furthermore, it is possible to use the new query language of EJB2.0 explanation to handle these relations.Relation can be by abstract visit
Ask that device method manages.In the relation that the multiformity of related object is many, parameter or the return Value Types of abstractions device are
Represent the collection class of this relation.This collection class implements java.util.Collection or java.util.Set interface.Optional
, these explanations can add java.util.Map and java.util.List as return type.Multiformity in collection class
Being in the relation of, parameter or the return Value Types of abstractions device are the single-instances about object.
Relation visitor in COF has the parameter as corresponding objects array or returns Value Types.So that they
Can be accessed by ejb by remote interface, it should the addition method of relation is provided in remote interface and implements in ImplW.
Such as, Employee To Address Relationship can be one-to-many and be two-way.Local and remote method
May be embodied as crossing a relation, such as Employee To AddressRelationship example.Such as, nation method can
To include: public Address [] getAddresses ();public void setAddresses(Address[]
address);public voidaddAddressElement(Address address);And public
BooleanremoveAddressElement(Address address).Remote method can include may include that
publicCollection getAddressesRemote();public void setAddressesRemote
(Collectionaddress);public void addAddressElementRemote(Address address);With
publicBoolean removeAddressElementRemote(Address address)。getAddressesRemote
The support of () method obtains the objectId list of all address objects relevant to Employee object.Can use
CmoQueryCursor mechanism, because need not buffer any address object.Therefore, from CmoQueryCursor extension, title
New class for CmoObjectCursor is created, to support the long-range instruction of EJB example.The method support utilizes remote domestic
Interface finds or creates ejb object, and stores them in set.The method returns the set of ejb object.
SetAddressesRemote (Collection address) method support utilizes local domestic interface create or find correspondence
Ejb object.Object is stored in array by the method.The method is called the nation method of correspondence and is updated.
Affairs support is the important basic service provided by J2EE platform.This explanation describes JavaTransaction
API(JTA).JTA is to provide the interface accessing bottom task manager.Some primary interface include:
Javax.transaction.UserTransaction and javax.transaction.TransactionManager.
UserTransaction exposes to application assembly, and the bottom between J2EE server and JTATransactionManager is handed over
Mutual is transparent to this application assembly.TransactionManager implements back-level server to (container is distinguished) transaction boundaries
Control.The affairs support of JTA TransactionManager and JDBC is all available for J2EE application assembly.
Two kinds of transaction management examples supported by J2EE platform: declarative affairs are distinguished and planned affairs are distinguished.In declarative differentiation, hold
Device is responsible for starting, submitting to and rollback affairs.Container starts affairs to the user's each operation on bean.Client computer can
If to obtain JTA affairs and to perform the dry run in affairs.This by offer strengthen have between operations dependent certain
The motility of individual service logic.Transaction attributes supports that declarative affairs are distinguished, and passes on the meter about EJB assembly method to container
Draw affairs behavior.
Affairs differentiation 6 transaction attributes of support to Container Management: Required, RequiresNew,
NotSupported, Supports, Mandatory and Never.There is the method for Required transaction attributes in JTA affairs
Perform;According to circumstances, new affairs linguistic context cannot maybe can be created.If invocation component associates with JTA affairs, then hold
The method that device will be invoked in described affairs linguistic context.Associate with invocation component without affairs, then container will automatically create newly
Affairs linguistic context, and attempt to submit this things to when the method completes.According to having the method for RequiresNew transaction attributes in new thing
Business linguistic context performs.If invocation component associates with affairs linguistic context, then creating new affairs linguistic context, the method is at new affairs language
Performing in border, the method restarts the affairs of this invocation component after completing.The method with NotSupported transaction attributes
It it not a part for affairs.If invocation component associates with affairs linguistic context, then container suspends this affairs, call not with affairs
The method of association, and the affairs of invocation component are restarted when the method completes.The method with Support transaction attributes is propped up
Hold the transaction status of invocation component.If invocation component does not has any affairs linguistic context, then container will perform the method, just look like it
Transaction attributes is NotSupported.If invocation component associates with affairs linguistic context, then container will perform the method, seem
Its transaction attributes is Required.The method with Mandatory transaction attributes is adjusted from the affairs linguistic context of this invocation component
With.Otherwise, container will be dished out javax.transaction.TransactionRequiredException.There is Never thing
The method of business attribute never should be called from the affairs linguistic context of invocation component.
Planned transaction differentiation is the hard code of the transaction management in application code.Planned transaction is distinguished Session EJB,
Servlet and Jsp assembly is feasible option.Planned transaction can be JDBC or JTA affairs.Session for Container Management
EJB, can (although at all not recommending) mixing JDBC and JTA affairs.
One aspect of the present invention is can be with segmentation creation data.In data base, asking of repeated work is never made for solution
Topic, the fragmentation value of these data is stored in the data base identical with effective production value by an embodiment.But, this fragmentation value
Should not be present in the table identical with effective production value.If segment data is in identical table, then the performance of table and size
Will be affected.Therefore, for each object needing pitch capability, data base can exist two tables.Due to then
Needing add list, therefore OR mapping tool needs another java class to represent this table.For the Impl class of sectional, deposit
In corresponding ImplS class.Class formation and OR mapping is automatically processed, it is therefore desirable to add add list together with creating with sheet format
And/or the effort of class is actually reduced.
Copy to existing object properties new object is typically very directly simple.But, segmentation may also be supported
The change of relation between object.In order to support all segmentation features, need to define some rules:
1. the active object instance that produces can quote its fragment instance.Can only be segmented at certain time object and once (change
Sentence is talked about, and the relation between this object and its fragment instance is man-to-man two-way privately owned relation).
The most once by object fragments, its effective example cannot be revised.If this effective example can be changed, then need by
The change carried out in fragmentation value merges with virtual value.Generally, change needs are segmented or are directly enlivening amendment on object, it is impossible to
Both carry out.
3. relation is for effective example rather than for fragment instance.Otherwise, a lot of relationship map are necessary for being managed
Reason (effectively to segmentation, effectively to effective, segmentation to effective and segmentation to segmentation).Additionally, change to effectively from segmentation when object or
Otherwise, the relation just for this object needs to manage this change.This rule simplifies these problems.Additionally, be cited is effective
Example with segmentation, and can quote its fragment instance, the most still supports various relation, but is not direct.
4. segmentation change must be a part for sectional project.The method managing a set of segmentation change is they to be combined
In same container.All objects that sectional project tracking has been segmented into.Then this project can be configured for testing, or
Delete it.
5. can only be segmented once at certain time object, and be a part for single sectional project.Management merges
Typically also without.
Support one-one relationship in segmentation table owing to above-mentioned rule #3 is easily.All relations all refer to effective reality
Example, the segmentation tabular therefore pointing to another object has only to point to effective example of this another object.Many-one relationship must make
Use intermediate interactions table, even if this relation is two-way.This prevent and enliven Object table and have to be understood that any pass with fragment instance
System.
Many-to-many relationship also has the intermediate interactions table that fragment instance is linked to effective example.These intermediate interactions tables must
Must be from existing to enliven object relation table different.If many-to-many relationship is two-way, then need to create two intermediate interactions tables,
One is used for each direction.This is because this relation can be segmented from either party of this relation, and there is different values.Attached
Add relation table automatically and to effectively generate.
Other aspects of the present invention are the horizontal segmentation in intermediate layer, as with so-called back-office i.e. database layer phase
To.Figure 11 briefly shows horizontal segmentation.In this embodiment, object model includes that assembly 1 (1101) is to n (1102), account 1102
And BI1104.Assembly 1 is mapped to main 1111 data bases, and the latter is centralized database.By between data base by horizontal segmentation,
Assembly n is mapped to master 1111 and main 1112 data bases.Assembly n can be single object or a group objects.For bag and specify by
This group objects carries out the instrument of horizontal segmentation may be very useful.Described above is this instrument for arranging project characteristic, and
And be very familiar with for the user of Rational Rose.Or, it is provided that for object is distributed to one group or many
Group, the group default properties that then setting will not be capped or the instrument of group global property.In any one embodiment, as list
One result arranged makes a group objects be very use by (or not being subject to) horizontal segmentation.The mapping of assembly 1...n is in this embodiment
Can be configured by database description.The explanation side of table or user readable (such as XML) configuration file that such as user completes
Method may be used for the logical name of specified database and/or is connected with object and object group by the logical name of data base.At this
In example, account and BI have been respectively mapped to safety 1113 and BI1114 data bases.
Support that the class carrying out horizontal segmentation in intermediate layer is applicable to and data base or the interface of data basic structure, in this example
In be applicable to the interface with TopLink.Figure 12 illustrates the class that may be used in the segmentation of intermediate layer carrying out horizontal.This figure is on left top
It is initially with CmoServerSession1221 and is easy to allow people understand.This object has the data base that this basic structure needs
Connect and information.Owing to the logical identifier of data base is static, therefore this object can have static data and static method,
And can be shared by multiple users.CmoSystemSession1231 can obtain from server session 1221.Have only to for
Server creates single system session object, and CmoClientSession object 1241 has each use for this server
The linguistic context at family and status information.This object has place and the registration of the information specific to user, such as user.Holding is similar to
Status information for the status information that http session keeps.Method getDb and setDb are used for arranging language ambience information.Client computer meeting
Words can relate to some data bases.Relation # between client session 1241 and any alive data storehouse session 1242
DbClientSessions is 0...* relation.It is effective for not having database client session when obtaining client session.?
During the life of client session, a lot of database client sessions can become effective.
CmoTransaction 1251 target cache in the figure is by by the data of horizontal segmentation.
The role of CmoTransaction is to maintain the state of affairs, including the affairs that the life-span is the longest, until these affairs are ready to submit to
Till.Owing to collecting this affairs, therefore collect the information allowing decision which data base new or amended object belongs to.
When these affairs are ready to submit to, it can be by CmoDatabaseTransaction 1252 in one or more data bases
One or more examples submit to.
Horizontal segmentation is supported, can add basis to including middle column object 1212,1222,1232,1242 and 1252 and connect
In the existing arrangement of mouthfuls 1223,1243,1253 and the session 1221,1241,1251 that exposes, without changing outside these sessions
Dew mode or change the operable service logic of object that these sessions expose.Such as, horizontal segmentation may be used for supporting two
Use same code and automaker F and G of software.All data for F can such as be divided into Oracle number
According to storehouse, all data for G can be divided into SQL database.It is provided with linguistic context F or G once such as log in user,
The segmentation of data is exactly transparent for system.All call F data is all carried out for oracle database, and owns
G data is called and all carries out for SQL database.Identity logic can be applied, be available to F also regardless of this data, services
It is G.The code implementing service logic even can be shared, because only that linguistic context arranges the data just identifying or distinguishing F and G.
Segmentation on this grade can isolate the data of client.Less data base can be by more efficiently process.Even if preparing for after
Public room i.e. database server level, the search that F is carried out also will never consider the data of G.With SQL, QL or other data base querying
The mixing of code will not return data from more than one data base, and this can reduce a client and obtain other customer datas of access
Chance.This is particularly useful in race condition, such as when some assembly of lawyer's shared data bank of plaintiff and defendant but uncommon
Hope and their work product is strictly kept apart, or when competitor's use with the addition of service and the service supplier of identical value
It is desired to ensure that the data of two clients (competitor) are the safest.While the data of client and other client keep apart, week
Phase maintenance function can be completed by the system manager of repeat specification in multiple client's linguistic context.
Middle column object 1212,1222,1232,1242,1252 is supported based on the linguistic context access to multiple data bases, wherein
The example of the horizontal segmentation of multiple database purchase same object.CmoDatabaseServerSession object 1222 is each
On the server effective data base and exist.The identification of data base's logic by logical name is given
CmoDatabaseServerSession object 1222, this logical name can be protected as key attribute dbName of this object
Hold.GetAllVersions method supports version management.The method can return version or the lattice of the object in data base
Formula version.The code accessing data base or the code authorizing this data base of access should check that version is compatible.
Object is connected to data base by CmoClassConfiguration object 1212.CmoClassConfiguration object 1212
Addressable object in representation database.CuDatabaseConfig1232 has the physics number corresponding to logical data base title
According to storehouse configuration information.This information may be used for arranging according to linguistic context multiple physical databases are connected to a logical name.
CmoDatabaseServerSession object 1222 is connected to basic object by #serverSession relation
ServerSession 1223.CmoDatabaseClientSession1242 basic object ClientSession1243 manages
Reason client session, considers the linguistic context of this client computer (F or G in this embodiment) simultaneously.
Again accessing the operation of CmoTransaction1251, when getting out submit to affairs, CmoTransaction uses
Suitable linguistic context arranges and calls CmoDatabaseTransaction1252.CmoDatabaseTransaction1252 linker
UnitOfWork in this object 1253, such as TopLink, to process one or Two-phase commitment of this object.
Two-phase commitment is a kind of transaction protocol submitted in an atomic manner and change in multiple physical data.An enforcement
In example, Application Server based on JTS is (any double with J2EE1.3 to support the component software of Two-phase commitment to include
The App Server held), in Distributed Transaction support in JDBC driver (such as Opta2000 and Seropto) and data base
The Distributed Transaction support of (such as SQL Server and Oracle).COF and COF/EJB uses TopLink to support and based on JTS
The task manager (generally being provided by J2EE application server) of (Java Transaction Service) carries out affairs fusion.Two-phase commitment
Use is an option.The cost of Two-phase commitment is very big, therefore only uses when needed.Affect multiple object and cross over multiple
The user's business of physical database generally uses Two-phase commitment affairs.When EJB object and COF object need in affairs
During submission, Two-phase commitment is suitable.This agreement can be with any group of COF object, the object of horizontal segmentation and EJB object
Conjunction is used together.
Attention level segmentation is not dependent on COF or another agreement is to be used directly also to be packaged in EJB or other is long-range
In method call encapsulation.Intermediate layer encapsulation process horizontal segmentation between self contained data base, and it is independent of database manager.
This can be cited as the horizontal segmentation of loose coupling, because self contained data base can even is that incompatible with disparate databases supplier
Data base.
Relatively small number of service logic or system code are also required to change, to use horizontal segmentation.Some fundamental rules arrange
Table is as follows.
If 1. in configuration file, only one of which data base be currently in use, it means that characteristic
The value of " database.projects " is single, then this data base will always be used.
If configuration file 2. exists more than one data base, then understand or analytical data vaguely when performing operation
Storehouse information.Clearly analyzing the meaning is to call on CmoClientSession object and/or CmoTransaction object
“setDb(CuDatabaseConfig)”.CuDatabaseConfig object generally creates when system start-up.For for whole
System obtains the list of availability database object.For certain kinds, " CmoServerSession.getDbObjectsForClas
S (Class aCLass) " and " CmoServerSession.getDbObjectsForClass (String aCLassName) "
Return the list of " class " resident CuDatabaseConfig object.Fuzzy analysis the meaning be CmoClientSession and/
Or which data base CmoTransaction object can find be processed and without at application code cleverly
In call especially " setDb (CuDatabaseConfig) ", as described below.
3. when data message clearly can not be analyzed on CmoClientSession and CmoTransaction object, meeting
Words object is attempted with involved all objects to analyze this information.If involved any object has some data bases
Information (non-NULL), then this information compares with the database information of correlating sessions object.If the data for session object
Storehouse information is empty, then this database information is set to the data message from this object;This information is different else if, then give
Go out exception.Involved all objects are all continued by this logic.In order to contribute to identifying for operation and/or the data base of things
Information, COF has introduced new interface " CmoDbConflictResolver ".It it is a project configuration
CmoDbConflictResolver object.This can be at keyword: database.Conflictresolver.{full
Class name of project}={fullclass name that implements CmoDbConflictResolver
The configuration of interface} is carried out.
4. calling analyzer in the most possible moment, the meaning is if creating object, then attempt to submit to this object it
Before will not call this analyzer.It means that analyzer is it is anticipated that all properties of this object is all to arrange for establishment, and
Can be used for them determining which data base this object should belong to.
When finding, by expression or attribute query or attribute map locating, thus analyzer can be based on just
Which data base querying the attribute being queried determines for.We never support that integration across database is looked in a single inquiry
Ask.Only when also not calling setDb on clientSession and the object that is just being queried has been configured as being present in more than one
Individual data base just needs do so.
Can realize the approach of CmoDbConflictResolver be use some configuration informations or other illustrate that some are right
As property value is mapped to the dynamic data of specific physical database.This should be the simplest.Such as, the group of this object is used
Knit id and determine based on orgId names which data base or which data base, thus this is a single mapping.These data
Library name is " logic " title, determines to come for one title of data base and such as its position etc. when configuration/installation
Configuration information.Therefore, the title that therefore we use is logical name, and represents the database-name that configuration accesses, and not
It it is the actual physics database name in data system.
In client session, available 4 functions are controlled database information.They are: setDb
(CuDatabaseConfig);getDb();overrideDb(CuDatabaseConfig);resetDb().GetDb () only returns
Return and be arranged on the current database on clientSession object;OverrideDb (CuDatabaseConfig aNewdb) and
ResetDb () uses Stack mechanism to follow the tracks of the change of the database information on clientSession.overrideDb
Current db is pushed storehouse by (CuDatabaseConfig aNewdb), and current db is set to " aNewdb " having been enter into.As
Really storehouse non-NULL, then current db is set to the top element of storehouse by resetDb ();The most do not do anything.setDb
Current db is set to " aNewdb2 " and empties storehouse by (CuDatabaseConfig aNewdb2).Therefore, if when storehouse has
Call setDb () when having some information, then storehouse is simply cleared.System client session pair as particular client chance words
As each thread basis being used this 4 functions.Therefore the database information on a thread and the data on another thread
Storehouse information is unrelated.
OverrideDb (CuDatabaseConfig) and resetDb () function can not be adjusted on CmoTransaction
With, although this is the subclass of CmoClientSession.
CmoDbConflictResolver API includes: public CuDatabaseConfigresolveCreate
(CmoDbResolverinfo aDbResolverInfo) dish out CeDbNameConflictResolveException;
Public CuDatabaseConfigresolveFind (CmoDbResolverinfo aDbResolverInfo) dishes out
CeDbNameConflictResolveException.CmoDbResolverinfo API includes:
publicCmoClientSession getClientSession();public Class getMainclass();public
HahMapgetAttValuePairs();public CmoFindObject getFindObject();public
CmoBasegetNewlyCreatedObject()。
After developing the class implementing CmoDbResolverinfo interface, in CmoDbResolverinfo
GetNewlyCreatedObject () may be used for helping to implement resolveCreate (CmoDbResolverinfo);Equally,
GetAttValuePairs () and/or getFindObject () in CmoDbResolverinfo may be used for implementing
resolveFind(CmoDbResolverinfo)。
From foregoing description, it will be apparent to those skilled in the art that various system and method can be in terms of the present invention
Build with in part.One embodiment is one embodiment of the present of invention, including the side generating application development code
Method.The method is it can in addition contain be implemented as system or the device of the method step.This system or device can include some
Embodiment, is combined with the step of the method, aspect, option and alternative embodiment.The method is also implemented as being carved with execution should
The magnetizing mediums of the program of method step.The generation of exploitation code can be especially useful for the encapsulation business applied environment of multilamellar.The party
Method object based on OO application programming, relation and the model of operation.To these objects, relation and operation
Modeling can use graphical tool to realize visually.The characteristic distributing to object, relation and/or operation can include representing
Whether generate the first characteristic of interface with modeling object.Also include indicating whether generating this locality with assigned operation and/or remote
Second characteristic of journey interface.From this model, generate corresponding to this model and the machine-readable data of characteristic thereof.These data can
To realize in interior model or output model.This model can be by machine recognition, it is also possible to identified by the mankind.Machine readable
Data are for being mapped as data base by model.In one embodiment, data base is relational database.Employing maps and machine can
Read data genaration application development code.The application code generated can include object in lasting accesses database
Code.Can also include exchanging the interface of the code of object in this lasting accesses database.This is consistent with the first characteristic.Also
Can include the interface with assigned operation, this is consistent with the second characteristic.Actually may be used with the interface of described code and assigned operation
With component model and remote method invocation (RMI) protocol-compliant with measured server end.Substitute, application development
Code can actually with Enterprise JavaBean (EJB) standard 2.0 or update edition compatibility.Continue and access EJB pair
The code of elephant can actually with managed by bean continue (BMP) protocol-compliant.Substituting, application development code is permissible
The actually DCOM with Microsoft illustrates compatibility.In another aspect of this invention, OO Application Design can be actual
Go up and UML (UML) standard is compatible.
One aspect of application and development code method includes generating the method fragment adding custom service logic.In order to realize
This aspect of the invention, the code generated when amendment is for the object-oriented model of system with comprise custom service logic
Code-insulated comes, and should not be capped or regenerate when revising object-oriented model.
Another aspect of the present invention also includes that multiple 3rd characteristics of object and relation, the 3rd Characteristics Control map step
Suddenly.These characteristics are for by object and underlying database that relationship map is such as relational database.These the 3rd characteristics are permissible
Include whether to support the segmentation of the configuration to modeling object.Also include whether to record the change histories of the configuration of modeling object.Also
Include whether that the one or more fields in Dynamic Array modeling object are with these fields that internationalize.With the present invention relates to dynamically
The aspect of array field is associated, and lasting and Access modeling object code can be analyzed and retrieve dynamically based on appointed language
Which element of array.This language can be specified by data existing in object being processed are fuzzy, or is understood by language
Specify.
Another aspect of the present invention is user can specify which application code of generation, generates machine-readable data, mapping
Can continue in the case of the further action not having user with the method step of additional generation.
Another aspect of the present invention is that the database manager that a kind of set is supported issued transaction by least one processes
The method of affairs.Replacing, the method can be implemented as performing system or the device of the method step.This system or device are permissible
Including some embodiments, it is combined with the step of the method, aspect, option and alternative embodiment.The method is also implemented as carving
There is the magnetizing mediums of the program performing the method step.The method can include providing is propped up by the issued transaction of database manager
Hold the object oriented framework accessing the method with duration data.It addition, also provide for actually with measured server end
Component model and the object oriented framework of remote method invocation (RMI) protocol-compliant.The component model of measured server end with
And the example of remote method invocation (RMI) agreement includes Enterprise JavaBean (EJB), Distributed Common Object model (DCOM)
And CORBA.The method of set affairs can also include accepting or relevant to affairs for one or more data bases of caching
Movable.This acceptance or caching can be carried out by the compatible version of OO framework He this OO framework simultaneously.
One aspect of this embodiment is to accept step to include cache object, and when affairs are submitted in instruction to, the method is also wrapped
Include and call database manager to process affairs.The aspects includes and accepted and affairs phase by the mechanism of non-database manager
The activity closed.This aspect of the invention can use any of the above described standard implementation, including EJB, DCOM and CORBA.
Other embodiments of the invention are that the data management system machine that a kind of set is supported issued transaction by least one processes
The method of affairs.As it has been described above, the method is also implemented as method, device or includes that the magnetic implementing the program of the method is situated between
Matter.The replacement method of this embodiment is the approximation deformation of above-mentioned collection approach.A kind of deformation includes that data base administration is passed through in offer
The issued transaction support access of device and the object oriented framework of the method for duration data.The method also include offer be applicable to
Process that EJB standard is compatible and the object oriented framework version called.The method also include simultaneously by object oriented framework and
The object oriented framework version compatible to EJB standard accepts activity relevant with affairs, for one or more data bases.?
In other two deformation of this embodiment, object oriented framework is applicable to compatible with DCOM or CORBA.Deform at any one
In, the thing of acceptance potentially includes cache object and calls database manager to process this affairs when submitting affairs to.
Another embodiment is the method making the data that processed by least one database manager lasting.As it has been described above,
The method is also implemented as method, device or includes implementing the magnetizing mediums of the program of the method.The method bag of duration data
Include and provide by database manager access and the object oriented framework of the method for duration data.Also include providing by data pipe
That reason device accesses the method with duration data and that standard is compatible interface.These interfaces compatible with standard can with EJB,
DCOM or CORBA is compatible.The method also includes being accepted for one by object oriented framework and the interface compatible with standard simultaneously
Individual or the object accesses of multiple data base and continuation requests.When standard is EJB, object requests can be by OO framework
With the interface compatible with EJB standard submits to Java transaction services engine.
The aspect that may be used for any of above embodiment of the present invention is that object oriented framework is applicable to accurate object
Last till in data base.The interface compatible with standard, including the interface compatible with EJB standard, it is adaptable to by the object in affairs
Last till in more than one data base.
Another embodiment of the present invention is to gather to process the database manager being supported issued transaction by least one
The method of things.As it has been described above, the method is also implemented as method, device or includes that the magnetic implementing the program of the method is situated between
Matter.The method includes the method providing issued transaction support access and duration data by database manager and implements additional
The object oriented framework of the method for function.This additional function can be to be divided by object to test and add production system to
Section.This additional function can also is that the change histories following the tracks of object in production system.Or, can be by field in object
Carry out Dynamic Array with these fields that internationalize.These additional functions can combine in pairs or all.The method of set affairs
Also include additionally providing actually with measured server-side component model and the face of remote method invocation (RMI) protocol-compliant
To object-oriented framework version, this version also includes one or more above-mentioned additional function.Individually embodiment includes single additional merit
Energy, the combination of paired additional function and whole 3 additional functions.The standard that the present invention of set affairs is compatible can be EJB,
DCOM or CORBA.
Another embodiment of the present invention is a kind of to generate data base and the method by the multilamellar service application of horizontal segmentation.As
Upper described, the method is also implemented as method, device or includes realizing the magnetizing mediums of program of the method.The method include by
Object and relationship modeling, and specify the operation of object-oriented Application Design, wherein this Properties of Objects includes whether that level is divided
Cut the object across multiple data bases.The method can apply to object or object group.Object group can be come by a logical name
Represent.The method also includes generating the machine-readable data corresponding to model, including characteristic.This machine-readable data can
By machine recognition, it is also possible to identified by people, as XML illustrates.The method also includes that model is mapped as this machine of multiple use can
Read the data base of data, and from this mapping and machine-readable data, additionally generate application and development code.This application and development generation
Code includes the code continuing and accessing the object across multiple data bases.Continue and the code of access object is on database layer
The part of interlude layer.Another aspect of the present invention is that the code continuing and accessing object can call multiple independent digit
According to storehouse.These self contained data bases can be provided by different database suppliers, although or being carried by a database supplier
Supplying can also independent operating.The another aspect of this embodiment can include the data base that multiple cutting object thereon is described, with
And one or more field for object or object component are segmented into certain database is described.
Another embodiment of the present invention is a kind of to include at least database layer and many layer services of intermediary service application layer
The method carrying out horizontal segmentation object across multiple self contained data bases in application.As it has been described above, the method is also implemented as method, dress
Put or include realizing the magnetizing mediums of program of the method.This embodiment is included at least one by explanation in the object of horizontal segmentation
One or more fields that may be used for special object is assigned to certain database.The method includes setting up with multiple by level
The connection of the data base belonging to object of segmentation, although need not and by all Databases belonging to the object of horizontal segmentation
Connect.Before or after establishing the connections, the method include caching one or more need to find, create or need to find or
The object created, including by the object of horizontal segmentation.When finding or create, the field of explanation is utilized to analyze this object
Affiliated certain database, and call this certain database in database layer, to perform find or create.Similar embodiment
It is a kind of method carrying out horizontal segmentation object across multiple self contained data bases, including setting up with at least one by the object of horizontal segmentation
The connection of the multiple data bases belonging to Ke Neng.Additionally, arrange or identify the certain database belonging to object of horizontal segmentation.Setting
Before or after putting step, cache one or more object needing and finding, create or need to find or create, including by level
The object of segmentation.When finding or create, call this certain database in database layer to perform find or create.Quilt
Multiple data bases belonging to the object of horizontal segmentation can be marked with a logical name jointly.Use by the one of horizontal segmentation object
Individual or multiple attributes carry out the certain database in the multiple data base of logical mappings.These attributes can be this horizontal segmentation object
Field.
Although passing through with reference to preferred embodiment and above examples disclose the present invention, it is possible to understand that these examples being to say
Bright and unrestricted.Computer aided processing implies in the embodiments described.Therefore, the present invention real can also be currently used for meter
The method of calculation machine aid in treatment, include implementing the system of the logic of the method, be carved with the medium of the logic implementing the method, have
The data stream implementing the logic of the method or the process service accessed by computer.Those skilled in the art may expect
Amendment in the scope of spirit and claims of the present invention and combination.
Claims (4)
1. one kind in the multilamellar service application include at least database layer and intermediary service application layer across multiple self contained data bases
The method carrying out horizontal segmentation object, including:
Special object in described object is stated multiple may be used for the multiple horizontal segmentation in this special object right
As distributing to the field of multiple data base;
Setting up the connection between described special object and multiple data base, described special object can be based on the field value stated by water
Divide equally and cut to the plurality of data base;
Cache one or more object needing to find or create, including described special object;And
When receiving the instruction carrying out finding or create, utilize the field of statement in described special object described specific to resolve
Multiple data bases belonging to object, and call the plurality of data base in database layer perform described in find or create.
2. one kind in the multilamellar service application include at least database layer and intermediary service application layer across multiple self contained data bases
The method carrying out horizontal segmentation object, including:
Setting up the special object in described object and the connection between multiple data base, this special object can be based on the field of statement
It is worth by horizontal segmentation to the plurality of data base;
The plurality of data base belonging to described special object is set;
Before or after this setting steps, cache one or more object needing and finding or create, including described specific right
As;And
When receiving the instruction carrying out finding or create, call the plurality of data base in database layer perform to find or
Create.
Method the most according to claim 2, wherein, the plurality of data base is marked with a logical name jointly, and these are many
Certain database in individual data base is logically mapped out of one or more adeditive attribute.
Method the most according to claim 3, wherein, described adeditive attribute is the field of described special object.
Applications Claiming Priority (3)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
US28191402A | 2002-10-28 | 2002-10-28 | |
US10/281,914 | 2002-10-28 | ||
CNB038257335A CN100552625C (en) | 2002-10-28 | 2003-08-21 | Transparent EJB supports and horizontal data is cut apart |
Related Parent Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CNB038257335A Division CN100552625C (en) | 2002-10-28 | 2003-08-21 | Transparent EJB supports and horizontal data is cut apart |
Publications (2)
Publication Number | Publication Date |
---|---|
CN101630259A CN101630259A (en) | 2010-01-20 |
CN101630259B true CN101630259B (en) | 2016-09-14 |
Family
ID=32228781
Family Applications (3)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN2009101634291A Expired - Fee Related CN101630331B (en) | 2002-10-28 | 2003-08-21 | Transparent ejb support and horizontal data partitioning |
CN200910163430.4A Expired - Fee Related CN101630259B (en) | 2002-10-28 | 2003-08-21 | Transparent EJB supports and horizontal data is split |
CNB038257335A Expired - Fee Related CN100552625C (en) | 2002-10-28 | 2003-08-21 | Transparent EJB supports and horizontal data is cut apart |
Family Applications Before (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN2009101634291A Expired - Fee Related CN101630331B (en) | 2002-10-28 | 2003-08-21 | Transparent ejb support and horizontal data partitioning |
Family Applications After (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CNB038257335A Expired - Fee Related CN100552625C (en) | 2002-10-28 | 2003-08-21 | Transparent EJB supports and horizontal data is cut apart |
Country Status (6)
Country | Link |
---|---|
EP (1) | EP1579297A4 (en) |
JP (1) | JP2006504194A (en) |
KR (1) | KR20050065638A (en) |
CN (3) | CN101630331B (en) |
AU (2) | AU2003263943B2 (en) |
WO (1) | WO2004040399A2 (en) |
Families Citing this family (15)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US7676791B2 (en) * | 2004-07-09 | 2010-03-09 | Microsoft Corporation | Implementation of concurrent programs in object-oriented languages |
US7890926B2 (en) * | 2005-01-04 | 2011-02-15 | Vaakya Technologies Private Limited | System and method for application development and deployment |
US8141032B2 (en) | 2007-02-02 | 2012-03-20 | Microsoft Corporation | N-tiered applications support via common interface |
KR101470319B1 (en) * | 2008-02-15 | 2014-12-08 | 삼성전자주식회사 | Method and apparatus for generating virtual software platform based on component model and validating software platform architecture using thereof |
KR100945181B1 (en) * | 2008-03-26 | 2010-03-03 | 한양대학교 산학협력단 | Storage system, middle storage and data management method for data protection using file name |
US8396845B2 (en) * | 2008-09-26 | 2013-03-12 | Microsoft Corporation | Data-tier application component |
CN103186564A (en) * | 2011-12-28 | 2013-07-03 | 深圳市金蝶中间件有限公司 | Data object processing method and system |
CN105827671A (en) * | 2015-01-04 | 2016-08-03 | 深圳市领耀东方科技股份有限公司 | System platform characterized by distributed use and centralized management and portal server |
US9916373B2 (en) | 2015-03-26 | 2018-03-13 | Red Hat, Inc. | Dynamic data partitioning extension |
CN108287717B (en) * | 2017-03-13 | 2021-03-09 | 平安科技(深圳)有限公司 | Jar packet generation method and terminal |
US11936739B2 (en) * | 2019-09-12 | 2024-03-19 | Oracle International Corporation | Automated reset of session state |
KR102258241B1 (en) * | 2019-11-18 | 2021-06-01 | 주식회사 오픈드래프트 | Server side data component for support of development and management and method for perform the data component |
US11372675B2 (en) * | 2020-06-15 | 2022-06-28 | Bank Of America Corporation | Jobs synchronize framework |
WO2022010491A1 (en) * | 2020-07-10 | 2022-01-13 | Hewlett-Packard Development Company, L.P. | Application version switching |
WO2024039382A1 (en) * | 2022-08-17 | 2024-02-22 | Rakuten Mobile, Inc. | Method and uniqueness constraint management server for managing uniqueness constraints associated with entities |
Family Cites Families (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US6263342B1 (en) * | 1998-04-01 | 2001-07-17 | International Business Machines Corp. | Federated searching of heterogeneous datastores using a federated datastore object |
US6067548A (en) * | 1998-07-16 | 2000-05-23 | E Guanxi, Inc. | Dynamic organization model and management computing system and method therefor |
US7152228B2 (en) * | 1999-07-08 | 2006-12-19 | Science Applications International Corporation | Automatically generated objects within extensible object frameworks and links to enterprise resources |
US6370541B1 (en) * | 1999-09-21 | 2002-04-09 | International Business Machines Corporation | Design and implementation of a client/server framework for federated multi-search and update across heterogeneous datastores |
US7404175B2 (en) * | 2000-10-10 | 2008-07-22 | Bea Systems, Inc. | Smart generator |
AU2001226401A1 (en) * | 2000-01-14 | 2001-07-24 | Saba Software, Inc. | Method and apparatus for a business applications server |
US6631519B1 (en) * | 2000-03-30 | 2003-10-07 | Microsoft Corporation | Automated schema and interface generation |
AU2001259107A1 (en) * | 2000-04-21 | 2001-11-07 | Togethersoft Corporation | Methods and systems for supporting and deploying distributed computing components |
WO2002019652A2 (en) * | 2000-08-28 | 2002-03-07 | Ramesh Venkataramaiah | System and method for transmitting and retrieving data via a distributed persistence framework |
US20030018694A1 (en) * | 2000-09-01 | 2003-01-23 | Shuang Chen | System, method, uses, products, program products, and business methods for distributed internet and distributed network services over multi-tiered networks |
WO2002046916A2 (en) * | 2000-10-20 | 2002-06-13 | Polexis, Inc. | Extensible information system (xis) |
US20030212987A1 (en) * | 2001-02-28 | 2003-11-13 | Demuth Steven J. | Client container for building EJB-hosted java applications |
US6847974B2 (en) * | 2001-03-26 | 2005-01-25 | Us Search.Com Inc | Method and apparatus for intelligent data assimilation |
US7149730B2 (en) * | 2002-05-03 | 2006-12-12 | Ward Mullins | Dynamic class inheritance and distributed caching with object relational mapping and cartesian model support in a database manipulation and mapping system |
-
2003
- 2003-08-21 CN CN2009101634291A patent/CN101630331B/en not_active Expired - Fee Related
- 2003-08-21 WO PCT/US2003/026010 patent/WO2004040399A2/en active Application Filing
- 2003-08-21 JP JP2004548300A patent/JP2006504194A/en active Pending
- 2003-08-21 AU AU2003263943A patent/AU2003263943B2/en not_active Ceased
- 2003-08-21 CN CN200910163430.4A patent/CN101630259B/en not_active Expired - Fee Related
- 2003-08-21 EP EP03809930A patent/EP1579297A4/en not_active Withdrawn
- 2003-08-21 CN CNB038257335A patent/CN100552625C/en not_active Expired - Fee Related
- 2003-08-21 KR KR1020057007438A patent/KR20050065638A/en not_active Application Discontinuation
-
2010
- 2010-04-15 AU AU2010201505A patent/AU2010201505A1/en not_active Abandoned
Also Published As
Publication number | Publication date |
---|---|
AU2010201505A1 (en) | 2010-05-06 |
CN100552625C (en) | 2009-10-21 |
WO2004040399A2 (en) | 2004-05-13 |
AU2003263943A1 (en) | 2004-05-25 |
JP2006504194A (en) | 2006-02-02 |
AU2003263943B2 (en) | 2010-01-21 |
CN1729448A (en) | 2006-02-01 |
CN101630331B (en) | 2011-04-06 |
KR20050065638A (en) | 2005-06-29 |
CN101630331A (en) | 2010-01-20 |
CN101630259A (en) | 2010-01-20 |
EP1579297A4 (en) | 2008-07-02 |
EP1579297A2 (en) | 2005-09-28 |
WO2004040399A3 (en) | 2005-09-29 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
Bauer | Hibernate in action | |
CN100550010C (en) | Be used for application program and system and method based on the storage platform interface of item | |
US6662188B1 (en) | Metadata model | |
JP4594306B2 (en) | Self-describing business object | |
CN100570549C (en) | The system and method that is used for the data modeling of project-based storage platform | |
CN101630259B (en) | Transparent EJB supports and horizontal data is split | |
JP4571636B2 (en) | Service management of service-oriented business framework | |
Blakeley et al. | The ado. net entity framework: Making the conceptual level real | |
Staudt et al. | The role of metadata for data warehousing | |
Ogheneovo et al. | An Object Relational Mapping Technique for Java Framework | |
Peng et al. | Using object deputy model to prepare data for data warehousing | |
Mak et al. | Hibernate Recipes: A Problem-Solution Approach | |
Hamilton et al. | ADO. NET in a Nutshell | |
Morris et al. | Database management systems in engineering | |
Kappel et al. | Database requirements for CIM applications | |
Revathi et al. | Auto JSON: An Automatic Transformation Model for Converting Relational Database to Non-relational Documents | |
Roantree | Engineering Federated Information Systems: Proceedings of the 3rd Workshop, EFIS 2000, June 19-20, 2000, Dublin (Ireland) | |
Case et al. | A generic object-oriented design methodology incorporating database considerations | |
Alia et al. | A middleware framework for the persistence and querying of java objects | |
Hohenstein et al. | An aspect-oriented implementation of the ejb3. 0 persistence concept | |
Hohenstein | Using aspect-orientation to add persistency to applications | |
Klausner | Semantic XVSM: design and implementation | |
Morris | Database management systems in engineering | |
Semenov et al. | Distributed STEP-Compliant Platform for Multimodal Collaboration in Architecture, Engineering, and Construction | |
Sam-Bodden | Object Relational Mapping with Hibernate |
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 | ||
CF01 | Termination of patent right due to non-payment of annual fee |
Granted publication date: 20160914 Termination date: 20190821 |
|
CF01 | Termination of patent right due to non-payment of annual fee |