An Adapter-Based Approach to Co-evolve Generated SQL in M2T Transformations Jokin García 1, Oscar Díaz 1 and Jordi Cabot 2 Onekin 1 University of the Basque.

Slides:



Advertisements
Similar presentations
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 5 More SQL: Complex Queries, Triggers, Views, and Schema Modification.
Advertisements

How SAS implements structured programming constructs
SQLite is a software library. It is: self-contained + Serverless + zero-configuration transactional = SQL database engine. Most widely deployed. The source.
Technical BI Project Lifecycle
Case-Based Reasoning, 1993, Ch11 Kolodner Adaptation method and Strategies Teacher : Dr. C.S. Ho Student : L.W. Pan No. : M Date : 1/7/2000.
Management of the Evolution of Database-Centric Information Systems Panos Vassiliadis 2, George Papastefanatos 1, Timos Sellis 1, Yannis Vassiliou 1 1.
Toward Online Schema Evolution for Non-Stop Systems Amol Deshpande, University of Maryland Michael Hicks, University of Maryland.
Cognos 8.4 Upgrade Business Intelligence. Why Cognos 8.4 Increased Performance on Database due to optimized SQL and more filters passed in native SQL.
George Papastefanatos 1, Panos Vassiliadis 2, Alkis Simitsis 3,Yannis Vassiliou 1 (1) National Technical University of Athens
Database Systems More SQL Database Design -- More SQL1.
G. Papastefanatos 1, P. Vassiliadis 2, A. Simitsis 3, K. Aggistalis 2, F. Pechlivani 2, Yannis Vassiliou 1 (1) National Technical University of Athens.
5 Copyright © 2009, Oracle. All rights reserved. Defining ETL Mappings for Staging Data.
State of Connecticut Core-CT Project Query 4 hrs Updated 1/21/2011.
Chapter 18: Modifying SAS Data Sets and Tracking Changes 1 STAT 541 ©Spring 2012 Imelda Go, John Grego, Jennifer Lasecki and the University of South Carolina.
Impact Analysis of Database Schema Changes Andy Maule, Wolfgang Emmerich and David S. Rosenblum London Software Systems Dept. of Computer Science, University.
M. Taimoor Khan * Java Server Pages (JSP) is a server-side programming technology that enables the creation of dynamic,
Agenda Journalling More Embedded SQL. Journalling.
MT311 Java Application Development and Programming Languages Li Tak Sing( 李德成 )
® IBM Software Group © 2009 IBM Corporation Rational Publishing Engine RQM Multi Level Report Tutorial David Rennie, IBM Rational Services A/NZ
® IBM Software Group © IBM Corporation ITIM Common Lifecycle Operation Modifications.
1 v1.6 08/02/2006 Overview of Eclipse Lectures 1.Overview 2.Installing and Running 3.Building and Running Java Classes 4.Refactoring 5.Debugging 6.Testing.
CSE314 Database Systems More SQL: Complex Queries, Triggers, Views, and Schema Modification Doç. Dr. Mehmet Göktürk src: Elmasri & Navanthe 6E Pearson.
Sofia, Bulgaria | 9-10 October SQL Server 2005 High Availability for developers Vladimir Tchalkov Crossroad Ltd. Vladimir Tchalkov Crossroad Ltd.
Introducing Reporting Services for SQL Server 2005.
A Tooling Environment for Quality-Driven Domain- Specific Modelling Janne Merilinna.
©Ian Sommerville 2000 Software Engineering, 6th edition. Chapter 10Slide 1 Architectural Design l Establishing the overall structure of a software system.
© Copyright by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. 1 Tutorial 30 – Bookstore Application: Client Tier Examining.
Maintenance and Support Week 15 CMIS570. User Training Need to consider the same 2 groups: End users Use the system to achieve the business purpose Creating,
Display Text SDD 1.1 Topic. Current Situation COSMOS team is implementing a CLI for user interaction Need the ability to specify strings for display to.
Copyright © 2009 AtlanMod. All Rights Reserved Frédéric Jouault & Hugo Bruneliere AtlanMod team (INRIA & Mines de Nantes) Possible Benefits of Bridging.
Reviewing Recent ICSE Proceedings For:.  Defining and Continuous Checking of Structural Program Dependencies  Automatic Inference of Structural Changes.
INTRODUCTION TO JAVASCRIPT AND DOM Internet Engineering Spring 2012.
Oracle Data Integrator Procedures, Advanced Workflows.
Chapter 18 Object Database Management Systems. McGraw-Hill/Irwin © 2004 The McGraw-Hill Companies, Inc. All rights reserved. Outline Motivation for object.
Replay Compilation: Improving Debuggability of a Just-in Time Complier Presenter: Jun Tao.
Stored Procedures Week 9. Test Details Stored Procedures SQL can call code written in iSeries High Level Languages –Called stored procedures SQL has.
Environment Change Information Request Change Definition has subtype of Business Case based upon ConceptPopulation Gives context for Statistical Program.
Display Text SDD 1.1 Topic. Current Situation COSMOS team is implementing a CLI for user interaction Need the ability to specify strings for display to.
Automated Transformation of Statements Within Evolving Domain Specific Languages Peter Bell CEO/CTO, SystemsForge 7th OOPSLA Workshop on Domain-Specific.
Persistance Android. Adding Persistance SQL Refresher Understand how to create and migrate SQLLite database with android APIs. – Get all tasks – Add a.
E.Bertino, L.Matino Object-Oriented Database Systems 1 Chapter 5. Evolution Seoul National University Department of Computer Engineering OOPSLA Lab.
Netprog: Corba Object Services1 CORBA 2.0 Object Services Ref: The Essential Distributed Objects Survival Guide: Orfali, Harky & Edwards.
Requirements Engineering-Based Conceptual Modelling From: Requirements Engineering E. Insfran, O. Pastor and R. Wieringa Presented by Chin-Yi Tsai.
Differences Training BAAN IVc-BaanERP 5.0c: Application Administration, Customization and Exchange BaanERP 5.0c Tools / Exchange.
Chapter 5 : Integrity And Security  Domain Constraints  Referential Integrity  Security  Triggers  Authorization  Authorization in SQL  Views 
NETWORK VISUALIZATION ABHISHEK KUMAR (2011CS50272)
Chapter 18 Object Database Management Systems. Outline Motivation for object database management Object-oriented principles Architectures for object database.
CSCI 3327 Visual Basic Chapter 13: Databases and LINQ UTPA – Fall 2011.
Slide 1 Chapter 8 Architectural Design. Slide 2 Topics covered l System structuring l Control models l Modular decomposition l Domain-specific architectures.
 CONACT UC:  Magnific training   
