A Methodology for Building Reliable Service-Based Applications
Total Page:16
File Type:pdf, Size:1020Kb
UNIVERSIDADE FEDERAL DO RIO GRANDE DO NORTE DEPARTAMENTO DE INFORMÁTICA E MATEMÁTICA APLICADA DOUTORADO EM CIÊNCIA DA COMPUTAÇÃO Plácido Antônio de Souza Neto A Methodology for Building Reliable Service-Based Applications Natal-RN / Brasil 2012 Plácido Antônio de Souza Neto A Methodology for Building Reliable Service-Based Applications Tese submetida ao Programa de Pós-Graduação em Sistemas e Computação do Departamento de Informática e Matemática Aplicada da Uni- versidade Federal do Rio Grande do Norte (UFRN), como requisito para a obtenção do grau de Doutor em Ciência da Computação. Advisor: Prof. Dr. Martin Alejandro Musicante (UFRN-Brazil) Co-Advisor: Prof. Dra. Genoveva Vargas-Solar (CNRS-France) Natal-RN / Brasil 2012 I dedicate this work to my beloved wife Ana Flávia and to my son Lucas Kauai, my daily sunshine. Resumo Esta tese apresenta πSOD-M (Policy-based Service Oriented Development Methodology), uma metodologia para a modelagem de aplicações orientadas a serviços associandas a Políticas de qualidade. O trabalho propõe um método orientado a modelo para desenvolvimento de apli- cações confiáveis. πSOD-M consiste de: (i) um conjunto de meta-modelos para representação de requisitos não-funcionais associados a serviços nos diferentes níveis de modelagem, a partir de um modelo de caso de uso até um modelo de composição de serviço, (ii) um meta-modelo de plataforma específica que representa a especificação das composiçoes e as políticas, (iii) regras de transformação model-to-model e model-to-text para semi-automatizar a implementação de composiçoes de serviços confiáveis, e (iv) um ambiente que implementa estes meta-modelos e regras, representando assim aspectos transversais e limitações associadas a serviços, que devem ser respeitados. Esta tese também apresenta uma classificação e nomenclatura de requisitos não-funcionais para o desenvolvimento de aplicações orientadas a serviços. Nossa abordagem visa agregar valor ao desenvolvimento de aplicações orientadas a serviços que têm necessidades de garantias de requisitos de qualidade. Este trabalho utiliza conceitos das áreas de desenvolvi- mento orientado a serviços, design de requisitos não-funcionais e desenvolvimento dirigido a modelos para propor uma solução que minimiza o problema de modelagem de serviços web confiáveis. Área de Concentração: Engenharia de Software Palavras-chave: serviços confiáveis, políticas, desenvolvimento dirigido a modelos, metodolo- gia, πSOD-M. Abstract This thesis presents πSOD-M (Policy-based Service Oriented Development Methodology), a methodology for modeling reliable service-based applications using policies. It proposes a model driven method with: (i) a set of meta-models for representing non-functional constraints associated to service-based applications, starting from an use case model until a service com- position model; (ii) a platform providing guidelines for expressing the composition and the policies; (iii) model-to-model and model-to-text transformation rules for semi-automatizing the implementation of reliable service-based applications; and (iv) an environment that im- plements these meta-models and rules, and enables the application of πSOD-M. This thesis also presents a classification and nomenclature for non-functional requirements for developing service-oriented applications. Our approach is intended to add value to the development of service-oriented applications that have quality requirements needs. This work uses concepts from the service-oriented development, non-functional requirements design and model-driven delevopment areas to propose a solution that minimizes the problem of reliable service model- ing. Some examples are developed as proof of concepts. Area of Concentration: Software Engineering Key words: reliable service, policy, model-driven development, methodology, πSOD-M. Contents List of Figures List of Tables 1 Introduction p. 13 1.1 Motivation and Problem Statement....................... p. 14 1.2 Objectives and Main Results.......................... p. 16 1.3 Document Organization............................. p. 17 2 State of the Art p. 19 2.1 Non-Functional Requirements for Service-Based Applications........ p. 21 2.1.1 Concepts and Works.......................... p. 22 2.1.2 Analysis................................ p. 24 2.2 Methodologies for Service Oriented Development............... p. 28 2.2.1 Concepts and Works.......................... p. 29 2.2.2 Analysis................................ p. 33 2.3 Classification of Non-Functional Requirements for Service-Based Applications p. 36 2.3.1 NFR Meta-Model............................ p. 36 2.3.2 NFR Classification........................... p. 37 2.4 Conclusions................................... p. 41 3 πSOD-M: A Methodology for Building Reliable Service Based Applications p. 43 3.1 πSOD-M.................................... p. 44 3.1.1 General Overview........................... p. 44 3.1.2 Development Process.......................... p. 45 3.1.3 Methodology Concepts......................... p. 47 3.1.4 Case Study............................... p. 50 3.2 Platform Independent Models.......................... p. 52 3.2.1 π-UseCase Model........................... p. 53 3.2.1.1 π-UseCase Diagram, Terms and Concepts......... p. 54 3.2.1.2 Meta-model......................... p. 56 3.2.1.3 UML Concepts Representation............... p. 57 3.2.1.4 To Publish Music Use Case................. p. 61 3.2.2 π-ServiceProcess Model........................ p. 62 3.2.2.1 π-ServiceProcess Diagram, Terms and Concepts...... p. 63 3.2.2.2 Meta-model......................... p. 65 3.2.2.3 UML Concepts Representation............... p. 66 3.2.2.4 To Publish Music Process.................. p. 69 3.2.3 π-ServiceComposition Model..................... p. 70 3.2.3.1 π-ServiceComposition Diagram, Terms and Concepts... p. 71 3.2.3.2 Meta-model......................... p. 72 3.2.3.3 UML Concepts Representation............... p. 75 3.2.3.4 Publish Music Service Composition............ p. 75 3.3 π-PEWS Platform Specific Models....................... p. 78 3.3.1 π-PEWS Specification, Terms and Concepts.............. p. 78 3.3.2 Meta-model............................... p. 79 3.4 Model Transformations............................. p. 82 3.4.1 From π-UseCase to π-ServiceProcess................. p. 83 3.4.2 From π-ServiceProcess to π-ServiceComposition........... p. 88 3.4.3 From π-ServiceComposition to π-PEWS............... p. 91 3.5 Conclusions................................... p. 93 4 πSOD-M Environment p. 94 4.1 General Architecture.............................. p. 95 4.1.1 Ecore Meta-models (Models Plugin Module)............. p. 96 4.1.2 Model Transformation (Mapping Plugin Module)........... p. 97 4.1.2.1 π-UseCase2πServiceProcess Transformation Rules.... p. 99 4.1.2.2 π-ServiceComposition2π-PEWS Transformation Rules.. p. 101 4.1.3 Code Generation (Code Generation Module)............. p. 101 4.2 Defining Reliable Service Based Applications................. p. 105 4.2.1 π-UseCase Model........................... p. 106 4.2.2 π-ServiceProcess Models........................ p. 108 4.2.3 π-ServiceComposition Models..................... p. 111 4.2.4 π-PEWS Models............................ p. 112 4.3 Extending the Environment........................... p. 113 4.4 Conclusion................................... p. 114 5 Validation p. 115 5.1 Case Study 1: To Publish Music........................ p. 116 5.1.1 π-UseCase Model........................... p. 116 5.1.2 π-ServiceProcess Model........................ p. 119 5.1.3 π-ServiceComposition Model..................... p. 120 5.2 Case Study 2: Crime Map............................ p. 121 5.2.1 π-UseCase Model........................... p. 122 5.2.2 π-ServiceProcess Model........................ p. 126 5.2.3 π-ServiceComposition Model..................... p. 128 5.3 Case Study 3: GesIMED Application...................... p. 132 5.3.1 π-UseCase Model........................... p. 135 5.3.2 π-ServiceProcess Model........................ p. 136 5.3.3 π-ServiceComposition Model..................... p. 136 5.4 Lessons Learned................................ p. 137 5.4.1 Case Study 1: To Publish Music.................... p. 137 5.4.2 Case Study 2: Crime Map....................... p. 138 5.4.3 Case Study 3: GesIMED........................ p. 139 5.5 Conclusions................................... p. 141 6 Conclusions p. 143 6.1 Main Contributions............................... p. 143 6.2 Future Work................................... p. 144 References p. 146 Appendix A -- Source Selection and Analysis Method: Non-Functional Require- ments for Service-Based Applications p. 153 Appendix B --Service-Based Non-Functional Requirement Concepts p. 156 Appendix C -- π-PEWS Language p. 158 Appendix D -- To Publish Music Case Study Diagrams p. 161 List of Figures 1 Service-Based Non-Functional Requirement Model............... p. 37 2 Relationship of the NFR Concepts........................ p. 41 3 Related Works Analysis............................. p. 42 4 SOD-M and πSOD-M Extension Models.................... p. 45 5 πSOD-M Development Process and Models................... p. 46 6 πSOD-M Concepts................................ p. 48 7 Use Case Model “To Publish Music” - Spotify Music Service......... p. 51 8 Service Process Model “To Publish Music”.................. p. 52 9 Traditional UML Concepts............................ p. 53 10 π-UseCase model Example........................... p. 54 11 Constraint Representation............................ p. 55 12 Non-functional