0% found this document useful (0 votes)
26 views

Lecture3 - Software Reuse

The document discusses software reuse including its benefits and challenges. It covers topics like application frameworks, software product lines, and application system reuse. It also describes different approaches that support software reuse at various levels from simple functions to complete application systems.

Uploaded by

asmm.rahaman
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
26 views

Lecture3 - Software Reuse

The document discusses software reuse including its benefits and challenges. It covers topics like application frameworks, software product lines, and application system reuse. It also describes different approaches that support software reuse at various levels from simple functions to complete application systems.

Uploaded by

asmm.rahaman
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 58

Software Reuse

Dr. Abu Sayed Md. Mostafizur Rahaman


Professor
Department of Computer Science and Engineering
Jahangirnagar University

05/12/2024 Chapter 15 Software reuse 1


Topics covered

 The reuse landscape


 Application frameworks
 Software product lines
 Application system reuse

05/12/2024 Chapter 15 Software reuse 2


Software reuse

 In most engineering disciplines, systems are designed by composing existing


components that have been used in other systems.
 Software engineering has been more focused on original development but it
is now recognised that to achieve better software, more quickly and at lower
cost, we need a design process that is based on systematic software reuse.
 There has been a major switch to reuse-based development over the past
10 years.

05/12/2024 Chapter 15 Software reuse 3


Reuse-based software engineering

 System reuse
 Complete systems, which may include several application programs may be reused.
 Application reuse
 An application may be reused either by incorporating it without change into other or by
developing application families.
 Component reuse
 Components of an application from sub-systems to single objects may be reused.
 For example, a pattern-matching system developed as part of a text-processing system
may be reused in a database management system
 Object and function reuse
 Small-scale software components that implement a single well-defined object or function
may be reused.

05/12/2024 Chapter 15 Software reuse 4


Benefits of software reuse

Benefit Explanation
Accelerated development Bringing a system to market as early as possible is often
more important than overall development costs. Reusing
software can speed up system production because both
development and validation time may be reduced.

Effective use of specialists Instead of doing the same work over and over again,
application specialists can develop reusable software that
encapsulates their knowledge.

Increased dependability Reused software, which has been tried and tested in
working systems, should be more dependable than new
software. Its design and implementation faults should
have been found and fixed.

05/12/2024 Chapter 15 Software reuse 5


Benefits of software reuse

Benefit Explanation

Lower development Development costs are proportional to the size of the software being
costs developed. Reusing software means that fewer lines of code have to be
written.
Reduced process The cost of existing software is already known, whereas the costs of
risk development are always a matter of judgment. This is an important factor
for project management because it reduces the margin of error in project
cost estimation. This is particularly true when relatively large software
components such as subsystems are reused.

Standards Some standards, such as user interface standards, can be implemented


compliance as a set of reusable components. For example, if menus in a user
interface are implemented using reusable components, all applications
present the same menu formats to users. The use of standard user
interfaces improves dependability because users make fewer mistakes
when presented with a familiar interface.
05/12/2024 Chapter 15 Software reuse 6
Problems with reuse

Problem Explanation
Creating, maintaining, Populating a reusable component library and ensuring the software
and using a component developers can use this library can be expensive. Development
library processes have to be adapted to ensure that the library is used.

Finding, understanding, Software components have to be discovered in a library, understood


and adapting reusable and, sometimes, adapted to work in a new environment. Engineers
components must be reasonably confident of finding a component in the library
before they include a component search as part of their normal
development process.

Increased maintenance If the source code of a reused software system or component is not
costs available then maintenance costs may be higher because the
reused elements of the system may become increasingly
incompatible with system changes.
05/12/2024 Chapter 15 Software reuse 7
Problems with reuse

Problem Explanation
Lack of tool support Some software tools do not support development with reuse. It may
be difficult or impossible to integrate these tools with a component
library system. The software process assumed by these tools may
not take reuse into account. This is particularly true for tools that
support embedded systems engineering, less so for object-oriented
development tools.

Not-invented-here Some software engineers prefer to rewrite components because


syndrome they believe they can improve on them. This is partly to do with trust
and partly to do with the fact that writing original software is seen as
more challenging than reusing other people’s software.

