Multiple Model Repositories Sergejs Kozlovičs sergejskozlovicslumiilv Research Laboratory of Modeling and Software Technologies Institute of Mathematics and Computer Science University of Latvia ID: 245882
Download Presentation The PPT/PDF document "The Orchestra of" is the property of its rightful owner. Permission is granted to download and print the materials on this web site for personal, non-commercial use only, and to display it on your personal computer provided you do not modify the materials and that you retain all copyright notices contained in the materials. By downloading content from our website, you accept the terms of this agreement.
Slide1
The Orchestra ofMultiple Model Repositories
Sergejs Kozlovičssergejs.kozlovics@lumii.lv
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide2
The ``Orchestra'' Metaphor
Orchestra:multiple musical instrumentsplaying simultaneously
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide3
The ``Orchestra'' Metaphor
Orchestra:multiple musical instrumentsplaying simultaneously
multiple model repositoriesaccessed simultaneously
(inter-repository links are possible)002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide4
The ``Orchestra'' Metaphor
Orchestra:multiple musical instrumentsplaying simultaneously
multiple model repositories
accessed simultaneously(inter-repository links are possible)
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide5
Meta-s
* a publication * a newspaper * The San Francisco Chronicle * the May 18 edition of the The San Francisco Chronicle * my copy of the May 18 edition of the
The San Francisco Chronicle * my copy of the May 18 edition of the The San Francisco Chronicle as it was when
I first picked it up (as contrasted with my copy as it was a few days later: in my fireplace, burning)
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
The "Gödel, Escher, Bach" book
by Douglas HofstadterSlide6
MOF Meta-Levels (Linguistic)
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide7
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
Artifacts are organized into three layers:the meta-metamodel;
metamodels conforming to the meta-metamodel;
models conforming to some particular metamodel.
The Three-Level Conjecture
(I. Kurtev and J. Bézivin)Slide8
The Three-Level Conjecture(I. Kurtev and J. Bézivin, 2005)
Artifacts are organized into three layers:the meta-metamodel;
metamodels conforming to the meta-metamodel;models conforming to some particular metamodel.
The meta-metamodel is able to describe itself.
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide9
MOF Meta-Levels (Linguistic)
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
UML metamodel
UML model
MOF
conforms to
conforms to
conforms toSlide10
Technical Spaces(I. Kurtev, J. Bézivin, and M. Aksit; 2002, 2005)
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
UML metamodel
UML model
MOF
conforms to
conforms to
conforms to
MOF TS
OWL classes
OWL individuals
OWL DL
conforms to
conforms to
conforms to
RDF/OWL TS
ER-model (DB schema)
DB rows
DB system tables
conforms to
conforms to
conforms to
Relational DB TSSlide11
Technical Spaces (cont.)(I. Kurtev, J. Bézivin, and M. Aksit; 2002, 2005)
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
XML schema
(.xsd)
XML document
XML metaschema
(XSD.xsd)
conforms to
conforms to
conforms to
XML TS
Java grammar
Java program
BNF
conforms to
conforms to
conforms to
Grammarware TSSlide12
Why different technical spaces?
One TS can be more suitable than anotherReusing skills and knowledge of a familiar TSA capability not available in a desired TS can be borrowed from another
TS
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide13
TS interoperability
Offline solution: using projectors and extractors (B´ezivin et al.)“Online” (On-the-fly) solution: this paper!No deep copying of the data is required!
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide14
Problem 1: Numerous different repositories
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
See Table 1 in the paper!Slide15
Repositories
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
See Table 1 in the paper!
MOF TS:
EMF
CDO
MDR (NetBeans)
Enchanced Model Repository
MetaMart Metadata Repository
JR
...Slide16
Repositories
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
The solution is a univeral Repository Access API, RAAPI
t
da.lumii.lv/raapi.htmlSlide17
Problem 2: Ontological meta-levels
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide18
Ontological meta-levels
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide19
Meta-Levels (Ontological)
A meta-metamodel that supports infinitely many ontological meta-levels (used by the JR repository):002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide20
Meta-Levels (Ontological)
A meta-metamodel that supports infinitely many ontological meta-levels (used by the JR repository):
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide21
Meta-Levels (Ontological)
OWL Full also supports infinitely many ontological meta-levels.002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide22
Shostaks' conjecture
It is difficult for a human to think at more than two meta-levels at a time.Still, it is pretty easy for a human to focus on any two adjacent meta-levels.
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide23
Shostaks' conjecture
It is difficult for a human to think at more than two meta-levels at a time.Still, it is pretty easy for a human to focus on any two adjacent meta-levels.
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
Agris Šostaks
a
t SOFSEM 2012Slide24
We divide the repository into two parts:M3 contating the meta-metamodel; fixed for a particular repository/technical space;
all other data (either M2+M1 or multiple ontological meta-levels)
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
Dealing with Šostaks' conjectureSlide25
Dealing with Šostaks' conjecture
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
RAAPI is designed to work with any two adjacent meta-levels
Switching between levels and mixing them is possible by, e.g., passing a reference to a class when a reference to an object is expected.Slide26
The Idea
The kernel represents all repositories as one big virtual repository.The kernel substitutes native references (integers) of each repository by globally unique proxy references.
Inter-repository links are stored in the pivot repository.
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide27
Kernel Metamodel (the essence)
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide28
RAAPI call example: createLink()
createLink(obj1_ref, obj2_ref, association_ref
);If all proxy references point to the same repository, the call is forwarded to this repository.
Otherwise, an inter-repository link is created and stored in the pivot repository.
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide29
Organizing repositories
Unix file system directory tree:/boot/bin/mnt
/mnt/c /mnt/d/media
/media/cdrom/etc
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
m
ount pointsSlide30
Organizing repositories
Package tree (~ UML package tree):Package1Package2Package2::SubPackage
Package3Package4
Use “MountPoint::ClassName” to access
a class in a mounted repository
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
m
ount pointsSlide31
Organizing repositories
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
Pivot
Root
package
P1
P2Slide32
Organizing repositories
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
Pivot
Root
package
P1
P2
New repository
SubPSlide33
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
Problem 3:
M
anipulating the packages
How to merge packages?
I.e., when working with class Package1::A, objects and properties of Package2::A are also taken into a consideration.Slide34
Virtual repositories
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
Pivot
Root
package
P1
P2
Virtual repository
SubP
Relies on data from somewhere else
(or, invents data)Slide35
Virtual repositories
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
Pivot
Root
package
P1
P2
Virtual repository
SubP
Relies on data from somewhere elseSlide36
Virtual repositories
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
Pivot
Root
package
P1
P2
Virtual repository
SubP
Relies on data from somewhere else
On-the-fly
m
odel
transformationSlide37
Use cases for virtual repositories
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of LatviaSlide38
Views on metamodels
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
Pivot
Root
package
P1
P2
Virtual repository
SubP
View
Base
metamodelSlide39
Volatile repository
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
Pivot
Root
package
P1
P2
Virtual repository
(stores its content
In RAM)
SubP
Volatile
repositorySlide40
Virtual merge
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
P
QSlide41
Virtual merge
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
P
Virtual repository
i
mplementing
“merge”
Q
PSlide42
Derived (calculated) associations and properties
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
A
BSlide43
Derived (calculated) associations and properties
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
A
B
A
B
Virtual repository
c
omputes
the associationSlide44
Derived (calculated) associations and properties
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
A
B
A
B
Virtual repository
c
omputes
the association
Finally, we just need to virtually merge these two packages!
mergeSlide45
Virtual copy
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
PSlide46
Virtual copy
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
P
Virtual
repository
2
P’
P
(old data)
Virtual
repository
1Slide47
Virtual copy
002
Research Laboratory of Modeling and Software Technologies
Institute of Mathematics and Computer Science, University of Latvia
P
Virtual
repository
2
P’
P
(old data)
Virtual
repository
1
Δ
2
Δ
1Slide48