Presentation is loading. Please wait.

Presentation is loading. Please wait.

Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Copyright © 2011 Applied Science University. All Rights Reserved ASU Open Course.

Similar presentations


Presentation on theme: "Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Copyright © 2011 Applied Science University. All Rights Reserved ASU Open Course."— Presentation transcript:

1 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved ASU Open Course System Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Component-Based Software Engineering Basic Concepts Dr. Eman M. Saleh Al-Maghary Email: e_saleh@asu.edu.joEmail: e_saleh@asu.edu.jo – Ext. 1269 SE Department Faculty of Information Technology http://fit.asu.edu.johttp://fit.asu.edu.jo – http://OpenCourse.asu.edu.johttp://OpenCourse.asu.edu.jo

2 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component-Based Software Engineering 1302481 Prerequisite: 1302386 Course Description Text Books: “Building Reliable Component Based Software Systems, Ivica Crnkovic and Magnus Larsson, Artech House, 2002.“Building Reliable Component Based Software Systems, Ivica Crnkovic and Magnus Larsson, Artech House, 2002. “Software Engineering, Ian Sommerville, 9 th Ed., 2012.“Software Engineering, Ian Sommerville, 9 th Ed., 2012.

3 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Lecture Contents Introduction Goals and advantages of CBSE Essentials of CBSE Components definition and charactestics 3

4 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Introduction What is this course about ? –A journey in searching for the “holy grail” of software “integrated circuits”

5 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Introduction What is this course about ? –A journey in searching for the “holy grail” of software “integrated circuits”

6 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component-Based Software Engineering Component-based software engineering (CBSE) is an approach to software development that relies on the reuse of entities called ‘software components’. 6Chapter 17 Software reuse

7 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component-Based Software Engineering Component-based software engineering (CBSE) is The process of defining, implementing and integrating (or composing) loosely coupled, independent components into systems. 7Chapter 17 Software reuse

8 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved It emerged from the failure of object- oriented development to support effective reuse. Single object classes are too detailed and specific. Components are more abstract than object classes and can be considered to be stand-alone service providers. They can exist as stand-alone entities. 8Chapter 17 Software reuse Component-Based Software Engineering

9 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved 9 CBSE (Component-Based Software Engineering) Definition Component-based software engineering (CBSE) is a branch of software engineering, the priority of which is the separation of concerns in respect of the wide-ranging functionality available throughout a given software system Developing new software from pre-built components. Attempt to make an association between SE and other engineering disciplines. It emerged from the failure of object-oriented development to support effective reuse.

10 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved 10 Reuse via Components Catalogue of software components Customer requirements Software application Component Providers Component integrator

11 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved 11 Why CBSE Software systems contain many similar or even identical components that are developed from scratch over and over again has led to reuse existing components (reusability- lower cost) Structuring a system into largely independent components make it easy to distribute the components among various engineers to allow parallel development (easier management - Work breakdown in PM) Maintenance: Lower cost of maintenance, easier to replace and upgrade Better quality and efficiency (next few slides) Support distributed systems (next few slides) Time-to-mark (next few slides)

12 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Goals of CBSE 1: Software construction Application Software construction vs. creation: application is developed as an assembly of “integrated circuits”

13 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Goals of CBSE 2: Reuse C1 Application 1 Application 2 Software “integrated circuits” are reusable entities It pays off to have as many applications that reuse an entity

14 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Goals of CBSE 3: Maintenance & Evolution C1 Application C1new update Maintenance and upgrading can be done by replacing parts, maybe even at runtime

15 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved 15 Improve Quality: Idea: Assuming that a collection of high- quality components is available, assembling these should yield systems of high-quality. 1.The cost of establishing the high quality of components is amortized over multiple use. 2.Multiple use of a component increases the likelihood of finding and removing errors.

16 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved 16 Time-to-market If the reuse of a component requires less time than the development of a component, systems can be built faster.

17 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved 17 Support Distributed system A computer running several software components is often called an application server. Using this combination of application servers and software components is usually called distributed computing. The usual real-world application of this is in financial applications or business software that is placed in deferent departments and environment (for example, purchasing, sales, HR management ).

18 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved 18 Integration of heterogeneous sources: –operating systems –programming language –network protocol –data representation

19 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved 19 Components should provide services to clients running locally or remotely Remote CLIENTS EJB Container EJB Remote CLIENTS Remote CLIENTS Local CLIENTS