05/12/2024 Chapter 15 Software reuse 8


The reuse landscape

05/12/2024 Chapter 15 Software reuse 9


The reuse landscape

 Although reuse is often simply thought of as the reuse of system


components, there are many different approaches to reuse that may be used.
 Reuse is possible at a range of levels from simple functions to complete
application systems.
 The reuse landscape covers the range of possible reuse techniques.

05/12/2024 Chapter 15 Software reuse 10


The reuse landscape

05/12/2024 Chapter 15 Software reuse 11


Approaches that support software reuse

Approach Description
Application frameworks Collections of abstract and concrete classes are adapted and extended to
create application systems.
Application system integration Two or more application systems are integrated to provide extended
functionality
Architectural patterns Standard software architectures that support common types of
application system are used as the basis of applications. Described in
Chapters 6, 11 and 17.
Aspect-oriented software Shared components are woven into an application at different places
development when the program is compiled. Described in web chapter 31.
Component-based software Systems are developed by integrating components (collections of
engineering objects) that conform to component-model standards. Described in
Chapter 16.
05/12/2024 Chapter 15 Software reuse 12
Approaches that support software reuse

Approach Description
Configurable application Domain-specific systems are designed so that they can be configured to
systems the needs of specific system customers.
Design patterns Generic abstractions that occur across applications are represented as
design patterns showing abstract and concrete objects and interactions.
Described in Chapter 7.
ERP systems Large-scale systems that encapsulate generic business functionality and
rules are configured for an organization.
Legacy system wrapping Legacy systems (Chapter 9) are ‘wrapped’ by defining a set of interfaces
and providing access to these legacy systems through these interfaces.
Model-driven engineering Software is represented as domain models and implementation
independent models and code is generated from these models. Described
in Chapter 5.

05/12/2024 Chapter 15 Software reuse 13


Approaches that support software reuse

Approach Description
Program generators A generator system embeds knowledge of a type of application and is
used to generate systems in that domain from a user-supplied system
model.
Program libraries Class and function libraries that implement commonly used abstractions
are available for reuse.
Service-oriented systems Systems are developed by linking shared services, which may be
externally provided. Described in Chapter 18.
Software product lines An application type is generalized around a common architecture so that
it can be adapted for different customers.
Systems of systems Two or more distributed systems are integrated to create a new system.
Described in Chapter 20.

05/12/2024 Chapter 15 Software reuse 14


Which is the most appropriate technique to use in a particular
situation?

 “Obviously, the answer to this question depends on


 the requirements for the system being developed
 the technology
 Reusable assets available, and
 the expertise of the development team.
 Key factors that you should consider when planning reuse are shows in the
next slide

05/12/2024 Chapter 15 Software reuse 15


Reuse planning factors

 The development schedule for the software.


 If the software has to be developed quickly, you should try to reuse complete systems
rather than individual components. Although the fit to requirements may be imperfect, this
approach minimizes the amount of development required.
 The expected software lifetime.
 If you are developing a long-lifetime system, you should focus on the maintainability of
the system
 not just think about the immediate benefits of reuse but also of the long-term implications
 If you do not have access to the source code of the reusable components, you may
prefer to avoid off-the shelf components and systems from external suppliers.
 These suppliers may not be able to continue support for the reused software.
 You may decide that it is safer to reuse open-source systems and components as this
means you can access and keep copies of the source code.
Chapter 15 Software reuse 16
Reuse planning factors (Cont.)

 The background, skills and experience of the development team.


 The background, skills and experience of the development team All reuse technologies
are fairly complex, and you need quite a lot of time to understand and use them
effectively.
 Therefore, you should focus your reuse effort in areas where your development team has
expertise.
 The criticality of the software and its non-functional requirements.
 safety or security case
 This is difficult if you don’t have access to the source code of the software.
 If your software has stringent performance requirements, it may be impossible to use
strategies such as model-driven engineering (MDE)

05/12/2024 Chapter 15 Software reuse 17


Reuse planning factors (Cont.)

 The application domain.


 In many application domains, such as manufacturing and medical information systems,