Audit API : Hints and Tricks Mehdi BELMEKKI, Consultancy Team Alfresco.
Understand Data Definition Language (DDL) Database Administration Fundamentals LESSON 1.4.
Views / Session 3/ 1 of 40 Session 3 Module 5: Implementing Views Module 6: Managing Views.
2 Copyright © 2009, Oracle. All rights reserved. Managing Schema Objects.
© 2011 LabKey Software LabKey Server Release 11.3 Atlas Developers Meeting 11/16/2011 Adam Rauch
More SQL: Complex Queries, Triggers, Views, and Schema Modification
Top 10 Entity Framework Features Every Developer Should Know
EF Code First (Advanced)
BrowserShield: Vulnerability-Driven Filtering of Dynamic HTML
Database System Concepts and Architecture
CIS16 Application Programming with Visual Basic
Dynamic Data Flows in SSIS without ProgramminG
Software Architecture
Analysis models and design models
Dynamics AX Upgrades Microsoft Dynamics AX 2009
Contents Preface I Introduction Lesson Objectives I-2
Business Add-Ins.
Updating Databases With Open SQL
Martin Rinard, Jiasi Shen, Varun Mangalick
Updating Databases With Open SQL
Presentation transcript:

An Adapter-Based Approach to Co-evolve Generated SQL in M2T Transformations Jokin García 1, Oscar Díaz 1 and Jordi Cabot 2 Onekin 1 University of the Basque Country, Spain AtlanMod 2 Ecole des Mines, Nantes (France) Thessaloniki - 19 th of june, 2014 CAiSE

2 Index  Problem statement  Case study  Solution  Evaluation  Conclusions, future work

3 Problem statement: context  Software components on top of platforms  Dependencies  Platform evolution is a common situation.  DB  API API Application

4 Problem statement: context  Perpetual beta state of platforms.  External dependency

5 Problem statement: context Domain modelM2T TransformationCode Model refs. (Dynamic) Embedded platform code (Static) Transformation code

6 Problem statement: problem  Different versions of the platform leave the code and M2T transformation outdated. DBDB’ Δ Code M2T ?