20 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved CBSE essentials Independent components specified by their interfaces. Component standards to facilitate component integration. Middleware that provides support for component inter-operability. A development process that is geared to CBSE. 20 Chapter 17 sommerville

21 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved CBSE and design principles Apart from the benefits of reuse, CBSE is based on sound software engineering design principles: –Components are independent so do not interfere with each other; –Component implementations are hidden; –Communication is through well-defined interfaces; –Component platforms are shared and reduce development costs. 21 Chapter 17 Software reuse

22 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Components Components provide a service without regard to where the component is executing or its programming language –A component is an independent executable entity that can be made up of one or more executable objects; –The component interface is published and all interactions are through the published interface; 22Chapter 17 Software reuse

23 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component definitions Councill and Heinmann: –A software component is a software element that conforms to a component model and can be independently deployed and composed without modification according to a composition standard. Szyperski: –A software component is a unit of composition with contractually specified interfaces and explicit context dependencies only. A software component can be deployed independently and is subject to composition by third-parties. 23

24 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component Definition (Szyperski)

25 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component Definition (Szyperski)

26 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component Definition (Szyperski)

27 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component Definition (Szyperski) What is independent deployment? –no dependencies on peer-components –never partially deployed

28 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component characteristics Component characteristic Description StandardizedComponent standardization means that a component used in a CBSE process has to conform to a standard component model. This model may define component interfaces, component metadata, documentation, composition, and deployment. IndependentA component should be independent—it should be possible to compose and deploy it without having to use other specific components. In situations where the component needs externally provided services, these should be explicitly set out in a ‘requires’ interface specification. ComposableFor a component to be composable, all external interactions must take place through publicly defined interfaces. In addition, it must provide external access to information about itself, such as its methods and attributes. 28Chapter 17 Software reuse

29 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component characteristics Component characteristic Description DeployableTo be deployable, a component has to be self-contained. It must be able to operate as a stand-alone entity on a component platform that provides an implementation of the component model. This usually means that the component is binary and does not have to be compiled before it is deployed. If a component is implemented as a service, it does not have to be deployed by a user of a component. Rather, it is deployed by the service provider. DocumentedComponents have to be fully documented so that potential users can decide whether or not the components meet their needs. The syntax and, ideally, the semantics of all component interfaces should be specified. 29 Chapter 17 Software reuse

30 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component (Models) standards Standards need to be established so that components can communicate with each other and inter-operate. Unfortunately, several competing component standards were established: –Sun’s Enterprise Java Beans –Microsoft’s COM and.NET –CORBA’s CCM In practice, these multiple standards have hindered the uptake of CBSE. It is impossible for components developed using different approaches to work together. 30 Chapter 17 Software reuse

31 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved CBSE problems Component trustworthiness - how can a component with no available source code be trusted? Component certification - who will certify the quality of components? Emergent property prediction - how can the emergent properties of component compositions be predicted? Requirements trade-offs - how do we do trade-off analysis between the features of one component and another? Higher initial cost to build (making it more general, more testing, etc 31 Chapter 17 Sommerville

32 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component as a service provider The component is an independent, executable entity. It does not have to be compiled before it is used with other components. The services offered by a component are made available through an interface and all component interactions take place through that interface. The component interface is expressed in terms of parameterized operations and its internal state is never exposed. 32 Sommerville,Chapter 17

33 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component interfaces Provides interface –Defines the services that are provided by the component to other components. Requires interface –Specifies what services must be made available for the component to execute as specified. 33

34 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved Component interfaces Note UML notation. Ball and sockets can fit together. 34

35 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights Reserved A model of a data collector component 35

36 Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Email:info@asu.edu.jo Copyright © 2011 Applied Science University. All Rights ReservedContracts A more accurate specification of a component's behavior can be achieved through contracts. A contract is comprised of: – The Invariant, the global constraints which the component will maintain; – The Pre-condition, the constraints which need to be met by the client; – The Post-condition, the constraints which the component promises to establish in return. A contract specifies the interactions among components, in terms of: – The set of participating components; – The role of each component through its contractual obligations, such as type and casual obligations; – The invariant to be maintained by the components; – The specification of the methods which instantiate the contract.


Download ppt "Jordan - Amman Tel:5609999 Fax:5232899 P.O.Box : 166 Copyright © 2011 Applied Science University. All Rights Reserved ASU Open Course."

Similar presentations


Ads by Google