Relational and Object-Relational Database Management Systems As Platforms for Managing Software Engineering Artifacts
Total Page:16
File Type:pdf, Size:1020Kb
THESIS ON INFORMATICS AND SYSTEM ENGINEERING C32 Relational and Object-Relational Database Management Systems as Platforms for Managing Software Engineering Artifacts ERKI EESSAAR TUT PRESS Faculty of Information Technology Department of Informatics TALLINN UNIVERSITY OF TECHNOLOGY Dissertation was accepted for the commencement of the degree of Doctor of Philosophy in Engineering on November 15, 2006. Supervisor: Prof. Rein Kuusik, Faculty of Information Technology Opponents: Prof. Bernhard Thalheim, Christian-Albrechts-University Kiel, Computer Science Institute, Germany Prof. Jüri Kiho, University of Tartu, Estonia Commencement: December 18, 2006 Declaration: Hereby I declare that this doctoral thesis, my original investigation and achievement, submitted for the doctoral degree at Tallinn University of Technology has not been submitted for any degree or examination. /Erki Eessaar/ Copyright: Erki Eessaar, 2006 ISSN 1406-4731 ISBN 9985-59-671-4 Table of Contents INTRODUCTION........................................................................................ 6 OBJECTIVES ................................................................................................ 7 LIMITATIONS ............................................................................................ 10 OUTLINE OF THE DISSERTATION .............................................................. 11 ACKNOWLEDGEMENTS ............................................................................. 13 LIST OF ABBREVIATIONS.................................................................... 15 1 DATA MODELS ................................................................................. 16 1.1 IMPORTANT CONCEPTS OF DATA MODELS ................................... 16 1.2 COMPARISON METHODS OF DATA MODELS .................................. 19 1.3 COMPARISON OF THE DATA MODELS ............................................ 21 1.3.1 Proposed Method for Comparing Data Models.................... 24 1.3.2 Comparison of Data Types.................................................... 27 1.3.2.1 Discussion......................................................................... 32 1.3.3 Comparison of Data Structures............................................. 35 1.3.3.1 Discussion......................................................................... 39 1.3.4 Comparison of Data Integrity Rules...................................... 42 1.3.4.1 Discussion......................................................................... 44 1.3.5 Comparison of Data Operators............................................. 46 1.3.5.1 Discussion......................................................................... 51 1.3.6 Observations.......................................................................... 53 1.3.7 Metrics Values....................................................................... 55 1.3.8 Orthogonality Principle in Language Design ....................... 57 1.4 COMPARISON WITH THE EXISTING SATE OF THE ART ................... 59 1.4.1 Object-Oriented Database Metamodel.................................. 59 1.4.2 CIM Database Model ............................................................ 60 1.4.3 Common Warehouse Metamodel........................................... 60 1.4.4 SQL:2003 Ontology............................................................... 61 1.4.5 SQL Definition Schema ......................................................... 66 1.5 SUMMARY ...................................................................................... 67 2 DATABASE MANAGEMENT SYSTEMS IN EXISTING SOFTWARE ENGINEERING SYSTEMS................................................... 69 2.1 REQUIREMENTS TO THE REPOSITORY SYSTEMS ............................ 72 2.2 EXISTING SOFTWARE ENGINEERING SYSTEMS ............................. 74 2.2.1 Systems that do not Use a DBMS .......................................... 75 2.2.2 Heterogeneous Systems ......................................................... 77 2.2.3 Systems that Use Only an Engineering DBMS...................... 79 2.2.4 Systems that Use Only a General-purpose DBMS ................ 81 2.2.4.1 Systems that Use a RDBMS ............................................. 81 2.2.4.2 Systems that Use an OODBMS ........................................ 84 2.2.4.3 Systems that Use an ORDBMS ........................................ 84 3 2.3 PROBLEMS OF USING THE RELATIONAL MODEL AND RDBMS SQL S IN ENGINEERING SYSTEMS ............................................................................ 86 2.4 SUMMARY ...................................................................................... 90 3 REPOSITORY DATABASE DESIGN.............................................. 92 3.1 DESIGN ALTERNATIVES OF DATABASE SCHEMA OF A SOFTWARE ENGINEERING SYSTEM .................................................................................. 92 3.1.1 Encapsulated Artifact Types.................................................. 93 3.1.2 Non-encapsulated Artifact Element Types ............................ 95 3.1.3 Encapsulated Artifact Element Types.................................... 96 3.1.4 Universal Data Model........................................................... 97 3.2 CHECKING OF THE WELL -FORMEDNESS RULES .......................... 107 3.2.1 Ignore All Well-formedness Rules....................................... 108 3.2.2 Automatically Resolve Constraint Violations as they Arrive 108 3.2.3 Disallow an Operation and Inform a User.......................... 108 3.2.3.1 Example with SimpleM .................................................. 109 3.2.3.2 Example with Use Cases................................................. 110 3.2.4 Allow Everything Initially and Search Errors Later ........... 111 3.2.4.1 Integrated Approach with Versioning............................. 112 3.3 PRESERVING THE SEMANTICS OF RELATIONSHIPS IN A DATABASE 116 3.3.1 Generalization Relationships .............................................. 116 3.3.2 Whole-Part Relationships.................................................... 117 3.3.2.1 Related Works................................................................. 117 3.3.2.2 Possible Designs ............................................................. 118 3.3.2.3 Choosing Between the Designs....................................... 120 3.3.3 Advantages of Attributes with Complex Types in Real Relvars 126 3.3.4 Disadvantages of Attributes with Complex Types in Real Relvars 128 3.4 ADDITIONAL GUIDELINES FOR DATABASE DESIGN .................... 128 3.4.1 The Principle of Orthogonal Design ................................... 129 3.4.2 The Extended Principle of Orthogonal Database Design... 135 3.4.2.1 Discussion and Examples ............................................... 136 3.4.3 Heuristic Rules for Reducing Data Redundancy within the Value of One Real Relvar........................................................................ 138 3.4.3.1 Discussion and Examples ............................................... 139 3.4.4 An Example about the Suitability of Relation-Valued Attribute 142 3.5 VIEW TO ORDBMS SQL S .............................................................. 145 3.5.1 SQL-specific Solutions ........................................................ 145 3.5.2 Usability of the Designs and Guidelines in ORDBMS SQL s .. 145 3.6 SUMMARY .................................................................................... 154 4 4 REPOSITORY SYSTEM WITH A FIXED DATABASE SCHEMA 156 4.1 RELATED WORKS ........................................................................ 158 4.2 DESCRIPTION OF THE MODELING LANGUAGE ............................. 160 4.3 QUERIES ....................................................................................... 164 4.3.1 Consistency and Completeness Checks............................... 165 4.4 DISCUSSION AND COMPARISONS ................................................. 167 4.5 SUMMARY .................................................................................... 171 CONCLUSIONS ...................................................................................... 172 SUMMARY OF CONTRIBUTIONS .............................................................. 172 DIRECTIONS FOR FURTHER RESEARCH .................................................. 178 KOKKUVÕTE ......................................................................................... 181 REFERENCES......................................................................................... 185 APPENDIX A: SOME PROPERTIES OF EXISTING SOFTWARE ENGINEERING SYSTEMS THAT USE THE HELP OF A DBMS ....... 205 APPENDIX B: SOME SECONDARY CHARACTERISTICS OF WHOLE-PART RELATIONSHIPS ........................................................... 207 APPENDIX C: COMPARISON OF SOME SYSTEMS THAT RECORD MODELS IN A DATABASE ..................................................... 208 APPENDIX D: THE LOCATION OF PROTOTYPE SYSTEM ........ 210 APPENDIX E: CURRICULUM VITAE ............................................... 211 APPENDIX F: ELULOOKIRJELDUS (CV IN ESTONIAN)............. 214 5 INTRODUCTION The main areas of this study are relational and object-relational data models and their suitability in the systems that help to manage software engineering artifacts. The concept "data model" has two different meanings (it is "construct overload"): • Meaning 1 : "An abstract, self-contained, logical definition of the data structures, data operators, and so forth, that together make up the abstract machine with which users interact." (Date, 2003, p.15,