7 Problem statement: solution  Adapter to adapt generated code to new platform Media Wiki Media Wiki’ Δ Code M2T Adapter Code

8 Case study: MediaWiki DB in Wikiwhirl

9 Case study: MediaWiki  Used by Wikipedia and more than wikis  In 4,5 years: 171 schema upgrades

10 Case study: MediaWiki DB in Wikiwhirl Platform-dependent concepts Refs to domain model

11 Solution  Synchronize the generated code with platform  Using adapters at runtime Media Wiki’ M2T Adapter Code INSERT INTO categorylinks (cl_from, cl_to, cl_sortkey, cl_timestamp, cl_type, cl_sortkey_prefix, cl_collation) VALUES ‘Softwareproject’, ‘House_Testing’, (DATE_FORMAT(CURRENT_TIMESTAMP(), ‘%Y%m%d%k%i%s’), ‘page’, ‘’, ‘0’); print("INSERT into categorylinks (cl_from, cl_to, cl_sortkey, cl_timestamp) VALUES '" + categoryTitle + "','" + pageTitle) New columns “cl_type”, “cl_sortkey_prefix” and “cl_collation”

12 Process outline Code (MediaWiki DB) New MediaWiki schema Old MediaWiki schema Domain model Difference model New schema model Old schema model

13 Process outline Code (MediaWiki DB) New MediaWiki schema Old MediaWiki schema Domain model Difference model New schema model Old schema model Don't worry: all in one click

14 Process: Differences between platforms: DB schema

15 Process: Schema Modification Operators (SMO) SMO% of usage Change type Adaptation Create table8.9NBCNew comment in the transformation on the existence of this table in the new version Drop table3.3BRCDelete statement associated to the table Rename table1.1BRCUpdate name Copy table2.2NBC(None) Add column38.7NBC/ BRC For insert statements: if the attribute is Not Null, add the new column in the statement with a default value (from the DB if there is available or according to the type if there is not) Drop column26.4BRCDelete the column and the value in the statement Rename column16BRCUpdate name Copy column0.4BRCLike add column case Move column1.5BRCLike drop column + add column cases

16 Process: Adaptation  Plaform-specific, schema-independent  Replace all “println” instructions with “printSQL”  Import “printSQL” library  ZQL extension  For each printSQL invocation:  Iterate over the changes reported in the Difference model  Checks if any of the changes impacts the current statement.  Needed information to adapt the statement is retrieved and added to a list of parameters: the statement, affected table, column, …  A function that adapts the statement is called and new statement is printed.

17 Process: Adaptation output Added columns Delete tables Delete columns

18 Roles  Producer  Injector for target platform  Implement adapter as a library for transformation  Consumer  Import adapter library in the transformation  Execute the batch

19 Evaluation  Manual Cost = D + P * #Impacts  D: Detection time  P: Propagation time  Assisted Cost = C + V * #Impacts  C: Configuration time  V: Verification time

20 Evaluation

21 Dump changes from code to transformation  Assist manual propagation  Record generation with change to be done and where (line and column in the transformation) M2T transformation M2T transformation’ HOT print(“select * from …”) printSQL(“select * from …”, line, column) RECORD: #Added columns cl_type, cl_sortkey_prefix and cl_collation #transformation line: 12, column: 11 INSERT INTO categorylinks (cl_from, cl_to, cl_sortkey, cl_timestamp, cl_type, cl_sortkey_prefix, cl_collation) VALUES ‘Softwareproject’, ‘House_Testing’, (DATE_FORMAT(CURRENT_TIMESTAMP(), ‘%Y%m%d%k%i%s’), ‘page’, ‘’, ‘0’);

22 Conclusions  Mechanism to adapt code generated by M2T transformations to platform evolution  Apply in a specific case study  Premises: platform instability and transformation coupling

23 Issues and future work  Generalization: other platforms  Methodology for adapter development

24 Questions Implementation: Screencasts:

25 Process: Adaptation 1- Iterate over the changes reported in the Difference model 2- check that the deleted column's table corresponds with the table name of the statement 3- the statement, the table name and the removed column are added to a list of parameters 4- outputs an SQL statement without the removed column, using a function with the list of parameters that modifies the expression

26 Generate traceability model Domain model Traceability model MOFScript + Adapter printSQL(statement l,ine, column, print_type) -> Difference model

27 Visualize traceability model Traceability model Handy MOF