Chapter 2.3 - Reuse Flashcards

1
Q

What is the main goal of software reuse?

A

To avoid reinventing the wheel by reusing existing solutions in multiple projects.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

How does software architecture support reuse?

A

Through clearly defined interfaces, separation of concerns, and low coupling.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

Name some common approaches that focus on reusability.

A

Libraries, frameworks, Service-Oriented Architecture (SOA), and Component-Based Architectures.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

Why does reuse often fail in practice?

A

It is often done at a small scale, unsystematically, and without considering non-functional requirements.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

What is the “Not Invented Here” syndrome?

A

A resistance to using external solutions due to a preference for in-house development.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

What is the trade-off between flexibility and stability in reusable components?

A

Too much flexibility leads to expensive adaptations, while too little limits reusability.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

What is ad-hoc reuse?

A

Reuse of artifacts that were not originally designed for reuse (e.g., copy-pasting code).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Why is ad-hoc reuse problematic?

A

It leads to high maintenance costs due to inconsistent and unstructured code duplication.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

What is structured reuse?

A

Systematic planning and development of reusable artifacts, often seen in software product lines.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

What is variability in software reuse?

A

The ability of software to adapt to different requirements or contexts.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

What is the difference between external and internal variability?

A

External variability is visible to customers, while internal variability is hidden (e.g., different communication protocols).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

What is a variation point?

A

A place where the system can be customized or configured.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

What are variants?

A

Specific implementations of a variation point (e.g., different authentication methods).

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

What is Software Product Line Engineering (PLE)?

A

A proactive approach to reuse, focusing on developing reusable core assets and customizing them for different applications.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

What are the two main processes in PLE?

A

Domain Engineering – Defines commonalities and variabilities.
Application Engineering – Customizes products based on the reusable assets.

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

What are the benefits of PLE?

A

Reduces costs, improves time-to-market, and enhances quality by managing variability systematically.

17
Q

What is an example of PLE success?

A

Nokia increased the number of phone models from 4 to 25 using PLE.

18
Q

What is scoping in PLE?

A

The process of defining what should be included in the product line based on economic and market factors.

19
Q

What are the key factors considered in scoping?

A

Products - what is their market
domains - what problems do we solve?,
features - what is easy, what is risky?
assets - what is there already, what needs to be reimplemented?

Think of cars, planes, phones, etc. e.g they all need a navigation service that reads their position etc but everyone might need something more special with similar core

20
Q

What is a software framework?

A

A reusable set of classes that provides a common structure for solving related problems.

21
Q

What is the Inversion of Control (IoC) principle in frameworks?

A

The framework calls the user’s code instead of the user calling framework functions (Hollywood principle: “Don’t call us, we’ll call you”).

22
Q

What is the difference between a library and a framework?

A

Library: The application controls when to call it.
Framework: The framework controls execution flow and calls the application code.

23
Q

What is a reference architecture?

A

A blueprint that defines the best practices, components, and interactions for a specific domain.

24
Q

What are some examples of reference architectures?

A

Database-centric (e.g., data warehouses)
Service-oriented (e.g., microservices, REST)
Component-based (e.g., Spring, .NET)

25
Q

What are the differences between ad-hoc reuse and structured reuse?

A

Reuse of existing artifacts without prior planning vs Planned, systematic reuse with design considerations
E.g Copy-pasting code from one project to another vs creating Software product lines, frameworks, configurable software
Problems

26
Q

What is an example of internal vs. external variability?

A

Internal Variability - Hidden from the user, used for technical improvements. E.g a software system supporting two network protocols but automatically selecting the best one.

External Variability - Visible to the customer, offers customization options. E.g a user choosing between fingerprint, PIN, or face recognition for authentication