there are generic products that may be reused by configuring them to a local situation.
 This is one of the most effective approaches to reuse, and it is almost always cheaper to
buy rather than build a new system
 The execution platform for the software.
 Some components models, such as .NET, are specific to Microsoft platforms.
 Similarly, generic application systems may be platform-specific, and you may only be
able to reuse these if your system is designed for the same platform

05/12/2024 Chapter 15 Software reuse 18


Application frameworks

05/12/2024 Chapter 15 Software reuse 19


Framework definition

 A framework is a generic structure that is extended to create a more specific


subsystem or application define a framework to be
 “..an integrated set of software artefacts (such as classes, objects and components) that
collaborate to provide a reusable architecture for a family of related applications.”

05/12/2024 Chapter 15 Software reuse 20


Application frameworks

 Frameworks are moderately large entities that can be reused.


 They are somewhere between system and component reuse.
 Frameworks are a sub-system design made up of a collection of abstract and
concrete classes and the interfaces between them.
 The sub-system is implemented by adding components to fill in parts of the
design and by instantiating the abstract classes in the framework.

05/12/2024 Chapter 15 Software reuse 21


Web application frameworks

 Support the construction of dynamic websites as a front-end for web


applications.
 WAFs are now available for all of the commonly used web programming
languages e.g. Java, Python, Ruby, etc.
 Interaction model is based on the Model-View-Controller composite pattern.

05/12/2024 Chapter 15 Software reuse 22


Model-view controller

 System infrastructure framework for GUI design.


 Allows for multiple presentations of an object and separate interactions with
these presentations.
 MVC framework involves the instantiation of a number of patterns (as
discussed in Chapter 7).

05/12/2024 Chapter 15 Software reuse 23


The Model-View-Controller pattern

05/12/2024 Chapter 15 Software reuse 24


WAF features

 Security
 WAFs may include classes to help implement user authentication (login) and access.
 Dynamic web pages
 Classes are provided to help you define web page templates and to populate these dynamically from the
system database.
 Database support
 The framework may provide classes that provide an abstract interface to different databases.
 Session management
 Classes to create and manage sessions (a number of interactions with the system by a user) are usually part of
a WAF.
 User interaction
 Most web frameworks now provide AJAX support (Holdener, 2008), which allows more interactive web pages to
be created.

05/12/2024 Chapter 15 Software reuse 25


Extending frameworks

 Frameworks are generic and are extended to create a more specific application
or sub-system. They provide a skeleton architecture for the system.
 Extending the framework involves
 Adding concrete classes that inherit operations from abstract classes in the
framework;
 Adding methods that are called in response to events that are recognised by the
framework.
 Problem with frameworks is their complexity which means that it takes a long
time to use them effectively.

05/12/2024 Chapter 15 Software reuse 26


Other Framework classes

 System infrastructure frameworks


 Support the development of system infrastructures such as communications, user
interfaces and compilers.
 Middleware integration frameworks
 Standards and classes that support component communication and information
exchange.
 Enterprise application frameworks
 Support the development of specific types of application such as telecommunications or
financial systems.

05/12/2024 Chapter 15 Software reuse 27


Software product lines

05/12/2024 Chapter 15 Software reuse 28


Software product lines

 Software product lines or application families are applications with generic


functionality that can be adapted and configured for use in a specific context.
 A software product line is a set of applications with a common architecture
and shared components, with each application specialized to reflect different
requirements.
 Adaptation may involve:
 Component and system configuration;
 Adding new components to the system;
 Selecting from a library of existing components;
 Modifying components to meet new requirements.

05/12/2024 Chapter 15 Software reuse 29


Base systems for a software product line

05/12/2024 Chapter 15 Software reuse 30


Base applications

 Core components that provide infrastructure support. These are not usually
modified when developing a new instance of the product line.
 Configurable components that may be modified and configured to specialize
them to a new application. Sometimes, it is possible to reconfigure these
components without changing their code by using a built-in component
configuration language.
 Specialized, domain-specific components some or all of which may be
replaced when a new instance of a product line is created.

05/12/2024 Chapter 15 Software reuse 31


Application frameworks and product lines

 Application frameworks rely on object-oriented features such as


