DDI & Model-View-Controller: An Architectural Perspective Dennis Wegener, Matthäus Zloch, Thomas...
-
Upload
easter-miller -
Category
Documents
-
view
212 -
download
0
Transcript of DDI & Model-View-Controller: An Architectural Perspective Dennis Wegener, Matthäus Zloch, Thomas...
![Page 1: DDI & Model-View-Controller: An Architectural Perspective Dennis Wegener, Matthäus Zloch, Thomas Bosch (GESIS) Dagstuhl, 23.10.2012.](https://reader030.fdocuments.net/reader030/viewer/2022032805/56649ee55503460f94bf43c5/html5/thumbnails/1.jpg)
DDI & Model-View-Controller: An Architectural Perspective
Dennis Wegener, Matthäus Zloch, Thomas Bosch (GESIS)
Dagstuhl, 23.10.2012
![Page 2: DDI & Model-View-Controller: An Architectural Perspective Dennis Wegener, Matthäus Zloch, Thomas Bosch (GESIS) Dagstuhl, 23.10.2012.](https://reader030.fdocuments.net/reader030/viewer/2022032805/56649ee55503460f94bf43c5/html5/thumbnails/2.jpg)
Page 2
Overview Architecture Missy/StarDat
Presentation
Business Logic
Abstract Persistence
MVC
Persistence
![Page 3: DDI & Model-View-Controller: An Architectural Perspective Dennis Wegener, Matthäus Zloch, Thomas Bosch (GESIS) Dagstuhl, 23.10.2012.](https://reader030.fdocuments.net/reader030/viewer/2022032805/56649ee55503460f94bf43c5/html5/thumbnails/3.jpg)
Software Management - Maven & GIT
• Apache Maven– software project management and comprehension tool
• Maven Modules for data modelling in our projects:– Abstract module for DDI (based on DDI ontology)– Concrete modules for each project that
• Inherit from abstract ddi module• Add project-specific data fields
• Sharing via VersionControlSystem– Project sources in internal VCS (GESIS-SVN)– Data Module shared externally (GIT)
• https://github.com/missy-project/ddi-model
DDI model
DDI model + Missy
Extensions
DDI model + StarDat
Extensions
![Page 4: DDI & Model-View-Controller: An Architectural Perspective Dennis Wegener, Matthäus Zloch, Thomas Bosch (GESIS) Dagstuhl, 23.10.2012.](https://reader030.fdocuments.net/reader030/viewer/2022032805/56649ee55503460f94bf43c5/html5/thumbnails/4.jpg)
Missy Maven Structure
![Page 5: DDI & Model-View-Controller: An Architectural Perspective Dennis Wegener, Matthäus Zloch, Thomas Bosch (GESIS) Dagstuhl, 23.10.2012.](https://reader030.fdocuments.net/reader030/viewer/2022032805/56649ee55503460f94bf43c5/html5/thumbnails/5.jpg)
Data model & presentation - MVC
• MVC design pattern• Model
– Domain classes– Attributes– Relations
• View– Representation– JSP, Velocity, XML, JSON, …
• Controller– Commands– RESTful interface
![Page 6: DDI & Model-View-Controller: An Architectural Perspective Dennis Wegener, Matthäus Zloch, Thomas Bosch (GESIS) Dagstuhl, 23.10.2012.](https://reader030.fdocuments.net/reader030/viewer/2022032805/56649ee55503460f94bf43c5/html5/thumbnails/6.jpg)
RESTful interface
• Well-defined interface based on HTTP– With few basic methods: GET, POST, PUT, DELETE– Response codes (e.g. 200 OK, 404 Not Found)– Data supported described by MIME types (e.g. text/xml,
application/json)
• Resources are identified using URIs– Collection URI (like http://missy.org/studies)– Element URI (like http://missy.org/studies/studyZA1000)
• Resources could map to domain classes / entities of the DDI ontology
![Page 7: DDI & Model-View-Controller: An Architectural Perspective Dennis Wegener, Matthäus Zloch, Thomas Bosch (GESIS) Dagstuhl, 23.10.2012.](https://reader030.fdocuments.net/reader030/viewer/2022032805/56649ee55503460f94bf43c5/html5/thumbnails/7.jpg)
Data model & persistance – API
• Once you have the model you can…– Generate views / user interfaces– Generate storage model (in RDB via hibernate)
• Abstract persistance API– To be published …
• Concrete Implementations– Relational DB– DDI XML files– …
![Page 8: DDI & Model-View-Controller: An Architectural Perspective Dennis Wegener, Matthäus Zloch, Thomas Bosch (GESIS) Dagstuhl, 23.10.2012.](https://reader030.fdocuments.net/reader030/viewer/2022032805/56649ee55503460f94bf43c5/html5/thumbnails/8.jpg)
Missy Example
• Question:– DDI Ontology: class Question,
fields like dcterms_identifier, …, field question text
• Variable:– DDI Ontology: class Variable,
fields like dcterms_identifier,…– Missy: inherits class Variable,
adds fields variable name, variable label, classification, …
• Relation: – Variable * hasQuestion 1 Question– Defined at level of DDI Ontology
![Page 9: DDI & Model-View-Controller: An Architectural Perspective Dennis Wegener, Matthäus Zloch, Thomas Bosch (GESIS) Dagstuhl, 23.10.2012.](https://reader030.fdocuments.net/reader030/viewer/2022032805/56649ee55503460f94bf43c5/html5/thumbnails/9.jpg)
Page 9
Missy Extension
DDI Ontology
![Page 10: DDI & Model-View-Controller: An Architectural Perspective Dennis Wegener, Matthäus Zloch, Thomas Bosch (GESIS) Dagstuhl, 23.10.2012.](https://reader030.fdocuments.net/reader030/viewer/2022032805/56649ee55503460f94bf43c5/html5/thumbnails/10.jpg)
Key Messages & Questions
• DDI model implemented as abstract data model in OO programming language
– According to MVC - domain classes with attributes & relations– Do we need a standard REST interface?
• DDI model not directly based on XML representation– „Data model vs. Data format“– Export mechanisms for XML based representation
• DDI model integrated into project‘s architectures – Does it make sense to create a reference architecture?
• Reuse of software modules is possible– We already share modules/code between internal projects Missy & StarDat– Is anyone else interested in sharing?