Robusta: an Approach to Building Dynamic Applications Walter Rudametkin

Total Page:16

File Type:pdf, Size:1020Kb

Robusta: an Approach to Building Dynamic Applications Walter Rudametkin Robusta: An approach to building dynamic applications Walter Rudametkin To cite this version: Walter Rudametkin. Robusta: An approach to building dynamic applications. Software Engineering [cs.SE]. Université de Grenoble, 2013. English. tel-00948174 HAL Id: tel-00948174 https://tel.archives-ouvertes.fr/tel-00948174 Submitted on 17 Feb 2014 HAL is a multi-disciplinary open access L’archive ouverte pluridisciplinaire HAL, est archive for the deposit and dissemination of sci- destinée au dépôt et à la diffusion de documents entific research documents, whether they are pub- scientifiques de niveau recherche, publiés ou non, lished or not. The documents may come from émanant des établissements d’enseignement et de teaching and research institutions in France or recherche français ou étrangers, des laboratoires abroad, or from public or private research centers. publics ou privés. THÈSE Pour obtenir le grade de DOCTEUR DE L’UNIVERSITÉ DE GRENOBLE Spécialité : Informatique Arrêté ministériel : 7 août 2006 Présentée par Walter Andrew RUDAMETKIN IVEY Thèse dirigée par Jacky ESTUBLIER préparée au sein du Laboratoire d’Informatique de Grenoble dans L’École Doctorale Mathématiques, Sciences et Technologies de l’Information, Informatique Robusta : Une approche pour la construction d’applications dynamiques Thèse soutenue publiquement le 21/02/2013, devant le jury composé de : M. Noel DE PALMA Professeur à l’Université Joseph Fourier, Président M. Benoit BAUDRY Chargé de Recherche, INRIA Rennes, Rapporteur M. Luciano BARESI Professeur au Politecnico di Milano, Rapporteur M. Eric GRESSIER-SOUDAN Professeur au CNAM, Examinateur M. François EXERTIER Responsable de l’équipe JOnAS à Bull S.A.S., Examinateur M. Jacky ESTUBLIER Directeur de Recherche au CNRS, Directeur de thèse 1 Dedication I dedicate this dissertation to my loving family and my beautiful wife. Acknowledgements Thank you everybody! You know who you are. You know how you helped. There are so many people. Thank you for everything. I couldn’t have done it without you. Each and every one of you. I sincerely thank you. Robusta: An approach to building dynamic applications Abstract Current areas of research, such as ubiquitous and cloud computing, consider execution environments to be in a constant state of change. Dynamic applications—where components can be added, removed and substituted during execution—allow software to adapt and adjust to changing environments, and to accommodate evolving features. Unfortunately, dynamic applications raise design and development issues that have yet to be fully addressed. In this dissertation we show that dynamism is a crosscutting concern that breaks many of the assumptions that developers are otherwise allowed to make in classic applications. Dynamism deeply impacts software design and development. If not handled correctly, dynamism can silently corrupt the application. Furthermore, writing dynamic applications is complex and error-prone, and given the level of complexity and the impact dynamism has on the development process, software cannot become dynamic without (extensive) modification and dynamism cannot be entirely transparent (although much of it may often be externalized or automated). This work focuses on giving the software architect control over the level, the nature and the granularity of dynamism that is required in dynamic applications. This allows architects and developers to choose where the efforts of programming dynamic components are best spent, avoiding the cost and complexity of making all components dynamic. The idea is to allow architects to determine the balance between the efforts spent and the level of dynamism required for the application’s needs. At design-time we perform an impact analysis using the architect’s requirements for dynamism. This serves to identify components that can be corrupted by dynamism and to—at the architect’s disposition—render selected components resilient to dynamism. The application becomes a well-defined mix of dynamic areas, where components are expected to change at runtime, and static areas that are protected from dynamism and where programming is simpler and less restrictive. At runtime, our framework ensures the application remains consistent—even after unexpected dynamic events—by computing and removing potentially corrupt components. The framework attempts to recover quickly from dynamism and to minimize the impact of dynamism on the application. Our work builds on recent Software Engineering and Middleware technologies—namely, OSGi, iPOJO and APAM—that provide basic mechanisms to handle dynamism, such as dependency injection, late-binding, service availability notifications, deployment, lifecycle and dependency management. Our approach, implemented in the Robusta prototype, extends and complements these technologies by providing design and development-time support, and enforcing application execution consistency in the face of dynamism. i Table of Contents Part I: Introduction .............................................................................................. 1 Chapter 1 Introduction............................................................................................................. 1 1.1 Motivations and Overview .................................................................................................... 1 1.2 Dissertation Structure ............................................................................................................ 5 Part II: State of the Art ........................................................................................ 7 Chapter 2 Background .............................................................................................................. 9 2.1 Introduction ........................................................................................................................... 9 2.2 Software Architecture .......................................................................................................... 10 2.2.1 Definitions for Software Architecture.............................................................................................................. 11 2.3 Component-Based Software Engineering ........................................................................... 14 2.3.1 A little bit of history ............................................................................................................................................... 14 2.3.2 Component ............................................................................................................................................................... 15 2.3.3 Connector .................................................................................................................................................................. 17 2.3.4 Composite component.......................................................................................................................................... 18 2.3.5 Configuration .......................................................................................................................................................... 19 2.3.6 Ports ............................................................................................................................................................................ 19 2.3.7 Bindings..................................................................................................................................................................... 20 2.3.8 Component framework ........................................................................................................................................ 20 2.3.9 Other concepts......................................................................................................................................................... 20 2.3.9.1 Deployment...................................................................................................................................................... 21 2.3.9.2 Architecture Description Languages ....................................................................................................... 21 2.3.10 Modules vs. Components.................................................................................................................................. 23 2.4 Service Oriented Computing ............................................................................................... 25 2.5 Service-Oriented Components............................................................................................. 26 2.5.1 Abstraction levels ................................................................................................................................................... 27 2.5.2 Mapping components to objects........................................................................................................................ 28 2.5.3 Dependencies ........................................................................................................................................................... 29 2.5.4 Dependency types.................................................................................................................................................. 30 2.6 Conclusion ........................................................................................................................... 30 Chapter 3 Software Evolution .............................................................................................
Recommended publications
  • Jonas 5 Configuration Guide
    JOnAS 5 Configuration guide JOnAS Team ( ) - September 2009 - Copyright © OW2 Consortium 2007-2009 This work is licensed under the Creative Commons Attribution-ShareAlike License. To view a copy of this license,visit http://creativecommons.org/licenses/by-sa/2.0/deed.en or send a letter to Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. Table of Contents 1. Introduction .............................................................................................................. 1 1.1. Configuring JOnAS ......................................................................................... 1 1.2. Terminology .................................................................................................. 1 1.2.1. Server or JOnAS instance ...................................................................... 1 1.2.2. Service ............................................................................................... 1 1.2.3. Container ............................................................................................ 1 1.2.4. Domain .............................................................................................. 1 1.2.5. Master server ....................................................................................... 2 1.2.6. Cluster ................................................................................................ 2 2. Configuring a JOnAS instance ..................................................................................... 3 2.1. Configuring JOnAS Environment
    [Show full text]
  • 9. Platforms – Java ME and Osgi
    Department of Computer Science Institute for System Architecture, Chair for Computer Networks Application Development for Mobile and Ubiquitous Computing 9. Platforms – Java ME and OSGi Dr. Ing. Thomas Springer Technische Universität Dresden Chair of Computer Networks JAVA MICRO EDITION Java Micro Edition - Overview Creation of Stand-alone applications for resource limited devices • Native programming limits portability and reusability • Java is a widely deployed platform • supports portability and reusability • issues with resource-limited devices for Java SE Sun divides today the Java-technology into 3 domains: • Java SE (Standard Edition) ⇨ Desktop applications • Java ME (Micro Edition) ⇨ Resource restricted systems • Java EE (Enterprise Edition) ⇨ Server-side solution Goals of Java ME • Portability of applications for large range of resource-limited devices • same (Java) programming model • Comfortable development of applications for mobile devices Fast growing distribution of Java Micro Edition • Number of Java ME-enabled mobile phones: o 2002: 31 Mio. o 2003: 88 Mio. o 2008: 592 Mio. (prognosis) Dr. Thomas Springer Application Development - Lecture 9. Platforms - Java ME and OSGi 3 Application Domains of Java ME Designed for devices with restrictions concerning processor power, memory, display size and networking capabilities Heterogeneous requirements for Java ME devices • Personal, mobile, networked devices o Mobile phones, PDA`s, Smart phones, pagers o Characteristics:• Simple User Interfaces • Memory capacity: 128 – 512 kb • Wireless network connection (low bandwidth) • Commonly used, stationary, networked devices o Set-Top-Boxes, video-phones, entertainment and navigation systems… o Characteristics:• More complex user interfaces • Memory capacity: 2 – 16 MB • Broadband network connection over TCP/IP Dr. Thomas Springer Application Development - Lecture 9.
    [Show full text]
  • Full-Graph-Limited-Mvn-Deps.Pdf
    org.jboss.cl.jboss-cl-2.0.9.GA org.jboss.cl.jboss-cl-parent-2.2.1.GA org.jboss.cl.jboss-classloader-N/A org.jboss.cl.jboss-classloading-vfs-N/A org.jboss.cl.jboss-classloading-N/A org.primefaces.extensions.master-pom-1.0.0 org.sonatype.mercury.mercury-mp3-1.0-alpha-1 org.primefaces.themes.overcast-${primefaces.theme.version} org.primefaces.themes.dark-hive-${primefaces.theme.version}org.primefaces.themes.humanity-${primefaces.theme.version}org.primefaces.themes.le-frog-${primefaces.theme.version} org.primefaces.themes.south-street-${primefaces.theme.version}org.primefaces.themes.sunny-${primefaces.theme.version}org.primefaces.themes.hot-sneaks-${primefaces.theme.version}org.primefaces.themes.cupertino-${primefaces.theme.version} org.primefaces.themes.trontastic-${primefaces.theme.version}org.primefaces.themes.excite-bike-${primefaces.theme.version} org.apache.maven.mercury.mercury-external-N/A org.primefaces.themes.redmond-${primefaces.theme.version}org.primefaces.themes.afterwork-${primefaces.theme.version}org.primefaces.themes.glass-x-${primefaces.theme.version}org.primefaces.themes.home-${primefaces.theme.version} org.primefaces.themes.black-tie-${primefaces.theme.version}org.primefaces.themes.eggplant-${primefaces.theme.version} org.apache.maven.mercury.mercury-repo-remote-m2-N/Aorg.apache.maven.mercury.mercury-md-sat-N/A org.primefaces.themes.ui-lightness-${primefaces.theme.version}org.primefaces.themes.midnight-${primefaces.theme.version}org.primefaces.themes.mint-choc-${primefaces.theme.version}org.primefaces.themes.afternoon-${primefaces.theme.version}org.primefaces.themes.dot-luv-${primefaces.theme.version}org.primefaces.themes.smoothness-${primefaces.theme.version}org.primefaces.themes.swanky-purse-${primefaces.theme.version}
    [Show full text]
  • EJB 3 in Action by Debu Panda Reza Rahman Ryan Cuprak Michael Remijan
    S AMPLE CHAPTER MANNING SECOND EDITION Debu Panda Reza Rahman Ryan Cuprak Michael Remijan EJB 3 in Action by Debu Panda Reza Rahman Ryan Cuprak Michael Remijan Chapter 1 Copyright 2014 Manning Publications brief contents PART 1OVERVIEW OF THE EJB LANDSCAPE................................1 1 ■ What’s what in EJB 3 3 2 ■ A first taste of EJB 25 PART 2WORKING WITH EJB COMPONENTS ..............................47 3 ■ Building business logic with session beans 49 4 ■ Messaging and developing MDBs 93 5 ■ EJB runtime context, dependency injection, and crosscutting logic 117 6 ■ Transactions and security 160 7 ■ Scheduling and timers 196 8 ■ Exposing EJBs as web services 214 PART 3USING EJB WITH JPA AND CDI .................................251 9 ■ JPA entities 253 10 ■ Managing entities 294 11 ■ JPQL 321 12 ■ Using CDI with EJB 3 359 v vi BRIEF CONTENTS PART 4PUTTING EJB INTO ACTION.......................................395 13 ■ Packaging EJB 3 applications 397 14 ■ Using WebSockets with EJB 3 427 15 ■ Testing and EJB 458 What’s what in EJB 3 This chapter covers ■ The EJB container and its role in Enterprise applications ■ The different types of Enterprise Java Beans (EJBs) ■ Closely related technologies such as the Java Persistence API (JPA) ■ The different EJB runtime environments ■ Innovations started with EJB 3 ■ New changes with EJB 3.2 One day, when God was looking over his creatures, he noticed a boy named Sadhu whose humor and cleverness pleased him. God felt generous that day and granted Sadhu three wishes. Sadhu asked for three reincarnations—one as a ladybug, one as an elephant, and the last as a cow.
    [Show full text]
  • Getting Started with Jonas 5
    Getting started with JOnAS 5 JOnAS Team ( Philippe Coq, Guillaume Sauthier) - March 2009 - Copyright © OW2 Consortium 2007-2009 This work is licensed under the Creative Commons Attribution-ShareAlike License. To view a copy of this license,visit http://creativecommons.org/licenses/by-sa/2.0/deed.en or send a letter to Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. Table of Contents Preface ........................................................................................................................ v 1. First contact with JOnAS 5 ......................................................................................... 1 1.1. How do I set up a JOnAS environment? ............................................................. 1 1.1.1. JONAS_BASE creation ......................................................................... 1 1.2. How can I check if everything is correct? ............................................................ 2 1.2.1. jonas check ......................................................................................... 2 1.3. How can I run a JOnAS server? ........................................................................ 2 1.4. How can I run my first Java EE application? ....................................................... 3 1.5. Understanding how all of this runs out of the box ................................................. 4 1.6. First step in JOnAS administration ..................................................................... 5 2. Learning JOnAS by examples
    [Show full text]
  • The Glassfish Community Delivering a Java EE Application Server
    The GlassFish Community: An Overview The GlassFish Community Delivering a Java EE Application Server Eduardo Pelegri-Llopart Yutaka Yoshida Alexis Moussine-Pouchkine Sun Microsystems, Inc. http://blogs.sun.com/theaquarium Last Updated September 2007 The GlassFish Community 1 At JavaOne 2005, Sun announced Project GlassFish, an initiative to open source its Application Server and the Java EE Reference Implementation (see inset: Project GlassFish). This was the first step of open sourcing all the Java platform, but it also had other effects. Project GlassFish Project GlassFish accelerated the adoption of Java EE 5, added a new enterprise-quality App Server Sun launched Project GlassFish to the options available to the Open Source in June 2005, during JavaOne, to community, and has lead to a Open Source the Reference transformation of how Sun's AppServer is Implementation for Java EE 5 and developed, tested, made available, and Sun's Application Server. evolved, in the process creating a much The first release followed less better product. than a year after, at JavaOne 2006 A year and a half after the initial launch, the (May 2006). GlassFish community has already delivered The second release was released its first final release and is on its way to its in September 2007. second. In this article we will provide an overview of all the aspects of the GlassFish The focus is now on GlassFish v3, Community and the GlassFish AppServer. the modular and lightweight application server (see HK2). What is GlassFish GlassFish is a Community and an Application Server. The community's main deliverables are a Java EE 5 compatible Application Server, the GlassFish AppServer, and the Reference Implementation for the Java Persistence API, TopLink Essentials.
    [Show full text]
  • Service Coroner: a Diagnostic Tool for Locating Osgi Stale References
    Service Coroner: A Diagnostic Tool for Locating OSGi Stale References Kiev Gama and Didier Donsez University of Grenoble, LIG laboratory, ADELE team {firstname.lastname}@imag.fr Abstract Moreover, the OSGi specification applies service- The OSGi Services Platform provides a framework oriented architecture principles to Java application for the dynamic deployment of Java-based design. The concept of service is important to decouple applications. It allows to install, to activate, to update the application modules in order to dynamically and to uninstall application modules without the need substitute or update individual modules without to restart the host Java Virtual Machine. However, the affecting the entire system. mishandling of such OSGi dynamics may result in a The OSGi has proved to be successful in embedded problem described in the OSGi specification as Stale systems. Its adoption in the software industry is References, which happen when services from continuously growing as more applications tend to take uninstalled modules are still referenced by active code. advantage of its pluggable architecture. One of the well It may lead to inconsistencies in application’s known cases is the Eclipse project [2] that since behavior, state and memory. Currently, there are no version 3.0 has migrated to the OSGi platform. A new tools available to address this issue. This paper trend in desktop applications [2] and server presents a diagnostics tool named ServiceCoroner that middlewares [3] (i.e., JOnAS, Weblogic, WebSphere) detects such problems. It helps developers and shows the growing adoption of OSGi as a modular administrators diagnose OSGi applications running layer for either commercial or open-source Java-based either in production or test environments.
    [Show full text]
  • Unit Test Virtualization with VMVM
    Unit Test Virtualization with VMVM Jonathan Bell Gail Kaiser Columbia University Columbia University 500 West 120th St, MC 0401 500 West 120th St, MC 0401 New York, NY USA New York, NY USA [email protected] [email protected] ABSTRACT by the test suite. These tests are added to existing unit test Testing large software packages can become very time in- suites and in an ideal continuous integration environment, tensive. To address this problem, researchers have inves- executed regularly (e.g., upon code check-ins, or nightly). tigated techniques such as Test Suite Minimization. Test Because developers are often creating new tests, as software Suite Minimization reduces the number of tests in a suite grows in size and complexity, its test suite frequently grows by removing tests that appear redundant, at the risk of a similarly. Software can reach a point where its test suite has reduction in fault-finding ability since it can be difficult to gotten so large that it takes too long to regularly execute identify which tests are truly redundant. We take a com- | previous work has reported test suites in industry taking pletely different approach to solving the same problem of several weeks to execute fully [36]. long running test suites by instead reducing the time needed To cope with long running test suites, testers might turn to execute each test, an approach that we call Unit Test to Test Suite Minimization or Test Suite Prioritization [43]. Virtualization. With Unit Test Virtualization, we reduce Test Suite Minimization techniques such as [14, 15, 22, 23, the overhead of isolating each unit test with a lightweight 27, 28, 38, 41] seek to reduce the total number of tests to virtualization container.
    [Show full text]
  • Extending an Open Source Enterprise Service Bus for Multi-Tenancy Support Focusing on Administration and Management
    Institute of Architecture of Application Systems University of Stuttgart Universitätsstraße 38 D-70569 Stuttgart Diplomarbeit Nr. 3226 Extending an Open Source Enterprise Service Bus for Multi-Tenancy Support Focusing on Administration and Management Dominik Muhler Course of Study: Software Engineering Examiner: Prof. Dr. Frank Leymann Supervisor: Dipl.-Inf. Steve Strauch Dipl.-Inf. Tobias Binz Commenced: July 28, 2011 Completed: January 27, 2012 CR-Classification: C.2.4, D.2.11, H.2.1, H.3.4 Abstract As part of cloud computing, the service model Platform-as-a-Service (PaaS) has emerged, where customers can develop and host internet-scale applications on cloud infrastructure. The Enterprise Service Bus (ESB) is one possible building block of a PaaS offering, providing integration capabilities for service-oriented architectures. Bringing the ESB to the cloud requires scalability and multi-tenancy support. When applied, these characteristics lead to economies of scale, reducing the costs per customer. In this diploma thesis we specify, design, and implement a multi-tenant management ap- plication for an existing open source ESB. The management application grants tenant users limited configuration access to the ESB’s connectivity and integration services. A tenant registry and a service registry serve as platform-wide databases. We ensure data isolation between tenants for the management application and ESB message flows. Furthermore, the management application can control clusters of ESB instances, retaining elasticity. These goals also involve extensions to the ESB itself, which implements the Java Business Integration (JBI) specification. As a result, an integration scenario emerged from the EU-funded project 4CaaSt was applied to the system.
    [Show full text]
  • Multitenancy Guide
    Multitenancy Guide JOnAS Team () - Jun 2012 - Copyright © OW2 Consortium 2012 This work is licensed under the Creative Commons Attribution-ShareAlike License. To view a copy of this license,visit http://creativecommons.org/licenses/by-sa/2.0/deed.en or send a letter to Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. Table of Contents 1. Introduction .............................................................................................................. 1 1.1. Multitenancy .................................................................................................. 1 1.2. Shared application server ................................................................................. 1 2. Tenant context .......................................................................................................... 2 3. Customization ........................................................................................................... 3 3.1. Context root customization ............................................................................... 3 3.2. Data isolation in database ................................................................................. 3 3.3. JNDI names customization ............................................................................... 4 3.4. MBeans customization ..................................................................................... 5 3.5. Tenants administration isolation ......................................................................... 6 3.6. Logs customization
    [Show full text]
  • EJB 3.0 Programmer's Guide
    EJB 3.0 Programmer's Guide (Florent BENOIT) - March 2009 - Copyright © OW2 Consortium 2008-2009 This work is licensed under the Creative Commons Attribution-ShareAlike License. To view a copy of this license,visit http://creativecommons.org/licenses/by-sa/2.0/deed.en or send a letter to Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. Table of Contents 1. Introduction to EJB3 .................................................................................................. 1 1.1. Overview ....................................................................................................... 1 1.2. The Advantage of EJB3 ................................................................................... 1 1.3. EJB2 vs EJB3: EoD ........................................................................................ 1 1.4. New Features ................................................................................................. 2 1.4.1. Metadata Annotations ............................................................................ 2 1.4.2. Business Interceptors ............................................................................. 2 1.4.3. Lifecycle Interceptors ............................................................................ 2 1.4.4. Dependency Injection ............................................................................ 2 1.4.5. Persistence .......................................................................................... 2 2. Writing a HelloWorld Bean .......................................................................................
    [Show full text]
  • Easybeans Developer's Guide
    EasyBeans Developer's guide Florent BENOIT, OW2 consortium EasyBeans Developer's guide by Florent BENOIT Published $Id: developerguide.xml 216 2006-03-16 19:01:07Z benoitf $ Copyright © 2006-2008 OW2 Consortium Abstract The EasyBeans developer guide is intended for developers wanting to work with the source distribution of EasyBeans. People wanted to contribute to EasyBeans should read this documentation. This work is licensed under the Creative Commons Attribution-ShareAlike License. To view a copy of this license,visit http:// creativecommons.org/licenses/by-sa/2.0/deed.en [http://creativecommons.org/licenses/by/2.0/] or send a letter to Creative Commons, 559 Nathan Abbott Way, Stanford, California 94305, USA. Table of Contents 1. Building EasyBeans From Source. ................................................................................ 1 1.1. Requirements ................................................................................................. 1 1.1.1. JDK ................................................................................................... 1 1.1.2. Maven ................................................................................................ 1 1.1.3. Ant .................................................................................................... 1 1.1.4. TestNG ............................................................................................... 1 1.1.5. Clover ................................................................................................ 1 1.2. Optional Requirements
    [Show full text]