1 / 47

Advanced Component-Based Software Engineering

Advanced Component-Based Software Engineering. Overview of several component models. Agenda. Unified Modelling Language (UML) Picolo Fractal BIP Autosar. Unified Modelling Language (UML). C. <<component>> C. Component diagram. Three representations for a component

deanne
Download Presentation

Advanced Component-Based Software Engineering

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Advanced Component-Based SoftwareEngineering Overview of several component models Séverine Sentilles

  2. Agenda • Unified Modelling Language (UML) • Picolo • Fractal • BIP • Autosar Séverine Sentilles

  3. Unified Modelling Language(UML) Séverine Sentilles

  4. C <<component>> C Component diagram • Three representations for a component • But access points are required • Utilisation of interfaces • Utilisation of port <<component>> C Séverine Sentilles

  5. Interfaces • Role: • Specification of the access point • Required functionalities • Provided functionalities • 2 existing representation • The most descriptive • The compact • The compact <<interface>> ProvidedItf <<component>> C <<interface>> RequiredItf <<component>> C ProvidedItf RequiredItf Séverine Sentilles

  6. Ports • Role: • Access point to the internal structure of the component • Can have 0 or several interfaces • Representation: <<component>> C Séverine Sentilles

  7. <<component>> Client <<component>> Server IdenticalItf Relationship between components • Use the notion of connector • Roughly a way to link components together & make them ”communicate”via a request of services • Generalisation of the means of communication • Example: • Client-server • Pipe&filter • Message exchange • Can also be called horizontal composition Séverine Sentilles

  8. <<component>> A <<component>> B Vertical composition • Can also be called hierarchical composition • Role • To increase the component granularity • To expose the content of the component • Use the notion of delegation connector (between two ports) <<component>> C Séverine Sentilles

  9. Profile UML • Extension of the UML model in order to adapt it to the particular requirements of a context • Uses • Stereotypes • Tagged values • OCL Constraints • Examples: • Profile for EJB components • Profile for a software architecture Séverine Sentilles

  10. EJB Profile Séverine Sentilles

  11. Agenda • Unified Modelling Language (UML) • Picolo • Fractal • BIP • Autosar Séverine Sentilles

  12. Picolo Séverine Sentilles

  13. Characteristics • A simple componentmodel • to understand how components work • Not suited for building real applications • Programinglanguage: Python • Developed by: • LIFL (FRANCE) Séverine Sentilles From “Picolo: A Simple Python Framework for Introducing Components Principles, 2005”

  14. The component model Séverine Sentilles From “Picolo: A Simple Python Framework for Introducing Components Principles, 2005”

  15. Agenda • Unified Modelling Language (UML) • Picolo • Fractal • BIP • Autosar Séverine Sentilles

  16. The Fractal component model Séverine Sentilles

  17. Characteristics • Hierarchical, • Reflexive, • Open • Allow the sharing of components • Extensible • Several implementation • Julia (Java) • Think (C) • FracTalk (smalltalk) • FracNet (.NET) • Developed by • France Telecom R&D (FRANCE) • INRIA (FRANCE) Séverine Sentilles

  18. Components • Existence at compile-time and run-time • “3” types • Primitive • Composite • (Shared) • Divided in 2 parts • Membrane • Management of the extra-functional properties (Controllers) • Ex: Binding, Life-cycle, state, etc. • Extensible (open set of control capabilities) • Content (management of the functional properties) • Reflexive capabilities • execution and internal structure of component can be made explicit • through well-defined interfaces • Extendable/adaptable (to fit the programmer’s constraints and objectives) Séverine Sentilles

  19. Interfaces • Access point to the components • Characteristics: • Client (required)/Server (provided) • Mandatory/optional • Simple/multiple • Some predetermined interface (used in the membrane) • Binding-controller-itf • Lifecycle-controller-itf • Name-controller-itf • … Séverine Sentilles

  20. Communication • 2 types: • Primitive binding: • link a server interface to a client interface within a component • Composite binding: • Communication path between an arbitrary number of component interfaces • primitives bindings • and/or binding components (stub, skeleton, adapters, etc.) Séverine Sentilles

  21. Julia • Small, efficient, extensible run-time framework • Programming language: Java • Relies on a combination of interceptors and mixins (for the programming of the reflective features) Séverine Sentilles

  22. Example The Serveur Component: @FractalComponent(controllerDesc="primitive") @Provides( interfaces= @Interface(name="s",signature=Service.class) ) public class ServeurImpl implements Service { public void print( String msg ) { System.out.println(msg); } } Séverine Sentilles

  23. Example The Client Component: @FractalComponent(controllerDesc="primitive") @Provides( interfaces= @Interface(name="r",signature=Runnable.class) ) public class ClientImpl implements Runnable { @Requires(name="s") private Service service; public void run() { service.print("Hello world!"); } } Séverine Sentilles

  24. Example Assembling the components: <definition name="HelloWorld"> <interface name="r" role="server" signature="java.lang.Runnable" /> <component name="client" name="Client"> <interface name="r" role="server" signature="java.lang.Runnable" /> <interface name="s" role="client" signature="Service" /> <content class="ClientImpl" /> </component> <component name="server" name="Server"> <interface name="s" role="client" signature="Service" /> <content class="ServerImpl" /> </component> <binding client="this.r" server="client.r" /> <binding client="client.s" server="server.s" /> </definition> Séverine Sentilles

  25. Fractal and the main principles of the CBSE • Reusability • Utilisation of type system, communication semantic, component semantic => risk to have a conflict/incompatibility between component developed independently • Substituability • Possible ? • Extensibility • At design-time: ok • At run-time: with the introspection mechanism ? • Composability: • Behaviour superimposed by the ”parent-component” to the subcomponents (extra-functional properties) Séverine Sentilles

  26. Agenda • Unified Modelling Language (UML) • Picolo • Fractal • BIP • Autosar Séverine Sentilles

  27. BIP Séverine Sentilles

  28. Priority Interaction Behavior A BIP component Structure Characteristics • Framework for modelling heterogeneous real-time components • Developed by Verimag (FRANCE) • Hierarchical • Structured in 3 layers <B, I, P>: • B: Behavior • I: Interaction (a set of connectors describing the interactions between transition of the behavior) • P: Priority rules (set of constraints describing scheduling policy for interaction) Séverine Sentilles

  29. States Variables Ports Transitions Components • A component consists of: • A set of ports : action names used for synchronization with other components. • A set of control states: synchronization points. • A set of variablesused to store (local) data. • A set of transitions modeling atomic computation steps. Séverine Sentilles

  30. component • Compound component: • new components from existing components Séverine Sentilles

  31. Communication styles • Interactions • Synchronous • Rendez-vous • Broadcast • Utilisation of connectors • Set of ports from different components that can be involved in an interaction • Ex: p1, p2, p3 ports of 3 distincts components, then the connector {p1,p2,p3} has => 7 interactions: p1, p2, p3, {p1,p2}, {p1,p3}, {p2,p3}, {p1,p2,p3}. Séverine Sentilles Synchronization

  32. Priorities • used to filter interactions among the feasible ones depending on given conditions Séverine Sentilles

  33. BIP and the main principles of CBSE • Reusability • existing components can be combined to generate complex components using platform glue • Substituability • ? • Extensibility • ? • Composability: • Utilization of parameterized binary composition operator • The product of two components consists in composition layer by layer Séverine Sentilles

  34. Example Defining a component component Reactive port in, out data int x, y behavior state empty on in provided 0 < x do y:=f(x) to full state full on out to empty end end Séverine Sentilles

  35. Example Defining an interaction connector C1 = p1|p2|p3 behavior on p1|p2|p3 provided ¬(x1 = x2 = x3) do x1, x2, x3 := MAX(x1, x2, x3) end Séverine Sentilles

  36. Agenda • Unified Modelling Language (UML) • Picolo • Fractal • BIP • Autosar Séverine Sentilles

  37. Autosar Séverine Sentilles

  38. Chacteristics • Automotive Open System Architecture • Goal: Separation of concerns • Software components deals with application logic and can be developed independently of the underlying hardware and os • Middleware-layer handles aspects of remote communication, component lifecycle, scheduling, timing as well as OS abstraction. • configurable/customizable run-time environment • Adding new functions • product variants, platforms Séverine Sentilles

  39. Developed by Séverine Sentilles

  40. View Séverine Sentilles

  41. Components Layered architecture Séverine Sentilles

  42. Components • Independent of the infrastructure • Ports and connectors • No imposed size • Reusable piece of functionality (filter) • An entire automotive functionality • Sensors/actuators • Particular components • Encapsulate the dependencies of the application on specific sensors/actuators • crossing module boundaries (function distribution) • one function: several SW components one/several ECUs • one ECU: several SW Components from different functions / vendors Séverine Sentilles

  43. Component (cont) • Owns a description (SW-C Description) • Operations and datas provided/required • Requirements on the infrastructure • Resources needed (CPU-time, memory) • Information regarding the specific implementation of the component Séverine Sentilles

  44. Component connexion Séverine Sentilles

  45. Communication style • Communication style • Client/server • Synchronous communication pattern(The client can be blocked) • Sender/Receiver • Asynchronous communication pattern(the sender is not blocked) • Event is considered as a subcategory of sender/receiver Séverine Sentilles

  46. Autosar and the main principles of CBSE • Reusability • ok • Substituability • At run-time: No (the desired system is static after design time) • Extensibility: • ? • Composability: • ? Séverine Sentilles

  47. Literature • Unified Modelling Language (UML) • Picolo • Picolo: A Simple Python Framework for Introducing Components Principles • http://www.win.tue.nl/~mchaudro/cbse2006/PicoloTalk.pdf • http://www.win.tue.nl/~mchaudro/cbse2006/Picolo%20Introducing%20Components%20using%20Python.pdf • Fractal • The Fractal Component Model and Its Support in Java • http://fractal.objectweb.org/doc/pub/SPE06.pdf • Fractal tutorial at ICAR 2006 (in French) • http://sardes.inrialpes.fr/ecole/2006/cours-fractal.pdf • BIP • Modeling Heterogeneous Real-time Components in BIP • http://www-verimag.imag.fr/%7Easync/BIP/publications/BIP-invited-paperSEFM06.pdf • A Methodology and Supporting Tools for the Development of Low-Footprint and Safe Embedded Systems • http://www-verimag.imag.fr/%7Easync/BIP/publications/BIP2THINK.pdf • AUTOSAR • AUTOSAR: Technical Overview • http://www.autosar.org/download/AUTOSAR_TechnicalOverview.pdf • AUTOSAR: Standardization of software architecture in automotive industry • http://symposium.itea2.org/symposium2006/main/presentations/day_2/AUTOSAR_Standardization_of_software_architecture_in_automotive_industry.pdf?PHPSESSID=433abcfec16c19b0dbb2554976 Séverine Sentilles

More Related