The present invention relates generally to object models, and more particularly to a method and system for generating dynamic comparison models.
Models are often used to help visualize concepts by using symbolic representations. Models may include a group of objects, entities, properties, or attributes. For example, a model may be a category of type “planets.” An object within the model may be a specific planet, such as Earth. Properties or attributes within the object may be characteristics, such as size, population, or relative location.
It is often desirable to compare two models to determine any differences between the models. Comparing two different models can help to ensure that the models are synchronized and semantically valid at all times. Existing tools are available that compare different models and identify the differences between the models. For example, a comparison tool called COMPLETE COMPARE™ (available from CA, Inc.) provides one way of comparing models. Previous architectures of the COMPLETE COMPARE™ comparison tool represented the comparison of two models in a set of ‘C’ (the programming language) structures. These structures maintained the memory address of the two models being compared, and a flag indicating the state of equality between them. Then, the COMPLETE COMPARE™ comparison tool displayed the comparison data. In order to synchronize the models, the user designated data in one model that the user wanted to import into the second model. The changes requested by the user were incorporated in an asynchronous or batch mode, in which the changes were held in a script and executed at the end of the comparison process.
This approach often suffered from side-effects. Side-effects are encountered during the act of bringing data into a target model (e.g., in order to synchronize it with another model). Since side-effects did not become immediately visible to the user in real-time, as the user was indicating the desired changes, this often resulted in changes that the user did not intend. In other cases, side-effects might cause a violation of modeling rules and cause certain actions to fail or result in an invalid model.
The present invention is related to a system and method for comparing models, and generating a dynamic comparison model that identifies differences between the compared models. The teachings of the present invention also allow a user to utilize the dynamic comparison model to designate changes to one or more of the compared models in order to synchronize aspects of the models and/or synchronize the models entirely.
In accordance with the teachings of the present invention, the process of comparing two models results in a collection of comparison nodes that hold information about the comparison. The comparison nodes may be modeled as an object model using a modeling tool. All operations performed upon the two data models, and all operations performed upon the comparison model, may be performed immediately upon their designation by the user. Side-effects then become more immediately apparent.
In accordance with a particular embodiment of the present invention, a method for generating a dynamic comparison model includes selecting a first model and a second model. The method also includes running a comparison engine on the first model and the second model. Next, the method generates the comparison model based on the inequality between the first model and second model. The method further includes registering the comparison model as a subscriber to the first model and the second model in a notification manager. The notification manager notifies all subscribers of changes that occur to a model. The method further includes displaying the comparison model using a modeling tool.
Technical advantages of particular embodiments of the present invention include a system and method for generating dynamic comparison models that allows a user to view a graphical representation of a comparison of a plurality of models. Thus, differences between the models are easily ascertainable to a user, and the user can more easily identify and implement desired changes to at least one of the models.
Another technical advantage of particular embodiments of the present invention includes a system and method for generating dynamic comparison models that accommodates synchronous modifications to at least one of the models. Accordingly, updates to the target model are made in approximately real time, as the user designates the changes to be made.
Yet another technical advantage of particular embodiments of the present invention includes a system and method for generating dynamic comparison models that allows side-effects to be identified more quickly and easily. Accordingly, a user may correct potential problems caused by side-effects as they arise (i.e., as additional changes are being made), to avoid the potential for the side-effects to impact later changes. Thus, problems caused by side-effects may be reduced or eliminated.
Still another technical advantage of particular embodiments of the present invention includes a system and method for generating dynamic comparison models that interact with a notification manager that broadcasts a list of all changes to the model upon the successful completion of an operation. Therefore, a user is provided with immediate feedback regarding all changes to the models, including those caused by modeling rules instead of user-designated changes.
Still another technical advantage of particular embodiments of the present invention includes a system and method for generating dynamic comparison models that interact with a transaction manager that tracks changes to the model and allows a user to undo and/or redo changes at the click of a button. This feature simplifies and speeds the process of synchronizing models.
Other technical advantages of the present invention will be readily apparent to one skilled in the art from the following figures, descriptions, and claims. Moreover, while specific advantages have been enumerated above, various embodiments may include all, some, or none of the enumerated advantages.
A model is a representation that is often used to help illustrate a concept using symbolic representations. It is often beneficial and/or necessary to compare two models in order to better understand similarities and/or differences between the models. For example, such a comparison is often helpful to synchronize or bring some level of conformity to the models. By comparing two models and identifying any differences between them, a user can more readily make desired changes to one or both models, in order to achieve the desired level of conformity.
Models are typically represented using various hierarchical components. For example, a model may include one or more objects. Each object may include one or more attributes (e.g., properties).
Various types of models are used to illustrate concepts using visual representations. This specification will focus primarily on object models. An object model may include any physical or logical description of data that is to be defined, processed, or retrieved by implemented code (e.g., externally implemented code). An object model typically represents categories of data. Models may be referred to in a variety of different ways and various types of models may benefit from the teachings of the present invention including models, object/property models, data models and schemas (e.g., DBMS schemas and/or any set of objects).
Objects of the model typically represent data belonging to the model. Based on the hierarchical structure of models, objects may own, or be owned by, other objects. An object owns another object if the objects are in a hierarchical relationship and the owning object is at a higher level than the owned object. Each object may include one or more attributes or properties that are relevant to the model. Properties or attributes typically represent characteristics of the object.
In accordance with the teachings of the present invention, the process of comparing two models results in a collection of comparison nodes that hold information about the comparison. For example, the objects and/or attributes of one model are compared to the objects and/or attributes of a second model and the comparison is stored as a collection of comparison nodes. In this manner, the results of the comparison can be reviewed and/or the models can be brought into some higher level of conformity with one another, as desired by a user.
One way to identify, log and/or correct for deviations between the models is to build scripts that indicate actions to be taken on the nodes of the comparison. For example, the script may include the instruction “in Node 1, move the data from the first model to the second model.” The user may build these scripts as the comparison is being reviewed and then the user may execute the scripts in a batch after the user has completed building the scripts. This batch method does not allow for the user to monitor the progress of the modifications to the models as the changes are designated by the user, and does not allow the user to identify any problems and/or inconsistencies with the changes until after the user has indicated all of the changes to be made.
In accordance with a particular embodiment of the present invention, comparison nodes are modeled (i.e., represented as a model) as an object/property model using an underlying modeling engine. One such modeling engine is the ALLFUSION® ERWIN® Data Modeler modeling engine offered by CA Inc. Models within an object/property model are also commonly referred to as graphs. Modeling a comparison model or comparison graph allows for representing similar and dissimilar aspects of the compared models.
In accordance with another embodiment of the present invention, all operations on the two data models, and all operations on the comparison node model (based upon desired changes to one or both models) are performed approximately in real-time, as the changes are designated by the user. This allows the user to view the changes to either of the models as the changes are designated, and allows the user to view an updated version of the comparison node model, as the changes are being designated by the user.
In accordance with yet another embodiment of the present invention, the comparison nodes are modeled using an object/property modeling engine that includes undo/redo capability. This allows the user to undo and/or redo changes in object matching and to undo and/or redo operations performed.
Thus, when comparing differences between two models, the comparison data that is generated is modeled into an object model. All of the changes to the models are synchronous and displayed immediately (e.g., approximately in real-time) upon their designation by the user. This provides for approximately immediate feedback to the user regarding all changes to the models, including those changes that may be caused by modeling rules (e.g., automatically implemented by the system) instead of being specifically identified by the user. The user may also undo and/or redo changes quickly and easily, as objects of the models are compared.
Additional information regarding models and modeling tools is available within U.S. Pat. No. 6,859,919 (the “'919 patent”). The term “model” throughout this specification will include the object/property models implemented in the modeling engine described in the '919 patent.
In accordance with the teachings of the present invention, the modeling engine based upon the '919 patent will include: (i) a notification manager that broadcasts a list of all changes to the model upon successful completion of an operation; and (ii) a transaction manager that allows undo and redo operations to be performed at will.
For purposes of illustration, the present specification will refer to the AllFusion ERwin Data Modeler available from CA, Inc. The AllFusion ERwin Data Modeler includes models which represent DBMS schemas.
In accordance with a particular embodiment of the present invention, models may be represented in IDEF1x format. IDLE1x is a standard for diagramming schemas within the Integrated Definition Methods that will be familiar to programmers.
In order to bring the models of
Within this disclosure, models may also be represented in Unified Modeling Language (UML) format. UML is a standard notation for representing objects and other programming concepts that will be familiar to programmers.
If the models of
As shown in
For example, in 402, the client may select Models M1302 and M2342 for comparison. During the selection process in 402, a background process 512 may run which tracks the selections and display warnings if necessary. For example, if the client selects invalid models for comparison, the client will get an error message.
In 404, a comparison engine 514 compares the two models selected in 402. The comparison engine may comprise of any hardware, software, firmware, logic, or combination thereof operable to compare two or more models, such as the comparison engine disclosed in U.S. Pat. No. 6,385,610 entitled METHOD AND APPARATUS FOR IDENTIFYING AND VISUALIZING DIFFERENCES IN OBJECT MODEL DIAGRAMS. Comparison engine 514 may employ an object-matching algorithm for comparing models. The object-matching algorithm attempts to find a match for selected objects within a model. For example, the object-matching algorithm would recursively traverse Model M1302 looking for objects and properties. Then the object-matching algorithm would recursively traverse Model M2342 looking for a match.
In accordance with a particular embodiment of the present invention, matching objects by default in the object-matching algorithm may be overridden. Synchronization is achieved by employing some matching rules into the object-matching algorithm. For example, these rules would match two objects that have the same type and the same name. Object O1304 in Model M1304 matches with Object O1344 in Model M2342 by that algorithm. However, the client may designate the objects to be compared rather than those chosen by default.
In 406, comparison engine 514 generates a comparison model. The object-matching algorithm of the comparison engine in 404 creates a comparison node for every time it attempts a match. Comparison nodes may contain a comparison state indicating the state of equality between the object or property being compared. Inequality in an owned object implies inequality in the owning object. Therefore, a difference in equality in the comparison states between two properties in two models results in a difference in equality in the owning object and the owning model. For example, Table 1 describes such comparison states between Models M1302 and M2342 as these may be viewed if the comparison was accomplished using the “C” programming language.
In 408, the comparison model registers itself as a subscriber to the notification manager 516 of both models. In accordance with the teachings of the present invention, each model may include its own respective notification manager 516, or a single notification manager 516 may handle some or all models. The notification manager may be an implementation of the Observer Pattern described by Erich Gamma, et al, in Design Patterns, a volume commonly referenced by programmers. The Observer Pattern has two elements: the subscriber/observer element and the publisher/subject element. A software component, known as an observer or subscriber, can register itself as wanting notification of events from another software component, known as a subject or publisher. For example, in a modeling framework, Models M1302 and M2342 can implement this publisher pattern and notify subscriber CM 322 of all changes that occur.
In 410, a modeling tool 518 displays the comparison model and the compared models. The modeling tool is any modeling tool, application, component, or library operable to use models, such as the modeling tool disclosed in U.S. Pat. No. 6,859,919 entitled OBJECT MODELING TOOL WITH META MODEL SEMANTIC REGISTRY (RULES) A META DATA MANAGER FOR OBJECT(S) PROPERTIES AN OBJECT/PROPERTY INTERFACE FOR INSTANCE(S) OF OBJECTS/PROPERTIES RECEIVED VIA OBJECT/PROPERTY INTERFACE OF THE OBJECT FACTORY REGISTRY. The modeling tool can generate object based models. The modeling tool may comprise a child or subcomponent of another software component, without departing form the scope of this disclosure. The modeling tool represents each comparison node as an object. The comparison node objects have properties allowing identification of the objects in the schemas being compared and another property indicating the comparison state. For example, the modeling tool would display Comparison Model CM 322, Model M1302, and Model M2342 in an object model as in
In 412, the client makes an input operation to update a model. For example, the input operation may be creating Property P3350 in Model M1302, therefore synchronizing Models M1302 and M2342. In 414, the model is updated in response to the input operation. For example, Model M1302 is updated by adding Property P3350 under Object O1304.
In accordance with a particular embodiment of the present invention, the input operation at step 412 may also be undoing or redoing changes to a model. The modeling tool may include a transaction manager 520 to keep track of each of the models and the actions performed on each model. Transaction manager 520 may accomplish this by logging changes to a log file, obtaining undo data from the log file, and performing an undo operation. For example, if the client reverses changes to a model, the modeling information, including what object is matched with what other object, is subject to a transaction manager. An action to add a new Property P3350 to Model M1302 might update Model M1302 and the Comparison Model CM 322 structure. So undo will use the transaction manager's rollback feature to undo the changes caused by transactions on Model M1302 and the Comparison Model CM 322 structure.
In 416, the notification manager 516 publishes an event notifying all subscribers of the update. And the comparison model would receive the event notification. For example, Model M1302 would publish an event indicating that Object O1304 was modified to contain a new Property P3350.
In 418, the comparison engine runs again to update the comparison model. For example, the comparison engine would re-compare Model M1302 and Model M2342 and update the equality states of Comparison Model CM 322. The object-matching algorithm would determine that the new Property P3 in Model M1302 should be matched to Property P3350 in Model M2342. Next, it would locate the ObjectCO1304 and update it with a reference to the new Property P3 in Model M1302. Thus, Models CM, M1, and M2 are updated immediately and displayed to the client. The resulting model might be displayed as in
The system of
The immediate update and display of results can be beneficial particularly when side effects are possible. For example, consider the ERwin model of
Another IDEF1x rule requires that no two attributes have the same name-if they have the same name they must be merged into a single attribute. The rules for merging state that merging a key attribute and a non-key attribute results in a key attribute. Therefore, the addition of an attribute ‘c’ to the key of ‘E/1’ would result in a change to ‘E/3’ as represented in the
Now consider the model represented in
The import of attribute ‘c’ to the model of
Users also have the ability in Complete Compare to override the default matching of objects. Complete Compare employs some matching rules coded into the module. For instance, these rules would match two objects that have the same type and the same name. In our examples above, entity ‘E/1’ of
Although the present invention has been described with several embodiments, a myriad of changes, variations, alterations, transformations, and modifications as fall within the scope of the appended claims.
This application is a Continuation-in-part of U.S. patent application Ser. No. 10/890,313, filed Jul. 12, 2004, entitled “System and Method for Adding User-Defined Objects to a Modeling Tool”, which is a Continuation-in-part of U.S. patent application Ser. No. 09/420,223 filed on Oct. 16, 1999, entitled “Object Modeling Tool With Meta Model Semantic Registry (Rules) A Meta Datamanager for Object(s) Properties an Object/Property Interface For Instance(s) of Objects/Properties Received Via Object/Property Interface of the Object Factory Registry”, now U.S. Pat. No. 6,859,919, both of which are incorporated by reference into this application.
Number | Name | Date | Kind |
---|---|---|---|
3656178 | De Maine et al. | Apr 1972 | A |
4667290 | Goss et al. | May 1987 | A |
4787035 | Bourne | Nov 1988 | A |
4931928 | Greenfeld | Jun 1990 | A |
4949253 | Chigira et al. | Aug 1990 | A |
5070534 | Lascelles et al. | Dec 1991 | A |
5245675 | Ferre et al. | Sep 1993 | A |
5257363 | Shapiro et al. | Oct 1993 | A |
5276880 | Platoff et al. | Jan 1994 | A |
5295059 | Brooks et al. | Mar 1994 | A |
5295256 | Bapat | Mar 1994 | A |
5421016 | Conner et al. | May 1995 | A |
5481718 | Ryu et al. | Jan 1996 | A |
5495613 | Brody | Feb 1996 | A |
5513314 | Kandasamy et al. | Apr 1996 | A |
5517641 | Barry et al. | May 1996 | A |
5548758 | Pirahesh et al. | Aug 1996 | A |
5550971 | Brunner et al. | Aug 1996 | A |
5596746 | Shen et al. | Jan 1997 | A |
5638381 | Cho et al. | Jun 1997 | A |
5644764 | Johnson et al. | Jul 1997 | A |
5649203 | Sites | Jul 1997 | A |
5692195 | Conner et al. | Nov 1997 | A |
5694539 | Haley et al. | Dec 1997 | A |
5699310 | Garloff et al. | Dec 1997 | A |
5701487 | Arbouzov | Dec 1997 | A |
5715453 | Stewart | Feb 1998 | A |
5717924 | Kawai | Feb 1998 | A |
5721895 | Velissaropoulos et al. | Feb 1998 | A |
5721915 | Sockut et al. | Feb 1998 | A |
5721925 | Cheng et al. | Feb 1998 | A |
5721929 | Pasquariello | Feb 1998 | A |
5724425 | Chang et al. | Mar 1998 | A |
5732192 | Malin et al. | Mar 1998 | A |
5734907 | Jarossay et al. | Mar 1998 | A |
5737592 | Nguyen et al. | Apr 1998 | A |
5742828 | Canady et al. | Apr 1998 | A |
5761494 | Smedley et al. | Jun 1998 | A |
5764978 | Masumoto | Jun 1998 | A |
5768586 | Zweben et al. | Jun 1998 | A |
5790861 | Rose et al. | Aug 1998 | A |
5794229 | French et al. | Aug 1998 | A |
5802511 | Kouchi et al. | Sep 1998 | A |
5815415 | Bentley et al. | Sep 1998 | A |
5822750 | Jou et al. | Oct 1998 | A |
5855014 | Smith | Dec 1998 | A |
5857197 | Mullins | Jan 1999 | A |
5878411 | Burroughs et al. | Mar 1999 | A |
5905982 | Carey et al. | May 1999 | A |
5974201 | Chang et al. | Oct 1999 | A |
5974253 | Nahaboo et al. | Oct 1999 | A |
5974407 | Sacks | Oct 1999 | A |
5978789 | Griffin et al. | Nov 1999 | A |
5983016 | Brodsky et al. | Nov 1999 | A |
5987123 | Scott et al. | Nov 1999 | A |
6003037 | Kassabgi et al. | Dec 1999 | A |
6011917 | Leymann et al. | Jan 2000 | A |
6031993 | Andrews et al. | Feb 2000 | A |
6052720 | Traversat et al. | Apr 2000 | A |
6065002 | Knotts et al. | May 2000 | A |
6081774 | de Hita et al. | Jun 2000 | A |
6085120 | Schwerdtfeger et al. | Jul 2000 | A |
6091895 | Govindaraj | Jul 2000 | A |
6105043 | Francisco et al. | Aug 2000 | A |
6112024 | Almond et al. | Aug 2000 | A |
6112304 | Clawson | Aug 2000 | A |
6112649 | Jeong | Sep 2000 | A |
6114978 | Hoag | Sep 2000 | A |
6182274 | Lau | Jan 2001 | B1 |
6226792 | Goiffon et al. | May 2001 | B1 |
6243709 | Tung | Jun 2001 | B1 |
6247020 | Minard | Jun 2001 | B1 |
6292811 | Clancey et al. | Sep 2001 | B1 |
6374252 | Althoff et al. | Apr 2002 | B1 |
6374256 | Ng et al. | Apr 2002 | B1 |
6385610 | Deffler et al. | May 2002 | B1 |
6385767 | Ziebell | May 2002 | B1 |
6446109 | Gupta | Sep 2002 | B2 |
6453356 | Sheard et al. | Sep 2002 | B1 |
6502234 | Gauthier et al. | Dec 2002 | B1 |
6513152 | Branson et al. | Jan 2003 | B1 |
6601023 | Deffler et al. | Jul 2003 | B1 |
6665677 | Wotring et al. | Dec 2003 | B1 |
6678882 | Hurley et al. | Jan 2004 | B1 |
6754671 | Hrebejk et al. | Jun 2004 | B2 |
6859919 | Deffler et al. | Feb 2005 | B1 |
7353252 | Yang et al. | Apr 2008 | B1 |
20020059446 | Visalli et al. | May 2002 | A1 |
20030014439 | Boughannam | Jan 2003 | A1 |
20030084424 | Reddy et al. | May 2003 | A1 |
20040103393 | Reddy et al. | May 2004 | A1 |
20050160401 | Russo et al. | Jul 2005 | A1 |
Number | Date | Country |
---|---|---|
0 396 310 | May 1990 | EP |
1 134 949 | Aug 2001 | EP |
2 227 339 | Jul 1990 | GB |
Number | Date | Country | |
---|---|---|---|
20060225030 A1 | Oct 2006 | US |
Number | Date | Country | |
---|---|---|---|
Parent | 10890313 | Jul 2004 | US |
Child | 11379197 | US | |
Parent | 09420223 | Oct 1999 | US |
Child | 10890313 | US |