polymorphism to implement extensions. Product lines need not be object-
oriented (e.g. embedded software for a mobile phone)
 Application frameworks focus on providing technical rather than domain-
specific support. Product lines embed domain and platform information.
 Product lines often control applications for equipment.
 Software product lines are made up of a family of applications, usually owned
by the same organization.

05/12/2024 Chapter 15 Software reuse 32


Product line architectures

 Architectures must be structured in such a way to separate different sub-


systems and to allow them to be modified.
 The architecture should also separate entities and their descriptions and the
higher levels in the system access entities through descriptions rather than
directly.

05/12/2024 Chapter 15 Software reuse 33


The architecture of a resource allocation system

05/12/2024 Chapter 15 Software reuse 34


The product line architecture of a vehicle dIspatcher

05/12/2024 Chapter 15 Software reuse 35


Vehicle dispatching

 A specialised resource management system where the aim is to allocate resources


(vehicles) to handle incidents.
 Adaptations include:
 At the UI level, there are components for operator display and communications;
 At the I/O management level, there are components that handle authentication, reporting and
route planning;
 At the resource management level, there are components for vehicle location and despatch,
managing vehicle status and incident logging;
 The database includes equipment, vehicle and map databases.

05/12/2024 Chapter 15 Software reuse 36


Product line specialisation

 Platform specialization
 Different versions of the application are developed for different platforms.
 Environment specialization
 Different versions of the application are created to handle different operating
environments e.g. different types of communication equipment.
 Functional specialization
 Different versions of the application are created for customers with different
requirements.
 Process specialization
 Different versions of the application are created to support different business
processes.

05/12/2024 Chapter 15 Software reuse 37


Product instance development

05/12/2024 Chapter 15 Software reuse 38


Product instance development

 Elicit stakeholder requirements


 Use existing family member as a prototype
 Choose closest-fit family member
 Find the family member that best meets the requirements
 Re-negotiate requirements
 Adapt requirements as necessary to capabilities of the software
 Adapt existing system
 Develop new modules and make changes for family member
 Deliver new family member
 Document key features for further member development

05/12/2024 Chapter 15 Software reuse 39


Product line configuration

 Design time configuration


 The organization that is developing the software modifies a common product line core by
developing, selecting or adapting components to create a new system for a customer.
 Deployment time configuration
 A generic system is designed for configuration by a customer or consultants working with
the customer. Knowledge of the customer’s specific requirements and the system’s
operating environment is embedded in configuration data that are used by the generic
system.

05/12/2024 Chapter 15 Software reuse 40


Deployment-time configuration

05/12/2024 Chapter 15 Software reuse 41


Levels of deployment time configuration

 Component selection, where you select the modules in a system that provide
the required functionality.
 Workflow and rule definition, where you define workflows (how information is
processed, stage-by-stage) and validation rules that should apply to
information entered by users or generated by the system.
 Parameter definition, where you specify the values of specific system
parameters that reflect the instance of the application that you are creating

05/12/2024 Chapter 15 Software reuse 42


Application system reuse

05/12/2024 Chapter 15 Software reuse 43


Application system reuse

 An application system product is a software system that can be adapted for


different customers without changing the source code of the system.
 Application systems have generic features and so can be used/reused in
different environments.
 Application system products are adapted by using built-in configuration
mechanisms that allow the functionality of the system to be tailored to
specific customer needs.
 For example, in a hospital patient record system, separate input forms and output
reports might be defined for different types of patient.

05/12/2024 Chapter 15 Software reuse 44


Benefits of application system reuse

 As with other types of reuse, more rapid deployment of a reliable system may be possible.
 It is possible to see what functionality is provided by the applications and so it is easier to
judge whether or not they are likely to be suitable.
 Some development risks are avoided by using existing software. However, this approach
has its own risks, as I discuss below.
 Businesses can focus on their core activity without having to devote a lot of resources to IT
systems development.
 As operating platforms evolve, technology updates may be simplified as these are the
responsibility of the COTS product vendor rather than the customer.

05/12/2024 Chapter 15 Software reuse 45


Problems of application system reuse

 Requirements usually have to be adapted to reflect the functionality and mode of


operation of the COTS product.
 The COTS product may be based on assumptions that are practically impossible to
change.
 Choosing the right COTS system for an enterprise can be a difficult process,
especially as many COTS products are not well documented.
 There may be a lack of local expertise to support systems development.
 The COTS product vendor controls system support and evolution.

05/12/2024 Chapter 15 Software reuse 46


Configurable application systems

 Configurable application systems are generic application systems that may


be designed to support a particular business type, business activity or,
sometimes, a complete business enterprise.
 For example, an application system may be produced for dentists that handles
appointments, dental records, patient recall, etc.
 Domain-specific systems, such as systems to support a business function
(e.g. document management) provide functionality that is likely to be required
by a range of potential users.

05/12/2024 Chapter 15 Software reuse 47


COTS-solution and COTS-integrated systems

Configurable application systems Application system integration

Single product that provides the functionality Several heterogeneous system products are
required by a customer integrated to provide customized
functionality

Based around a generic solution and Flexible solutions may be developed for
standardized processes customer processes
Development focus is on system Development focus is on system integration
configuration
System vendor is responsible for System owner is responsible for
maintenance maintenance
System vendor provides the platform for the System owner provides the platform for the
system system

05/12/2024 Chapter 15 Software reuse 48


ERP systems

 An Enterprise Resource Planning (ERP) system is a generic system that


supports common business processes such as ordering and invoicing,
manufacturing, etc.
 These are very widely used in large companies - they represent probably the
most common form of software reuse.
 The generic core is adapted by including modules and by incorporating
knowledge of business processes and rules.

05/12/2024 Chapter 15 Software reuse 49


The architecture of an ERP system

05/12/2024 Chapter 15 Software reuse 50


ERP architecture

 A number of modules to support different business functions.


 A defined set of business processes, associated with each module, which
relate to activities in that module.
 A common database that maintains information about all related business
functions.
 A set of business rules that apply to all data in the database.

05/12/2024 Chapter 15 Software reuse 51


ERP configuration

 Selecting the required functionality from the system.


 Establishing a data model that defines how the organization’s data will be structured
in the system database.
 Defining business rules that apply to that data.
 Defining the expected interactions with external systems.
 Designing the input forms and the output reports generated by the system.
 Designing new business processes that conform to the underlying process model
supported by the system.
 Setting parameters that define how the system is deployed on its underlying
platform.

05/12/2024 Chapter 15 Software reuse 52


Integrated application systems

 Integrated application systems are applications that include two or more


application system products and/or legacy application systems.
 You may use this approach when there is no single application system that
meets all of your needs or when you wish to integrate a new application
system with systems that you already use.

05/12/2024 Chapter 15 Software reuse 53


Design choices

 Which individual application systems offer the most appropriate functionality?


 Typically, there will be several application system products available, which can be
combined in different ways.
 How will data be exchanged?
 Different products normally use unique data structures and formats. You have to write
adaptors that convert from one representation to another.
 What features of a product will actually be used?
 Individual application systems may include more functionality than you need and
functionality may be duplicated across different products.

05/12/2024 Chapter 15 Software reuse 54


An integrated procurement system

05/12/2024 Chapter 15 Software reuse 55


Service-oriented interfaces

 Application system integration can be simplified if a service-oriented


approach is used.
 A service-oriented approach means allowing access to the application
system’s functionality through a standard service interface, with a service for
each discrete unit of functionality.
 Some applications may offer a service interface but, sometimes, this service
interface has to be implemented by the system integrator. You have to
program a wrapper that hides the application and provides externally visible
services.

05/12/2024 Chapter 15 Software reuse 56


Application wrapping

05/12/2024 Chapter 15 Software reuse 57


Application system integration problems

 Lack of control over functionality and performance


 Application systems may be less effective than they appear
 Problems with application system inter-operability
 Different application systems may make different assumptions that means integration
is difficult
 No control over system evolution
 Application system vendors not system users control evolution
 Support from system vendors
 Application system vendors may not offer support over the lifetime of the product

05/12/2024 Chapter 15 Software reuse 58

You might also like

pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy